/* ==========================================================================
   SITE — QualyFisio: tokens da marca + layout de cada seção.
   Regra: CSS de hover usa translate/scale/rotate; GSAP usa transform.
   ========================================================================== */
:root {
  --bg: #FAF8FE; --bg-2: #EFEBF8; --bg-3: #E2DCF1; --paper-hi: #FFFFFF;
  --fg: #241B3F; --fg-2: #33285A; --fg-soft: #4A4166; --muted: #665D80;
  --line: rgba(36, 27, 63, .12); --line-2: rgba(36, 27, 63, .24);
  --inv-line: rgba(250, 248, 254, .16); --inv-line-2: rgba(250, 248, 254, .32); --inv-muted: rgba(250, 248, 254, .72);
  --field-line: #8A80A8; --err: #B21E3C;
  --c1: #4C397E; --c2: #1EC8DC; --c3: #2A2050; --c4: #B3A6DA; --c5: #E3F8FB;
  --accent: var(--c2); --focus: var(--c1); --focus-inv: var(--c2);
  --f-sans: 'Bricolage Grotesque', ui-sans-serif, system-ui, sans-serif;
  --f-mono: 'DM Mono', ui-monospace, Menlo, monospace;
  --radius: 999px;
  --round: 28px;
}
::selection { background: var(--c2); color: var(--fg); }
.is-dark { background: var(--c3); }

/* Títulos: a Bricolage não tem largura >100, então peso e tamanho fazem o trabalho */
.hero__title, .sec__title, .app__title, .onde__title, .cad__title, .equipe__title { font-variation-settings: 'opsz' 96; font-weight: 700; }
.sec__title { letter-spacing: -.04em; }
.layer__base { color: var(--bg-3); }
.is-dark .layer__base { color: rgba(250, 248, 254, .12); }
.btn { font-weight: 600; }
.btn--light { --b-fill: var(--c2); }

/* ── Cabeçalho: logo por extenso ──────────────────────────────────────── */
.brand__logo { height: 38px; width: auto; transition: scale .6s var(--e-out); }
.brand:hover .brand__logo { scale: 1.04; }
@media (max-width: 520px) { .brand__logo { height: 32px; } }

/* ── Hero ─────────────────────────────────────────────────────────────── */
.hero { overflow: clip; background: radial-gradient(120% 80% at 100% 0%, var(--c5) 0%, transparent 55%), var(--bg); }
.hero__grid { flex: 1; display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 72px); align-items: stretch; }
.hero__in { min-width: 0; }
.hero__title { font-size: clamp(2.9rem, 6.6vw, 7.4rem); line-height: .92; letter-spacing: -.05em; max-width: 11ch; color: var(--fg); }
.hero .hero__foot { grid-template-columns: 1fr; }
.hero .hero__lead, .hero .hero__ctas { grid-column: 1 / -1; }
.hero__fig { position: relative; align-self: center; justify-self: center; width: min(100%, 440px); margin-top: clamp(8px, 2vw, 24px); }
.hero__photo { position: relative; z-index: 1; border-radius: 220px 220px var(--round) var(--round); overflow: hidden; aspect-ratio: 610 / 1000; background: var(--bg-2); box-shadow: 0 40px 80px -40px rgba(42, 32, 80, .45); }
.hero__photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.hero__cap { margin-top: 14px; color: var(--muted); text-align: center; }
.ribbon { position: absolute; pointer-events: none; overflow: visible; }
.ribbon path { fill: none; stroke-linecap: round; }
.ribbon__back { stroke: var(--c1); stroke-width: 26; }
.ribbon__front { stroke: var(--c2); stroke-width: 14; }
.ribbon--hero { z-index: 0; top: -4%; left: -16%; width: 132%; height: 100%; }
@media (max-width: 900px) {
  .hero { min-height: auto; }
  .hero__grid { grid-template-columns: 1fr; }
  .hero__fig { order: -1; width: min(72%, 320px); margin: 0 auto 8px; }
  .hero__photo { aspect-ratio: 4 / 5; border-radius: 160px 160px var(--round) var(--round); }
  .hero__title { max-width: 13ch; }
  .hero__cap { display: none; }
}

