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

:root {
  --bg: #eef4f1;
  --bg-alt: #dfeae5;
  --dark: #1c2a28;
  --text: #16211f;
  --muted: #5f7370;
  --accent: #2f6f63;
  --accent-2: #c25340;
  --serif: Georgia, 'Times New Roman', serif;
  --sans: system-ui, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --gap: 24px;
  --rhythm: 80px;
}

* { 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: 17px;
  line-height: 1.72;
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: normal;
  text-transform: none;
  color: var(--text);
}

h1 {
  font-size: clamp(1.95rem, 4.2vw, 3rem);
  line-height: 1.14;
  margin: 0 0 18px;
  letter-spacing: -0.01em;
}

h2 {
  font-size: clamp(1.42rem, 2.5vw, 1.95rem);
  line-height: 1.25;
  margin: 0 0 18px;
}

h3 {
  font-style: italic;
  font-size: 1.18rem;
  line-height: 1.35;
  margin: 32px 0 10px;
}

p { margin: 0 0 18px; max-width: 68ch; }

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

a:hover { text-decoration-style: dashed; }

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

.label {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.14em;
  line-height: 1.6;
  color: var(--muted);
  margin: 0 0 14px;
}

.label .num { color: var(--accent-2); }

/* ---------- rejilla ---------- */

.wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 32px;
}

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

/* ---------- costura punteada ---------- */

.stitch-box { position: relative; }

.stitch-box::before {
  content: "";
  position: absolute;
  inset: var(--stitch-inset, 24px);
  pointer-events: none;
  background-image:
    repeating-linear-gradient(to right, var(--stitch-color, var(--accent)) 0 14px, transparent 14px 26px),
    repeating-linear-gradient(to right, var(--stitch-color, var(--accent)) 0 14px, transparent 14px 26px),
    repeating-linear-gradient(to bottom, var(--stitch-color, var(--accent)) 0 14px, transparent 14px 26px),
    repeating-linear-gradient(to bottom, var(--stitch-color, var(--accent)) 0 14px, transparent 14px 26px);
  background-size: 100% 2px, 100% 2px, 2px 100%, 2px 100%;
  background-position: left top, left bottom, left top, right top;
  background-repeat: no-repeat;
}

.seam { position: relative; }

.seam::after {
  content: "";
  position: absolute;
  top: 4px;
  bottom: 4px;
  width: 2px;
  background: repeating-linear-gradient(to bottom, var(--accent) 0 12px, transparent 12px 24px);
}

.seam-left::after { left: -14px; }
.seam-right::after { right: -28px; }

.rule {
  height: 2px;
  border: 0;
  margin: 30px 0;
  background: repeating-linear-gradient(to right, var(--muted) 0 10px, transparent 10px 20px);
  background-size: 100% 2px;
  background-repeat: no-repeat;
  max-width: 68ch;
}

.rule-double {
  height: 8px;
  border: 0;
  margin: 0;
  background-image:
    linear-gradient(var(--accent-2), var(--accent-2)),
    repeating-linear-gradient(to right, var(--muted) 0 10px, transparent 10px 20px);
  background-size: 100% 1px, 100% 2px;
  background-position: left top, left 6px;
  background-repeat: no-repeat;
}

/* ---------- cabecera ---------- */

.site-header { padding: 26px 0 20px; }

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px 32px;
}

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

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

.brand:hover { text-decoration: underline dashed; text-underline-offset: 5px; }

.site-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 24px;
  margin: 0;
  padding: 0;
}

.site-nav a {
  font-size: 14.5px;
  color: var(--text);
  text-decoration: none;
  padding-bottom: 3px;
  border-bottom: 1px dashed transparent;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* ---------- portada ---------- */

.hero {
  padding: 34px 0 var(--rhythm);
  --stitch-inset: 24px;
}

.hero .grid { row-gap: 0; }

.hero-head { grid-column: 1 / 9; padding: 44px 0 0; }

.hero-head h1 { max-width: 17ch; }

.hero-intro {
  grid-column: 9 / 13;
  padding: 52px 0 0 16px;
}

.hero-intro p {
  font-size: 16px;
  color: var(--muted);
  max-width: 34ch;
}

.hero-figure {
  grid-column: 7 / 13;
  margin: 50px 0 0;
  padding: 12px;
  --stitch-inset: 0px;
  justify-self: end;
  width: 100%;
}

.hero-figure img,
figure img {
  display: block;
  width: 100%;
  height: auto;
}

figcaption {
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--muted);
  margin-top: 14px;
  max-width: 46ch;
}

figcaption b {
  font-weight: normal;
  color: var(--accent-2);
}

