/* growtainer.org — shared stylesheet · v5 */

:root {
  --bg: #f5efe3;
  --bg-card: #fbf6ec;
  --ink: #1c1812;
  --ink-soft: #5a5147;
  --rule: #d4c8b0;
  --rule-soft: #e6dcc6;
  --green: #4a6b3a;
  --green-deep: #2f4524;
  --water: #2c5e7a;
  --brick: #a04830;
  --gold: #b08a3c;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: 'IBM Plex Sans', system-ui, sans-serif;
  font-size: 16px; line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(circle at 15% 20%, rgba(74,107,58,0.04) 0%, transparent 50%),
    radial-gradient(circle at 85% 75%, rgba(160,72,48,0.03) 0%, transparent 50%);
}
::selection { background: var(--gold); color: var(--bg); }
a { color: var(--water); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--brick); }
h1, h2, h3, h4 {
  font-family: 'Fraunces', 'Georgia', serif;
  font-weight: 500; letter-spacing: -0.015em;
  line-height: 1.15; margin: 0;
  font-variation-settings: "SOFT" 50;
}

/* Header */
header.top {
  position: sticky; top: 0; z-index: 100;
  background: rgba(245,239,227,0.93);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}
.topbar {
  max-width: 1080px; margin: 0 auto; padding: 12px 20px;
  display: flex; justify-content: space-between; align-items: baseline;
}
.brand {
  font-family: 'Fraunces', serif; font-weight: 700; font-size: 20px;
  letter-spacing: -0.02em; color: var(--ink); text-decoration: none;
}
.brand span { color: var(--green); }
nav.top-links { display: flex; gap: 20px; font-size: 13px; }
nav.top-links a { color: var(--ink-soft); text-decoration: none; }
nav.top-links a:hover { color: var(--ink); }
nav.top-links a.active { color: var(--ink); border-bottom: 1px solid var(--green); }
@media (max-width: 700px) { nav.top-links { display: none; } }

/* Sections */
section { padding: 48px 20px; max-width: 1080px; margin: 0 auto; }
section + section { border-top: 1px solid var(--rule-soft); }
@media (min-width: 760px) { section { padding: 64px 28px; } }

.section-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.15em; color: var(--ink-soft);
  margin-bottom: 14px; display: flex; align-items: center; gap: 12px;
}
.section-label::before { content: ""; width: 22px; height: 1px; background: var(--ink-soft); }

h1 { font-size: clamp(30px, 6vw, 48px); margin-bottom: 20px; }
h1 em { font-style: italic; color: var(--green); font-variation-settings: "SOFT" 100; }
h2 { font-size: clamp(24px, 4.5vw, 36px); margin-bottom: 16px; }
h3 { font-size: 20px; margin-bottom: 12px; }
h4 { font-size: 17px; margin-bottom: 8px; color: var(--green-deep); }

p { margin: 0 0 14px; }
.lede { font-size: 17px; color: var(--ink-soft); max-width: 640px; margin-bottom: 28px; }

/* Subpage hero (smaller than main hero) */
.subhero {
  padding-top: 40px; padding-bottom: 40px;
}
.subhero .section-label { color: var(--green-deep); }
.subhero h1 { max-width: 800px; }

/* Buttons */
.cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 20px; background: var(--ink); color: var(--bg);
  text-decoration: none; font-size: 14px; font-weight: 500;
  transition: background .15s;
}
.cta:hover { background: var(--green-deep); color: var(--bg); }
.cta-secondary {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 20px; background: transparent; color: var(--ink);
  text-decoration: none; font-size: 14px; font-weight: 500;
  border: 1px solid var(--rule);
  transition: all .15s;
}
.cta-secondary:hover { border-color: var(--green); color: var(--green-deep); }

/* Cards */
.card {
  background: var(--bg-card); border: 1px solid var(--rule);
  padding: 24px; box-shadow: 4px 4px 0 var(--rule-soft);
  margin-bottom: 24px;
}
.card.featured { border-left: 4px solid var(--green); }
.card.warning { border-left: 4px solid var(--brick); }
.card.note { border-left: 4px solid var(--gold); }

.card h3 { margin-top: 0; }
.card-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--ink-soft);
  margin-bottom: 8px;
}

/* Two-column grid */
.two-col {
  display: grid; grid-template-columns: 1fr; gap: 24px;
}
@media (min-width: 760px) { .two-col { grid-template-columns: 1fr 1fr; gap: 32px; } }

.three-col {
  display: grid; grid-template-columns: 1fr; gap: 24px;
}
@media (min-width: 720px) { .three-col { grid-template-columns: repeat(3, 1fr); gap: 28px; } }