/* ── Duas frentes ─────────────────────────────────────────────────────── */
.frentes__grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(40px, 6vw, 96px); align-items: start; }
.frente { display: grid; gap: clamp(24px, 3vw, 40px); }
.frente--pilates { margin-top: clamp(80px, 14vw, 220px); }
.frente__img { border-radius: var(--round); overflow: hidden; background: var(--bg-2); }
.frente__img img { width: 100%; height: 100%; object-fit: cover; }
.frente--fisio .frente__img { aspect-ratio: 16 / 13; }
.frente--pilates .frente__img { aspect-ratio: 4 / 5; border-radius: var(--round) var(--round) 180px 180px; }
.frente__tag { display: inline-flex; align-items: center; gap: 10px; color: var(--c1); }
.frente__tag::before { content: ''; width: 28px; height: 6px; border-radius: 6px; background: var(--c2); }
.frente__h { font-size: clamp(1.6rem, 2.6vw, 2.5rem); font-weight: 650; line-height: 1.05; letter-spacing: -.03em; margin: 12px 0 16px; max-width: 20ch; text-wrap: balance; }
.frente__txt > p:not(.frente__tag) { color: var(--fg-soft); max-width: 46ch; }
.frente__list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; list-style: none; }
.frente__list li { padding: 6px 14px; border: 1px solid var(--line-2); border-radius: 99px; font-size: 15px; }
@media (max-width: 900px) {
  .frentes__grid { grid-template-columns: 1fr; }
  .frente--pilates { margin-top: 0; }
  .frente--pilates .frente__img { order: -1; }
}

/* ── Aparelhos: mostruário ────────────────────────────────────────────── */
.aparelhos { background: var(--bg-2); }
.mostra { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.mostra__stage { position: sticky; top: calc(var(--hdr-h) + 24px); aspect-ratio: 4 / 5; max-height: calc(100svh - var(--hdr-h) - 48px); width: 100%; }
.mostra__ring { position: absolute; inset: -4%; border-radius: 50%; border: 1px dashed var(--c4); }
.mostra__ring span { position: absolute; top: 50%; left: -7px; width: 14px; height: 14px; border-radius: 50%; background: var(--c2); }
.mostra__img { position: absolute; inset: 0; border-radius: 50% 50% var(--round) var(--round) / 40% 40% var(--round) var(--round); overflow: hidden; clip-path: inset(100% 0 0 0); transition: clip-path .9s var(--e-io); background: var(--bg-3); }
.mostra__img.is-on { clip-path: inset(0 0 0 0); z-index: 1; }
.mostra__img img { width: 100%; height: 100%; object-fit: cover; }
.mostra__list { list-style: none; border-top: 1px solid var(--line-2); }
.mostra__list li { border-bottom: 1px solid var(--line-2); }
.mostra__item { width: 100%; display: grid; grid-template-columns: 44px 1fr; column-gap: 12px; text-align: left; padding: clamp(18px, 2.4vw, 30px) 0; color: var(--muted); transition: color .4s; }
.mostra__n { padding-top: .9em; }
.mostra__name { font-size: clamp(1.9rem, 4vw, 3.6rem); font-weight: 700; letter-spacing: -.04em; line-height: 1; transition: translate .6s var(--e-out); }
.mostra__desc { grid-column: 2; max-width: 44ch; font-size: 16.5px; color: var(--fg-soft); display: block; max-height: 0; overflow: hidden; opacity: 0; transition: max-height .6s var(--e-out), opacity .4s, margin .6s var(--e-out); }
.mostra__item.is-on { color: var(--fg); }
.mostra__item.is-on .mostra__name { translate: 8px 0; }
.mostra__item.is-on .mostra__n { color: var(--c1); }
.mostra__item.is-on .mostra__desc { max-height: 12em; opacity: 1; margin-top: 12px; }
.mostra__item:hover { color: var(--fg); }
.mostra__item:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; border-radius: 8px; }
@media (max-width: 900px) {
  .mostra { grid-template-columns: 1fr; }
  .mostra__stage { position: relative; top: auto; width: min(78%, 360px); margin: 0 auto 24px; }
}

