/* =========================================================
   PH Arquiteto - proposta de site
   Sistema: concreto + grafite + sol (laranja da marca)
   Tipografia: Jost (linhagem Futura, eco do concretismo)
   Raios: midia e cards 14px (casca 20px), interativos em pilula,
   campos de formulario 12px.
   Camadas (z-index): nav 50, menu 60, abertura 80, granulado 90.
   ========================================================= */

@font-face {
  font-family: "Jost";
  src: url("../fonts/jost-latin-var.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Jost";
  src: url("../fonts/jost-latin-ext-var.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Tokens ---------- */
:root {
  color-scheme: light;
  --bg: #E8E7E2;          /* concreto claro */
  --bg-2: #DFDED8;
  --bg-3: #D3D1CA;
  --ink: #15191E;         /* grafite azulado */
  --ink-2: #4A5058;
  --line: rgb(21 25 30 / 0.13);
  --line-strong: rgb(21 25 30 / 0.3);
  --accent: #D9622B;      /* sol */
  --accent-text: #A9461A;
  --on-accent: #15191E;
  --error: #B42318;
  --glass: rgb(232 231 226 / 0.72);
  --highlight: rgb(255 255 255 / 0.55);
  --shadow: 0 40px 90px -50px rgb(21 25 30 / 0.45);
  --media-ink: #F3F2EE;
  --media-dark: rgb(9 12 15);

  --font: "Jost", "Futura", "Century Gothic", system-ui, sans-serif;
  --step-hero: clamp(2.85rem, 1.1rem + 5.6vw, 7rem);
  --step-h2: clamp(2.3rem, 1.25rem + 3.3vw, 4.75rem);
  --step-manifesto: clamp(1.7rem, 0.95rem + 2.75vw, 3.85rem);
  --step-h3: clamp(1.3rem, 1.1rem + 0.7vw, 1.85rem);
  --step-lead: clamp(1.06rem, 1rem + 0.3vw, 1.25rem);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-io: cubic-bezier(0.65, 0, 0.35, 1);
  --radius: 14px;
  --radius-shell: 20px;
  --radius-field: 12px;
  --pad-x: clamp(16px, 4.2vw, 64px);
  --nav-h: 76px;
  --space-section: clamp(104px, 15vh, 190px);

  --z-nav: 50;
  --z-menu: 60;
  --z-intro: 80;
  --z-grain: 90;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0E141A;        /* noite */
    --bg-2: #141B23;
    --bg-3: #1C252F;
    --ink: #E8E7E2;
    --ink-2: #A3ABB4;
    --line: rgb(232 231 226 / 0.12);
    --line-strong: rgb(232 231 226 / 0.28);
    --accent: #EE7A3F;
    --accent-text: #EE7A3F;
    --on-accent: #0E141A;
    --error: #FF8A80;
    --glass: rgb(14 20 26 / 0.62);
    --highlight: rgb(255 255 255 / 0.05);
    --shadow: 0 40px 90px -50px rgb(0 0 0 / 0.8);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0E141A;
  --bg-2: #141B23;
  --bg-3: #1C252F;
  --ink: #E8E7E2;
  --ink-2: #A3ABB4;
  --line: rgb(232 231 226 / 0.12);
  --line-strong: rgb(232 231 226 / 0.28);
  --accent: #EE7A3F;
  --accent-text: #EE7A3F;
  --on-accent: #0E141A;
  --error: #FF8A80;
  --glass: rgb(14 20 26 / 0.62);
  --highlight: rgb(255 255 255 / 0.05);
  --shadow: 0 40px 90px -50px rgb(0 0 0 / 0.8);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
}
html.lenis, html.lenis body { height: auto; }
.lenis:not(.lenis-autoToggle).lenis-stopped { overflow: clip; }
.lenis [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-smooth iframe { pointer-events: none; }

@media (prefers-reduced-motion: no-preference) {
  html:not(.lenis) { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  transition: background-color 0.5s var(--ease-out), color 0.5s var(--ease-out);
}

/* Granulado fixo, sem custo de repintura no scroll */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: var(--z-grain);
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

main { overflow-x: clip; }
img, video, svg { display: block; max-width: 100%; }
video { object-fit: cover; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; margin: 0; cursor: pointer; }
h1, h2, h3, p, figure, dl, dd { margin: 0; }
::selection { background: var(--accent); color: var(--on-accent); }

[hidden] { display: none !important; }
[tabindex="-1"]:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}
.skip-link {
  position: fixed;
  top: 12px; left: 12px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  transform: translateY(-160%);
  transition: transform 0.4s var(--ease-out);
}
.skip-link:focus-visible { transform: none; }

.wrap {
  width: 100%;
  max-width: 1440px;
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

.icon { width: 1.15em; height: 1.15em; flex: none; fill: currentColor; }

/* ---------- Tipografia de secao ---------- */
.section-title {
  font-size: var(--step-h2);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.032em;
  max-width: 15ch;
  text-wrap: balance;
}
.section-lead {
  margin-top: 22px;
  max-width: 44ch;
  color: var(--ink-2);
  font-size: var(--step-lead);
  line-height: 1.55;
}

/* ---------- Marca ---------- */
.mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1.5px solid currentColor;
  border-radius: 3px;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1;
}
.mark--xl {
  width: 92px;
  height: 92px;
  border-width: 2px;
  font-size: 2rem;
  font-weight: 400;
}

/* ---------- Botoes ---------- */
.btn {
  --btn-h: 54px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  height: var(--btn-h);
  padding: 0 7px 0 24px;
  border-radius: 999px;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: -0.005em;
  white-space: nowrap;
  transition: transform 0.6s var(--ease-out), background-color 0.4s var(--ease-out), color 0.4s var(--ease-out), border-color 0.4s var(--ease-out);
}
.btn:active { transform: scale(0.98); }
.btn__icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  transition: transform 0.6s var(--ease-out);
}
.btn__icon .icon { width: 18px; height: 18px; }
.btn:hover .btn__icon { transform: translate(2px, -2px) scale(1.06); }

.btn--solid { background: var(--ink); color: var(--bg); }
.btn--solid .btn__icon { background: var(--accent); color: var(--on-accent); }
.btn--solid:hover { background: color-mix(in srgb, var(--ink) 88%, var(--accent)); }

.btn--accent { background: var(--accent); color: #15191E; }
.btn--accent .btn__icon { background: #15191E; color: #F3F2EE; }
.btn--accent:hover { background: color-mix(in srgb, var(--accent) 90%, #fff); }

.btn--glass {
  padding: 0 26px;
  color: var(--media-ink);
  background: rgb(243 242 238 / 0.08);
  border: 1px solid rgb(243 242 238 / 0.42);
}
.btn--glass:hover { background: rgb(243 242 238 / 0.16); border-color: rgb(243 242 238 / 0.7); }

.btn--line {
  border: 1px solid var(--line-strong);
  color: var(--ink);
}
.btn--line .btn__icon { background: var(--bg-3); }
.btn--line:hover { border-color: var(--ink); }

.btn--sm { --btn-h: 46px; gap: 10px; padding-left: 18px; padding-right: 5px; font-size: 0.94rem; }
.btn--sm .btn__icon { width: 36px; height: 36px; }
.btn--lg { --btn-h: 60px; }

.icon-btn {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--line);
  transition: background-color 0.4s var(--ease-out), border-color 0.4s var(--ease-out), transform 0.5s var(--ease-out);
}
.icon-btn:hover { border-color: var(--line-strong); background: var(--bg-2); }
.icon-btn:active { transform: scale(0.96); }
.icon-btn .icon { width: 19px; height: 19px; }

.link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 4px;
  font-weight: 500;
  border-bottom: 1px solid var(--line-strong);
  transition: border-color 0.4s var(--ease-out), gap 0.5s var(--ease-out);
}
.link:hover { border-color: currentColor; gap: 11px; }
.link .icon { width: 16px; height: 16px; }

/* ---------- Abertura (cobogo) ---------- */
.intro { display: none; }
.is-intro .intro {
  display: block;
  position: fixed;
  inset: 0;
  z-index: var(--z-intro);
  pointer-events: none;
  background: var(--bg);
  /* se o JS falhar, a abertura some sozinha */
  animation: intro-failsafe 0s linear 6s forwards;
}
.intro.is-built { background: transparent; }
.is-intro .nav,
.is-intro .hero__toggle { opacity: 0; }
.intro__grid {
  --hole: 0%;
  position: absolute;
  display: grid;
}
.intro__cell {
  background: radial-gradient(circle closest-side, transparent var(--hole), var(--bg) calc(var(--hole) + 1.5%));
  transform: scale(1.02);
  will-change: transform;
}
.intro__mark {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--ink);
}
.intro__mark .mark { background: var(--bg); }
@keyframes intro-failsafe { to { visibility: hidden; } }

/* ---------- Navegacao ---------- */
.nav {
  position: fixed;
  top: 14px;
  left: 0;
  right: 0;
  z-index: var(--z-nav);
  padding-inline: var(--pad-x);
  pointer-events: none;
  transition: transform 0.7s var(--ease-out);
}
.nav.is-hidden { transform: translateY(calc(-100% - 20px)); }
.nav__bar {
  pointer-events: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  max-width: 1240px;
  height: 64px;
  margin-inline: auto;
  padding: 0 9px 0 16px;
  border-radius: 999px;
  background: var(--glass);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 var(--highlight), 0 18px 50px -30px rgb(9 12 15 / 0.45);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  backdrop-filter: blur(18px) saturate(150%);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
  font-size: 1.02rem;
  letter-spacing: -0.01em;
}
.nav__links {
  display: flex;
  gap: clamp(18px, 2.4vw, 36px);
  font-size: 0.97rem;
}
.nav__links a {
  position: relative;
  padding: 6px 0;
  color: var(--ink-2);
  transition: color 0.3s var(--ease-out);
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.6s var(--ease-out);
}
.nav__links a:hover,
.nav__links a.is-current { color: var(--ink); }
.nav__links a:hover::after,
.nav__links a.is-current::after { transform: scaleX(1); transform-origin: left; }
.nav__actions { display: flex; align-items: center; gap: 8px; }

.theme-toggle .icon--sun { display: none; }
[data-theme="dark"] .theme-toggle .icon--sun { display: block; }
[data-theme="dark"] .theme-toggle .icon--moon { display: none; }

.menu-toggle { display: none; position: relative; }
.menu-toggle__line {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 18px;
  height: 1.5px;
  margin-left: -9px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.6s var(--ease-out);
}
.menu-toggle__line:nth-of-type(2) { transform: translateY(-4px); }
.menu-toggle__line:nth-of-type(3) { transform: translateY(4px); }
.menu-open .menu-toggle__line:nth-of-type(2) { transform: rotate(45deg); }
.menu-open .menu-toggle__line:nth-of-type(3) { transform: rotate(-45deg); }

.menu {
  position: fixed;
  inset: 0;
  z-index: var(--z-menu);
  display: grid;
  grid-template-rows: 1fr auto;
  padding: calc(var(--nav-h) + 48px) var(--pad-x) calc(28px + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  -webkit-backdrop-filter: blur(26px);
  backdrop-filter: blur(26px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s var(--ease-out), visibility 0s linear 0.5s;
}
.menu-open .menu {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.5s var(--ease-out);
}
.menu__list { list-style: none; margin: 0; padding: 0; align-self: center; }
.menu__list a {
  display: block;
  padding: 6px 0;
  font-size: clamp(2.6rem, 12vw, 4.6rem);
  font-weight: 300;
  line-height: 1.08;
  letter-spacing: -0.035em;
  opacity: 0;
  transform: translateY(44px);
  transition: transform 0.9s var(--ease-out), opacity 0.6s var(--ease-out);
}
.menu-open .menu__list a {
  opacity: 1;
  transform: none;
  transition-delay: calc(0.12s + var(--n) * 0.07s);
}
.menu__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  align-items: end;
  color: var(--media-ink);
  overflow: clip;
  background: var(--media-dark);
}
.hero__media {
  position: absolute;
  inset: 0;
  will-change: transform;
}
.hero__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero__scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgb(9 12 15 / 0.82) 0%, rgb(9 12 15 / 0.42) 34%, rgb(9 12 15 / 0) 62%),
    linear-gradient(to right, rgb(9 12 15 / 0.38) 0%, rgb(9 12 15 / 0) 58%),
    linear-gradient(to bottom, rgb(9 12 15 / 0.32) 0%, rgb(9 12 15 / 0) 22%);
}
.hero__content {
  position: relative;
  padding-top: calc(var(--nav-h) + 48px);
  padding-bottom: clamp(32px, 7vh, 72px);
}
.motion-ok .hero__content { visibility: hidden; animation: reveal-failsafe 0s linear 5s forwards; }
@keyframes reveal-failsafe { to { visibility: visible; } }

.hero__title {
  max-width: 12.2em;
  font-size: var(--step-hero);
  font-weight: 300;
  line-height: 0.98;
  letter-spacing: -0.038em;
  text-wrap: balance;
}
.hero__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px 48px;
  margin-top: clamp(26px, 4vh, 44px);
}
.hero__lead {
  max-width: 36ch;
  font-size: var(--step-lead);
  line-height: 1.5;
  color: rgb(243 242 238 / 0.86);
}
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.hero__toggle {
  position: absolute;
  right: var(--pad-x);
  top: calc(var(--nav-h) + 34px);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 14px 0 12px;
  border-radius: 999px;
  font-size: 0.84rem;
  color: var(--media-ink);
  background: rgb(9 12 15 / 0.3);
  border: 1px solid rgb(243 242 238 / 0.24);
  transition: background-color 0.4s var(--ease-out), border-color 0.4s var(--ease-out);
}
.hero__toggle:hover { background: rgb(9 12 15 / 0.5); border-color: rgb(243 242 238 / 0.5); }
.hero .btn:focus-visible,
.hero__toggle:focus-visible { outline-color: var(--media-ink); }
.no-js .hero__toggle { display: none; }
.hero__toggle .icon { width: 15px; height: 15px; }

.line-mask { padding-bottom: 0.16em; margin-bottom: -0.16em; }

/* ---------- Sobre ---------- */
.about { padding-block: var(--space-section); }
.manifesto {
  max-width: 21em;
  font-size: var(--step-manifesto);
  font-weight: 300;
  line-height: 1.18;
  letter-spacing: -0.024em;
}
.manifesto .w { display: inline; }
.pill {
  display: inline-block;
  position: relative;
  width: 1.95em;
  height: 0.94em;
  margin: 0 0.02em;
  vertical-align: -0.1em;
  border-radius: 999px;
  overflow: hidden;
  background: var(--bg-3);
  transform-origin: 50% 60%;
}
.pill video { width: 100%; height: 100%; object-fit: cover; }

.about__grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: clamp(16px, 2vw, 32px);
  margin-top: clamp(80px, 13vh, 160px);
}
.about__figure {
  --hole: 100%;
  --cell: 54px;
  grid-column: 1 / span 7;
  grid-row: 1;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--bg-3);
  aspect-ratio: 4 / 3;
}
.about__figure img { width: 100%; height: 100%; object-fit: cover; }
.motion-ok .about__figure:not(.is-revealed) img {
  -webkit-mask-image: radial-gradient(circle farthest-corner, #000 var(--hole), transparent calc(var(--hole) + 0.6%));
  mask-image: radial-gradient(circle farthest-corner, #000 var(--hole), transparent calc(var(--hole) + 0.6%));
  -webkit-mask-size: var(--cell) var(--cell);
  mask-size: var(--cell) var(--cell);
  -webkit-mask-position: center;
  mask-position: center;
}
.about__detail {
  grid-column: 6 / span 3;
  grid-row: 2;
  margin-top: -22%;
  overflow: hidden;
  border-radius: var(--radius);
  aspect-ratio: 3 / 4;
  background: var(--bg-3);
  box-shadow: 0 0 0 10px var(--bg);
}
.about__detail img { width: 100%; height: 118%; object-fit: cover; }
.about__text {
  grid-column: 9 / span 4;
  grid-row: 1 / span 2;
  align-self: center;
  padding-top: 8%;
}
.about__title {
  font-size: var(--step-h3);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin-bottom: 18px;
}
.about__text > p { color: var(--ink-2); max-width: 38ch; }
.stats {
  display: grid;
  gap: 28px;
  margin-top: clamp(36px, 6vh, 60px);
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.stat { display: flex; flex-direction: column-reverse; gap: 4px; }
.stat dt { color: var(--ink-2); font-size: 0.97rem; }
.stat dd {
  display: flex;
  align-items: baseline;
  font-size: clamp(3rem, 2rem + 3.2vw, 5.2rem);
  font-weight: 300;
  line-height: 0.95;
  letter-spacing: -0.045em;
  font-variant-numeric: tabular-nums;
}
.stat__plus { color: var(--accent-text); margin-right: 0.04em; }
.stat__unit { font-size: 0.4em; letter-spacing: -0.01em; margin-left: 0.18em; }

/* ---------- Projetos ---------- */
.work { position: relative; }
.work__pin { position: relative; padding-block: clamp(72px, 10vh, 120px) var(--space-section); }
.work__intro { padding-inline: var(--pad-x); margin-bottom: clamp(32px, 5vh, 56px); }
.work__intro .section-lead { max-width: 30ch; }
.work__track {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-inline: var(--pad-x);
  scroll-padding-inline: var(--pad-x);
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}
.work__track::-webkit-scrollbar { display: none; }
.work-card {
  position: relative;
  flex: none;
  width: min(80vw, 440px);
  scroll-snap-align: start;
}
.work-card__hit { position: absolute; inset: 0; z-index: 2; border-radius: var(--radius); }
.work-card__hit:focus-visible { outline-offset: 6px; }
.work-card__media {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--bg-3);
  aspect-ratio: 4 / 5;
}
.work-card__parallax { position: absolute; inset: 0; }
.work-card__parallax video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.001);
  transition: transform 1.2s var(--ease-out);
}
.work-card:hover .work-card__parallax video { transform: scale(1.045); }
.work-card__info {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding-top: 16px;
}
.work-card__title {
  font-size: clamp(1.2rem, 1.05rem + 0.55vw, 1.65rem);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.015em;
}
.work-card__meta { margin-top: 3px; color: var(--ink-2); font-size: 0.95rem; }
.work-card__more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding-bottom: 3px;
  font-size: 0.9rem;
  font-weight: 500;
  white-space: nowrap;
  border-bottom: 1px solid var(--line-strong);
  transition: border-color 0.4s var(--ease-out);
}
.work-card__more .icon { width: 15px; height: 15px; transition: transform 0.6s var(--ease-out); }
.work-card:hover .work-card__more { border-color: currentColor; }
.work-card:hover .work-card__more .icon { transform: translate(2px, -2px); }
.work__outro {
  flex: none;
  width: min(80vw, 440px);
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 26px;
  padding: 28px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--bg-2);
  scroll-snap-align: start;
}
.work__outro-text {
  font-size: clamp(1.8rem, 1.2rem + 2vw, 3rem);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.03em;
  max-width: 9ch;
}
.work__progress { display: none; }

