/* sections.css — стилі секцій сторінок (hero, showreel, marquee, Kontakt, кейси...). Наповнюється з етапу 2. */

/* ==========================================================
   HERO
   ========================================================== */
.hero { position: relative; overflow-x: clip; }
.hero__inner { max-width: var(--max); margin-inline: auto; padding: clamp(24px, 3.5vw, 56px) var(--gutter) clamp(40px, 5vw, 72px); }
.hero__label { margin-bottom: clamp(16px, 2.2vw, 36px); }

/* Верхній ряд: заголовок зліва, галерея карток справа (одна висота) */
.hero__top { display: grid; grid-template-columns: 58fr 42fr; align-items: stretch; }
.hero__top h1 { position: relative; z-index: 5; }
.hero-cards { position: relative; min-width: 0; }

/* Нижній ряд: напрями + тексти зліва, дії справа */
.hero__bottom { display: grid; grid-template-columns: 58fr 42fr; align-items: end; margin-top: clamp(32px, 3.4vw, 56px); gap: 24px 0; }
.hero__dirs { display: flex; flex-wrap: wrap; gap: 8px 32px; margin-bottom: clamp(20px, 2vw, 32px); }
.dir {
  position: relative; padding-bottom: 8px;
  font-size: var(--fs-label); font-weight: 500; letter-spacing: .09em;
  text-transform: uppercase; line-height: var(--lh-label); color: var(--grau);
}
.dir.is-on { color: var(--tinte); }
/* Підкреслення анімується через transform (не через розмір фону) */
.dir::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 9px;
  background: url("/assets/img/underline/u1_l.svg") no-repeat 0 100% / 100% 9px;
  transform: scaleX(0); transform-origin: left center;
  transition: transform var(--t-slow) var(--ease);
}
/* Підкреслення лише при наведенні (Софія 06.11). Активний напрям відрізняється кольором. */
@media (hover: hover) { .dir:hover::after { transform: scaleX(1); } }
.dir:hover { color: var(--tinte); }

.hero .sub { max-width: 19em; }
.hero__intro { max-width: 30em; margin-top: clamp(14px, 1.4vw, 22px); color: var(--grau); }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 16px 28px; }

@media (max-width: 820px) {
  .hero__top, .hero__bottom { grid-template-columns: 1fr; }
  /* Мобільний: картки під заголовком, не перекривають літери (заголовок завжди читається) */
  .hero-cards { height: min(86vw, 420px); margin-top: 1rem; }
  .hero__actions { justify-content: flex-start; }
  .hero__bottom { margin-top: clamp(24px, 6vw, 40px); }
}
@media (min-width: 821px) {
  .hero-cards { margin-top: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .dir::after { transition: none; }
}

/* ==========================================================
   Спільне для секцій головної
   ========================================================== */
.section { max-width: var(--max); margin-inline: auto; padding: clamp(56px, 8vw, 128px) var(--gutter); }
.section__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 32px; margin-bottom: clamp(24px, 3vw, 48px); }
.section__intro { max-width: 40em; margin-top: 12px; color: var(--grau); }
.h2--sm { font-size: clamp(2.25rem, 5.2vw, 5.5rem); }

/* Поява при скролі: ховає лише якщо є JS (клас html.js) */
.js .rv { opacity: 0; transform: translateY(30px); transition: opacity .9s var(--ease), transform .9s var(--ease); }   /* 07.11: значення прототипів (30 px / 0,9 с); SISTERS, Zine, Transformation перевизначають у своїх case-*.css */
.js .rv.d1 { transition-delay: .08s; } .js .rv.d2 { transition-delay: .16s; } .js .rv.d3 { transition-delay: .24s; }
.js .rv.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .rv { opacity: 1; transform: none; transition: none; }
}

/* ==========================================================
   SHOWREEL: повноекранна темна панель, наступна секція виїжджає поверх
   ========================================================== */
