/* Vetubrore — hoja de estilo común */

:root {
  --bg: #101a24;
  --bg-alt: #16232f;
  --bg-light: #e9edf0;
  --text: #e3e9ee;
  --muted: #8b9aa6;
  --ink: #101a24;
  --accent: #3fb3ae;
  --accent-2: #d8a15a;
  --rule: #070d13;
  --pad-y: 72px;
  --pad-x: 44px;
  --serif: Georgia, 'Times New Roman', serif;
  --sans: system-ui, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.9;
  overflow-x: hidden;
}

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

a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 4px;
}

a:hover { text-decoration-thickness: 2px; }

a:focus-visible,
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: normal;
  line-height: 1.3;
  margin: 0 0 22px;
}

h1 { font-size: clamp(30px, 4.6vw, 50px); }
h2 { font-size: clamp(25px, 2.7vw, 33px); }
h3 { font-size: clamp(20px, 1.7vw, 23px); margin-top: 34px; }

p { margin: 0 0 28px; max-width: 66ch; }
p:last-child { margin-bottom: 0; }

.caption {
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
  max-width: 40ch;
}

.num {
  font-family: var(--serif);
  font-size: 14px;
  letter-spacing: 0.08em;
  color: var(--accent-2);
  display: block;
  margin-bottom: 14px;
}

/* ---------- cabecera y navegación ---------- */

.topbar {
  background: var(--bg-alt);
  border-bottom: 6px solid var(--rule);
  padding: 24px var(--pad-x);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 18px 34px;
}

.brand {
  font-family: var(--serif);
  font-size: 22px;
  letter-spacing: 0.02em;
  color: var(--text);
  text-decoration: none;
}

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

.topnav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 26px;
  font-size: 16px;
}

.topnav a { color: var(--muted); text-decoration: none; }
.topnav a:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 5px; }
.topnav a[aria-current="page"] {
  color: var(--text);
  border-bottom: 2px solid var(--accent-2);
}

/* ---------- hero ---------- */

.hero {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 5px;
  background: var(--rule);
  border-bottom: 6px solid var(--rule);
}

.hero-title {
  grid-column: span 7;
  grid-row: 1 / span 2;
  background: var(--bg-alt);
  padding: var(--pad-y) var(--pad-x);
  display: flex;
  align-items: center;
}

.hero-title h1 { margin: 0; max-width: 18ch; }
.hero-title .line { display: block; }

.hero-intro {
  grid-column: span 5;
  background: var(--accent);
  color: var(--ink);
  padding: 52px var(--pad-x);
}

.hero-intro p { max-width: 40ch; }

.hero-field {
  grid-column: span 5;
  background: var(--bg-light);
  min-height: 120px;
}

.hero-nav {
  grid-column: span 12;
  background: var(--bg);
  padding: 26px var(--pad-x);
}

.hero-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 30px;
  font-size: 15px;
  line-height: 1.7;
}

.hero-nav a { color: var(--muted); text-decoration: none; }
.hero-nav a:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 5px; }

/* ---------- bandas y rejilla ---------- */

.band {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 6px;
  background: var(--rule);
  border-bottom: 6px solid var(--rule);
}

.cell {
  background: var(--bg);
  padding: var(--pad-y) var(--pad-x);
  min-width: 0;
}

