/*
 * firmeza.app: the same "anil e pemba" as the dashboard, with more room.
 * The one memorable thing is the guia: a thread down the page with a bead at each section,
 * as in the dashboard's navigation. Beads take the colours of the linhas; everything else stays quiet.
 * Type: Atkinson Hyperlegible Next, set large (many who run a casa are elders).
 */

@font-face {
  font-family: "Atkinson Hyperlegible Next";
  src: url("../fonts/atkinson-hyperlegible-next-latin-wght.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --pemba: #f5f6f8;
  --cal: #ffffff;
  --carvao: #1d2130;
  --cinza: #5d6375;
  --linha: #dadde6;
  --linha-forte: #b9bfcf;
  --anil: #233a7a;
  --anil-ink: #ffffff;
  --anil-wash: #e8ecf7;
  --vela: #9a6412;
  --dende: #a3302a;
  --folha: #2e6a4c;
  --noite: #182448;      /* the closing band: the gira at night */
  --noite-ink: #eef1fa;

  --gutter: 20px;
  --wide: 1120px;
  --text: 40rem;

  color-scheme: light dark;
}

/* Dark: when the system asks for it, or when chosen in the Tema menu. Keep both blocks the same. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --pemba: #141826;
    --cal: #1b2031;
    --carvao: #e6e8ef;
    --cinza: #a3a9ba;
    --linha: #2c3247;
    --linha-forte: #3d4560;
    --anil: #a9b6f0;
    --anil-ink: #141826;
    --anil-wash: #232a42;
    --vela: #f2d49a;
    --dende: #f0a39d;
    --folha: #8ccba9;
    --noite: #0e1220;
    --noite-ink: #e6e8ef;
  }
}
:root[data-theme="dark"] {
  --pemba: #141826;
  --cal: #1b2031;
  --carvao: #e6e8ef;
  --cinza: #a3a9ba;
  --linha: #2c3247;
  --linha-forte: #3d4560;
  --anil: #a9b6f0;
  --anil-ink: #141826;
  --anil-wash: #232a42;
  --vela: #f2d49a;
  --dende: #f0a39d;
  --folha: #8ccba9;
  --noite: #0e1220;
  --noite-ink: #e6e8ef;
}
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: "Atkinson Hyperlegible Next", system-ui, "Segoe UI", sans-serif;
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--carvao);
  background: var(--pemba);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--anil); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--anil); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { line-height: 1.1; letter-spacing: -.02em; margin: 0; }
p { margin: 0 0 1em; }

.skip { position: absolute; left: -999px; }
.skip:focus { left: 8px; top: 8px; z-index: 10; background: var(--cal); padding: 8px 12px; }

.wrap { max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter); }

/* --- Header --- */

.top { border-bottom: 1px solid var(--linha); background: var(--cal); }
.top .wrap { display: flex; align-items: center; gap: 28px; min-height: 64px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.25rem; color: var(--carvao); text-decoration: none; letter-spacing: -.01em; }
.brand svg { width: 22px; height: 22px; }
.top nav { display: flex; gap: 22px; font-size: 1rem; margin-right: auto; }
.top nav a { color: var(--cinza); text-decoration: none; }
.top nav a:hover { color: var(--carvao); }
.top .tools { display: flex; align-items: center; gap: 16px; font-size: 1rem; margin-left: auto; }
.signin { font-weight: 700; text-decoration: none; }

/* Idioma and Tema: native disclosures. The current choice gets a bead, not a different weight,
   so every item reads in the same type. */
.menu { position: relative; }
.menu summary { cursor: pointer; color: var(--cinza); list-style: none; padding: 4px 2px; }
.menu summary::-webkit-details-marker { display: none; }
.menu summary::after { content: ""; display: inline-block; margin-left: 6px; border: 4px solid transparent; border-top-color: currentColor; transform: translateY(2px); }
.menu ul { position: absolute; right: 0; top: calc(100% + 6px); margin: 0; padding: 6px; list-style: none; background: var(--cal); border: 1px solid var(--linha); border-radius: 8px; min-width: 210px; z-index: 5; box-shadow: 0 10px 24px rgb(20 24 38 / .12); }
.menu li a, .menu li button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border: 0; border-radius: 6px; background: none; font: inherit; color: var(--carvao); text-align: left; text-decoration: none; cursor: pointer; }
.menu li a:hover, .menu li button:hover { background: var(--anil-wash); }
.menu li a::before, .menu li button::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; }
.menu li a[aria-current]::before, .menu li button[aria-pressed="true"]::before { background: var(--anil); }

