/* ==========================================================================
   Hara Design Studio — v2 "brutal tech" claro.
   Base: cinza-claro + preto, tipografia estilo Helvetica (Inter Tight / Inter),
   letras-fantasma "HARA DSGN" ao fundo (texto liso),
   detalhes de interface técnica: índices [001], coordenadas, cruzes, relógio.
   Sem cor: só preto, branco e cinzas. Setas = SVG da marca.
   ========================================================================== */

:root {
  --bg: #F3F4F6;
  --ink: #000;
  --gray: #6E6E6E;
  --mute: #A3A5AA;
  --ghost: #E4E5E9;
  --line: #DADBDF;
  --salmon: #FF5A66;
  --pad: clamp(20px, 4.8vw, 58px);
  --f-display: "Inter Tight", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --f-text: "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { background: var(--bg); color: var(--ink); font: 400 14px/1.5 var(--f-text); overflow-x: clip; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
::selection { background: var(--ink); color: var(--bg); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
svg { stroke: currentColor; fill: none; }
/* Seta da marca (SVG) usada em todo o site */
.ar { width: .78em; height: .78em; flex: none; fill: currentColor; stroke: none; transition: translate .3s cubic-bezier(.2,.8,.2,1); }
.ar--down { rotate: 135deg; }
a:hover > .ar:not(.ar--down) { translate: 2px -2px; }

/* Cursor da marca (seta), com contorno branco para aparecer no fundo escuro */
html, a, button, [data-cursor] { cursor: url("../img/cursor.svg?v=2") 1 1, auto; }
a, button { cursor: url("../img/cursor.svg?v=2") 1 1, pointer; }

.wrap { padding-inline: var(--pad); }

/* Rótulo técnico: [001] seção */
.tag { display: inline-flex; gap: 8px; font-size: 11px; letter-spacing: .02em; color: var(--gray); font-variant-numeric: tabular-nums; }
.tag span { color: var(--ink); }
.tag--dark { color: #8A8C91; }
.tag--dark span { color: #fff; }


/* --------------------------------------------------------------------------
   Topo: três palavras, sem moldura
   -------------------------------------------------------------------------- */
.top {
  position: sticky; top: 0; z-index: 40;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: 64px; font-size: 14px; letter-spacing: -.01em; color: var(--gray);
  transition: background-color .3s, height .3s;
}
.top a { transition: color .2s; }
.top a:hover { color: var(--ink); }
.top__brand { justify-self: start; }
.top__end { justify-self: end; }
.top.is-scrolled { height: 56px; background: rgba(243,244,246,.86); backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--line); }

/* --------------------------------------------------------------------------
   Abertura
   -------------------------------------------------------------------------- */
.open {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: calc(100svh - 64px);
  display: flex; flex-direction: column; justify-content: space-between;
  padding-top: clamp(48px, 9vh, 100px);
}

.cross { position: absolute; width: 9px; height: 9px; z-index: 1; }
.cross::before, .cross::after { content: ""; position: absolute; background: var(--ink); }
.cross::before { left: 4px; top: 0; width: 1px; height: 9px; }
.cross::after { top: 4px; left: 0; height: 1px; width: 9px; }
.cross--tl { left: calc(var(--pad) - 4px); top: 20px; }
.cross--tr { right: calc(var(--pad) - 4px); top: 20px; }

.open__title {
  margin-top: clamp(18px, 2.4vw, 30px);
  font: 600 clamp(2.6rem, 6.4vw, 7rem)/.93 var(--f-display); letter-spacing: -.045em;
}
.open__title { position: relative; }
.open__title .line { display: block; }
/* Hover do título: um círculo suave em salmão acompanha o mouse */
.open__glow {
  position: absolute; inset: -.35em; padding: .35em; display: block; pointer-events: none;
  color: var(--salmon);
  -webkit-mask-image: radial-gradient(circle var(--gr, 170px) at var(--gx, -999px) var(--gy, -999px), #000 0%, rgba(0,0,0,.55) 45%, transparent 100%);
          mask-image: radial-gradient(circle var(--gr, 170px) at var(--gx, -999px) var(--gy, -999px), #000 0%, rgba(0,0,0,.55) 45%, transparent 100%);
  opacity: 0; transition: opacity .5s cubic-bezier(.2,.8,.2,1);
}
.open__glow.is-on { opacity: 1; }
/* Na cópia em salmão, nada de máscara nas palavras (cortava o "g") e sem as capas */
.open__glow .wd { clip-path: none; }
.open__glow .reel { visibility: hidden; }

/* Box no título que passa as capas dos projetos */
.reel {
  position: relative; display: inline-block; overflow: hidden;
  width: 1.9em; height: .68em; margin-left: .16em; vertical-align: .02em;
  border-radius: .11em; background: #1a1a1a;
}
.reel img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  clip-path: inset(100% 0 0 0); transition: clip-path 1.3s cubic-bezier(.16,1,.3,1), scale 2s cubic-bezier(.16,1,.3,1);
  scale: 1.15;
}
.reel img.is-on { clip-path: inset(0 0 0 0); scale: 1; }
.open__arrow { display: inline-block; margin-left: .14em; vertical-align: .04em; line-height: 0; }
.open__arrow .ar { width: .52em; height: .52em; }
.open__body { margin-block: auto; text-align: left; }
.open__sub { margin-top: clamp(22px, 3vw, 40px); font-size: clamp(14px, 1vw, 15px); color: var(--gray); }

/* Barra técnica no pé da abertura */
.hud {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px;
  margin-top: clamp(48px, 8vh, 96px); padding-block: 14px 18px;
  border-top: 1px solid var(--ink);
  font-size: 11px; color: var(--gray); font-variant-numeric: tabular-nums;
}
.hud__clock { font-weight: 500; color: var(--ink); margin-left: 8px; }
.hud__live { display: inline-flex; align-items: center; gap: 8px; }
.hud__live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--ink); animation: blink 2.4s steps(1) infinite; }
@keyframes blink { 50% { opacity: .2; } }
.hud__go { justify-self: end; display: inline-flex; align-items: center; gap: 6px; color: var(--ink); }
.hud__go .ar { width: 9px; height: 9px; }

/* --------------------------------------------------------------------------
   Projetos: rótulo · imagem · texto
   -------------------------------------------------------------------------- */
.projects { padding-top: clamp(64px, 8vw, 120px); }
.sec-bar { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 5fr) minmax(0, 4fr); column-gap: clamp(24px, 4.6vw, 56px); align-items: end; padding-bottom: 18px; border-bottom: 1px solid var(--ink); }
.sec-bar .tag { justify-self: end; text-align: right; }
.sec-bar__title { font: 600 clamp(1.5rem, 2.3vw, 2.3rem)/1 var(--f-display); letter-spacing: -.035em; }
.sec-bar__count { font-size: 11px; color: var(--gray); justify-self: end; font-variant-numeric: tabular-nums; }

.w {
  position: relative;
  display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 5fr) minmax(0, 4fr);
  column-gap: clamp(24px, 4.6vw, 56px);
  padding-block: clamp(24px, 3.4vw, 40px) 0;
}
.w__label { text-align: right; }
.w__kind { font-size: 13px; letter-spacing: -.01em; color: var(--gray); line-height: 1.2; }
.w__n { margin-top: 6px; font-size: 11px; color: var(--mute); font-variant-numeric: tabular-nums; }