.cell.alt { background: var(--bg-alt); }
.cell.light { background: var(--bg-light); color: var(--ink); }
.cell.light .caption { color: #4d5c68; }
.cell.light .num { color: #a06f2a; }
.cell.light a { color: #17726f; }
.cell.solid { background: var(--accent); color: var(--ink); }
.cell.plain { padding: 0; }

.c2 { grid-column: span 2; }
.c3 { grid-column: span 3; }
.c4 { grid-column: span 4; }
.c5 { grid-column: span 5; }
.c6 { grid-column: span 6; }
.c7 { grid-column: span 7; }
.c8 { grid-column: span 8; }
.c12 { grid-column: span 12; }

.side { padding: var(--pad-y) var(--pad-x); }

/* ---------- imágenes ---------- */

.figure-main {
  margin: 0;
  border: 5px solid var(--rule);
  background: var(--rule);
}

.figure-detail { margin: 0; }
.figure-detail img { width: 100%; }
.figure-detail figcaption { margin-top: 16px; }

/* ---------- listas ---------- */

ul.marked, ol.marked {
  margin: 0 0 28px;
  padding: 0;
  list-style: none;
  max-width: 66ch;
}

ul.marked li, ol.marked li {
  position: relative;
  padding-left: 26px;
  margin-bottom: 14px;
}

ul.marked li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 15px;
  width: 12px;
  height: 2px;
  background: var(--accent);
}

ol.marked { counter-reset: paso; }
ol.marked li { padding-left: 38px; }
ol.marked li::before {
  counter-increment: paso;
  content: counter(paso, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0;
  font-family: var(--serif);
  font-size: 15px;
  color: var(--accent-2);
}

.cell.light ul.marked li::before { background: #17726f; }
.cell.light ol.marked li::before { color: #a06f2a; }

dl.terms { margin: 0 0 28px; max-width: 66ch; }
dl.terms dt {
  font-family: var(--serif);
  font-size: 20px;
  margin-top: 26px;
  color: var(--text);
}
dl.terms dd { margin: 6px 0 0; }
.cell.light dl.terms dt { color: var(--ink); }

.hairline {
  border: 0;
  border-top: 1px solid var(--accent-2);
  margin: 40px 0;
  max-width: 120px;
}

/* ---------- páginas de texto ---------- */

.stack { display: grid; gap: 6px; background: var(--rule); border-bottom: 6px solid var(--rule); }

.panel { background: var(--bg); padding: var(--pad-y) var(--pad-x); }
.panel.alt { background: var(--bg-alt); }
.panel.light { background: var(--bg-light); color: var(--ink); }
.panel.light a { color: #17726f; }
.panel.light .num { color: #a06f2a; }
.panel.light ul.marked li::before { background: #17726f; }
.panel-inner { max-width: 62ch; }
.panel.tall { padding-top: 104px; padding-bottom: 104px; }

/* ---------- pie ---------- */

.site-footer {
  border-top: 6px solid var(--rule);
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 6px;
  background: var(--rule);
}

.foot {
  padding: 48px var(--pad-x);
  min-width: 0;
}

.foot-name { grid-column: span 4; background: var(--bg-alt); }
.foot-nav { grid-column: span 3; background: var(--bg); }
.foot-mail { grid-column: span 5; background: var(--bg-light); color: var(--ink); }
.foot-mail a { color: #17726f; }
.foot-mail p { font-size: 16px; max-width: 44ch; }

.foot-name .brand-mark {
  font-family: var(--serif);
  font-size: 24px;
  display: block;
  margin-bottom: 16px;
}

.foot-name p { font-size: 15px; color: var(--muted); max-width: 34ch; }

.foot-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 16px;
  line-height: 2.1;
}

.foot-nav a { color: var(--muted); text-decoration: none; }
.foot-nav a:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 5px; }

/* ---------- adaptación ---------- */

@media (max-width: 1000px) {
  :root { --pad-y: 56px; --pad-x: 32px; }

  .hero-title,
  .hero-intro,
  .hero-field,
  .hero-nav { grid-column: 1 / -1; grid-row: auto; }

  .c2, .c3, .c4, .c5, .c6, .c7, .c8 { grid-column: 1 / -1; }

  .foot-name, .foot-nav, .foot-mail { grid-column: 1 / -1; }

  .hero-field { min-height: 64px; }
}

@media (max-width: 620px) {
  :root { --pad-y: 44px; --pad-x: 20px; }
  body { font-size: 17px; line-height: 1.85; }
  .topbar { padding: 20px 20px; }
  .topnav ul { gap: 6px 20px; font-size: 15px; }
  .panel.tall { padding-top: 56px; padding-bottom: 56px; }
}
