:root {
  --me: "Libre Baskerville", serif;
  --projects: "Playwrite NZ Basic", serif;
  --job: "Merriweather", serif;
}
html, body {
  height: 100%;
  margin: 0;
}
.logo_bubble {
    position: fixed;
    opacity: 0;
    top: 20px;
    left: 18rem;
    flex-direction: row;
    z-index: 10;
    width: auto;
    border: 2px solid black;
    border-radius: 25px;
    padding: 0.5rem;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    background-color: #e2e3db;
}
.logo_bubble.active {
    opacity: 1;
    transform: translateY(0);
}
.view {
  position: fixed;      /* key: overlays the entire page */
  inset: 0;             /* top/right/bottom/left: 0 */
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 350ms ease, transform 350ms ease;
  background: white;    /* prevents “blank transparency” */
  overflow-y: auto;     /* ✅ allow scrolling */
  overflow-x: hidden;
  z-index: 1;
}

.view.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
  z-index: 10;
}
.view.is-hidden {
  display: none;
}
#projectFrame {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}


.main_section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    padding: 1rem;
    min-height: 120vh;
}
.fil-stack {           /* (also: your HTML says fil-stack; pick one name) */
  width: 100%;
  max-width: 32.5rem;
}
.tab-instruction {
    padding: 0.5rem;
    display: none;
}
.file-card {
  position: relative;
  width: min(15rem, 100%);
  height: 6rem;
  background: #fff;
  border: 2px solid #d7d7d7;
  border-radius: 18px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.12);
  overflow: visible; /* important so the tab can sit “outside” */
  transition: transform 350ms ease, width 350ms ease, box-shadow 350ms ease, background-color 350ms ease;
  will-change: transform;
  transform-origin: left center;
  transition-delay: 0ms;
  transition-property: transform, width, box-shadow;
}
.no-video{
  display: none;
}
#portfolioView { z-index: 2; }
#projectView { z-index: 1; }

#projectView.active { z-index: 3; }

.file-tab {
  position: absolute;
  top: -22px;
  left: 28px;
  padding: 7px 12px;
  background: #eee8dc;
  border: 2px solid #d7d7d7;
  border-bottom: none;
  border-radius: 18px 18px 14px 14px;
  font-weight: 600;
  line-height: 1;
  font-size: 0.8rem;
}

/* This creates the “cut-in” curve where the tab meets the card */
.file-tab::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -14px;
  height: 14px;
  background: #fff; /* same as card background */
  border-bottom-left-radius: 18px;
  border-bottom-right-radius: 18px;
}
.bubble {
  position: absolute;
  top: 10%;
  left: 40%;
  border: 2px solid #d7d7d7;
  border-radius: 18px;
  padding: 7px;
  transform: translateY(-50%) scale(0.1);
  background-color: #edede7;
  font-size: 0.85rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none; /* so hover stays on the card */
  transition: opacity 200ms ease, transform 200ms ease;
  transform-origin: left center;
}
.file-card:hover .bubble {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(6px) scale(1); 
}
.file-body {
  padding: 23px 14px 14px; /* top padding accounts for the tab */
}

.file-body h3 {
  margin: 0 0 5px;
  font-size: 0.8rem;
  font-family: var(--job);
}

.file-body p {
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 300ms ease, transform 300ms ease;
  font-family: var(--projects);
  font-size: 0.8rem;
}
.file-card:nth-child(1) { transform: translate(0rem, 20rem);   z-index: 4; }
.file-card:nth-child(2) { transform: translate(2rem, 10rem);   z-index: 3; }
.file-card:nth-child(3) { transform: translate(4rem, 0rem);   z-index: 2; }
.file-card:nth-child(4) { transform: translate(6rem, -10rem);   z-index: 1; }
.file-card:nth-child(5) { transform: translate(8rem, -20rem);   z-index: 0; }

.fil-stack:hover .file-card {
  width: min(22rem, 100%);
  box-shadow: 0 18px 40px rgba(0,0,0,0.16);
}

.fil-stack:hover{
  cursor: pointer;
}
.fil-stack:hover .file-card:nth-child(1){ transform: translate(0, 0) scale(1.06); }
.fil-stack:hover .file-card:nth-child(2){ transform: translate(0, 3rem) scale(1.06); }
.fil-stack:hover .file-card:nth-child(3){ transform: translate(0, 6rem) scale(1.06); }
.fil-stack:hover .file-card:nth-child(4){ transform: translate(0, 9rem) scale(1.06); }
.fil-stack:hover .file-card:nth-child(5){ transform: translate(0, 12rem) scale(1.06); }
/*animation ----IT DOES NOT ANIMATE*/
.file-card:nth-child(1) { transition-delay: 0ms; }
.file-card:nth-child(2) { transition-delay: 60ms; }
.file-card:nth-child(3) { transition-delay: 120ms; }
.file-card:nth-child(4) { transition-delay: 180ms; }
.file-card:nth-child(5) { transition-delay: 240ms; }

.fil-stack:hover .file-body p {
  opacity: 1;
  transform: translate(0);
  margin-left: 1rem;
}

.fil-stack:hover .file-body p, h3 {
  display: inline;
}
.cinema {
  position: relative;
  z-index: 100;
}
.instruction {
  display: none;
}
.contacts {
  display: flex;
  gap: 2rem;
  margin-top: 1rem;
}
.fa-brands {
  font-size: 24px;
  margin: 0 10px;
  color: #333;
}

.fa-brands:hover {
  cursor: pointer;
  color: #0077b5;
}
.video {
  width: 100%;
  border-radius: 10px;
  position: absolute;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.4s ease;
  transform: scale(0.98);
}
.video.visible{
  visibility: visible;
  opacity: 1;
  transform: scale(1);
}
.me {
  font-family: var(--me);
}
.description {
  font-family: var(--job);

}
.todo {
  top: 1rem;
}
.deny {
  top: 4rem;
}
.loomora{
  top: 7rem;
}
.space {
  top: 10rem;
}
.scrolling {
  top: 13rem;
}
.hero {
  position: relative;
  top: 10rem;
  left: 5rem;
  z-index: -10;
}
@media (max-width: 800px) {
  .main_section {
    grid-template-columns: 1fr!important; /* stack vertically */
    grid-template-rows: auto auto;         /* optional */
    gap: 1rem;
    height: auto;
  }
    /* reset the manual scatter positioning */
  .file-card {
    transform: none !important;
    width: 100%;
    max-width: 100%;
  }
  .no-video {
    display: block;
  }
  .fil-stack {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 2rem;
    
  }
  .file-card {
    height: 3rem;
    margin-top: 1.5rem;
  }
  .file-body {
    height: 3rem;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  .file-body h3 {
    margin: 0;
  }
  .logo_bubble{
    left: 7rem;
  }
  .file-tab::after {
    display: none;
  }
  .file-body p {
    display: none;
  }
  .file-card:hover .bubble {
    display: none;
  }
  .fil-stack:hover .file-body p {
    display: none;
  }
  .main_section {
    min-height: auto;

  }
  .hero {
  position: relative;
  top: 3rem;
  
  }
  .video {
    top: 2rem;
  }
  .instruction {
    display: block;
    margin-left: 2rem;
  }
  h3.inactive {
    display: none;
  }
  .tab-instruction.active {
    display: block;
  
  }
  .cinema {
    align-items: center;
    height: auto;
    display: flex;
    flex-direction: column;
  }
  .video {
    width: 100%;
    height: 70vh;
  }
  .hero {
    left: 1rem;
  }
}
