/* YardSync, pagina inicial. CSS escrito a mao, sem framework e sem build:
   a pagina e uma so, e um passo de build so para ela seria peso morto.
   Os tokens repetem os do design system dos apps (packages/ui/lib/src/
   tokens.dart): tinta sobre papel, amarelo so para o proximo movimento,
   cantos quase retos, separacao por filete e nao por sombra.
   As fontes sao Inter e IBM Plex Mono reduzidas ao latim (pyftsubset):
   ~15 KB cada. Um caractere fora disso cai na fonte do sistema. */

@font-face { font-family: Inter; font-weight: 400; font-display: swap; src: url(fonts/Inter-Regular.woff2) format("woff2"); }
@font-face { font-family: Inter; font-weight: 600; font-display: swap; src: url(fonts/Inter-SemiBold.woff2) format("woff2"); }
@font-face { font-family: Inter; font-weight: 700; font-display: swap; src: url(fonts/Inter-Bold.woff2) format("woff2"); }
@font-face { font-family: Inter; font-weight: 800; font-display: swap; src: url(fonts/Inter-ExtraBold.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 600; font-display: swap; src: url(fonts/IBMPlexMono-SemiBold.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 700; font-display: swap; src: url(fonts/IBMPlexMono-Bold.woff2) format("woff2"); }

/* 1. Tokens */
:root {
  --ink: #101820;
  --ink-soft: #2B343C;
  --carbon: #171A1C;
  --paper: #F4F3EF;
  --paper-deep: #EAE8E1;
  --white: #FFFFFF;
  --line: #DAD7CE;
  --line-strong: #B4B0A5;
  --muted: #62676B;
  --signal: #E0A72F;
  --signal-soft: #F6E8B8;
  --danger: #C83A32;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --r-xs: 2px;
  --r-sm: 4px;
  --r-md: 6px;
  --topbar-h: 64px;
}

/* 2. Base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--topbar-h) + 12px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); }
h1, h2, h3 { color: var(--ink); line-height: 1.15; margin: 0; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); font-weight: 800; letter-spacing: -.03em; margin-bottom: 36px; }
h3 { font-size: 1.08rem; font-weight: 800; letter-spacing: -.01em; margin-bottom: 6px; }
p { margin: 0; }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 2px; }

.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 768px) { .wrap { padding: 0 32px; } }
.narrow { max-width: 820px; }

/* Rotulo de sinalizacao: pequeno, espacado, em maiusculas. */
.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink); margin-bottom: 14px; display: flex; align-items: center; gap: 10px; }
.eyebrow::before { content: ""; width: 10px; height: 10px; background: var(--ink); flex: none; }
.hero .eyebrow { color: rgb(255 255 255 / .75); }
.hero .eyebrow::before { background: var(--signal); }

