/* Truntepu — folha de estilos comum */

:root {
  --bg: #eaeee6;
  --bg-alt: #dbe2d5;
  --bg-dark: #26302a;
  --ink: #1b221d;
  --ink-soft: #67715f;
  --ink-on-dark: #eaeee6;
  --accent: #a8512c;
  --accent-2: #4e6f52;
  --serif: Georgia, 'Times New Roman', serif;
  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --space: 128px;
  --gutter: 24px;
  --wrap: 1200px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.65;
  overflow-wrap: break-word;
}

img { display: block; max-width: 100%; height: auto; }

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

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--bg);
  padding: 8px 14px;
  font-family: var(--sans);
  font-size: 14px;
  z-index: 10;
}
.skip:focus { left: 16px; top: 16px; }

/* ---------- Grelha ---------- */

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

.grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
}

.col-text { grid-column: 4 / span 6; }
.col-list { grid-column: 3 / span 7; }
.col-figure { grid-column: 3 / span 8; }

/* ---------- Navegação ---------- */

.site-nav {
  padding: 28px 0;
}
.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 44px;
}
.site-nav a {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  padding: 4px 0;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 6px;
}
.site-nav .brand {
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 0.04em;
  text-transform: none;
  font-style: italic;
}

/* ---------- Hero da página inicial ---------- */

.hero {
  min-height: 92vh;
  min-height: 92svh;
  display: flex;
  flex-direction: column;
}
.hero-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  text-align: center;
  padding-bottom: 20vh;
}
.hero h1 {
  font-weight: normal;
  font-size: clamp(34px, 4.6vw, 58px);
  line-height: 1.12;
  letter-spacing: -0.01em;
  max-width: 17em;
  margin: 0 auto 28px;
}
.hero .lede {
  margin: 0;
  color: var(--ink-soft);
  font-style: italic;
  font-size: 19px;
  max-width: 34em;
}

/* ---------- Cabeçalho das páginas interiores ---------- */

.page-head {
  text-align: center;
  padding: 120px 0 0;
}
.page-head h1 {
  font-weight: normal;
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.15;
  margin: 0 0 20px;
}
.page-head .lede {
  color: var(--ink-soft);
  font-style: italic;
  margin: 0 auto;
  max-width: 32em;
}

/* ---------- Figura principal ---------- */

.lead-figure {
  margin: 96px 0;
}
.lead-figure figure { margin: 0; }
.lead-figure img { width: 100%; }

figcaption {
  font-family: var(--sans);
  font-size: 12px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  margin-top: 14px;
}
.lead-figure figcaption { text-align: center; }

/* ---------- Secções ---------- */

.section { padding: var(--space) 0; }
.section.cont { padding-top: 0; }
.section.alt { background: var(--bg-alt); }
.section.dark {
  background: var(--bg-dark);
  color: var(--ink-on-dark);
}

.num {
  display: block;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--accent-2);
  margin-bottom: 18px;
}

h2 {
  font-weight: normal;
  font-size: clamp(26px, 2.6vw, 34px);
  line-height: 1.22;
  margin: 0 0 36px;
}
h3 {
  font-weight: normal;
  font-style: italic;
  font-size: 22px;
  line-height: 1.35;
  margin: 48px 0 14px;
}

p { margin: 0 0 1.4em; }
.col-text > :last-child,
.col-list > :last-child { margin-bottom: 0; }

.col-list { margin-top: 12px; margin-bottom: 1.6em; }
.col-list:last-child { margin-bottom: 0; }

/* Listas */
.list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.list li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 14px;
}
.list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.72em;
  width: 12px;
  height: 1px;
  background: var(--accent);
}
ol.list { counter-reset: step; }
ol.list li { counter-increment: step; padding-left: 44px; }
ol.list li::before {
  content: counter(step, decimal-leading-zero);
  width: auto;
  height: auto;
  background: none;
  top: 0.35em;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--accent);
}
.list strong { font-weight: bold; }

/* Índice */
.toc {
  list-style: none;
  margin: 0;
  padding: 0;
}
.toc li {
  display: grid;
  grid-template-columns: 44px 1fr;
  align-items: baseline;
  margin-bottom: 12px;
}
.toc span {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--accent-2);
}
.toc a { color: var(--ink); text-decoration-color: var(--accent); }
.toc a:hover { color: var(--accent); }

/* ---------- Secção escura com imagem de detalhe ---------- */

.dark .num { color: #9fbca2; }
.dark a { color: #e39a76; }
.dark a:focus-visible { outline-color: #e39a76; }
.dark .list li::before { background: #e39a76; }
.dark figcaption { color: #b6bfb0; }

.detail-figure {
  grid-column: 1 / span 5;
  margin: 0;
  align-self: start;
}
.detail-text {
  grid-column: 7 / span 6;
  align-self: center;
  max-width: 36em;
}

/* ---------- Contacto ---------- */

.contact-line {
  font-size: 21px;
  margin-top: 8px;
}

/* ---------- Sobre ---------- */

.prose .intro {
  font-size: 21px;
  line-height: 1.6;
}
.prose section { margin-top: 96px; }
.prose section::before {
  content: "—";
  display: block;
  text-align: center;
  color: var(--accent-2);
  margin-bottom: 72px;
}
.prose h2 { text-align: left; }

/* Páginas legais */
.legal h2 { font-size: 24px; margin: 64px 0 18px; }
.legal .updated {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
}

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

.site-footer {
  background: var(--bg-alt);
  padding: 144px 0 112px;
  text-align: center;
}
.footer-name {
  font-size: 26px;
  font-style: italic;
  margin: 0 0 36px;
}
.footer-nav ul {
  list-style: none;
  margin: 0 0 36px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px 40px;
}
.footer-nav a {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
}
.footer-nav a:hover { color: var(--accent); text-decoration: underline; }
.footer-mail { margin: 0 0 28px; }
.footer-note {
  font-family: var(--sans);
  font-size: 12px;
  line-height: 1.6;
  color: #525c4c;
  max-width: 34em;
  margin: 0 auto;
}

/* ---------- Responsivo ---------- */

@media (max-width: 1024px) {
  .col-text { grid-column: 2 / span 10; }
  .col-list { grid-column: 2 / span 10; }
  .col-figure { grid-column: 2 / span 10; }
  .detail-figure { grid-column: 1 / span 5; }
  .detail-text { grid-column: 6 / span 7; }
}

@media (max-width: 760px) {
  :root { --space: 72px; --gutter: 16px; }
  body { font-size: 17px; }
  .col-text, .col-list, .col-figure,
  .detail-figure, .detail-text { grid-column: 1 / -1; }
  .detail-figure { max-width: 420px; margin-bottom: 48px; }
  .site-nav { padding: 20px 0; }
  .site-nav ul { gap: 8px 22px; }
  .hero-body { padding-bottom: 14vh; }
  .hero .lede { font-size: 17px; }
  .lead-figure { margin: 72px 0; }
  .page-head { padding-top: 72px; }
  .prose section { margin-top: 64px; }
  .prose section::before { margin-bottom: 48px; }
  .prose .intro { font-size: 19px; }
  .site-footer { padding: 96px 0 80px; }
  .footer-nav ul { flex-direction: column; gap: 14px; }
  h3 { font-size: 20px; margin-top: 40px; }
}