.w__img { position: relative; display: block; overflow: hidden; background: #6E6E6E; }
.w__img img { width: 100%; aspect-ratio: 422 / 230; object-fit: cover; filter: grayscale(1) contrast(1.05); transition: filter .5s, transform .8s cubic-bezier(.2,.7,.2,1); }
.w__img::before, .w__img::after { content: ""; position: absolute; z-index: 1; width: 10px; height: 10px; border: 1px solid #fff; opacity: 0; transition: opacity .3s, inset .4s cubic-bezier(.2,.8,.2,1); }
.w__img::before { top: 22px; left: 22px; border-right: 0; border-bottom: 0; }
.w__img::after { bottom: 22px; right: 22px; border-left: 0; border-top: 0; }
.w:hover .w__img img { filter: none; transform: scale(1.025); }
.w:hover .w__img::before { opacity: 1; top: 12px; left: 12px; }
.w:hover .w__img::after { opacity: 1; bottom: 12px; right: 12px; }

.w__info { display: flex; flex-direction: column; gap: 10px; }
.w__info h3 { font: 600 clamp(16px, 1.2vw, 18px)/1.2 var(--f-display); letter-spacing: -.03em; }
.w__line { font-size: 14px; line-height: 1.45; color: var(--gray); max-width: 36ch; }
.w__deliv { font-size: 11px; color: var(--mute); }
.w__link { margin-top: auto; width: fit-content; display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; border-bottom: 1px solid var(--ink); padding-bottom: 2px; }

.cursor-tag {
  position: fixed; top: 0; left: 0; z-index: 70;
  padding: 6px 10px; background: var(--ink); color: #fff;
  font-size: 11px; font-weight: 500; white-space: nowrap; pointer-events: none;
  translate: calc(var(--x, -300) * 1px + 14px) calc(var(--y, -300) * 1px + 14px);
  transform-origin: 0 0; scale: 0; transition: scale .3s cubic-bezier(.2,.8,.2,1);
}
.cursor-tag.is-on { scale: 1; }

/* Balão do título: segue o mouse e alterna entre os serviços */
.say {
  position: fixed; top: 0; left: 0; z-index: 70; pointer-events: none;
  display: flex; align-items: center; gap: 7px; overflow: hidden;
  padding: 8px 14px 8px 11px; border-radius: 999px; border-top-left-radius: 4px;
  background: var(--ink); color: #fff;
  font-size: 12px; font-weight: 500; white-space: nowrap;
  translate: calc(var(--x, -300) * 1px + 16px) calc(var(--y, -300) * 1px + 18px);
  transform-origin: 0 0; scale: 0; transition: scale .35s cubic-bezier(.2,.8,.2,1), width .45s cubic-bezier(.16,1,.3,1);
}
.say::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--salmon); flex: none; }
.say.is-on { scale: 1; }
.say__t { display: inline-block; animation: say-in .5s cubic-bezier(.16,1,.3,1); }
@keyframes say-in { from { translate: 0 120%; opacity: 0; } }
@media (hover: none), (pointer: coarse) {
  .cursor-tag, .say { display: none; }
  .w__img img { filter: none; }
}