.hero-aside {
  grid-column: 1 / 6;
  margin-top: 50px;
  padding-right: 24px;
}

.hero-aside p { font-size: 16px; }

/* ---------- secciones ---------- */

.band { padding: var(--rhythm) 0; }
.band-alt { background: var(--bg-alt); }

.band-dark {
  background: var(--dark);
  color: var(--bg);
}

.band-dark h2,
.band-dark h3 { color: var(--bg); }

.band-dark p { color: #cfdcd8; }

.band-dark .label { color: #9db3ae; }

.band-dark a { color: #9ed2c6; }

.band-dark a:focus-visible { outline-color: #9ed2c6; }

.block-7-left { grid-column: 1 / 8; }
.block-5-right { grid-column: 8 / 13; }
.block-7-right { grid-column: 6 / 13; }
.block-5-left { grid-column: 1 / 6; }
.block-8-left { grid-column: 1 / 9; }
.block-6-right { grid-column: 7 / 13; }
.block-9-left { grid-column: 1 / 10; }

.dark-figure {
  grid-column: 1 / 6;
  margin: 0;
  padding: 12px;
  --stitch-inset: 0px;
  --stitch-color: #6f8c86;
}

.dark-text { grid-column: 7 / 13; }

.dark-figure figcaption { color: #9db3ae; }

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

ul.check,
ol.steps {
  max-width: 64ch;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

ul.check li,
ol.steps li {
  position: relative;
  padding: 0 0 0 26px;
  margin-bottom: 10px;
}

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

ol.steps { counter-reset: paso; }

ol.steps li { padding-left: 38px; }

ol.steps li::before {
  counter-increment: paso;
  content: counter(paso, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0;
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--accent-2);
  line-height: 2.4;
}

.band-dark ul.check li::before { background: #9ed2c6; }

/* ---------- páginas interiores ---------- */

.page-head { padding: 30px 0 46px; }

.page-head h1 { max-width: 20ch; }

.page-head p {
  color: var(--muted);
  max-width: 60ch;
}

.about-block { margin-bottom: 64px; padding: 26px 30px; }
.about-block:last-child { margin-bottom: 0; }
.about-block h2 { margin-top: 0; }
.about-block--a { grid-column: 1 / 9; --stitch-inset: 0px; }
.about-block--b { grid-column: 5 / 11; --stitch-inset: 0px; }
.about-block--c { grid-column: 3 / 10; --stitch-inset: 0px; }

.legal { padding-bottom: 70px; }
.legal h2 { margin-top: 46px; }
.legal h2:first-of-type { margin-top: 0; }

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

.site-footer {
  background: var(--bg-alt);
  margin-top: var(--rhythm);
  padding: 46px 0 40px;
  --stitch-inset: 16px;
  --stitch-color: var(--muted);
}

.footer-top { padding-bottom: 30px; }

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 34px 40px;
  padding: 30px 22px 6px;
}

.footer-brand { max-width: 40ch; }

.footer-brand .brand { display: inline-block; margin-bottom: 8px; }

.footer-brand p {
  font-size: 14.5px;
  color: var(--muted);
  margin: 0;
}

.footer-nav ul {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
}

.footer-nav a {
  font-size: 14.5px;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px dashed var(--muted);
  padding-bottom: 2px;
}

.footer-nav a:hover { color: var(--accent); border-bottom-color: var(--accent); }

.footer-mail { font-size: 14.5px; }

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

@media (max-width: 900px) {
  :root { --rhythm: 48px; --gap: 18px; }

  .wrap { padding: 0 22px; }

  .hero { --stitch-inset: 12px; }

  .seam::after { display: none; }

  .hero-head,
  .hero-intro,
  .hero-figure,
  .hero-aside,
  .dark-figure,
  .dark-text,
  .block-7-left,
  .block-5-right,
  .block-7-right,
  .block-5-left,
  .block-8-left,
  .block-6-right,
  .block-9-left,
  .about-block--a,
  .about-block--b,
  .about-block--c {
    grid-column: 1 / -1;
  }

  .hero-head { padding-top: 30px; }
  .hero-intro { padding: 0 0 6px; }
  .hero-intro p { max-width: 60ch; }
  .hero-figure { margin-top: 28px; }
  .hero-aside { margin-top: 30px; padding-right: 0; }
  .dark-figure { margin-bottom: 30px; }
  .about-block { margin-bottom: 34px; padding: 20px 18px; }
  .footer-inner { padding: 26px 14px 4px; }
  h3 { margin-top: 26px; }
}

@media (max-width: 560px) {
  body { font-size: 16.5px; }
  .site-nav ul { gap: 4px 16px; }
  .hero-figure { padding: 8px; }
}