/* Sem trilho (tablet, ou desktop com movimento reduzido): grade */
@media (min-width: 768px) {
  html:not(.has-pan) .work__track {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(36px, 5vw, 56px) clamp(16px, 2vw, 28px);
    overflow: visible;
    scroll-snap-type: none;
  }
  html:not(.has-pan) .work-card,
  html:not(.has-pan) .work__outro { width: auto; }
  html:not(.has-pan) .work__outro { grid-column: 1 / -1; min-height: 220px; }
}
@media (min-width: 1024px) {
  html:not(.has-pan) .work__track { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Trilho horizontal fixado (desktop com movimento) */
@media (min-width: 1024px) {
  .has-pan .work__pin {
    height: 100vh;
    height: 100svh;
    padding: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
  }
  .has-pan .work__rail {
    --h: min(56vh, 34vw);
    display: flex;
    align-items: center;
    gap: clamp(40px, 5vw, 96px);
    width: max-content;
    padding-inline: var(--pad-x);
    padding-top: calc(var(--nav-h) * 0.55);
    will-change: transform;
  }
  .has-pan .work__intro { flex: none; width: min(30vw, 440px); padding: 0; margin: 0; }
  .has-pan .work__track {
    overflow: visible;
    align-items: center;
    gap: clamp(36px, 3.6vw, 72px);
    padding: 0;
    scroll-snap-type: none;
  }
  .has-pan .work-card { --card-h: var(--h); width: auto; }
  .has-pan .work-card__media {
    aspect-ratio: auto;
    height: var(--card-h);
    width: calc(var(--card-h) * var(--ar, 1.4));
  }
  .has-pan .work-card--l { --ar: 1.46; }
  .has-pan .work-card--p { --ar: 0.8; }
  .has-pan .work-card--m { --ar: 1.12; --card-h: calc(var(--h) * 0.84); }
  .has-pan .work-card--low { margin-top: 13vh; }
  .has-pan .work-card--high { margin-bottom: 13vh; }
  .has-pan .work-card__parallax { inset: 0 -8%; }
  .has-pan .work__outro {
    width: 30vw;
    min-height: calc(var(--h) * 0.84);
    margin-left: 2vw;
    padding: clamp(28px, 3vw, 48px);
  }
  .has-pan .work__progress {
    display: block;
    position: absolute;
    left: var(--pad-x);
    right: var(--pad-x);
    bottom: clamp(24px, 4vh, 40px);
    height: 1px;
    background: var(--ink);
    transform: scaleX(0);
    transform-origin: left;
  }
}

/* ---------- Servicos ---------- */
.services { padding-block: var(--space-section); }
.services__head { margin-bottom: clamp(40px, 7vh, 80px); }
.svc { display: grid; gap: 14px; }
.svc__item {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  min-height: 420px;
  border-radius: var(--radius);
  background: var(--bg-3);
  color: var(--media-ink);
}
.svc__media { position: absolute; inset: 0; z-index: -2; }
.svc__media video { width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); transition: transform 1.4s var(--ease-out); }
.svc__item.is-active .svc__media video { transform: scale(1); }
.svc__shade {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to top, rgb(9 12 15 / 0.86) 0%, rgb(9 12 15 / 0.3) 52%, rgb(9 12 15 / 0.18) 100%);
}
.svc__shade::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgb(9 12 15 / 0.42);
  opacity: 0;
  transition: opacity 0.8s var(--ease-out);
}
.svc__content {
  position: absolute;
  inset: auto 0 0 0;
  padding: clamp(22px, 2.3vw, 34px);
  pointer-events: none;
}
.svc__title {
  font-size: clamp(1.35rem, 1.05rem + 0.9vw, 2rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.02em;
  max-width: 13ch;
}
.svc__body { max-width: 38ch; margin-top: 12px; color: rgb(243 242 238 / 0.86); font-size: 1rem; line-height: 1.5; }
.svc__trigger { display: none; }

@media (min-width: 900px) {
  .svc { display: flex; gap: 12px; height: clamp(520px, 74vh, 760px); }
  .svc__item {
    flex: 1 1 0;
    min-width: 0;
    min-height: 0;
    transition: flex-grow 1s var(--ease-out);
  }
  .svc__item.is-active { flex-grow: 3; }
  .svc__item:not(.is-active) .svc__shade::after { opacity: 1; }
  .svc__body {
    width: 38ch;
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.4s var(--ease-out), transform 0.8s var(--ease-out);
  }
  .svc__item.is-active .svc__body {
    opacity: 1;
    transform: none;
    transition-delay: 0.32s;
  }
  .svc__trigger {
    display: block;
    position: absolute;
    inset: 0;
    z-index: 2;
    border-radius: var(--radius);
  }
  .svc__trigger:focus-visible { outline-offset: -4px; }
}

/* ---------- Processo ---------- */
.process { padding-block: var(--space-section) calc(var(--space-section) * 0.7); }
.process__head { margin-bottom: clamp(56px, 9vh, 104px); }
.process__title { max-width: 17ch; }
.hl {
  padding: 0 0.08em;
  color: var(--on-accent);
  background-image: linear-gradient(var(--accent), var(--accent));
  background-repeat: no-repeat;
  background-position: 0 0.08em;
  background-size: 100% 0.98em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  transition: background-size 1.2s var(--ease-out), color 0.6s var(--ease-out);
}
.motion-ok .hl:not(.is-in) { background-size: 0% 0.98em; color: inherit; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 5vh; }
.step { position: relative; }
.step__shell {
  padding: 8px;
  border-radius: calc(var(--radius-shell) + 6px);
  background: var(--bg-2);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  transform-origin: 50% 0;
  will-change: transform;
}
.step__card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(20px, 3vw, 48px);
  min-height: min(62vh, 580px);
  padding: clamp(20px, 2.4vw, 36px);
  border-radius: var(--radius-shell);
  background: var(--bg);
  box-shadow: inset 0 1px 0 var(--highlight);
  overflow: hidden;
}
.step__text { display: flex; flex-direction: column; justify-content: space-between; gap: 32px; }
.step__num {
  font-size: clamp(3.4rem, 2rem + 4vw, 6.2rem);
  font-weight: 300;
  line-height: 0.9;
  letter-spacing: -0.05em;
  color: var(--accent-text);
}
.step__title {
  font-size: var(--step-h3);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.018em;
  margin-bottom: 12px;
}
.step__text p { color: var(--ink-2); max-width: 34ch; }
.step__media {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--radius) - 2px);
  background: var(--bg-3);
  min-height: 240px;
}
.step__media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.step__dim {
  position: absolute;
  inset: 0;
  background: var(--bg);
  opacity: 0;
  pointer-events: none;
}