.showreel {
  position: sticky; top: 0; z-index: 0;
  display: grid; place-items: center; height: 100svh;
  background: linear-gradient(160deg, #1b1d20 0%, var(--nacht) 100%);
  color: var(--licht);
}
.showreel__ph { font-style: italic; font-weight: 500; font-size: 13px; letter-spacing: .09em; text-transform: uppercase; color: rgba(242, 238, 229, .75); }
.rise { position: relative; z-index: 1; }
@media (max-width: 820px) {
  .showreel { position: relative; height: 70svh; }   /* на мобільному ефект вимкнено */
}

/* ==========================================================
   ПРОЄКТИ (плитки + фільтр)
   ========================================================== */
.projects { box-shadow: none; }   /* 11.11: прибрано важку тінь на межі hero/проєкти (некрасива границя) */
.projects .filter { margin-bottom: clamp(20px, 2.4vw, 36px); margin-left: -14px; }
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(48px, 5vw, 80px) clamp(20px, 2.4vw, 40px); }   /* 4 колонки + повітря (рішення Софії 06.11) */
@media (max-width: 1099px) { .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.tile--wide { grid-column: 1 / -1; }
.tile--wide .tile__media { aspect-ratio: 21 / 9; }
.projects__more { margin-top: clamp(32px, 4vw, 56px); }
@media (max-width: 820px) {
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tile--wide .tile__media { aspect-ratio: 4 / 5; }
}
@media (max-width: 560px) {
  .tiles { grid-template-columns: 1fr; }
}

/* ==========================================================
   MARQUEE (біжучий рядок)
   ========================================================== */
.marquee { overflow: hidden; border-block: 1px solid rgba(17, 17, 17, .14); padding: 18px 0; }
.marquee__track { display: flex; width: max-content; animation: marq 36s linear infinite; }
.marquee__group { display: flex; flex: none; align-items: center; }
.marquee__item {
  font-family: var(--font-display); text-transform: uppercase; white-space: nowrap;
  font-size: clamp(1.75rem, 3.4vw, 3.5rem); line-height: var(--lh-display);
  padding: 0 clamp(16px, 2vw, 32px);
}
.marquee__dot { color: var(--rot); }
@keyframes marq { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .marquee__track { animation: none; width: auto; flex-wrap: wrap; padding: 0 var(--gutter); }
  .marquee__group[aria-hidden="true"], .marquee__group + .marquee__group { display: none; }
}

/* ==========================================================
   FOTO & VIDEO (кіно-блок; еталон foto-video.png: світле тло, темні кадри)
   ========================================================== */
.fv__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 32px; padding-bottom: clamp(20px, 2.4vw, 40px); border-bottom: 1px solid rgba(17, 17, 17, .22); }
.fv__note { max-width: 36em; text-align: right; }
.fv__frames { display: grid; grid-template-columns: 1.45fr .85fr 1.1fr; gap: clamp(16px, 2.6vw, 40px); align-items: start; margin-top: clamp(24px, 3vw, 48px); }
.fv__frame { position: relative; overflow: hidden; border-radius: 3px; aspect-ratio: 3 / 4; }
.fv__frame--2 { margin-top: clamp(24px, 4vw, 64px); }
@media (max-width: 820px) {
  .fv__frames { grid-template-columns: 1fr 1fr; }
  .fv__frame--1 { grid-column: 1 / -1; }
  .fv__frame--2 { margin-top: 0; }
  .fv__note { text-align: left; }
}

/* ==========================================================
   ÜBER MICH (коротко)
   ========================================================== */
.about { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 5vw, 96px); align-items: start; }
.about__portrait { aspect-ratio: 4 / 5; border-radius: 3px; overflow: hidden; position: relative; }
/* Обрізка зверху (менше червоного тла): фото вище за рамку, нижній край вирівняний. Міняти --portrait-zoom у tokens.css */
.about__portrait img { display: block; position: absolute; left: 0; bottom: 0; width: 100%; height: var(--portrait-zoom); object-fit: cover; object-position: 50% 100%; }
.about__text > * + * { margin-top: clamp(16px, 1.6vw, 24px); }
.about__text p.lead { max-width: 40em; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 10px 24px; max-width: 44em; margin-top: clamp(24px, 3vw, 40px); }
.facts dt { font-size: var(--fs-label); font-weight: 500; letter-spacing: .09em; text-transform: uppercase; color: var(--grau); padding-top: 3px; }
.facts dd { margin: 0; }
@media (max-width: 820px) {
  .about { grid-template-columns: 1fr; }
  .about__portrait { max-width: 420px; }
}

/* ==========================================================
   KONTAKT (чорна секція, без текстури)
   ========================================================== */
.kontakt { background: var(--nacht); color: var(--licht); }
.kontakt__inner { max-width: var(--max); margin-inline: auto; padding: clamp(64px, 9vw, 150px) var(--gutter) clamp(48px, 6vw, 96px); }
.kontakt .label { color: var(--licht); }
/* v2: заголовок завжди в один рядок на всіх ширинах (мінімум 26px, щоб не переносився на 320px).
   Розмір задає клас .kontakt-h2 у chrome-slots.css (clamp(26px, 8.2vw, 170px)) */
