/* Reconnect Project: base partilhada
   Tokens, fontes, tipografia, cabeçalho, rodapé, botões.
   Regras de contraste e de tipografia em CLAUDE.md. */

/* ---------- Fontes (auto-alojadas, latin + latin-ext) ---------- */

@font-face {
  font-family: "Karla";
  src: url("/fonts/karla-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Karla";
  src: url("/fonts/karla-latin-ext-wght-normal.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Karla";
  src: url("/fonts/karla-latin-wght-italic.woff2") format("woff2");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Karla";
  src: url("/fonts/karla-latin-ext-wght-italic.woff2") format("woff2");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond-latin-ext-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond-latin-600-italic.woff2") format("woff2");
  font-weight: 600;
  font-style: italic;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/fonts/cormorant-garamond-latin-ext-600-italic.woff2") format("woff2");
  font-weight: 600;
  font-style: italic;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Tokens ---------- */

:root {
  --navy: #021d49;
  --apricot: #ffc37b;
  --apricot-bg: #ffd29c;  /* apricot ligeiramente esbatido, só como fundo de bloco */
  --white: #ffffff;
  --tan: #ab8c6a;      /* só títulos grandes sobre branco */
  --surface: #f4f6f8;
  --line: #dde1e6;
  --muted: #5a6472;

  --serif: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --sans: "Karla", system-ui, -apple-system, "Segoe UI", sans-serif;

  --measure: 52ch;   /* ≈ 66 caracteres em Karla (o ch da Karla é mais largo do que a média) */
  --gutter: clamp(1.25rem, 5vw, 3rem);
  --wide: 76rem;
  --ease: cubic-bezier(.2, .6, .2, 1);
  --t: 180ms;
}

/* ---------- Reset curto ---------- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body, h1, h2, h3, h4, p, ul, ol, figure, blockquote, dl, dd { margin: 0; }
img, picture, svg { display: block; max-width: 100%; height: auto; }
button { font: inherit; }

/* ---------- Tipografia ---------- */

body {
  background: var(--white);
  color: var(--navy);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.68;
  font-kerning: normal;
  -webkit-font-smoothing: antialiased;
}

/* Cormorant só a partir de 28px. Os mínimos dos clamp() garantem isso. */
.display, h1, h2 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.005em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.75rem, 7vw, 5.25rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }

/* h3 e abaixo em Karla */
h3 {
  font-family: var(--sans);
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.35;
}

p, li { max-width: var(--measure); }
p + p { margin-top: 1em; }
strong { font-weight: 700; }

.lede { font-size: 1.1875rem; line-height: 1.6; }
.meta { font-size: 0.9375rem; color: var(--muted); }
.on-dark .meta { color: rgba(255, 255, 255, .78); }

a { color: inherit; text-underline-offset: .2em; text-decoration-thickness: 1px; transition: text-decoration-color var(--t) var(--ease), color var(--t) var(--ease); }
a:hover { text-decoration-thickness: 2px; }

:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
.on-dark :focus-visible { outline-color: var(--apricot); }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--apricot); color: var(--navy); padding: .75rem 1rem; font-weight: 700;
}
.skip-link:focus { top: 1rem; }

/* ---------- Superfícies ---------- */

.on-dark { background: var(--navy); color: var(--white); }
.on-dark h1, .on-dark h2 { color: var(--white); }
.on-surface { background: var(--surface); }
/* Apricot: no máximo uma vez por página, sempre com texto navy */
.on-apricot { background: var(--apricot-bg); color: var(--navy); }

/* ---------- Botões ---------- */

.button {
  display: inline-flex; align-items: center; gap: .6em;
  min-height: 48px; padding: .8em 1.5em;
  font-family: var(--sans); font-size: 1rem; font-weight: 700; letter-spacing: .01em;
  text-decoration: none; border-radius: 2px; border: 1px solid transparent;
  transition: background-color var(--t) var(--ease), color var(--t) var(--ease), border-color var(--t) var(--ease);
}
.button--primary { background: var(--navy); color: var(--white); }
.button--primary:hover { background: #0b2c66; }
.on-dark .button--primary { background: var(--apricot); color: var(--navy); }
.on-dark .button--primary:hover { background: var(--white); }
.on-apricot .button--primary { background: var(--navy); color: var(--white); }

.button--ghost { border-color: currentColor; color: inherit; background: transparent; }
.button--ghost:hover { background: var(--navy); color: var(--white); border-color: var(--navy); }
.on-dark .button--ghost:hover { background: var(--white); color: var(--navy); border-color: var(--white); }

/* ---------- Marcadores de pendentes (nunca publicar com estes visíveis) ---------- */

.pending {
  display: inline-block; padding: .1em .5em;
  background: var(--white); color: #8a1c1c; border: 1px dashed #8a1c1c;
  font-family: var(--sans); font-size: .875rem; font-weight: 700;
}

/* ---------- Imagens ---------- */

.photo { position: relative; overflow: hidden; background: var(--surface); }
.on-dark .photo { background: #0b2148; }
.photo img { width: 100%; height: 100%; object-fit: cover; object-position: var(--focus, 50% 50%); }

/* aparecem suavemente quando carregam (só com JS; sem JS ficam visíveis) */
.js .photo img { opacity: 0; transition: opacity 400ms var(--ease); }
.js .photo img.is-loaded { opacity: 1; }

/* ---------- Rodapé ---------- */

.site-footer { background: var(--navy); color: var(--white); padding: 4rem var(--gutter) 2.5rem; }
.site-footer__inner { max-width: var(--wide); margin: 0 auto; display: grid; gap: 2.5rem; }
.site-footer__brand img { width: 150px; }
.site-footer nav ul, .site-footer__contact { list-style: none; padding: 0; display: grid; gap: .5rem; }
.site-footer a { text-decoration-color: rgba(255, 255, 255, .4); }
.site-footer a:hover { text-decoration-color: var(--apricot); }
.site-footer__legal span { display: block; }
.site-footer__legal { max-width: none; font-size: .875rem; color: rgba(255, 255, 255, .72); border-top: 1px solid rgba(255, 255, 255, .16); padding-top: 1.5rem; }
@media (min-width: 48rem) {
  .site-footer__inner { grid-template-columns: 1.2fr 1fr 1fr; }
  .site-footer__legal { grid-column: 1 / -1; }
}

/* ---------- Movimento reduzido ---------- */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .js .photo img { opacity: 1; }
}

/* ícones de contacto no rodapé: sempre ao lado do texto, nunca sozinhos */
.site-footer__contact a { display: inline-flex; align-items: flex-start; gap: .6em; }
.site-footer .icone { width: 1.15em; height: 1.15em; flex: none; margin-top: .25em; color: var(--apricot); }