/* ---------- Avaliacoes ---------- */
.rating {
  position: relative;
  isolation: isolate;
  overflow: clip;
  display: grid;
  align-items: end;
  min-height: 80vh;
  min-height: 80svh;
  padding-block: var(--space-section) clamp(48px, 9vh, 96px);
}
.rating__media { position: absolute; inset: 0; z-index: -2; }
.rating__media video { width: 100%; height: 100%; object-fit: cover; }
.rating::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(to bottom, var(--bg) 0%, color-mix(in srgb, var(--bg) 30%, transparent) 26%, color-mix(in srgb, var(--bg) 18%, transparent) 60%, color-mix(in srgb, var(--bg) 88%, transparent) 100%);
}
[data-theme="dark"] .rating::before {
  background:
    linear-gradient(to bottom, var(--bg) 0%, color-mix(in srgb, var(--bg) 62%, transparent) 26%, color-mix(in srgb, var(--bg) 55%, transparent) 60%, color-mix(in srgb, var(--bg) 92%, transparent) 100%);
}
.rating__inner {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  align-items: end;
  gap: 32px;
}
.rating__score { grid-column: 1 / span 7; }
.rating__num {
  font-size: clamp(7rem, 4rem + 17vw, 21rem);
  font-weight: 300;
  line-height: 0.78;
  letter-spacing: -0.065em;
  margin-left: -0.05em;
}
.rating__stars { display: flex; gap: 6px; margin-top: clamp(34px, 5.5vh, 60px); color: var(--accent); }
.rating__stars .icon { width: clamp(22px, 2vw, 30px); height: clamp(22px, 2vw, 30px); }
.rating__copy { grid-column: 9 / span 4; display: grid; gap: 26px; padding-bottom: 6px; }
.rating__text { font-size: var(--step-lead); line-height: 1.45; max-width: 26ch; }
.rating__links { display: grid; justify-items: start; gap: 14px; }