/* 3. Botoes: cantos moderados, sem pilula. Amarelo e a acao de contato. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 0 22px;
  border-radius: var(--r-md); border: 2px solid transparent;
  font: inherit; font-weight: 700; font-size: 1rem; text-decoration: none;
  cursor: pointer; transition: background-color .15s, color .15s, border-color .15s;
}
.btn-signal { background: var(--signal); color: var(--ink); }
.btn-signal:hover { background: #EDB648; }
.btn-outline-light { border-color: rgb(255 255 255 / .6); color: var(--white); }
.btn-outline-light:hover { background: rgb(255 255 255 / .08); border-color: var(--white); }
.btn-ghost { min-height: 40px; padding: 0 18px; background: var(--ink); color: var(--white); }
.btn-ghost:hover { background: var(--ink-soft); }

/* 4. Topo */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgb(244 243 239 / .96);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-bottom: 1.5px solid var(--ink);
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between; height: var(--topbar-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.wordmark { font-size: 1.12rem; letter-spacing: .08em; font-weight: 400; }
.wordmark b { font-weight: 800; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a:not(.btn) { color: var(--ink); font-weight: 600; font-size: .95rem; text-decoration: none; }
.nav a:not(.btn):hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; }
.menu-toggle { display: none; }

/* No celular o menu vira uma gaveta abaixo do topo. */
@media (max-width: 767px) {
  .menu-toggle {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 44px; height: 44px; padding: 0 11px; margin-right: -8px;
    background: none; border: 0; cursor: pointer;
  }
  .menu-toggle span { display: block; height: 2px; background: var(--ink); transition: transform .2s, opacity .2s; }
  .menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav {
    display: none;
    position: absolute; top: var(--topbar-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 4px 16px 16px; background: var(--paper);
    border-bottom: 1.5px solid var(--ink);
  }
  .nav.open { display: flex; }
  .nav a:not(.btn) { padding: 14px 2px; border-bottom: 1px solid var(--line); }
  .nav .btn { margin-top: 14px; min-height: 48px; }
}

/* 5. Abertura: tinta chapada, sem gradiente. A faixa zebrada embaixo e a
   mesma do estado Chamado no app. */
.hero { position: relative; color: var(--white); background: var(--ink); padding: 56px 0 72px; overflow: hidden; }
.hero-grid { display: grid; gap: 48px; align-items: center; }
@media (min-width: 1024px) {
  .hero { padding: 88px 0 104px; }
  .hero-grid { grid-template-columns: 1fr 1.15fr; gap: 56px; }
}
.hero h1 { color: var(--white); font-size: clamp(2.2rem, 5vw, 3.5rem); font-weight: 800; letter-spacing: -.035em; margin-bottom: 20px; }
.hero h1 span { color: var(--signal); display: block; }
.lead { font-size: 1.12rem; color: rgb(255 255 255 / .8); max-width: 560px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero-points { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-wrap: wrap; gap: 10px 24px; color: rgb(255 255 255 / .72); font-size: .93rem; }
.hero-points li { display: inline-flex; align-items: center; gap: 8px; }
.hero-points li::before { content: ""; width: 8px; height: 8px; background: var(--white); }
.stripe {
  position: absolute; left: 0; right: 0; bottom: 0; height: 12px;
  background: repeating-linear-gradient(-55deg, var(--signal) 0 14px, var(--ink) 14px 28px);
}

/* Capturas emolduradas: navegador ao fundo, celular na frente. */
.hero-art { position: relative; padding-right: 15%; padding-bottom: 8%; }
.browser { margin: 0; border-radius: var(--r-sm); overflow: hidden; background: var(--white); border: 1px solid rgb(255 255 255 / .18); }
.browser-bar { display: flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; background: var(--paper-deep); }
.browser-bar i { width: 8px; height: 8px; background: var(--line-strong); }
.browser-bar span { margin-left: 10px; padding: 1px 8px; background: var(--white); color: var(--muted); font-family: var(--mono); font-size: .68rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.phone {
  position: absolute; right: 0; bottom: 0; width: 30%; margin: 0;
  border: 6px solid var(--carbon); border-radius: 22px; overflow: hidden;
  background: var(--carbon); outline: 1px solid rgb(255 255 255 / .2);
}
.phone img { border-radius: 16px; }

/* 6. Secoes e blocos */
.section { padding: 72px 0; }
.section.alt { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
@media (min-width: 1024px) { .section { padding: 96px 0; } }

/* Grade com filetes: os blocos se separam por linha, nao por cartao. */
.grid { display: grid; gap: 0; border-top: 1.5px solid var(--ink); }
@media (min-width: 640px) { .grid.four, .grid.three { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) {
  .grid.four { grid-template-columns: repeat(4, 1fr); }
  .grid.three { grid-template-columns: repeat(3, 1fr); }
}
.card { padding: 24px 24px 28px 0; border-bottom: 1px solid var(--line); }
@media (min-width: 640px) { .card { padding-right: 28px; } }
.card p { color: var(--muted); font-size: .96rem; }
.num { display: block; font-family: var(--mono); font-weight: 700; font-size: .95rem; color: var(--muted); margin-bottom: 14px; }
.mark { display: block; width: 12px; height: 12px; margin-bottom: 16px; background: var(--ink); }
.mark.red { background: var(--danger); }

/* 7. Como funciona: os passos sao o trilho do agendamento, como no app. */
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 28px 6px; }
@media (min-width: 640px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .steps { grid-template-columns: repeat(4, 1fr); } }
.steps li { position: relative; padding-right: 20px; }
.steps p { color: var(--muted); font-size: .96rem; }
.step-n {
  display: inline-block; padding: 2px 7px; margin-bottom: 10px;
  background: var(--ink); color: var(--white);
  font-family: var(--mono); font-weight: 700; font-size: .95rem;
}
.step-n.signal { background: var(--signal); color: var(--ink); }
.lane { display: block; height: 6px; margin-bottom: 18px; background: var(--ink); }
.lane.signal { background: var(--signal); }

/* 8. Telas (abas e galeria) */
.tabs { display: inline-flex; margin-bottom: 28px; border: 1.5px solid var(--ink); border-radius: var(--r-sm); overflow: hidden; max-width: 100%; }
.tab {
  min-height: 42px; padding: 0 18px; border: 0;
  background: var(--white); color: var(--ink); font: inherit; font-weight: 700; font-size: .93rem; cursor: pointer;
}
.tab + .tab { border-left: 1.5px solid var(--ink); }
.tab[aria-selected="true"] { background: var(--ink); color: var(--white); }
.gallery { display: grid; gap: 24px; }
.gallery figure { margin: 0; }
.gallery img { border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--white); }
.gallery figcaption { margin-top: 10px; color: var(--ink); font-size: .92rem; font-weight: 600; }
@media (min-width: 768px) { .gallery.desk { grid-template-columns: repeat(2, 1fr); gap: 36px 28px; } }
.gallery.mobile { grid-template-columns: repeat(2, 1fr); gap: 20px 14px; }
@media (min-width: 900px) { .gallery.mobile { grid-template-columns: repeat(4, 1fr); gap: 28px; } }
.gallery.mobile img { border: 5px solid var(--carbon); border-radius: 20px; }

/* 9. Perguntas: lista com filetes, sem caixas. */
.faq { border-top: 1.5px solid var(--ink); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 2px; cursor: pointer; list-style: none;
  font-weight: 700; color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; font-family: var(--mono); font-weight: 700; font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 2px 20px; color: var(--muted); max-width: 680px; }

/* 10. Chamada final */
.cta { position: relative; background: var(--ink); color: var(--white); padding: 72px 0 84px; }
.cta-inner { display: grid; gap: 8px; align-items: center; }
@media (min-width: 900px) { .cta-inner { grid-template-columns: 1.2fr auto; gap: 40px; } .cta .actions { margin-top: 0; } }
.cta h2 { color: var(--white); margin-bottom: 12px; }
.cta p { color: rgb(255 255 255 / .78); font-size: 1.05rem; max-width: 560px; }

/* 11. Rodape */
.footer { background: var(--carbon); color: rgb(255 255 255 / .68); font-size: .9rem; padding: 28px 0; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; align-items: center; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.footer a { color: var(--white); text-decoration: none; font-weight: 600; overflow-wrap: anywhere; }
.footer a:hover { text-decoration: underline; }

/* 12. Celular estreito */
@media (max-width: 479px) {
  .actions .btn { flex: 1 1 100%; }
  .hero-art { padding-right: 20%; }
  .phone { width: 36%; border-width: 4px; border-radius: 16px; }
  .phone img { border-radius: 12px; }
  .tab { padding: 0 14px; }
}
