/* Entrada da área do cliente Solar Hoje (login.solarhoje.com.br).
   Mesma direção visual do site ("a leitura da energia", solarhoje-site/src/static/assets/site.css): carta solar no
   painel petróleo, cartão de entrada como canhoto de conta picotado, código de 6 dígitos como leitura de medidor.
   Tokens copiados do site: se a paleta ou as fontes mudarem lá, mudar aqui. */

:root {
  --deep: #06373a;
  --deep-2: #02474e;
  --teal-700: #0c636a;
  --teal-600: #277a82;
  --sun: #f5811e;
  --sun-400: #f89247;
  --sun-300: #f8a466;
  --sun-200: #fbbb8d;
  --sun-100: #fddfc7;
  --danger: #b42318;
  --danger-bg: #fdf0ee;

  --paper: #fbf9f6;
  --white: #ffffff;
  --ink: #12211f;
  --text-2: #4a5b58;
  --text-3: #5d6e6b;
  --line: #e6ded3;
  --line-2: #d3c8ba;
  --on-deep: #e7f1f1;
  --on-deep-2: rgba(231, 241, 241, .8);
  --on-deep-3: rgba(231, 241, 241, .62);
  --line-deep: rgba(231, 241, 241, .14);

  --f-display: 'Lexend', 'Century Gothic', system-ui, sans-serif;
  --f-body: 'Atkinson Hyperlegible Next', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-mono: 'Atkinson Hyperlegible Mono', ui-monospace, 'Cascadia Mono', Consolas, monospace;

  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px; --s8: 64px;
  --r-xs: 6px; --r: 12px; --r-lg: 18px; --r-pill: 999px;

  --sh-1: 0 1px 2px rgba(6, 55, 58, .06), 0 6px 16px -10px rgba(6, 55, 58, .16);
  --sh-3: 0 2px 4px rgba(6, 55, 58, .07), 0 24px 52px -22px rgba(6, 55, 58, .38);

  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --ease: cubic-bezier(.22, 1, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }
body { margin: 0; font-family: var(--f-body); font-size: 1.0625rem; line-height: 1.6; color: var(--ink); background: var(--paper); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
h1, h2, p, ul, dl, dd { margin: 0; }
ul { padding: 0; list-style: none; }
strong { font-weight: 600; }
a { color: var(--teal-700); text-underline-offset: 3px; }
a:hover { color: var(--deep); }
:focus-visible { outline: 3px solid var(--sun-400); outline-offset: 3px; border-radius: 4px; }
.mono { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 10; background: var(--deep); color: #fff; padding: 10px 16px; border-radius: var(--r-xs); font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; color: #fff; }

/* ---------- estrutura: painel petróleo + coluna de entrada ---------- */
.lg { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: 1fr; }
@media (min-width: 960px) { .lg { grid-template-columns: minmax(0, 1.05fr) minmax(440px, 1fr); } }

.side { position: relative; isolation: isolate; overflow: hidden; background: radial-gradient(420px 360px at 92% 0%, rgba(245, 129, 30, .22), transparent 66%), var(--deep); color: var(--on-deep); padding: 20px 16px 28px; display: flex; flex-direction: column; gap: var(--s5); }
@media (min-width: 640px) { .side { padding: 28px 40px 36px; } }
@media (min-width: 960px) { .side { position: sticky; top: 0; height: 100vh; height: 100dvh; padding: 40px 56px 44px; justify-content: space-between; } }

.cs { position: absolute; z-index: -1; width: min(900px, 150vw); height: auto; right: -42%; top: -30%; opacity: .8; -webkit-mask-image: radial-gradient(closest-side, #000 55%, transparent 100%); mask-image: radial-gradient(closest-side, #000 55%, transparent 100%); }
@media (min-width: 960px) { .cs { right: -30%; top: -16%; opacity: .95; } }
.cs__grid { fill: none; stroke: rgba(231, 241, 241, .085); stroke-width: 1; }
.cs__path { fill: none; stroke: rgba(248, 164, 102, .38); stroke-width: 1.4; stroke-dasharray: 2 7; stroke-linecap: round; }
.cs__path--v { stroke: rgba(248, 164, 102, .22); }
.cs__path--i { stroke: rgba(68, 165, 174, .3); }
.cs__h { fill: var(--sun-300); opacity: .55; }

.brand { display: inline-flex; align-self: flex-start; padding: 6px; margin: -6px; border-radius: var(--r-xs); transition: opacity .2s var(--ease); }
.brand:hover { opacity: .82; }
.brand:active { opacity: .7; }
.logo { width: 119px; height: auto; filter: brightness(0) invert(1); }

.eyebrow { display: inline-flex; font-family: var(--f-mono); font-size: .8rem; font-weight: 500; color: var(--sun-200); background: rgba(231, 241, 241, .07); border-left: 3px solid var(--sun); padding: 4px 10px 4px 9px; border-radius: 0 var(--r-xs) var(--r-xs) 0; margin-bottom: var(--s4); }
.h1 { font-family: var(--f-display); font-weight: 500; font-size: clamp(1.55rem, 5.4vw, 2.9rem); line-height: 1.1; letter-spacing: -0.03em; color: #fff; max-width: 16ch; text-wrap: balance; }
.hl { color: var(--sun-300); }

/* O que tem lá dentro: as 5 abas, no formato de leitura (mesmo bloco dos fatos do site). */
.inside { display: none; }
@media (min-width: 960px) {
  .inside { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; margin-top: var(--s7); max-width: 560px; background: var(--line-deep); border: 1px solid var(--line-deep); border-radius: var(--r); overflow: hidden; }
  .inside > div { background: rgba(6, 55, 58, .92); padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 4px; }
  .inside > div:last-child { grid-column: 1 / -1; }
  .inside dt { font-family: var(--f-mono); font-weight: 500; font-size: 1.02rem; color: #fff; }
  .inside dd { font-size: .88rem; line-height: 1.45; color: var(--on-deep-3); }
}
.hours { display: none; }
@media (min-width: 960px) { .hours { display: block; font-size: .88rem; line-height: 1.55; color: var(--on-deep-3); max-width: 48ch; } }

.main { display: flex; flex-direction: column; gap: var(--s5); padding: 24px 16px 32px; width: 100%; max-width: 520px; margin-inline: auto; }
@media (min-width: 640px) { .main { padding: 40px 32px; } }
@media (min-width: 960px) { .main { justify-content: center; padding: 56px 48px; } }
@media (max-width: 959px) { .main { margin-top: -18px; position: relative; } }

/* ---------- cartão de entrada: canhoto picotado ---------- */
.card { position: relative; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 36px 20px 24px; box-shadow: var(--sh-3); }
@media (min-width: 640px) { .card { padding: 40px 32px 32px; } }
.card::before { content: ''; position: absolute; left: 20px; right: 20px; top: 16px; border-top: 2px dashed var(--line-2); }
.card::after { content: ''; position: absolute; left: -10px; right: -10px; top: 7px; height: 20px; background: radial-gradient(circle at 10px 10px, var(--paper) 9px, transparent 9.5px) left / 20px 20px no-repeat, radial-gradient(circle at 10px 10px, var(--paper) 9px, transparent 9.5px) right / 20px 20px no-repeat; }
.card__field { display: flex; align-items: center; gap: 10px; font-family: var(--f-mono); font-size: .8rem; color: var(--text-3); margin: 6px 0 var(--s3); }
.card__dot { width: 4px; height: 4px; border-radius: 50%; background: var(--line-2); }
.card__t { font-family: var(--f-display); font-weight: 500; font-size: 1.7rem; line-height: 1.15; letter-spacing: -0.02em; margin-bottom: var(--s5); }
.card__t:focus { outline: none; }
.state { display: flex; flex-direction: column; gap: var(--s3); }
.lead { color: var(--text-2); line-height: 1.6; }
.lead strong { color: var(--ink); }

.lbl { font-weight: 600; font-size: .98rem; }
.inp { width: 100%; font: inherit; font-size: 1.06rem; color: var(--ink); background: var(--white); border: 1.5px solid var(--line-2); border-radius: var(--r); padding: 13px 14px; transition: border-color .2s var(--ease), box-shadow .2s var(--ease); }
.inp:hover { border-color: var(--teal-600); }
.inp:focus { outline: none; border-color: var(--teal-700); box-shadow: 0 0 0 4px rgba(12, 99, 106, .14); }
.inp[aria-invalid="true"] { border-color: var(--danger); }
.hint { font-size: .9rem; color: var(--text-3); line-height: 1.5; margin-top: -4px; }
.err { font-size: .92rem; color: var(--danger); background: var(--danger-bg); border-radius: var(--r-xs); padding: 8px 12px; line-height: 1.45; }
.sent { color: var(--text-2); font-size: .98rem; line-height: 1.55; padding: 12px 14px; background: rgba(12, 99, 106, .06); border-left: 3px solid var(--teal-600); border-radius: 0 var(--r-xs) var(--r-xs) 0; margin-bottom: var(--s2); word-break: break-word; }
.note { font-size: .92rem; line-height: 1.5; padding: 10px 12px; border-radius: var(--r-xs); background: var(--sun-100); margin-bottom: var(--s4); }

/* ---------- código: leitura de medidor (6 algarismos de largura fixa) ---------- */
.otp { position: relative; width: 100%; max-width: 348px; }
.otp__cells { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) 4px repeat(3, minmax(0, 1fr)); gap: 6px; pointer-events: none; }
.otp__cells span:nth-child(4) { grid-column: 5; }
.otp__cells span { display: grid; place-items: center; aspect-ratio: 5 / 6; background: var(--deep); color: #fff; border-radius: var(--r-xs); font-family: var(--f-mono); font-size: clamp(1.4rem, 6vw, 1.75rem); font-weight: 500; font-variant-numeric: tabular-nums; box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .22); transition: transform .25s var(--spring), box-shadow .2s var(--ease); }
.otp__cells span.is-cur { box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .22), 0 0 0 3px var(--sun-400); }
.otp__cells span.is-fill { transform: translateY(-1px); }
.otp__in { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; border: 0; font-size: 16px; cursor: text; }
.otp.is-err .otp__cells span { box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .22), 0 0 0 2px var(--danger); }

/* ---------- botões ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--s2); border-radius: var(--r-pill); font: inherit; font-weight: 600; text-decoration: none; line-height: 1.2; text-align: center; border: 1px solid transparent; cursor: pointer; transition: transform .25s var(--spring), background-color .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease); }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn--lg { padding: 15px 26px; font-size: 1.02rem; }
.btn--full { width: 100%; margin-top: var(--s2); }
.btn--sun { background: var(--sun); color: var(--ink); box-shadow: inset 0 -2px 0 rgba(18, 33, 31, .16), 0 6px 16px -10px rgba(154, 74, 8, .5); }
.btn--sun:hover { background: var(--sun-400); color: var(--ink); }
.btn--line { color: var(--ink); border-color: var(--line-2); background: var(--white); }
.btn--line:hover { border-color: var(--teal-600); color: var(--teal-700); }
.btn[aria-busy="true"] { cursor: progress; }
.btn[aria-busy="true"] .btn__txt { opacity: .55; }
.btn[aria-busy="true"]:hover { transform: none; }

.alt { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; margin-top: var(--s3); padding-top: var(--s3); border-top: 1px solid var(--line); }
.lnk { font: inherit; font-size: .95rem; color: var(--teal-700); background: none; border: 0; padding: 8px 2px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(12, 99, 106, .35); border-radius: 4px; transition: color .2s var(--ease), text-decoration-color .2s var(--ease); }
.lnk:hover { color: var(--deep); text-decoration-color: currentColor; }
.lnk:active { color: var(--ink); }
.lnk:disabled { color: var(--text-3); text-decoration: none; cursor: default; }

/* ---------- segurança, ajuda, rodapé ---------- */
.safe { border: 1px solid var(--line); border-radius: var(--r); padding: var(--s4) var(--s4) var(--s4) 18px; background: var(--white); box-shadow: var(--sh-1); border-left: 3px solid var(--teal-600); }
.safe__t { font-family: var(--f-mono); font-size: .8rem; color: var(--teal-700); margin-bottom: var(--s2); }
.safe ul { display: grid; gap: 6px; }
.safe li { font-size: .92rem; line-height: 1.5; color: var(--text-2); padding-left: 16px; position: relative; }
.safe li::before { content: ''; position: absolute; left: 0; top: .6em; width: 7px; height: 7px; border-radius: 2px; background: var(--sun-300); }
.safe strong { color: var(--ink); }
.help { font-size: .95rem; color: var(--text-2); }
.foot { font-size: .8rem; color: var(--text-3); display: grid; gap: 6px; padding-top: var(--s4); border-top: 1px solid var(--line); }
.foot p:last-child { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.foot a { color: var(--text-3); }
.foot a:hover { color: var(--teal-700); }
/* Turnstile: aparece só quando o widget pede interação */
.bot { margin-top: var(--s3); }
.bot:empty { display: none; }