/* ---------- Contato ---------- */
.contact { padding-block: var(--space-section); }
.contact__grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: clamp(16px, 2vw, 32px);
  row-gap: 56px;
}
.contact__intro { grid-column: 1 / span 5; }
.contact__form { grid-column: 7 / span 6; }
.contact__list { list-style: none; margin: clamp(36px, 6vh, 56px) 0 0; padding: 0; display: grid; gap: 22px; }
.contact__list li { display: flex; gap: 16px; align-items: flex-start; }
.contact__icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
}
.contact__icon .icon { width: 19px; height: 19px; }
.contact__label { display: block; font-size: 0.88rem; color: var(--ink-2); margin-bottom: 2px; }
.contact__value { font-weight: 500; line-height: 1.45; border-bottom: 1px solid transparent; transition: border-color 0.4s var(--ease-out); }
.contact__value:hover { border-color: currentColor; }
.contact__figure {
  margin-top: clamp(40px, 7vh, 72px);
  overflow: hidden;
  border-radius: var(--radius);
  aspect-ratio: 16 / 10;
  background: var(--bg-3);
}
.contact__figure img { width: 100%; height: 100%; object-fit: cover; }

/* Casca dupla: bandeja externa + nucleo interno */
.shell {
  padding: 8px;
  border-radius: calc(var(--radius-shell) + 8px);
  background: var(--bg-2);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.shell__core {
  border-radius: var(--radius-shell);
  background: var(--bg);
  box-shadow: inset 0 1px 0 var(--highlight);
}

.form { display: grid; gap: 26px; padding: clamp(22px, 3.2vw, 46px); }
.field { display: grid; gap: 9px; min-width: 0; margin: 0; padding: 0; border: 0; }
.field__label { padding: 0; font-weight: 500; font-size: 0.98rem; }
.field__opt { color: var(--ink-2); font-weight: 400; }
.field__input {
  width: 100%;
  height: 54px;
  padding: 0 16px;
  border-radius: var(--radius-field);
  border: 1px solid var(--line-strong);
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  transition: border-color 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}
.field__input--area { height: auto; min-height: 128px; padding: 14px 16px; resize: vertical; line-height: 1.5; }
.field__input::placeholder { color: var(--ink-2); opacity: 1; }
.field__input:hover { border-color: color-mix(in srgb, var(--ink) 55%, transparent); }
.field__input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 30%, transparent); }
.field__input[aria-invalid="true"] { border-color: var(--error); }
.field__error { color: var(--error); font-size: 0.92rem; font-weight: 500; }

