/* Brezekevo — ruled-margin layout
   ------------------------------------------------ */

:root {
  --bg: #eef4f1;
  --bg-alt: #dfeae5;
  --bg-dark: #1c2a28;
  --ink: #16211f;
  --ink-soft: #5f7370;
  --ink-inv: #eef4f1;
  --accent: #2f6f63;
  --accent-2: #c25340;
  --rule: rgba(95, 115, 112, 0.28);
  --rule-dark: rgba(238, 244, 241, 0.22);
  --r: 72px;
  --gap: 24px;
  --shell: 1180px;
  --font: 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(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.7;
  overflow-x: hidden;
}

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

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

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

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

/* ---------- grid shell ---------- */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 0 24px;
}

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

.rail {
  grid-column: 1 / 4;
  border-right: 1px solid var(--accent);
  min-height: 100%;
  align-self: stretch;
  padding-right: var(--gap);
  text-align: right;
  color: var(--accent-2);
  font-size: 13px;
  line-height: 1.5;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.rail .num { display: block; font-weight: 700; }
.rail .note {
  display: block;
  margin-top: 10px;
  color: var(--ink-soft);
  letter-spacing: 0.04em;
  text-transform: none;
}

.rail .initial {
  display: block;
  font-size: 64px;
  line-height: 0.9;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--accent);
  text-transform: none;
}

.col-text { grid-column: 4 / 10; }
.col-body { grid-column: 4 / 10; margin-top: 26px; }
.col-wide { grid-column: 4 / 12; }
.col-full { grid-column: 4 / 13; }

/* ---------- typography ---------- */

h1, h2, h3 { margin: 0; }

h1 {
  font-size: clamp(42px, 7.2vw, 86px);
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.035em;
  max-width: 14ch;
}

h2 {
  font-size: clamp(24px, 2.6vw, 31px);
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: -0.015em;
}

h3 {
  font-size: 19px;
  line-height: 1.35;
  font-weight: 600;
  margin-top: calc(var(--r) / 2);
}

p { margin: 0 0 22px; max-width: 74ch; }
p:last-child { margin-bottom: 0; }

.lead {
  font-size: 19px;
  line-height: 1.65;
  color: var(--ink);
}

.caption {
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink-soft);
}

.caption .mark {
  color: var(--accent-2);
  font-weight: 700;
  letter-spacing: 0.08em;
  display: block;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.guide {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 0;
  height: 0;
}

.heading-guide { margin-top: 18px; }

/* ---------- header / nav ---------- */

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

.site-header .grid { align-items: center; }

.brand {
  grid-column: 1 / 4;
  padding: 22px var(--gap) 22px 0;
  font-weight: 700;
  letter-spacing: 0.02em;
  font-size: 18px;
  text-align: right;
  border-right: 1px solid var(--accent);
  align-self: stretch;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.brand a { color: var(--ink); text-decoration: none; }
.brand a:hover { color: var(--accent); }

.site-nav {
  grid-column: 4 / 13;
  padding: 18px 0;
}

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

.site-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  padding: 4px 0;
  display: inline-block;
  border-bottom: 1px solid transparent;
}

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

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

.hero { padding: var(--r) 0 calc(var(--r) / 2); }

.hero h1 {
  grid-column: 1 / 13;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  column-gap: var(--gap);
  max-width: none;
}

.hero .drop {
  grid-column: 1 / 4;
  justify-self: end;
  align-self: start;
  font-size: clamp(90px, 13vw, 168px);
  line-height: 0.8;
  letter-spacing: -0.06em;
  color: var(--accent);
  border-right: 1px solid var(--accent);
  padding-right: var(--gap);
}

.hero .h1-rest { grid-column: 4 / 13; max-width: 15ch; }

.hero-lede {
  grid-column: 4 / 10;
  margin-top: calc(var(--r) / 2);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 26px 0;
}

.hero-tail {
  grid-column: 4 / 10;
  margin-top: 26px;
}

/* ---------- figures ---------- */

.figure-main { padding-bottom: var(--r); }

.figure-main .fig-note {
  grid-column: 1 / 4;
  border-right: 1px solid var(--accent);
  padding-right: var(--gap);
  text-align: right;
  align-self: stretch;
}

.figure-main .fig-img { grid-column: 6 / 13; }

figure { margin: 0; }

/* ---------- sections ---------- */

.band { padding: var(--r) 0; }
.band + .band { border-top: 1px solid var(--rule); }
.band-alt { background: var(--bg-alt); border-top: 1px solid var(--rule); }

.band-alt + .band { border-top: 1px solid var(--rule); }

.block + .block { margin-top: var(--r); }

.checklist,
.steps {
  grid-column: 4 / 12;
  margin: 30px 0 0;
  padding: 0;
}

.checklist { list-style: none; }

.checklist li {
  position: relative;
  padding: 0 0 12px 26px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--rule);
  max-width: 78ch;
}

.checklist li:last-child { border-bottom: 0; }

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

.steps { padding-left: 22px; }
.steps li { margin-bottom: 14px; max-width: 76ch; }

