/* ═══════════════════════════════════════════════════════════════
   TANK LOGIC — home.css  v1.0  (Phase 3 redesign)
   Homepage-specific styles. Builds on system.css tokens.

   DIRECTION:
   Dark freshwater ecosystem — like looking into a mature planted
   tank in a dim room. Forest-floor backgrounds, moss accents,
   water-blue and sand for secondary signals. Premium restraint:
   thin borders, no glassmorphism, no grain, no heavy shadows.

   STRUCTURE:
   1. Masthead (sticky nav)
   2. Hero (split layout — text left, photo right)
   3. Tools band (naked cards, no bg)
   4. Featured guide (editorial split)
   5. Guides index (numbered list)
   6. Story (first-person E-E-A-T narrative)
   7. Fishroom (photo grid from author's tanks)
   8. Stats (mono numbers)
   9. Closing CTA
   10. Footer
   ═══════════════════════════════════════════════════════════════ */

/* ─── 0. HOMEPAGE-SPECIFIC TOKENS ─────────────────── */
:root {
  --maxw: 1180px;
  --gutter: clamp(20px, 4.5vw, 56px);
}

/* ─── 1. BASE LAYOUT ──────────────────────────────── */
html, body {
  overflow-x: clip;
  max-width: 100%;
}
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, video { max-width: 100%; }
a { color: inherit; text-decoration: none; }

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

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 12px;
  top: 12px;
  background: var(--accent);
  color: var(--bg);
  padding: 8px 14px;
  border-radius: var(--r-md);
  z-index: 99;
}

/* ─── 2. TYPOGRAPHY ───────────────────────────────── */
h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--text);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
h1 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); line-height: 1.15; }
h2 { font-size: clamp(1.3rem, 2.5vw, 1.7rem); line-height: 1.2; }
h3 { font-size: 1rem; line-height: 1.35; }

.kicker {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.kicker::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--text-muted);
}
.kicker.sub::before { background: var(--accent); }
.kicker.sub { color: var(--accent); }

.lead {
  color: var(--text-mid);
  font-size: 1.06rem;
  max-width: 56ch;
  line-height: 1.7;
}

.link {
  color: var(--accent);
  font-weight: 500;
  font-size: 0.95rem;
  border-bottom: 1px solid transparent;
  transition: border-color var(--t) var(--ease);
}
.link:hover { border-color: var(--accent); }

/* ─── 3. BUTTONS ──────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 12px 22px;
  border-radius: var(--r-md);
  border: 1px solid transparent;
  transition: background var(--t) var(--ease),
              border-color var(--t) var(--ease),
              color var(--t) var(--ease);
}
.btn .arr { transition: transform var(--t) var(--ease); }
.btn:hover .arr { transform: translateX(3px); }

.btn-primary {
  background: var(--accent);
  color: var(--bg);
}
.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-ghost {
  border-color: var(--border-mid);
  color: var(--text);
  background: transparent;
}
.btn-ghost:hover {
  border-color: var(--accent);
}

.btn-light {
  background: var(--accent);
  color: var(--bg);
}
.btn-light:hover { background: var(--accent-hover); }

.btn-outline-light {
  border-color: var(--border-hi);
  color: var(--text);
}
.btn-outline-light:hover {
  border-color: var(--text);
}

/* ─── 4. MASTHEAD — removed, homepage uses standard .nav from style.css ── */

/* ─── 5. HERO ─────────────────────────────────────── */
.hero {
  position: relative;
  min-height: min(82vh, 720px);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 38%;
}
.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(7,10,8,0.72) 0%,
    rgba(7,10,8,0.30) 30%,
    rgba(7,10,8,0.55) 65%,
    rgba(7,10,8,0.94) 100%
  );
}
.hero-note {
  position: absolute;
  top: 88px;
  left: 0;
  right: 0;
  z-index: 2;
}
.hero-note .wrap {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.field-note {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(240,245,240,0.75);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.field-note .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.hero-body {
  position: relative;
  z-index: 2;
  padding: 0 0 64px;
}
.hero-body h1 {
  max-width: 14ch;
}
.hero-body h1 em {
  font-style: italic;
  color: var(--accent);
}
.hero-body .lead {
  margin: 18px 0 28px;
  color: rgba(240,245,240,0.88);
}
.hero-cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ─── 6. TOOLS BAND ───────────────────────────────── */
.tools-band {
  padding: 72px 0 64px;
  border-bottom: 1px solid var(--border);
}
.tools-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}
.tools-head h2 { margin-top: 10px; }
.tools-split {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}
.tools-rail {
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: sticky;
  top: 88px;
}

/* Naked tool cards — no background, thin border on hover */
.home-tool-card {
  display: block;
  padding: 22px 24px;
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--bg-elevated);
  transition: border-color var(--t) var(--ease),
              background var(--t) var(--ease);
}
.home-tool-card:hover {
  border-color: var(--accent);
  background: var(--bg-surface);
}
.home-tool-card__kicker {
  font-family: var(--font);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}