.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.chip span {
  display: inline-flex;
  align-items: center;
  height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  font-size: 0.96rem;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.35s var(--ease-out), color 0.35s var(--ease-out), border-color 0.35s var(--ease-out), transform 0.4s var(--ease-out);
}
.chip span:hover { border-color: var(--ink); }
.chip span:active { transform: scale(0.97); }
.chip input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 3px; }
.field.is-invalid .chip span { border-color: var(--error); }

.form__submit { justify-self: start; }
.form__note { color: var(--ink-2); font-size: 0.92rem; margin-top: -10px; }
.form__status:empty { display: none; }
.form__status {
  padding: 14px 16px;
  border-radius: var(--radius-field);
  background: var(--bg-2);
  border: 1px solid var(--line);
  font-size: 0.97rem;
}
.form__status a { font-weight: 500; border-bottom: 1px solid currentColor; }

/* ---------- Rodape ---------- */
.footer { padding-top: clamp(64px, 10vh, 120px); overflow: clip; }
.footer__word {
  font-size: clamp(3rem, 20vw, 18rem);
  font-weight: 300;
  line-height: 0.86;
  letter-spacing: -0.058em;
  white-space: nowrap;
  padding-bottom: 0.08em;
  margin-left: -0.04em;
}
.footer__word .char-mask { padding: 0.1em 0 0.24em; margin: -0.1em 0 -0.24em; }
.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 32px;
  margin-top: clamp(28px, 5vh, 48px);
  padding-block: 26px calc(30px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 0.93rem;
}
.footer__links { display: flex; flex-wrap: wrap; gap: 22px; color: var(--ink); }