.all { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 5fr) minmax(0, 4fr); column-gap: clamp(24px, 4.6vw, 56px); margin-top: clamp(56px, 6vw, 90px); }
.all a { grid-column: 3; width: fit-content; display: inline-flex; gap: 6px; align-items: center; font-size: 13px; font-weight: 500; border-bottom: 1px solid var(--ink); padding-bottom: 2px; }

/* --------------------------------------------------------------------------
   Método
   -------------------------------------------------------------------------- */
.view { padding-top: clamp(88px, 10vw, 160px); }
.view__say { margin-top: 20px; max-width: 18ch; font: 600 clamp(1.6rem, 3vw, 3rem)/1.02 var(--f-display); letter-spacing: -.035em; }
.soft { color: var(--mute); }
.view__rules { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 3vw, 40px); margin-top: clamp(48px, 6vw, 88px); }
.view__rules li { padding-top: 16px; border-top: 1px solid var(--ink); }
.view__rules h3 { font: 600 15px/1.25 var(--f-display); letter-spacing: -.02em; }
.view__rules p { margin-top: 6px; font-size: 13px; color: var(--gray); max-width: 32ch; }

/* --------------------------------------------------------------------------
   Sobre
   -------------------------------------------------------------------------- */
.about { padding-block: clamp(88px, 10vw, 160px); }
.about__grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 72px); margin-top: 24px; align-items: end; }
.about__photo { position: relative; perspective: 900px; }
/* Card da foto: cantos arredondados e inclinação 3D que segue o mouse */
.about__frame {
  position: relative; overflow: hidden; border-radius: 18px; isolation: isolate;
  transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) scale(var(--sz, 1));
  transition: transform .7s cubic-bezier(.2,.8,.2,1), box-shadow .7s cubic-bezier(.2,.8,.2,1);
  will-change: transform;
}
.about__frame.is-hover { --sz: 1.02; transition-duration: .15s, .7s; box-shadow: 0 30px 60px -30px rgba(0,0,0,.35); }
.about__photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 47% 35%; filter: grayscale(1) contrast(1.08); }
.about__frame img { scale: 1.08; translate: var(--ix, 0) var(--iy, 0); transition: translate .7s cubic-bezier(.2,.8,.2,1), filter .6s; }
.about__frame.is-hover img { transition-duration: .15s, .6s; filter: grayscale(1) contrast(1.12) brightness(1.03); }
.about__glare {
  position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: 0;
  background: radial-gradient(circle at var(--gx, 50%) var(--gy, 50%), rgba(255,255,255,.28), transparent 55%);
  transition: opacity .5s;
}
.about__frame.is-hover .about__glare { opacity: 1; }
.about__photo figcaption { margin-top: 10px; font-size: 12px; color: var(--mute); }
.about__name { font: 600 clamp(1.6rem, 2.8vw, 2.8rem)/1 var(--f-display); letter-spacing: -.035em; }
.about__text { margin-top: 20px; max-width: 34ch; font-size: 15px; line-height: 1.45; color: var(--gray); }
.about__data { margin-top: 36px; border-bottom: 1px solid var(--line); }
.about__data div { display: grid; grid-template-columns: 110px 1fr; gap: 16px; padding-block: 12px; border-top: 1px solid var(--line); font-size: 13px; }
.about__data dt { color: var(--mute); font-size: 11px; padding-top: 2px; }
.about__links { display: flex; gap: 24px; margin-top: 24px; font-size: 13px; font-weight: 500; }
.about__links a { display: inline-flex; align-items: center; gap: 6px; border-bottom: 1px solid var(--ink); padding-bottom: 2px; }