dl.terms { grid-column: 4 / 12; margin: 26px 0 0; }
dl.terms dt { font-weight: 600; margin-top: 20px; }
dl.terms dd { margin: 4px 0 0; color: var(--ink); max-width: 74ch; }

/* ---------- dark band ---------- */

.band-dark {
  background: var(--bg-dark);
  color: var(--ink-inv);
  padding: var(--r) 0;
}

.band-dark .rail { border-right-color: var(--rule-dark); }
.band-dark .rail .initial { color: var(--bg-alt); }
.band-dark .rail .note { color: rgba(238, 244, 241, 0.62); }
.band-dark .guide { border-top-color: var(--rule-dark); }
.band-dark .caption { color: rgba(238, 244, 241, 0.66); }
.band-dark a { color: #9ecfc3; }

.band-dark .dark-head { grid-column: 4 / 13; margin-bottom: calc(var(--r) / 2); }

.band-dark .dark-img { grid-column: 4 / 8; }
.band-dark .dark-img figcaption { margin-top: 14px; }

.band-dark .dark-text { grid-column: 8 / 13; }
.band-dark .dark-text p { max-width: 52ch; }

.band-dark .checklist li { border-bottom-color: var(--rule-dark); }
.band-dark .checklist li::before { background: var(--accent-2); }

/* ---------- contact block ---------- */

.contact-line {
  grid-column: 4 / 10;
  margin-top: 26px;
  border-top: 1px solid var(--rule);
  padding-top: 20px;
  font-size: 19px;
}

/* ---------- footer ---------- */

.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--rule);
  padding: calc(var(--r) / 1.5) 0;
  margin-top: 0;
}

.site-footer .f-rail {
  grid-column: 1 / 4;
  border-right: 1px solid var(--accent);
  padding-right: var(--gap);
  text-align: right;
  align-self: stretch;
}

.site-footer .f-name {
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 0.02em;
}

.site-footer .f-body { grid-column: 4 / 10; }
.site-footer .f-mail { grid-column: 10 / 13; text-align: right; }

.footer-nav ul {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  font-size: 15px;
}

.footer-nav li { display: flex; align-items: center; }

.footer-nav li + li::before {
  content: "/";
  color: var(--accent-2);
  margin: 0 12px;
}

.footer-nav a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--rule); }
.footer-nav a:hover { color: var(--accent); border-bottom-color: var(--accent); }

/* ---------- legal / about pages ---------- */

.page-head { padding: var(--r) 0 calc(var(--r) / 2); }
.page-head h1 { grid-column: 4 / 13; font-size: clamp(34px, 5.2vw, 62px); max-width: 18ch; }
.page-head .page-lede {
  grid-column: 4 / 10;
  margin-top: calc(var(--r) / 2);
  border-top: 1px solid var(--rule);
  padding-top: 24px;
}

.prose { padding-bottom: var(--r); }
.prose .block:first-child { margin-top: 0; }

.updated {
  grid-column: 4 / 10;
  margin-top: var(--r);
  border-top: 1px solid var(--rule);
  padding-top: 18px;
  font-size: 13px;
  color: var(--ink-soft);
}

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  :root { --r: 44px; --gap: 16px; }

  .grid { grid-template-columns: 1fr; }

  .rail,
  .brand,
  .site-nav,
  .site-footer .f-rail,
  .site-footer .f-body,
  .site-footer .f-mail,
  .col-text,
  .col-body,
  .col-wide,
  .col-full,
  .hero-lede,
  .hero-tail,
  .page-head h1,
  .page-head .page-lede,
  .checklist,
  .steps,
  dl.terms,
  .contact-line,
  .updated,
  .figure-main .fig-note,
  .figure-main .fig-img,
  .band-dark .dark-head,
  .band-dark .dark-img,
  .band-dark .dark-text {
    grid-column: 1;
  }

  .rail,
  .brand,
  .site-footer .f-rail,
  .figure-main .fig-note {
    border-right: 0;
    border-left: 1px solid var(--accent);
    padding-right: 0;
    padding-left: 14px;
    text-align: left;
    margin-bottom: 20px;
  }

  .brand { justify-content: flex-start; padding: 18px 0 18px 14px; }
  .site-nav { padding: 0 0 16px; }
  .site-nav ul { gap: 6px 18px; }

  .hero h1 { grid-column: 1; grid-template-columns: 1fr; }
  .hero .drop {
    grid-column: 1;
    justify-self: start;
    font-size: 78px;
    border-right: 0;
    border-left: 1px solid var(--accent);
    padding-right: 0;
    padding-left: 14px;
    margin-bottom: 8px;
  }
  .hero .h1-rest { grid-column: 1; max-width: none; }
  .rail .initial { font-size: 44px; }

  h1 { max-width: none; }

  .band-dark .dark-img { max-width: 320px; margin-bottom: 26px; }
  .band-dark .dark-text p { max-width: none; }

  .site-footer .f-mail { text-align: left; margin-top: 16px; }
  .site-footer .f-rail { margin-bottom: 16px; }
}

@media (max-width: 480px) {
  body { font-size: 16px; }
  .lead { font-size: 17px; }
  .shell { padding: 0 18px; }
}