/* ---------- Detalhe do projeto ---------- */
.case {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: var(--bg);
  color: var(--ink);
}
html.case-open { overflow: hidden; }
.case::backdrop { background: rgb(9 12 15 / 0.55); }
.case__scroll { height: 100%; overflow-y: auto; overscroll-behavior: contain; }
.case__bar {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px var(--pad-x);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.case__crumb { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; color: var(--ink-2); font-size: 0.95rem; }
.case__tag {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 11px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--ink);
  font-size: 0.82rem;
}
.case__hero {
  margin: clamp(16px, 3vh, 28px) var(--pad-x) 0;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--bg-3);
  height: min(72vh, calc((100vw - 2 * var(--pad-x)) * 0.5625));
}
.case__hero video { width: 100%; height: 100%; object-fit: cover; }
.case__body {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 32px clamp(16px, 2vw, 32px);
  padding-block: clamp(40px, 7vh, 80px);
}
.case__title {
  grid-column: 1 / span 6;
  font-size: var(--step-h2);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.032em;
}
.case__info { grid-column: 8 / span 5; display: grid; gap: 32px; align-content: start; }
.case__meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 24px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}
.case__meta dt { color: var(--ink-2); font-size: 0.9rem; }
.case__meta dd { font-size: 1.12rem; font-weight: 500; }
.case__desc { color: var(--ink-2); font-size: var(--step-lead); line-height: 1.55; }
.case__gallery {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 12px;
}
.case__gallery figure { overflow: hidden; border-radius: var(--radius); background: var(--bg-3); grid-column: span 12; aspect-ratio: 16 / 9; }
.case__gallery figure:nth-child(4n + 2) { grid-column: span 7; aspect-ratio: 4 / 3.2; }
.case__gallery figure:nth-child(4n + 3) { grid-column: span 5; aspect-ratio: 4 / 4.48; }
.case__gallery img { width: 100%; height: 100%; object-fit: cover; }
.case__next { padding-block: clamp(48px, 9vh, 96px) clamp(56px, 10vh, 112px); }
.case__next-btn {
  display: grid;
  gap: 8px;
  width: 100%;
  padding-top: 28px;
  text-align: left;
  border-top: 1px solid var(--line-strong);
}
.case__next-label { color: var(--ink-2); font-size: 0.95rem; }
.case__next-title {
  display: inline-flex;
  align-items: center;
  gap: 0.3em;
  font-size: var(--step-h2);
  font-weight: 300;
  line-height: 1.04;
  letter-spacing: -0.032em;
}
.case__next-title .icon { width: 0.7em; height: 0.7em; transition: transform 0.7s var(--ease-out); }
.case__next-btn:hover .case__next-title .icon { transform: translateX(0.18em); }