/* Step list (numbered roadmap) */
.step-list { list-style: none; padding: 0; margin: 0; }
.step-list li {
  display: grid; grid-template-columns: 1fr; gap: 4px;
  padding: 18px 0; border-top: 1px solid var(--rule-soft);
}
.step-list li:last-child { border-bottom: 1px solid var(--rule-soft); }
@media (min-width: 720px) {
  .step-list li { grid-template-columns: 100px 220px 1fr; gap: 20px; align-items: baseline; padding: 20px 0; }
}
.step-num {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px; font-weight: 500;
  color: var(--green-deep); letter-spacing: 0.05em;
}
.step-title { font-family: 'Fraunces', serif; font-size: 18px; font-weight: 500; }
.step-detail { color: var(--ink-soft); font-size: 14.5px; }
.step-detail strong { color: var(--ink); font-weight: 500; }

/* Tables */
.data-table { width: 100%; border-collapse: collapse; margin: 16px 0; }
.data-table th {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--ink-soft);
  font-weight: 500; padding: 8px 6px; text-align: left;
  border-bottom: 1px solid var(--rule);
}
.data-table td {
  padding: 10px 6px; font-size: 14px;
  border-bottom: 1px solid var(--rule-soft);
  vertical-align: top;
}
.data-table td.num {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px; color: var(--green-deep);
  white-space: nowrap;
}

/* Image cards (clickable for lightbox) */
.img-card {
  background: var(--bg-card); border: 1px solid var(--rule);
  padding: 14px; box-shadow: 4px 4px 0 var(--rule-soft);
  cursor: zoom-in;
  transition: transform .15s, box-shadow .15s;
}
.img-card:hover {
  transform: translate(-1px, -1px);
  box-shadow: 5px 5px 0 var(--rule-soft);
}
.img-card-frame {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
}
.img-card img { width: 100%; height: 100%; object-fit: cover; display: block; }
.img-card.contain img { object-fit: contain; padding: 4px; }
.img-card figcaption {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px; color: var(--ink-soft);
  text-transform: uppercase; letter-spacing: 0.1em; margin-top: 12px;
}

/* Video embed */
.video-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--ink);
  margin: 16px 0;
  overflow: hidden;
}
.video-wrap iframe, .video-wrap video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0;
}
.video-vertical {
  aspect-ratio: 9 / 16;
  max-width: 360px;
  margin: 16px auto;
}

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(28, 24, 18, 0.92);
  display: none; align-items: center; justify-content: center;
  padding: 20px; cursor: zoom-out;
  opacity: 0; transition: opacity .2s;
}
.lightbox.active { display: flex; opacity: 1; }
.lightbox img {
  max-width: 100%; max-height: 90vh;
  object-fit: contain;
  background: var(--bg-card);
  padding: 8px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
.lightbox-close {
  position: absolute; top: 20px; right: 24px;
  color: var(--bg); background: none; border: none;
  font-family: 'Fraunces', serif; font-size: 32px;
  cursor: pointer; line-height: 1; padding: 0;
}
.lightbox-caption {
  position: absolute; bottom: 24px; left: 50%;
  transform: translateX(-50%);
  color: var(--bg);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.12em;
  text-align: center;
}

/* Inline blocks */
.inline-tip {
  background: var(--bg-card);
  border-left: 3px solid var(--gold);
  padding: 14px 16px;
  margin: 16px 0;
  font-size: 14px;
  color: var(--ink-soft);
}
.inline-warn {
  background: var(--bg-card);
  border-left: 3px solid var(--brick);
  padding: 14px 16px;
  margin: 16px 0;
  font-size: 14px;
  color: var(--ink-soft);
}
.inline-warn strong { color: var(--brick); }
.inline-tip strong { color: var(--green-deep); }

/* Pull-quote style for emphasis */
blockquote {
  border-left: 2px solid var(--green);
  padding: 8px 0 8px 22px;
  margin: 28px 0;
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: 19px;
  color: var(--ink);
  max-width: 640px;
}

/* Source citation */
.src {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px; color: var(--ink-soft);
  margin-top: 10px; opacity: 0.8;
}

/* Footer */
footer {
  margin-top: 40px; border-top: 1px solid var(--rule);
  padding: 28px 20px 40px; max-width: 1080px;
  margin-left: auto; margin-right: auto;
  display: flex; justify-content: space-between; gap: 16px;
  font-size: 12px; color: var(--ink-soft); flex-wrap: wrap;
}
footer .credit { font-family: 'Fraunces', serif; font-style: italic; }
footer a { color: var(--ink-soft); }

/* Breadcrumb */
.breadcrumb {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--ink-soft);
  margin-bottom: 12px;
}
.breadcrumb a { color: var(--ink-soft); text-decoration: none; }
.breadcrumb a:hover { color: var(--ink); }
.breadcrumb span { margin: 0 6px; }

/* Misc */
ul.clean { padding-left: 20px; }
ul.clean li { margin-bottom: 8px; }
.muted { color: var(--ink-soft); }
.mono { font-family: 'IBM Plex Mono', monospace; font-size: 0.9em; }

@media print { body { background: white; } header.top { background: white; } }