/* ── Tratamento: goniômetro ───────────────────────────────────────────── */
.trat__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.gonio { position: sticky; top: calc(var(--hdr-h) + 40px); }
.gonio__svg { width: 100%; height: auto; overflow: visible; }
.gonio__ticks line { stroke: var(--fg); stroke-width: 1; opacity: .35; }
.gonio__ticks line.big { stroke-width: 1.6; opacity: .8; }
.gonio__ticks text { font-family: var(--f-mono); font-size: 8px; fill: var(--muted); text-anchor: middle; }
.gonio__sweep { fill: var(--c2); opacity: .28; }
.gonio__fixed { stroke: var(--c4); stroke-width: 10; stroke-linecap: round; }
.gonio__arm { stroke: var(--c1); stroke-width: 10; stroke-linecap: round; }
.gonio__pin { fill: var(--bg); stroke: var(--c1); stroke-width: 4; }
.gonio__read { display: flex; align-items: flex-start; justify-content: center; margin-top: 16px; color: var(--c1); font-weight: 700; letter-spacing: -.05em; line-height: .9; }
.gonio__read b { font-size: clamp(4.5rem, 10vw, 9rem); font-variant-numeric: tabular-nums; }
.gonio__read span { font-size: clamp(2.2rem, 4.5vw, 4rem); color: var(--c2); }
.trat__steps { list-style: none; }
.trat__step { padding: clamp(28px, 4vw, 48px) 0; border-top: 1px solid var(--line-2); min-height: 44svh; opacity: .45; transition: opacity .5s; }
html:not(.has-motion) .trat__step, .trat__step.is-on { opacity: 1; }
.trat__n { color: var(--c1); margin-bottom: 14px; }
.trat__step h3 { font-size: clamp(1.5rem, 2.4vw, 2.3rem); font-weight: 650; letter-spacing: -.03em; line-height: 1.08; margin-bottom: 14px; max-width: 22ch; text-wrap: balance; }
.trat__step p:last-child { color: var(--fg-soft); max-width: 46ch; }
@media (max-width: 900px) {
  .trat__grid { grid-template-columns: 1fr; }
  .gonio { top: calc(var(--hdr-h) + 8px); z-index: 2; background: var(--bg); padding: 8px 0 10px; display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 12px; border-bottom: 1px solid var(--line); }
  .gonio__svg { max-width: 220px; }
  .gonio__read { margin-top: 0; }
  .gonio__read b { font-size: 3.6rem; }
  .gonio__read span { font-size: 1.8rem; }
  .trat__step { min-height: 0; }
}

/* ── App do paciente ──────────────────────────────────────────────────── */
.app { position: relative; overflow: hidden; }
.ribbon--app { inset: auto 0 -40px 0; width: 100%; height: 220px; opacity: .9; }
.ribbon--app .ribbon__front { stroke-width: 10; }
.app__grid { position: relative; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.app .sec__idx { margin-bottom: 24px; }
.app__title { font-size: clamp(2.4rem, 5vw, 5.2rem); line-height: .95; letter-spacing: -.045em; max-width: 13ch; }
.app__lead { margin: 24px 0 36px; color: var(--inv-muted); max-width: 44ch; font-size: clamp(1.05rem, .6vw + .9rem, 1.3rem); }
.app__list { list-style: none; display: grid; gap: 12px; }
.app__list li { display: grid; gap: 6px; padding: 22px 26px; border-radius: 22px; background: rgba(250, 248, 254, .06); border: 1px solid var(--inv-line); transition: translate .5s var(--e-out), border-color .4s; }
.app__list li:hover { translate: -6px 0; border-color: var(--c2); }
.app__list .mono { color: var(--c2); }
.app__list b { font-size: clamp(1.15rem, 1.6vw, 1.45rem); font-weight: 600; letter-spacing: -.01em; }
@media (max-width: 900px) { .app__grid { grid-template-columns: 1fr; } .ribbon--app { height: 140px; } }

/* ── Equipe ───────────────────────────────────────────────────────────── */
.equipe__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.equipe .sec__idx { margin-bottom: 20px; }
.equipe__title { font-size: clamp(2.4rem, 5vw, 5rem); font-weight: 700; line-height: .95; letter-spacing: -.045em; max-width: 12ch; }
.equipe__lead { margin-top: 24px; color: var(--fg-soft); max-width: 42ch; font-size: clamp(1.05rem, .6vw + .9rem, 1.3rem); }
.equipe__list { list-style: none; display: grid; gap: var(--col-gap); }
@media (max-width: 900px) { .equipe__grid { grid-template-columns: 1fr; } }
.pessoa { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 32px); padding: clamp(20px, 2.6vw, 36px); border-radius: var(--round); background: var(--paper-hi); border: 1px solid var(--line); }
.pessoa__foto { position: relative; flex: none; width: clamp(96px, 10vw, 150px); height: clamp(96px, 10vw, 150px); border-radius: 50%; display: grid; place-items: center; background: var(--c5); color: var(--c1); font-size: clamp(2rem, 3.2vw, 3rem); font-weight: 700; overflow: hidden; }
.pessoa__foto::after { content: ''; position: absolute; inset: 4px; border-radius: 50%; border: 2px solid var(--c2); border-left-color: transparent; border-bottom-color: transparent; rotate: -30deg; transition: rotate .8s var(--e-out); }
.pessoa:hover .pessoa__foto::after { rotate: 60deg; }
.pessoa__foto img { width: 100%; height: 100%; object-fit: cover; }
.pessoa__nome { font-size: clamp(1.35rem, 2vw, 1.9rem); font-weight: 650; letter-spacing: -.02em; line-height: 1.15; }
.pessoa__cargo { color: var(--muted); margin-top: 8px; display: grid; gap: 2px; }