@media (max-width: 760px) {
  .top nav { display: none; }
  .top .wrap { gap: 12px; justify-content: space-between; flex-wrap: nowrap; position: relative; }
  .top .tools { gap: 12px; }
  /* Menus open from the header's right edge, so they never run off the screen. */
  .menu { position: static; }
  .menu ul { right: var(--gutter); top: calc(100% - 6px); }
}
@media (max-width: 400px) {
  .brand { font-size: 1.125rem; }
  .top .tools { font-size: .9375rem; gap: 10px; }
}

/* --- Buttons --- */

.button { display: inline-flex; align-items: center; min-height: 48px; padding: 12px 22px; border-radius: 8px; font-weight: 700; font-size: 1.0625rem; text-decoration: none; border: 1.5px solid var(--anil); }
.button.primary { background: var(--anil); color: var(--anil-ink); }
.button.primary:hover { background: color-mix(in srgb, var(--anil) 88%, var(--carvao)); }
.button.quiet { color: var(--anil); background: transparent; }
.button.quiet:hover { background: var(--anil-wash); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* --- Hero --- */

.hero { padding: 64px 0 72px; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 56px; align-items: center; }
.pilot { display: inline-block; margin-bottom: 18px; padding: 4px 12px; border-radius: 99px; background: var(--anil-wash); color: var(--anil); font-weight: 700; font-size: .9375rem; }
.hero h1 { font-size: clamp(2.4rem, 5.2vw, 3.75rem); font-weight: 800; margin-bottom: 20px; text-wrap: balance; }
.hero .lead { font-size: 1.25rem; color: var(--cinza); max-width: 30rem; margin-bottom: 28px; }
.hero .already { margin: 18px 0 0; font-size: 1rem; color: var(--cinza); }

.art { position: relative; margin: 0 0 28px; }
.browser { border-radius: 10px; overflow: hidden; border: 1px solid var(--linha); background: var(--cal); box-shadow: 0 24px 50px rgb(20 24 38 / .16); }
.browser .address { padding: 7px 12px; font-size: .8125rem; color: var(--cinza); background: var(--pemba); border-bottom: 1px solid var(--linha); }
.browser img { display: block; width: 100%; height: auto; }
/* The screenshot matches the page's theme. Keep in step with the dark tokens above. */
.browser .shot-dark { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .browser .shot-light { display: none; }
  :root:not([data-theme="light"]) .browser .shot-dark { display: block; }
}
:root[data-theme="dark"] .browser .shot-light { display: none; }
:root[data-theme="dark"] .browser .shot-dark { display: block; }

/* What members see: a sketch until the app's own screenshot replaces it. */
.phone { position: absolute; right: -10px; bottom: -36px; width: 190px; padding: 14px 10px 16px; border-radius: 26px; border: 5px solid var(--carvao); background: var(--cal); box-shadow: 0 18px 40px rgb(20 24 38 / .28); font-size: .75rem; line-height: 1.35; }
.phone .casa { font-weight: 800; font-size: .8125rem; margin: 2px 4px 10px; }
.phone ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.phone li { background: var(--pemba); border-radius: 10px; padding: 8px 9px; }
.phone li b { display: flex; align-items: center; gap: 6px; font-size: .8125rem; }
.phone li span { display: block; color: var(--cinza); margin-left: 15px; }
.phone .going { color: var(--folha); font-weight: 700; }
.phone .aviso { background: var(--anil-wash); }

@media (max-width: 900px) {
  .hero { padding: 40px 0 56px; }
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .phone { width: 150px; right: 6px; bottom: -28px; font-size: .6875rem; }
}
@media (max-width: 600px) {
  /* Taller than the screenshot here: hang it below, overlapping a little, instead of over the text. */
  .art { margin-bottom: 0; }
  .phone { position: relative; right: auto; bottom: auto; width: 170px; margin: -48px 8px 0 auto; }
}

/* --- Beads (contas) --- */

.bead { display: inline-block; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--anil); }
.bead.folha { background: var(--folha); }
.bead.cinza { background: var(--cinza); }
.bead.dende { background: var(--dende); }
.bead.vela { background: var(--vela); }
.bead.anil { background: var(--anil); }
.bead.open { background: var(--cal); box-shadow: inset 0 0 0 2px var(--anil); }

/* --- The guia: sections strung on a thread --- */

.guia { position: relative; }
.guia section { padding: 72px 0; scroll-margin-top: 12px; }
.guia section + section { border-top: 1px solid var(--linha); }
.guia h2 { position: relative; font-size: clamp(1.75rem, 3.4vw, 2.375rem); font-weight: 800; margin-bottom: 18px; max-width: 24ch; text-wrap: balance; }
.guia h2 .bead { position: absolute; left: -52px; top: .32em; width: 18px; height: 18px; box-shadow: 0 0 0 6px var(--pemba); }
.intro { color: var(--cinza); font-size: 1.1875rem; max-width: var(--text); margin-bottom: 36px; }