/* --------------------------------------------------------------------------
   Contato (preto)
   -------------------------------------------------------------------------- */
.contact { overflow: hidden; background: #0A0A0B; color: #fff; padding-top: clamp(72px, 8vw, 120px); }
.contact__title { margin-top: 20px; font: 600 clamp(1.9rem, 4.2vw, 4.3rem)/.95 var(--f-display); letter-spacing: -.04em; }
.contact__title .line { display: block; }
.contact__mail { display: inline-block; margin-top: clamp(24px, 3vw, 40px); font: 500 clamp(1.05rem, 1.6vw, 1.5rem)/1.1 var(--f-display); letter-spacing: -.03em; color: #BDBEC2; border-bottom: 1px solid #3A3B3F; transition: color .2s, border-color .2s; }
.contact__mail:hover { color: #fff; border-color: #fff; }
.contact__actions { margin-top: 32px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 16px; background: #fff; color: var(--ink); border: 1px solid #fff;
  font-size: 13px; font-weight: 500; transition: background-color .25s, color .25s;
}
.btn:hover { background: transparent; color: #fff; }
.contact__row { margin-top: clamp(64px, 7vw, 110px); padding-block: 18px; border-top: 1px solid #2A2B2F; display: flex; flex-wrap: wrap; gap: 12px 32px; font-size: 11px; color: #8A8C91; }
.contact__row a { color: #fff; }
.contact__row .push { margin-left: auto; }

/* Topo some ao descer e volta ao subir */
.top { transition: background-color .3s, height .3s, translate .45s cubic-bezier(.2,.8,.2,1); }
.top.is-hidden { translate: 0 -100%; }

/* Imagens dos projetos: parallax (translate via JS) + zoom (scale) */
.w__img img { will-change: translate; }

/* --------------------------------------------------------------------------
   Movimento de entrada (só com JS e sem "reduzir movimento")
   -------------------------------------------------------------------------- */
:root { --ease: cubic-bezier(.16, 1, .3, 1); }

@media (prefers-reduced-motion: no-preference) {
  /* Bloco que sobe e aparece */
  .js [data-reveal] { opacity: 0; translate: 0 32px; transition: opacity 1s var(--ease), translate 1.2s var(--ease); transition-delay: calc(var(--d, 0) * 90ms + var(--delay, 0ms)); }
  .js [data-reveal].is-in { opacity: 1; translate: 0 0; }

  /* Foto que abre de baixo para cima */
  .js [data-reveal="clip"] { opacity: 1; translate: none; clip-path: inset(100% 0 0 0); transition: clip-path 1.4s var(--ease); }
  .js [data-reveal="clip"] .about__frame { scale: 1.12; transition: scale 1.8s var(--ease), transform .7s cubic-bezier(.2,.8,.2,1), box-shadow .7s; }
  .js [data-reveal="clip"].is-in { clip-path: inset(-40px -40px -40px -40px); }
  .js [data-reveal="clip"].is-in .about__frame { scale: 1; }

  /* Títulos: cada palavra sobe de dentro de uma máscara */
  .wd { display: inline-block; clip-path: inset(-.25em -.15em -.32em -.15em); }
  .wd__i { display: inline-block; translate: 0 135%; transition: translate 1.1s var(--ease); transition-delay: calc(var(--w, 0) * 55ms + var(--delay, 0ms)); }
  .is-in .wd__i { translate: 0 0; }
  .js [data-split] .reel { clip-path: inset(0 100% 0 0 round .11em); transition: clip-path 1.2s var(--ease) 350ms; }
  .js [data-split].is-in .reel { clip-path: inset(0 0 0 0 round .11em); }
  .js .open__arrow { opacity: 0; translate: -.25em .25em; transition: opacity .8s var(--ease) 700ms, translate 1s var(--ease) 700ms; }
  .js .is-in .open__arrow { opacity: 1; translate: 0 0; }

  /* Abertura: letras de fundo, cruzes e linha da barra técnica */
  .js .cross { opacity: 0; rotate: -90deg; transition: opacity .8s var(--ease) .5s, rotate 1.2s var(--ease) .5s; }
  .js .open.is-in .cross { opacity: 1; rotate: 0deg; }
  .hud { position: relative; border-top: 0; }
  .hud::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px; background: var(--ink); transform-origin: 0 50%; }
  .js .hud::before { scale: 0 1; transition: scale 1.4s var(--ease) .35s; }
  .js .open.is-in .hud::before { scale: 1 1; }
  .js .hud [data-reveal] { --delay: 700ms; translate: 0 12px; }

  /* Projetos: imagem abre como cortina e o zoom assenta */
  .js .w__img { clip-path: inset(0 0 100% 0); transition: clip-path 1.3s var(--ease); }
  .js .w__img img { scale: 1.3; transition: filter .5s, scale 1.8s var(--ease); }
  .js .w.is-in .w__img { clip-path: inset(0 0 0 0); }
  .js .w.is-in .w__img img { scale: 1.12; }
  .js .w.is-in:hover .w__img img { scale: 1.17; }
  .js .w__info [data-reveal] { --delay: 250ms; }

  /* Frase do método acende palavra por palavra com a rolagem */
  .lw { color: #C9CBD0; transition: color .35s; }
  .lw.on { color: var(--ink); }

}
@media (prefers-reduced-motion: reduce) { .hud__live::before { animation: none; } }

/* --------------------------------------------------------------------------
   Responsivo
   -------------------------------------------------------------------------- */
@media (max-width: 900px) {
  .hud { grid-template-columns: 1fr 1fr; row-gap: 8px; }
  .sec-bar, .w, .all { grid-template-columns: 1fr; }
  .sec-bar .tag, .sec-bar__count { justify-self: start; }
  .sec-bar__title { margin-top: 10px; }
  .sec-bar__count { margin-top: 6px; }
  .w__label { display: flex; justify-content: space-between; align-items: baseline; text-align: left; margin-bottom: 12px; }
  .w__n { margin-top: 0; }
  .w__info { margin-top: 18px; }
  .w__link { margin-top: 4px; }
  .all a { grid-column: 1; }
  .view__rules { grid-template-columns: 1fr; }
  .about__grid { grid-template-columns: 1fr; }
  .about__photo { max-width: 420px; }
}
@media (max-width: 560px) {
  .top { font-size: 13px; height: 56px; }
  .open { min-height: calc(100svh - 56px); }
  .hud { grid-template-columns: 1fr; }
  .cross { display: none; }
  .open { padding-top: 40px; }
  .hud__go { justify-self: start; }
  .contact__row .push { margin-left: 0; }
}

/* Faixa com fluido animado logo abaixo do título */
.flow {
  position: relative; overflow: hidden; isolation: isolate;
  margin-top: clamp(28px, 4vw, 48px);
  height: clamp(200px, 32vh, 400px); border-radius: 18px; background: #0A0828;
}
.flow__fx { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
/* textura de filme por cima */
.flow::after {
  content: ""; position: absolute; inset: -50%; pointer-events: none; opacity: .1; mix-blend-mode: overlay;
  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='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(4) infinite;
}
@keyframes grain { 25% { translate: -3% 2%; } 50% { translate: 2% -3%; } 75% { translate: -2% -2%; } }
.open .hud { margin-top: clamp(28px, 4vh, 48px); }

/* Botão flutuante do WhatsApp */
.wa-fab {
  position: fixed; right: clamp(16px, 2.4vw, 28px); bottom: clamp(16px, 2.4vw, 28px); z-index: 60;
  display: inline-flex; align-items: center; gap: 0; height: 46px; padding: 0 13px;
  border-radius: 999px; background: var(--ink); color: #fff;
  box-shadow: 0 6px 20px rgba(0,0,0,.14);
  opacity: 0; translate: 0 14px; pointer-events: none;
  transition: background .3s ease, gap .35s ease, translate .45s cubic-bezier(.2,.7,.2,1), opacity .45s ease;
}
.wa-fab svg { width: 20px; height: 20px; flex: none; fill: currentColor; }
.wa-fab span { max-width: 0; overflow: hidden; white-space: nowrap; font-size: 12px; font-weight: 500; transition: max-width .35s ease; }
.wa-fab.is-on { opacity: 1; translate: 0 0; pointer-events: auto; }
.wa-fab.is-on:hover { background: var(--salmon); gap: 8px; translate: 0 -2px; }
.wa-fab:hover span { max-width: 80px; }
@media (prefers-reduced-motion: reduce) { .wa-fab { transition: none; } }