/* ── Onde ─────────────────────────────────────────────────────────────── */
.onde { background: var(--bg-2); }
.onde__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: clamp(32px, 5vw, 80px); align-items: stretch; }
.onde .sec__idx { margin-bottom: 20px; }
.onde__title { font-size: clamp(2.4rem, 5vw, 5rem); line-height: .95; letter-spacing: -.045em; }
.onde__dl { margin: 36px 0 28px; display: grid; gap: 22px; }
.onde__dl div { display: grid; gap: 4px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.onde__dl dt { color: var(--muted); }
.onde__dl dd { font-size: 1.12rem; }
.onde .ulink--ext { display: inline-block; padding-block: 12px; }
.onde__map { min-height: 420px; border-radius: var(--round); overflow: hidden; background: var(--bg-3); }
.onde__map iframe { width: 100%; height: 100%; min-height: 420px; border: 0; display: block; filter: saturate(.7) hue-rotate(10deg); }
@media (max-width: 900px) { .onde__grid { grid-template-columns: 1fr; } .onde__map, .onde__map iframe { min-height: 320px; } }

/* ── Cadastro ─────────────────────────────────────────────────────────── */
.cad__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.cad .sec__idx { margin-bottom: 20px; }
.cad__title { font-size: clamp(2.4rem, 5vw, 5rem); line-height: .95; letter-spacing: -.045em; max-width: 12ch; }
.cad__lead { margin-top: 24px; color: var(--fg-soft); max-width: 42ch; font-size: clamp(1.05rem, .6vw + .9rem, 1.3rem); }
.cad__exp { margin-top: 28px; padding: 20px 22px; border-radius: 20px; background: var(--c5); border: 1px solid var(--c2); max-width: 44ch; }
.cad__exp .mono { color: var(--c1); margin-bottom: 6px; }
.cad__form { display: grid; gap: 18px; padding: clamp(24px, 3vw, 40px); border-radius: var(--round); background: var(--paper-hi); border: 1px solid var(--line); box-shadow: 0 30px 60px -40px rgba(42, 32, 80, .35); }
.cad__form [hidden] { display: none !important; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.chips { border: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips legend { color: var(--muted); margin-bottom: 10px; }
.chip { min-height: 44px; padding: 0 18px; border-radius: 99px; border: 1px solid var(--field-line); font-size: 15px; transition: background-color .3s, border-color .3s, color .3s; }
.chip:hover { border-color: var(--c1); }
.chip[aria-pressed="true"] { background: var(--c1); border-color: var(--c1); color: var(--bg); }
.chip:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.fld { display: grid; gap: 6px; }
.fld label { font-size: 15px; font-weight: 550; }
.fld small { color: var(--muted); font-weight: 400; }
.fld input, .fld textarea { width: 100%; font: inherit; color: var(--fg); background: var(--bg); border: 1px solid var(--field-line); border-radius: 14px; padding: 13px 16px; min-height: 50px; transition: border-color .3s, box-shadow .3s; }
.fld textarea { resize: vertical; min-height: 96px; }
.fld input:focus-visible, .fld textarea:focus-visible { outline: none; border-color: var(--c1); box-shadow: 0 0 0 3px rgba(30, 200, 220, .45); }
.fld input[aria-invalid="true"] { border-color: var(--err); }
.cad__send { justify-content: space-between; width: 100%; }
.cad__send[disabled] { opacity: .6; pointer-events: none; }
.cad__msg { min-height: 1.5em; font-weight: 550; }
.cad__msg.is-err { color: var(--err); }
.cad__msg.is-ok { color: var(--c1); padding: 14px 16px; border-radius: 14px; background: var(--c5); }
@media (max-width: 900px) { .cad__grid { grid-template-columns: 1fr; } }

/* ── Rodapé ───────────────────────────────────────────────────────────── */
.ftr { background: var(--c3); }
.fab { background: var(--c1); }