.home-tool-card__title {
  font-family: var(--font-head);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}
.home-tool-card__desc {
  font-size: 0.88rem;
  color: var(--text-mid);
  line-height: 1.55;
  margin-bottom: 12px;
}
.home-tool-card__cta {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.04em;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: gap var(--t) var(--ease);
}
.home-tool-card:hover .home-tool-card__cta { gap: 8px; }

/* Sidebar rail panel */
.rail-panel {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px;
}
.rail-panel h3 {
  font-family: var(--font-head);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 12px;
}
.rail-panel ul {
  display: flex;
  flex-direction: column;
  gap: 8px;
  list-style: none;
}
.rail-panel a {
  font-size: 0.86rem;
  color: var(--text-mid);
  transition: color var(--t) var(--ease);
}
.rail-panel a:hover { color: var(--accent); }

/* ─── 7. FEATURED GUIDE ───────────────────────────── */
.feature-guide {
  padding: 72px 0;
  border-bottom: 1px solid var(--border);
}
.feature-guide__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.feature-guide__text h2 {
  margin: 14px 0 16px;
}
.feature-guide__text p {
  color: var(--text-mid);
  line-height: 1.7;
  margin-bottom: 20px;
}
.feature-guide__img {
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--border);
}
.feature-guide__img img {
  width: 100%;
  height: 360px;
  object-fit: cover;
  display: block;
}

/* ─── 8. GUIDES INDEX ─────────────────────────────── */
.guides-section {
  padding: 72px 0;
  border-bottom: 1px solid var(--border);
}
.guides-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}
.guides-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
}
@media (min-width: 700px) {
  .guides-list { grid-template-columns: 1fr 1fr; }
}

.g-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 22px;
  background: var(--bg-elevated);
  transition: background var(--t) var(--ease);
  min-height: 80px;
}
.g-item:hover { background: var(--bg-surface); }
.g-num {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-faint);
  flex-shrink: 0;
  min-width: 24px;
  padding-top: 4px;
  transition: color var(--t) var(--ease);
}
.g-item:hover .g-num { color: var(--accent); }
.g-main { flex: 1; }
.g-meta {
  font-family: var(--font);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.g-meta .cat { color: var(--accent); }
.g-main h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}
.g-main p {
  font-size: 0.86rem;
  color: var(--text-mid);
  line-height: 1.5;
}

/* ─── 9. STORY (E-E-A-T narrative) ────────────────── */
.story {
  padding: 56px 0 24px;
}
.story .wrap {
  max-width: 760px;
  margin-inline: auto;
}
.story h2 {
  margin: 14px 0 22px;
}
.story-body {
  font-size: 1.04rem;
  line-height: 1.8;
  color: var(--text-mid);
}
.story-body p {
  margin: 0 0 18px;
}
.story-body a {
  color: var(--accent);
  font-weight: 500;
  text-decoration: none;
  border-bottom: 1px solid var(--accent-border);
}
.story-body a:hover { border-bottom-color: var(--accent); }

/* ─── 10. FISHROOM (photo grid) ───────────────────── */
.fishroom {
  padding: 64px 0;
  border-top: 1px solid var(--border);
}
.fr-head { margin-bottom: 32px; }
.fr-head h2 { margin: 10px 0 12px; }
.fr-head p {
  color: var(--text-mid);
  max-width: 580px;
  line-height: 1.65;
}
.fr-byline {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
}
.fr-byline .avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-subtle);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  border: 1px solid var(--accent-border);
}
.fr-byline .who {
  font-size: 0.86rem;
  color: var(--text-mid);
  line-height: 1.4;
}
.fr-byline .who b { color: var(--text); }

.fr-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
@media (min-width: 800px) {
  .fr-grid { grid-template-columns: repeat(3, 1fr); }
}