/* ---------- Página 404 ---------- */
.notfound {
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 28px;
  padding-block: 64px;
}
.notfound .section-lead { margin-top: 0; }

/* ---------- Responsivo ---------- */
@media (max-width: 1099px) {
  .nav__links { display: none; }
  .menu-toggle { display: grid; }
}
@media (min-width: 1100px) {
  .menu { display: none; }
}

@media (max-width: 899px) {
  :root { --nav-h: 68px; }
  .nav { top: 10px; }
  .nav__bar { height: 58px; padding-left: 14px; }
  .nav__cta { display: none; }
  .hero__toggle { top: auto; bottom: clamp(32px, 7vh, 72px); right: var(--pad-x); }
  .hero__row { margin-right: 0; }
  .hero__content { padding-bottom: calc(clamp(32px, 7vh, 72px) + 56px); }

  .about__grid { display: block; }
  .about__figure { aspect-ratio: 4 / 3; }
  .about__detail { display: none; }
  .about__text { padding-top: 40px; }

  .step__card { grid-template-columns: 1fr; min-height: 0; gap: 18px; }
  .step__media { order: -1; aspect-ratio: 16 / 10; min-height: 0; }
  .step__text { gap: 18px; }
  .step__num { font-size: 2.6rem; }

  .rating__score, .rating__copy { grid-column: 1 / -1; }
  .rating__copy { margin-top: 12px; }

  .contact__intro, .contact__form { grid-column: 1 / -1; }
  .contact__figure { display: none; }
  .form__submit { justify-self: stretch; justify-content: space-between; }

  .case__title, .case__info { grid-column: 1 / -1; }
  .case__gallery figure:nth-child(n) { grid-column: span 12; aspect-ratio: 4 / 3; }
}

@media (max-width: 599px) {
  .brand__name { display: none; }
  .hero__ctas { width: 100%; }
  .hero__ctas .btn { flex: 1 1 auto; justify-content: space-between; }
  .hero__ctas .btn--glass { justify-content: center; }
  .stats { grid-template-columns: 1fr; }
}

/* ---------- Movimento reduzido ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