.kontakt h2, .kontakt h1 { margin-top: clamp(12px, 1.6vw, 24px); }
/* Мобільний (рішення Софії): заголовок у 3 рядки «Lassen / Sie uns / Sprechen» (EN: Let's / talk) */
@media (max-width: 700px) {
  .kontakt h2.kontakt-h2, .kontakt h1.kontakt-h2 { font-size: clamp(3rem, 17vw, 6.5rem); white-space: normal; }
  .kline { display: block; }
}
.kontakt__text { max-width: 40em; margin-top: clamp(20px, 2.4vw, 36px); }
.kontakt__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px 40px; margin-top: clamp(28px, 3.4vw, 56px); }
.kontakt__links { display: flex; flex-wrap: wrap; gap: 12px 32px; }
.kontakt .tlink { min-height: 44px; display: inline-flex; align-items: center; }

/* ==========================================================
   СТОРІНКА /projekte/
   ========================================================== */
.pj__title { font-size: clamp(4rem, 12vw, 13rem); margin-bottom: clamp(8px, 1.4vw, 20px); }
.pj__filter { margin: clamp(20px, 2.4vw, 36px) 0 clamp(20px, 2.4vw, 36px) -14px; }
.pj__filter .filter { margin: 0; }

/* Блок «Nächstes Projekt?» */
.cnext__in { max-width: var(--max); margin-inline: auto; padding: clamp(48px, 7vw, 112px) var(--gutter); }
.cnext__link { display: block; font-family: var(--font-display); text-transform: uppercase; text-decoration: none;
  font-size: clamp(2.25rem, 7vw, 7rem); line-height: var(--lh-display); margin: 12px 0 clamp(24px, 3vw, 40px); }
.cnext__link:hover { color: var(--rot); }
.cnext__row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 32px; }

/* ==========================================================
   КЕЙС-СТОРІНКА
   ========================================================== */
.case__in, .csec__in { max-width: var(--max); margin-inline: auto; padding: 0 var(--gutter); }
.case__head { padding: clamp(32px, 5vw, 72px) 0 clamp(32px, 4vw, 64px); }
.case__back { margin-bottom: clamp(16px, 2vw, 32px); }
.case__title { font-size: clamp(3rem, 9vw, 9rem); max-width: 16ch; }
.case__intro { max-width: 40em; margin-top: clamp(20px, 2.4vw, 32px); font-size: clamp(1.1rem, 1.5vw, 1.4rem); line-height: var(--lh-sub); font-weight: 300; }
.case__meta { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px 32px; margin-top: clamp(28px, 3.4vw, 56px); padding-top: 20px; border-top: 1px solid rgba(17, 17, 17, .22); }
.case__meta dt { font-size: var(--fs-label); font-weight: 500; letter-spacing: .09em; text-transform: uppercase; color: var(--grau); margin-bottom: 6px; line-height: var(--lh-label); }
.case__meta dd { margin: 0; }
.case__hero { aspect-ratio: 16 / 9; max-height: 80svh; width: 100%; }
.csec { padding: clamp(40px, 6vw, 104px) 0; }
.csec__in { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: 16px clamp(24px, 4vw, 64px); align-items: start; }
.csec__label { font-family: var(--font-text); font-size: var(--fs-label); font-weight: 500; letter-spacing: .09em; line-height: var(--lh-label); color: var(--grau); padding-top: 6px; }
.csec__body { min-width: 0; }
.csec__body > p, .csec__body > ul { max-width: 56ch; }
.csec__body > * + * { margin-top: 18px; }
.csec__body ul { padding-left: 1.2em; }
.csec__body li + li { margin-top: 10px; }
.case__frames { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(12px, 2vw, 28px); margin-top: clamp(24px, 3vw, 48px); max-width: none; }
.cframe { aspect-ratio: 4 / 5; border-radius: 3px; overflow: hidden; }
.case__wide { aspect-ratio: 16 / 9; border-radius: 3px; overflow: hidden; margin-top: clamp(24px, 3vw, 48px); max-width: none; }
.csec--dark { background: var(--nacht); color: var(--licht); }
.csec--dark .csec__label { color: rgba(242, 238, 229, .75); }
@media (max-width: 820px) {
  .case__meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .csec__in { grid-template-columns: 1fr; }
  .case__frames { grid-template-columns: 1fr 1fr; }
  .cframe:first-child { grid-column: 1 / -1; }
}

/* ==========================================================
   ЛАЙТБОКС (<dialog>) і відео «two-click»
   ========================================================== */
.lightbox { border: 0; padding: 0; background: var(--nacht); color: var(--licht); width: min(1100px, 94vw); max-height: 92svh; border-radius: 3px; }
.lightbox::backdrop { background: rgba(11, 11, 11, .8); }
.lightbox__inner { display: grid; gap: 12px; padding: 16px; }
.lightbox__img { max-width: none; width: 100%; max-height: 74svh; object-fit: contain; }
.lightbox__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.lightbox__btn { min-width: 44px; min-height: 44px; border: 0; border-radius: 999px; background: var(--licht); color: var(--tinte); cursor: pointer; font-size: 18px; }
.lightbox__btn:hover { background: var(--rot); color: var(--licht); }
.lightbox__cap { font-size: 14px; color: rgba(242, 238, 229, .85); }