@media (min-width: 1000px) {
  .guia .wrap { padding-left: calc(var(--gutter) + 64px); }
  .guia::before { content: ""; position: absolute; top: 0; bottom: 0; left: calc(max(0px, (100% - var(--wide)) / 2) + var(--gutter) + 20px); width: 2px; background: var(--linha-forte); }
}
@media (max-width: 999px) {
  .guia h2 .bead { position: static; display: block; width: 14px; height: 14px; margin-bottom: 14px; box-shadow: none; }
}

/* Recursos: a quiet two-column list, a bead per item. */
.features { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px 56px; }
.features li { display: grid; grid-template-columns: 10px 1fr; column-gap: 16px; }
.features .bead { margin-top: .5em; }
.features h3 { font-size: 1.25rem; font-weight: 750; margin-bottom: 6px; letter-spacing: -.01em; }
.features p { color: var(--cinza); margin: 0; }
.features li > div { min-width: 0; }
@media (max-width: 720px) { .features { grid-template-columns: 1fr; gap: 28px; } }

.note { margin: 40px 0 0; padding-left: 26px; color: var(--cinza); max-width: var(--text); }

/* Como começar: a real sequence, so the steps are beads on one thread. */
.steps { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; position: relative; }
.steps::before { content: ""; position: absolute; top: 8px; left: 9px; right: calc((100% - 64px) / 3 - 9px); height: 2px; background: var(--linha-forte); }
.steps li { position: relative; padding-top: 38px; }
.steps li::before { content: ""; position: absolute; top: 0; left: 0; width: 18px; height: 18px; border-radius: 50%; background: var(--anil); box-shadow: 0 0 0 6px var(--pemba); }
.steps li:nth-child(2)::before { background: var(--cal); box-shadow: inset 0 0 0 3px var(--anil), 0 0 0 6px var(--pemba); }
.steps h3 { font-size: 1.25rem; font-weight: 750; margin-bottom: 8px; }
.steps p { color: var(--cinza); margin: 0; }
@media (max-width: 760px) {
  .steps { grid-template-columns: 1fr; gap: 28px; padding-left: 36px; }
  .steps::before { top: 9px; bottom: 9px; left: 8px; right: auto; width: 2px; height: auto; }
  .steps li { padding-top: 0; }
  .steps li::before { left: -36px; top: .2em; }
}

/* Prose sections keep the page's left edge (on the thread); only the lines are kept short. */
.text > p { max-width: var(--text); }
.text p:last-child { margin-bottom: 0; }

/* Perguntas frequentes: native disclosures. */
.faq { max-width: 48rem; border-top: 1px solid var(--linha); }
.faq details { border-bottom: 1px solid var(--linha); }
.faq summary { cursor: pointer; padding: 18px 36px 18px 0; font-weight: 700; font-size: 1.1875rem; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 10px; height: 10px; margin-top: -7px; border-right: 2px solid var(--cinza); border-bottom: 2px solid var(--cinza); transform: rotate(45deg); }
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq details p { color: var(--cinza); margin: -4px 0 18px; max-width: var(--text); }

/* --- Closing band --- */

.closing { background: var(--noite); color: var(--noite-ink); padding: 72px 0; }
.closing h2 { font-size: clamp(1.75rem, 3.4vw, 2.5rem); font-weight: 800; margin-bottom: 12px; }
.closing p { color: color-mix(in srgb, var(--noite-ink) 78%, transparent); max-width: var(--text); margin-bottom: 28px; }
.closing .button.primary { background: var(--noite-ink); color: var(--noite); border-color: var(--noite-ink); }
.closing .button.primary:hover { background: #ffffff; }
.closing :focus-visible { outline-color: var(--noite-ink); }

/* --- Footer --- */

.foot { padding: 36px 0 48px; font-size: 1rem; color: var(--cinza); }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 14px 32px; align-items: baseline; }
.foot .brand { font-size: 1.0625rem; margin-right: auto; }
.foot ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; }

/* --- Privacy policy page --- */

.doc { padding: 56px 0 72px; }
.doc .wrap { max-width: 46rem; }
.doc h1 { font-size: clamp(2rem, 4.4vw, 2.75rem); font-weight: 800; margin-bottom: 12px; }
.doc .updated { color: var(--cinza); margin-bottom: 36px; }
.doc h2 { font-size: 1.375rem; margin: 36px 0 10px; letter-spacing: -.01em; }
.doc ul { padding-left: 1.2em; }
.doc li { margin-bottom: .45em; }
