/* ResumAI — identidade editorial (tinta, papel, latão).
   Newsreader + Source Sans 3, self-hosted. Sem CDN. */

@font-face {
  font-family: "Newsreader";
  src: url("/resumai/fonts/Newsreader-VariableFont_opsz_wght.ttf") format("truetype");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Newsreader";
  src: url("/resumai/fonts/Newsreader-Italic-VariableFont_opsz_wght.ttf") format("truetype");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "Source Sans 3";
  src: url("/resumai/fonts/SourceSans3-VariableFont_wght.ttf") format("truetype");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Source Sans 3";
  src: url("/resumai/fonts/SourceSans3-Italic-VariableFont_wght.ttf") format("truetype");
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}

:root {
  color-scheme: light dark;
  --ink: #1B3147;
  --ink-deep: #122436;
  --brass: #B0893A;
  --brass-bright: #C49A4A;
  --brass-text: #6F5420;
  --paper: #F4EFE6;
  --paper-raised: #FFFCF7;
  --paper-sunken: #E8E0D4;
  --rule: #D4CBBC;
  --text: #1C1915;
  --text-secondary: #5A554C;
  --text-tertiary: #726C60;
  --record: #9C3E2C;
  --link: #1B3147;
  --link-hover: #122436;
  --focus: #1B3147;
  --page: 70rem;
  --measure: 36rem;
  --gutter: 1.5rem;
  --margin: 4rem;
  --serif: "Newsreader", "Iowan Old Style", "Palatino Linotype", Palatino, serif;
  --sans: "Source Sans 3", "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #161410;
    --paper-raised: #221E19;
    --paper-sunken: #2A2620;
    --rule: #3A342C;
    --text: #F4EFE6;
    --text-secondary: #B4A99A;
    --text-tertiary: #B4A99A;
    --brass-text: #C49A4A;
    --link: #F4EFE6;
    --link-hover: #C49A4A;
    --focus: #C49A4A;
  }
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  background: var(--paper);
  color: var(--text);
  font-family: var(--sans);
  font-size: 100%;
  line-height: 1.65;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--sans);
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.65;
  min-height: 100vh;
}

body::before {
  content: "";
  display: block;
  height: 4px;
  background: var(--ink);
}

::selection {
  background: var(--ink);
  color: var(--paper-raised);
}

@media (prefers-color-scheme: dark) {
  ::selection {
    background: var(--brass-bright);
    color: #161410;
  }
}

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

:focus:not(:focus-visible) { outline: none; }

img, svg { max-width: 100%; height: auto; display: block; }
audio { display: block; max-width: 36rem; width: 100%; }

a {
  color: var(--link);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover { color: var(--link-hover); }

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 20;
  padding: 0.5rem 0.75rem;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  border-radius: 4px;
}

.skip:focus {
  top: 1rem;
  color: var(--paper);
}

.page {
  width: 100%;
  max-width: calc(var(--page) + (var(--margin) * 2));
  margin: 0 auto;
  padding-left: var(--margin);
  padding-right: var(--margin);
}

@media (max-width: 52rem) {
  :root { --margin: 1.5rem; }
}

/* --- header --- */

.site-header {
  border-bottom: 1px solid var(--rule);
}

.site-header .page {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--ink);
}

.brand:hover { color: var(--ink-deep); }

@media (prefers-color-scheme: dark) {
  .brand, .brand:hover { color: var(--text); }
}

.brand-icon {
  width: 32px;
  height: 32px;
  border-radius: 22%;
}

.wordmark {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.625rem;
  line-height: 1;
  letter-spacing: 0.01em;
  font-optical-sizing: auto;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

.site-nav a {
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.4;
  text-decoration: none;
  color: var(--text-secondary);
}

.site-nav a:hover { color: var(--link); text-decoration: underline; }

.site-nav a[aria-current="page"] {
  color: var(--text);
  box-shadow: inset 0 -1px 0 var(--brass);
}

/* --- type --- */

.overline {
  margin: 0 0 0.75rem;
  font-family: var(--sans);
  font-size: 0.6875rem;
  font-weight: 600;
  line-height: 1.27;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brass-text);
}

h1, h2, h3 {
  font-family: var(--serif);
  font-optical-sizing: auto;
  font-weight: 600;
  color: var(--text);
  text-wrap: balance;
}

h1 {
  margin: 0 0 1.5rem;
  font-size: 2.5rem;
  line-height: 1.2;
  font-weight: 500;
  letter-spacing: -0.015em;
}

h2 {
  margin: 0 0 1rem;
  font-size: 1.75rem;
  line-height: 1.29;
}

h3 {
  margin: 2rem 0 0.5rem;
  font-size: 1.375rem;
  line-height: 1.27;
}

p, li { text-wrap: pretty; }

p { margin: 0 0 1.25rem; }

.dek {
  max-width: var(--measure);
  font-size: 1.1875rem;
  line-height: 1.68;
  color: var(--text);
}

.lede,
.measure,
.legal-body p,
.legal-body li,
.faq p,
.demo-copy p {
  max-width: var(--measure);
}

.caption,
figcaption {
  font-size: 0.8125rem;
  line-height: 1.54;
  color: var(--text-tertiary);
}

.meta {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  color: var(--text-secondary);
}

/* --- landing --- */

.hero {
  padding: 4rem 0 3rem;
}

.hero h1 { max-width: 18ch; }

.hero-rule {
  display: block;
  width: 2.5rem;
  height: 2px;
  margin: 0 0 1.5rem;
  background: var(--brass);
  border: 0;
}

.store {
  margin: 2rem 0 0;
}