.vembed { position: relative; aspect-ratio: 16 / 9; background: var(--nacht); border-radius: 3px; overflow: hidden; color: var(--licht); }
.vembed__poster { position: absolute; inset: 0; }
.vembed__ui { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-end; gap: 12px; padding: clamp(16px, 2vw, 28px); }
.vembed__note { font-size: 13px; line-height: 1.4; max-width: 46ch; color: rgba(242, 238, 229, .9); }
.vembed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ==========================================================
   ÜBER MICH (сторінка), KONTAKT (сторінка), правові сторінки, 404
   ========================================================== */
.about--page .about__text > * + * { margin-top: 1.1em; }
.about--page .about__text { max-width: 44em; }
.um__facts { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 5vw, 96px); padding-top: 0; }
.um__h { font-family: var(--font-text); font-weight: 500; font-size: var(--fs-label); letter-spacing: .09em; text-transform: uppercase; line-height: var(--lh-label); color: var(--grau); margin: 0 0 16px; }
.um__col > * + .um__h { margin-top: clamp(24px, 3vw, 40px); }
.um__list ul { list-style: none; padding: 0; }
.um__list li { padding: 14px 0; border-top: 1px solid rgba(17, 17, 17, .18); max-width: 52em; }
.um__act { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; margin-top: clamp(28px, 3vw, 48px); }
@media (max-width: 820px) { .um__facts { grid-template-columns: 1fr; } }

.kontakt--page { min-height: calc(100svh - var(--nav-h)); display: flex; }
.kontakt--page .kontakt__inner { width: 100%; align-self: center; }
.kontakt__hint { margin-top: clamp(20px, 2.4vw, 32px); color: rgba(242, 238, 229, .85); }
.kontakt__ort { margin-top: 12px; }

.legal { overflow-wrap: anywhere; max-width: 46rem; margin-inline: auto; padding: clamp(40px, 6vw, 96px) var(--gutter); }
.legal h1 { font-size: clamp(3rem, 7vw, 6rem); margin-bottom: clamp(20px, 3vw, 40px); }
.legal h2 { font-family: var(--font-text); font-weight: 500; font-size: 1.15rem; text-transform: none; line-height: 1.3; margin: clamp(28px, 3vw, 44px) 0 10px; }
.legal h3 { font-family: var(--font-text); font-weight: 500; font-size: var(--fs-label); letter-spacing: .09em; text-transform: uppercase; color: var(--grau); margin: 28px 0 8px; }
.legal p + p { margin-top: 1em; }
.legal a { text-underline-offset: 3px; }

.e404__in { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 96px); min-height: 60svh; align-content: center; }
.e404__col > * + * { margin-top: 20px; }
.e404__col h1 { font-size: clamp(3rem, 7vw, 7rem); }
.e404__h { font-size: clamp(2rem, 4vw, 4rem); }
@media (max-width: 820px) { .e404__in { grid-template-columns: 1fr; min-height: 0; } }

/* 06.11: заголовки блоків у кейсах (Aufgabe / Meine Rolle / Ergebnis) більші за текст */
.csec__label { font-size: clamp(22px, 1.9vw, 28px); line-height: 1.15; letter-spacing: .05em; padding-top: 2px; }

/* 09.11 аудит: Impressum, підзаголовки h2.legal__h3 мають вигляд колишніх h3; великі зони натискання посилань-завантажень на мобільному */
.legal h2.legal__h3 { font-family: var(--font-text); font-weight: 500; font-size: var(--fs-label); letter-spacing: .09em; text-transform: uppercase; color: var(--grau); margin: 28px 0 8px; line-height: 1.3; }
@media (max-width: 900px) {
  a.tlink[download], a.tlink[target="_blank"] { display: inline-block; padding-block: 11px; }
}
@media (max-width: 900px) {
  .tlink:not(p .tlink):not(li .tlink):not(.hx__act .tlink) { display: inline-block; padding-block: 11px; }
}
@media (max-width: 900px) {
  p > a.tlink:only-child { display: inline-block; padding-block: 11px; }
}

/* 11.11: картки проєктів легко «лягають» при скролі (лише opacity і невеликий зсув) */
.js .tile.rv { transform: translateY(14px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .tile.rv.d1 { transition-delay: .06s; } .js .tile.rv.d2 { transition-delay: .12s; } .js .tile.rv.d3 { transition-delay: .18s; }
.js .tile.rv.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .tile.rv { opacity: 1; transform: none; transition: none; } }