.fr-card {
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--bg-elevated);
  transition: border-color var(--t) var(--ease);
}
.fr-card:hover { border-color: var(--accent); }
.fr-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}
.fr-card .txt {
  padding: 16px 18px;
}
.fr-card .cat {
  font-family: var(--font);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}
.fr-card h3 {
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--text);
  margin: 6px 0 6px;
  line-height: 1.3;
}
.fr-card p {
  font-size: 0.84rem;
  color: var(--text-mid);
  line-height: 1.5;
  margin-bottom: 10px;
}
.fr-card .go {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.02em;
}

/* Text-only fishroom card (no image) */
.fr-card--text {
  padding: 20px 22px;
}
.fr-card--text .txt { padding: 0; }
.fr-card--text .fr-card__strip {
  display: block;
  width: 32px;
  height: 2px;
  background: var(--accent);
  margin-bottom: 14px;
}

/* ─── 11. STATS ───────────────────────────────────── */
.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 48px;
  padding: 48px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.stat {
  display: flex;
  flex-direction: column;
}
.stat .n {
  font-family: var(--font-head);
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1;
  letter-spacing: -0.01em;
}
.stat .l {
  font-family: var(--font);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 10px;
}

/* ─── 12. CLOSING CTA ─────────────────────────────── */
.closing {
  padding: 72px 0 88px;
}
.closing .sec-head {
  max-width: 580px;
  margin-bottom: 28px;
}
.closing h2 { margin: 12px 0 14px; }
.closing p {
  color: var(--text-mid);
  line-height: 1.65;
}
.closing .hero-cta {
  margin-top: 8px;
}

/* ─── 13. FOOTER ──────────────────────────────────── */
.footer {
  background: var(--bg-elevated);
  border-top: 1px solid var(--border);
  padding: 48px 0 28px;
}
.foot-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 36px;
}
@media (min-width: 800px) {
  .foot-grid { grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
}

.foot-brand {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.foot-brand .brand { font-size: 1.1rem; }
.foot-brand p {
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 280px;
}
.foot-brand .mail {
  font-family: var(--font);
  font-size: 0.82rem;
  color: var(--text-muted);
  transition: color var(--t) var(--ease);
}
.foot-brand .mail:hover { color: var(--accent); }

.foot-col h4 {
  font-family: var(--font);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 14px;
}
.foot-col {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.foot-col a {
  font-size: 0.86rem;
  color: var(--text-muted);
  transition: color var(--t) var(--ease);
}
.foot-col a:hover { color: var(--accent); }

.foot-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-family: var(--font);
  font-size: 11px;
  color: var(--text-faint);
  flex-wrap: wrap;
  gap: 12px;
}
.foot-bottom a {
  color: var(--text-faint);
  transition: color var(--t) var(--ease);
}
.foot-bottom a:hover { color: var(--text-muted); }

/* ─── 14. AD SHELLS ───────────────────────────────── */
.ad-shell { width: 100%; }
.ad-shell .ad-label {
  display: none;
  font-family: var(--font);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
  text-align: center;
  padding: 4px 0 2px;
}
.ad-shell--filled {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
}
.ad-shell--filled .ad-label { display: block; }
.ad-shell--leaderboard.ad-shell--filled {
  min-height: 90px;
  max-height: 118px;
  overflow: hidden;
  margin: 18px auto 0;
}
.ad-shell--native.ad-shell--filled {
  min-height: 120px;
  margin: 0 auto 26px;
}
.ad-shell ins.adsbygoogle { display: block; width: 100%; }

/* ─── 15. RESPONSIVE ──────────────────────────────── */
@media (max-width: 900px) {
  .tools-split { grid-template-columns: 1fr; }
  .tools-rail { position: static; }
  .feature-guide__inner { grid-template-columns: 1fr; }
  .feature-guide__img { order: -1; }
  .feature-guide__img img { height: 240px; }
  /* .nav and .menu-btn rules removed — homepage now uses standard .nav from style.css */
}
@media (max-width: 640px) {
  .hero { min-height: 50vh; }
  .hero-body { padding: 0 0 48px; }
  .tools-band, .feature-guide, .guides-section { padding: 48px 0; }
  .fishroom { padding: 48px 0; }
  .closing { padding: 48px 0 64px; }
  .stats { gap: 32px; padding: 36px 0; }
  .stat .n { font-size: 1.9rem; }
  .fr-grid { grid-template-columns: 1fr; }
  .fr-card img { height: 180px; }
  .foot-grid { gap: 28px; }
}