.store a {
  display: inline-block;
  padding: 0.75rem 0.75rem 0.75rem 0;
  text-decoration: none;
}

.store img {
  height: 48px;
  width: auto;
}

.badge-dark { display: none; }

@media (prefers-color-scheme: dark) {
  .badge-light { display: none; }
  .badge-dark { display: block; }
}

.pull {
  margin: 3rem 0 0;
  padding: 0 0 0 1.25rem;
  border-left: 2px solid var(--brass);
  max-width: 32rem;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: 1.375rem;
  line-height: 1.45;
  color: var(--text);
}

.pull p { margin: 0; }

.split {
  display: grid;
  grid-template-columns: minmax(0, 28rem) minmax(0, 32rem);
  gap: 4rem;
  padding: 3rem 0 4rem;
  border-top: 1px solid var(--rule);
}

@media (min-width: 64.01rem) {
  .split > div + div {
    border-left: 1px solid var(--rule);
    padding-left: 4rem;
  }
  .legal-nav {
    border-right: 1px solid var(--rule);
    padding-right: 2rem;
  }
}

.steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: passo;
}

.steps li {
  position: relative;
  margin: 0 0 1.25rem;
  padding-left: 2.5rem;
  max-width: 28rem;
  counter-increment: passo;
}

.steps li::before {
  content: counter(passo);
  position: absolute;
  left: 0;
  top: 0.15rem;
  font-family: var(--serif);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
  color: var(--brass-text);
  font-variant-numeric: tabular-nums;
}

.shot {
  padding: 1rem 0 4rem;
  border-top: 1px solid var(--rule);
}

.shot h2 { margin-bottom: 0.5rem; }

.figure-pdf {
  margin: 1.5rem 0 2.5rem;
  max-width: 40rem;
}

.figure-pdf img,
.figure-pair img,
.slide img {
  border: 1px solid var(--rule);
  border-radius: 0;
  background: var(--paper-raised);
}

.figure-pair {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 17.5rem));
  gap: 1.5rem;
  justify-content: start;
  margin: 0;
}

.figure-pair figure { margin: 0; }

figure { margin: 0; }

figcaption { margin-top: 0.5rem; }

.note {
  padding: 0 0 5rem;
  border-top: 1px solid var(--rule);
}

.note p {
  margin-top: 1.25rem;
  max-width: var(--measure);
  color: var(--text-secondary);
}

/* --- legal / support --- */

.legal-wrap,
.stack {
  padding: 3rem 0 5rem;
}

.legal {
  display: grid;
  grid-template-columns: 14rem minmax(0, 36rem);
  column-gap: 4rem;
  row-gap: 2.5rem;
  align-items: start;
}

.legal-nav {
  position: sticky;
  top: 1.5rem;
}

.legal-nav ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

.legal-nav li { margin: 0 0 0.65rem; }

.legal-nav a {
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--text-secondary);
}

.legal-nav a:hover { color: var(--link); text-decoration: underline; }

.legal-body h1 { margin-bottom: 0.75rem; }
.legal-body h2 {
  margin-top: 2.5rem;
  padding-top: 0.5rem;
}

.faq h3 { margin-top: 2rem; }
.faq h3:first-of-type { margin-top: 1.5rem; }

.btn {
  display: inline-block;
  margin: 0.25rem 0 2rem;
  padding: 0.7rem 1.15rem;
  background: var(--ink);
  color: #F4EFE6;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.5;
  border-radius: 4px;
}

.btn:hover {
  background: var(--ink-deep);
  color: #F4EFE6;
}

/* --- demo --- */

.demo-copy { padding: 3rem 0 5rem; }

.demo-copy audio { margin: 0 0 0.75rem; }

.slide {
  margin: 1.25rem 0 1.5rem;
  max-width: 36rem;
}

.source {
  max-width: var(--measure);
  font-size: 0.8125rem;
  line-height: 1.54;
  color: var(--text-tertiary);
}

/* --- footer --- */

.site-footer {
  border-top: 1px solid var(--rule);
  padding: 2rem 0 3rem;
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.site-footer .page {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem 2rem;
}

.site-footer p { margin: 0; }

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
}

.footer-nav a {
  color: var(--text-secondary);
  text-decoration: none;
}

.footer-nav a:hover { color: var(--link); text-decoration: underline; }

/* --- responsive --- */

@media (max-width: 64rem) {
  .split {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .legal {
    grid-template-columns: 1fr;
  }
  .legal-nav { position: static; margin-bottom: 0.5rem; }
  .legal-nav ol {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 1.25rem;
  }
  .legal-nav li { margin: 0; }
}

@media (max-width: 40rem) {
  h1 { font-size: 2rem; line-height: 1.2; }
  h2 { font-size: 1.5rem; }
  .hero { padding: 2.5rem 0 2rem; }
  .figure-pair { grid-template-columns: minmax(0, 17.5rem); }
  .pull { font-size: 1.25rem; }
}

@media print {
  body::before,
  .site-header,
  .site-footer,
  .skip,
  .store,
  .legal-nav { display: none; }
  body { background: #fff; color: #000; }
  a { color: inherit; }
  .page { max-width: none; padding: 0; }
}

/* --- language switcher (v1.1) --- */
.lang-switch {
  display: flex;
  gap: 0.75rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.lang-switch a { color: var(--text-secondary); text-decoration: none; }
.lang-switch a:hover { color: var(--link); text-decoration: underline; }
.lang-switch a[aria-current="true"] { color: var(--text); box-shadow: inset 0 -1px 0 var(--brass); }
