:root {
  --bg: #0e1116;
  --bg-alt: #151a22;
  --panel: #1b212b;
  --ink: #f4f1ea;
  --muted: #9aa3b2;
  --accent: #e8a13a;
  --accent-2: #d94f3d;
  --line: #2a313d;
  --radius: 14px;
  --max: 1120px;
  --shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { line-height: 1.1; margin: 0 0 0.4em; letter-spacing: -0.02em; }
p { margin: 0 0 1em; }
a { color: var(--accent); text-decoration: none; }

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

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(14, 17, 22, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.brand { font-weight: 800; font-size: 1.15rem; letter-spacing: 0.04em; }
.brand span { color: var(--accent); }
.nav-links { display: none; gap: 22px; align-items: center; }
.nav-links a { color: var(--muted); font-size: 0.92rem; font-weight: 600; }
.nav-links a:hover { color: var(--ink); }
.nav .btn { padding: 9px 16px; font-size: 0.85rem; }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent; border: 1px solid var(--line); color: var(--ink);
  width: 42px; height: 40px; border-radius: 10px; font-size: 1.25rem; cursor: pointer; line-height: 1;
}

/* Experiences dropdown */
.has-dropdown { position: relative; }
.dropdown {
  display: none; position: absolute; top: calc(100% + 8px); left: 0;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 8px; min-width: 230px; box-shadow: var(--shadow); z-index: 60;
}
.has-dropdown:hover .dropdown, .has-dropdown:focus-within .dropdown { display: block; }
.dropdown a { display: block; padding: 10px 12px; color: var(--muted); font-size: 0.92rem; border-radius: 8px; }
.dropdown a:hover { background: var(--bg-alt); color: var(--ink); }

@media (min-width: 820px) {
  .nav-links { display: flex; }
  .nav-toggle { display: none; }
  /* Invisible bridge across the gap so the menu stays open while the cursor moves onto it. */
  .has-dropdown::after {
    content: ''; position: absolute; left: 0; top: 100%; width: 100%; height: 14px;
  }
}

/* Mobile menu panel */
@media (max-width: 819px) {
  .nav-links {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: rgba(14, 17, 22, 0.98); border-bottom: 1px solid var(--line);
    padding: 6px 20px 16px; backdrop-filter: blur(10px);
  }
  .nav.open .nav-links { display: flex; }
  .nav-links > a, .has-dropdown > a { display: block; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 1rem; }
  .dropdown { position: static; display: block; box-shadow: none; border: none; background: transparent; padding: 2px 0 8px 14px; min-width: 0; }
  .dropdown a { padding: 9px 0; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  background: var(--accent);
  color: #15110a;
  font-weight: 700;
  padding: 14px 26px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  transition: transform 0.12s ease, background 0.2s ease;
}
.btn:hover { background: #f2b150; transform: translateY(-1px); }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}
.btn-ghost:hover { background: var(--panel); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 110px 0 100px;
  background:
    linear-gradient(to right, rgba(14, 17, 22, 0.95) 0%, rgba(14, 17, 22, 0.82) 42%, rgba(14, 17, 22, 0.45) 100%),
    radial-gradient(900px 500px at 80% -10%, rgba(232, 161, 58, 0.18), transparent 60%),
    url('/images/generated/hero.png');
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--line);
}
.hero .eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.75rem;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 14px;
}
.hero h1 { font-size: clamp(2.2rem, 7vw, 4rem); max-width: 16ch; }
.hero .lead { font-size: clamp(1.05rem, 2.6vw, 1.3rem); color: var(--muted); max-width: 56ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }

/* ---------- Sections ---------- */
section { padding: 64px 0; }
.section-head { max-width: 60ch; margin-bottom: 36px; }
.section-head .kicker {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.74rem;
  color: var(--accent);
  font-weight: 700;
}
.section-head h2 { font-size: clamp(1.7rem, 4vw, 2.5rem); margin-top: 8px; }
.section-head p { color: var(--muted); }

/* ---------- Pillars ---------- */
.pillars { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.pillar {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding: 34px 0;
  border-bottom: 1px solid var(--line);
  align-items: center;
}
.pillar:last-child { border-bottom: none; }
.pillar-body .num {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.1em;
}
.pillar-body h3 { font-size: clamp(1.5rem, 3.5vw, 2rem); }
.pillar-body p { color: var(--muted); max-width: 52ch; }
.pillar-link { display: inline-block; margin-top: 6px; font-weight: 700; font-size: 0.95rem; }
.pillar-link:hover { color: #f2b150; }
.disciplines { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 14px; }
.disc-chip {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.03em;
  color: var(--accent); background: rgba(232, 161, 58, 0.12);
  border: 1px solid rgba(232, 161, 58, 0.4); border-radius: 999px; padding: 5px 12px;
}
.placeholder {
  background: repeating-linear-gradient(45deg, #232a35, #232a35 12px, #262e3a 12px, #262e3a 24px);
  border: 1px dashed #3a4452;
  border-radius: var(--radius);
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.95rem;
  text-align: center;
  padding: 16px;
}
.media {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg);
  box-shadow: var(--shadow);
}
.media img { display: block; width: 100%; height: auto; }

@media (min-width: 820px) {
  .pillar { grid-template-columns: 1fr 1fr; gap: 48px; padding: 48px 0; }
  .pillar:nth-child(even) .placeholder,
  .pillar:nth-child(even) .media { order: 2; }
  .pillar:nth-child(even) .pillar-body { order: 1; }
  .placeholder { min-height: 280px; }
}

/* ---------- Pricing ---------- */
.tiers {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-bottom: 40px;
}
.tier {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  position: relative;
}
.tier.featured { border-color: var(--accent); box-shadow: var(--shadow); }
.tier .tier-name { font-size: 1.2rem; font-weight: 800; letter-spacing: 0.04em; }
.tier .badge {
  position: absolute; top: -12px; right: 20px;
  background: var(--accent); color: #15110a;
  font-size: 0.7rem; font-weight: 800; letter-spacing: 0.08em;
  padding: 5px 12px; border-radius: 999px;
}
.tier .price { font-size: 2rem; font-weight: 800; margin: 10px 0 2px; }
.tier .price small { font-size: 0.85rem; color: var(--muted); font-weight: 600; }
.tier .eff {
  display: inline-block;
  margin: 2px 0 4px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent);
  background: rgba(232, 161, 58, 0.12);
  border: 1px solid rgba(232, 161, 58, 0.35);
  border-radius: 8px;
  padding: 4px 10px;
  line-height: 1.3;
}
.tier .eff span { color: var(--muted); font-weight: 600; }
.tier ul { list-style: none; padding: 0; margin: 18px 0 0; }
.tier li { padding: 8px 0 8px 26px; position: relative; color: var(--muted); border-top: 1px solid var(--line); }
.tier li:first-child { border-top: none; }
.tier li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }

@media (min-width: 820px) {
  .tiers { grid-template-columns: repeat(3, 1fr); align-items: start; }
}

/* ---------- Walk-in rates ---------- */
.rates {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 28px;
}
.rates h3 { font-size: 1.1rem; }
.rate-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 14px;
}
.rate-grid div {
  display: flex; justify-content: space-between; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--muted);
}
.rate-grid b { color: var(--ink); }
@media (min-width: 680px) { .rate-grid { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Signup ---------- */
.signup { background: var(--bg-alt); border-top: 1px solid var(--line); }
.signup-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  width: 100%;
  box-shadow: var(--shadow);
}
.field-row { display: grid; grid-template-columns: 1fr; gap: 0 20px; }
@media (min-width: 720px) { .field-row { grid-template-columns: 1fr 1fr; } }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; margin-bottom: 7px; font-size: 0.92rem; }
.field input[type="text"], .field input[type="email"] {
  width: 100%;
  padding: 13px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  font-size: 1rem;
}
.field input:focus { outline: none; border-color: var(--accent); }
.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
.check {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 14px; cursor: pointer;
  font-size: 0.95rem; transition: border-color 0.15s ease;
}
.check:hover { border-color: var(--accent); }
.check input { width: 18px; height: 18px; accent-color: var(--accent); flex-shrink: 0; }

.form-msg { margin-top: 16px; padding: 14px 16px; border-radius: 10px; font-weight: 600; display: none; }
.form-msg.ok { display: block; background: rgba(76, 175, 99, 0.15); color: #8fe0a3; border: 1px solid rgba(76, 175, 99, 0.4); }
.form-msg.err { display: block; background: rgba(217, 79, 61, 0.15); color: #f0a59b; border: 1px solid rgba(217, 79, 61, 0.4); }

/* ---------- Future / roadmap ideas ---------- */
.idea-group { margin-bottom: 44px; }
.idea-group-head {
  display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap;
  margin-bottom: 18px; padding-bottom: 10px; border-bottom: 1px solid var(--line);
}
.idea-group-head h3 { font-size: 1.25rem; margin: 0; }
.idea-group-head .gh-note { color: var(--muted); font-size: 0.9rem; }
.idea-grid { display: grid; grid-template-columns: 1fr; gap: 18px; }
@media (min-width: 680px) { .idea-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .idea-grid { grid-template-columns: repeat(3, 1fr); } }
.idea {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; display: flex; flex-direction: column; gap: 8px;
}
.idea h4 { font-size: 1.08rem; margin: 0; }
.idea p { color: var(--muted); margin: 0; font-size: 0.93rem; flex: 1; }
.idea .tag {
  align-self: flex-start; margin-top: 6px;
  font-size: 0.7rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px; border: 1px solid;
}
.tag.zero { color: #8fe0a3; border-color: rgba(76, 175, 99, 0.5); background: rgba(76, 175, 99, 0.12); }
.tag.low { color: var(--accent); border-color: rgba(232, 161, 58, 0.5); background: rgba(232, 161, 58, 0.12); }
.tag.time { color: #8fb6e0; border-color: rgba(76, 130, 175, 0.5); background: rgba(76, 130, 175, 0.12); }
.priorities {
  background: linear-gradient(135deg, rgba(232,161,58,0.12), rgba(217,79,61,0.1));
  border: 1px solid rgba(232, 161, 58, 0.4); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow);
}
.priorities h3 { font-size: 1.3rem; }
.priorities ol { margin: 14px 0 0; padding-left: 20px; }
.priorities li { color: var(--ink); margin-bottom: 10px; }
.priorities li span { color: var(--muted); }
.lens {
  border-left: 3px solid var(--accent); padding: 8px 0 8px 16px;
  color: var(--muted); font-style: italic; max-width: 64ch;
}

/* ---------- Detail pages ---------- */
.detail-hero {
  position: relative;
  padding: 120px 0 70px;
  border-bottom: 1px solid var(--line);
  background-size: cover;
  background-position: center;
}
.detail-hero .eyebrow {
  text-transform: uppercase; letter-spacing: 0.22em; font-size: 0.75rem;
  color: var(--accent); font-weight: 700; margin-bottom: 12px;
}
.detail-hero h1 { font-size: clamp(2rem, 6vw, 3.4rem); max-width: 18ch; }
.detail-hero .lead { font-size: clamp(1.05rem, 2.6vw, 1.25rem); color: var(--ink); max-width: 56ch; }
.detail-body { padding: 60px 0; }
.detail-cols { display: grid; grid-template-columns: 1fr; gap: 36px; }
@media (min-width: 900px) { .detail-cols { grid-template-columns: 1.6fr 1fr; gap: 56px; } }
.detail-prose p { color: var(--muted); font-size: 1.02rem; }
.detail-prose h2 { font-size: 1.5rem; margin-top: 28px; }
.feature-list { list-style: none; padding: 0; margin: 18px 0 0; }
.feature-list li { padding: 10px 0 10px 28px; position: relative; color: var(--ink); border-top: 1px solid var(--line); }
.feature-list li::before { content: "▹"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }
.detail-aside {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; align-self: start;
}
.detail-aside h3 { font-size: 1.1rem; }
.detail-aside .price-line { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--line); color: var(--muted); }
.detail-aside .price-line:last-of-type { border-bottom: none; }
.detail-aside .price-line b { color: var(--ink); }
.detail-aside .btn { width: 100%; text-align: center; margin-top: 16px; }

/* ---------- Gallery ---------- */
.gallery { padding: 10px 0 60px; }
.gallery-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (min-width: 760px) { .gallery-grid { grid-template-columns: repeat(4, 1fr); } }
.gtile {
  position: relative; margin: 0; aspect-ratio: 1 / 1; border-radius: var(--radius);
  overflow: hidden; border: 1px solid var(--line);
  background: repeating-linear-gradient(45deg, #232a35, #232a35 12px, #262e3a 12px, #262e3a 24px);
}
.gtile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.gtile figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 1;
  padding: 22px 12px 10px; font-size: 0.8rem; font-weight: 600; color: var(--ink);
  background: linear-gradient(to top, rgba(14,17,22,0.85), transparent);
}
.gtile.zoomable { cursor: zoom-in; }

/* Lightbox modal */
.lightbox {
  position: fixed; inset: 0; z-index: 200; display: none;
  align-items: center; justify-content: center;
  background: rgba(8, 10, 14, 0.94); padding: 24px;
}
.lightbox.open { display: flex; }
.lb-img {
  max-width: 94vw; max-height: 84vh; border-radius: 12px;
  border: 1px solid var(--line); box-shadow: var(--shadow); object-fit: contain;
}
.lb-cap {
  position: absolute; bottom: 20px; left: 0; right: 0; text-align: center;
  color: var(--ink); font-weight: 600; font-size: 0.95rem; padding: 0 20px;
}
.lb-btn {
  position: absolute; background: rgba(27, 33, 43, 0.7); border: 1px solid var(--line);
  color: var(--ink); cursor: pointer; border-radius: 999px; line-height: 1;
  display: flex; align-items: center; justify-content: center;
}
.lb-close { top: 18px; right: 20px; width: 46px; height: 46px; font-size: 1.8rem; }
.lb-prev, .lb-next { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; font-size: 1.6rem; }
.lb-prev { left: 16px; }
.lb-next { right: 16px; }
.lb-btn:hover { background: var(--accent); color: #15110a; }
@media (max-width: 560px) {
  .lb-prev, .lb-next { width: 44px; height: 44px; }
  .lb-prev { left: 8px; } .lb-next { right: 8px; }
}

/* ---------- Footer ---------- */
footer { padding: 40px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.9rem; }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }
footer a { color: var(--muted); }

/* ---------- Admin ---------- */
.admin-body { background: var(--bg); }
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 34px; width: 100%; max-width: 380px; box-shadow: var(--shadow);
}
.login-card h1 { font-size: 1.4rem; }
.login-card p { color: var(--muted); font-size: 0.9rem; }
.login-card input {
  width: 100%; padding: 13px 14px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--bg); color: var(--ink); font-size: 1rem; margin: 12px 0;
}
.admin-shell { display: none; padding: 30px 0 60px; }
.admin-shell.active { display: block; }
.stat-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin: 20px 0 36px; }
@media (min-width: 720px) { .stat-row { grid-template-columns: repeat(6, 1fr); } }
.stat {
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 16px; text-align: center;
}
.stat .v { font-size: 1.8rem; font-weight: 800; color: var(--accent); }
.stat .l { font-size: 0.78rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; }

table.data { width: 100%; border-collapse: collapse; margin-top: 12px; font-size: 0.9rem; }
table.data th, table.data td { text-align: left; padding: 11px 12px; border-bottom: 1px solid var(--line); }
table.data th { color: var(--muted); text-transform: uppercase; font-size: 0.72rem; letter-spacing: 0.06em; }
table.data tbody tr:hover { background: var(--bg-alt); }
.tick { color: var(--accent); font-weight: 800; }
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }

/* Admin tabs */
.tabs { display: flex; gap: 8px; margin: 26px 0 8px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.tab-btn {
  background: transparent; border: none; border-bottom: 3px solid transparent;
  color: var(--muted); font-size: 0.98rem; font-weight: 700; cursor: pointer;
  padding: 12px 16px; margin-bottom: -1px; border-radius: 8px 8px 0 0;
}
.tab-btn:hover { color: var(--ink); background: var(--bg-alt); }
.tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

.admin-section { margin-top: 46px; }
.admin-section h2 { font-size: 1.4rem; border-left: 3px solid var(--accent); padding-left: 12px; }
.money { text-align: right; font-variant-numeric: tabular-nums; }
td.money.cost { color: #f0a59b; }
.total-row td { font-weight: 800; color: var(--ink); border-top: 2px solid var(--accent); }
.scenario-c { color: var(--muted); }
.scenario-s { color: var(--accent); font-weight: 700; }

.empty { color: var(--muted); padding: 24px; text-align: center; }

/* Capital drill-down tree */
.tree-table tr.tnode { cursor: default; }
.tree-table tr.has-kids { cursor: pointer; }
.tree-table tr.has-kids:hover { background: var(--bg-alt); }
.tree-table .tcaret { display: inline-block; width: 16px; color: var(--muted); transition: transform 0.15s ease; }
.tree-table tr.open > td .tcaret { transform: rotate(90deg); color: var(--accent); }
.tree-table .tspacer { display: inline-block; width: 16px; }
.tree-table .depth-0 > td { font-weight: 700; }
.tree-table .depth-0 { background: rgba(232, 161, 58, 0.05); }
.tree-table .depth-1 > td:first-child { color: var(--ink); font-weight: 600; }
.tree-table .depth-2 > td { color: var(--muted); font-weight: 400; }
.tree-table tr.open.depth-0 { background: rgba(232, 161, 58, 0.12); }
.tree-table .tlabel { vertical-align: middle; }

/* Info tooltip on financial line items */
.info {
  display: inline-flex; align-items: center; justify-content: center;
  width: 15px; height: 15px; margin-left: 6px; border-radius: 50%;
  border: 1px solid var(--line); color: var(--muted);
  font-size: 10px; font-style: normal; font-weight: 700; cursor: help;
  position: relative; vertical-align: middle; flex-shrink: 0;
}
.info:hover, .info:focus { color: var(--accent); border-color: var(--accent); outline: none; }
.info::after {
  content: attr(data-tip);
  position: absolute; bottom: 150%; left: -6px;
  width: 260px; max-width: 72vw; padding: 9px 11px;
  background: var(--bg-alt); border: 1px solid var(--accent); border-radius: 8px;
  color: var(--ink); font-size: 0.76rem; font-weight: 400; font-style: normal;
  line-height: 1.45; text-align: left; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transition: opacity 0.15s ease; z-index: 90; pointer-events: none;
}
.info:hover::after, .info:focus::after { opacity: 1; visibility: visible; }

/* Expandable financial rows */
.fin-row { cursor: pointer; }
.fin-row .caret { display: inline-block; color: var(--muted); transition: transform 0.15s ease; }
.fin-row.open .caret { transform: rotate(90deg); color: var(--accent); }
.fin-row.open { background: var(--bg-alt); }
.fin-row:hover { background: var(--bg-alt); }
.fin-drow { display: none; }
.fin-drow.open { display: table-row; }
.fin-drow > td { background: var(--bg); padding: 0 !important; }
.fin-detail { padding: 6px 0 10px; }
.fin-line {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 8px 16px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 0.9rem;
}
.fin-line:last-child { border-bottom: none; }
.fin-line span:last-child { font-variant-numeric: tabular-nums; color: var(--ink); }
.fin-line.sub { font-weight: 800; color: var(--ink); border-top: 1px solid var(--accent); }
.fin-line.sub span:last-child { color: var(--accent); }
/* Nested P&L breakdown table */
table.nested { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
table.nested td { padding: 8px 12px; border-bottom: 1px solid var(--line); color: var(--muted); }
table.nested td.money { color: var(--ink); }
table.nested td.cost { color: #f0a59b; }
table.nested .nested-net td { font-weight: 800; color: var(--ink); border-top: 2px solid var(--accent); border-bottom: none; }
table.nested .nested-net td.money { color: var(--accent); }

/* Expandable signup rows */
.srow { cursor: pointer; }
.srow .caret-cell { width: 24px; }
.srow .caret { display: inline-block; color: var(--muted); transition: transform 0.15s ease; }
.srow.open .caret { transform: rotate(90deg); color: var(--accent); }
.srow.open { background: var(--bg-alt); }
.drow > td { padding: 0 !important; border-bottom: 1px solid var(--line); }
.detail-wrap {
  max-height: 0; overflow: hidden;
  transition: max-height 0.25s ease, padding 0.25s ease;
  padding: 0 14px;
}
.drow.open .detail-wrap { max-height: 320px; padding: 18px 14px; }
.detail-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 640px) { .detail-grid { grid-template-columns: repeat(2, 1fr); } }
.detail-grid > div { display: flex; flex-direction: column; gap: 3px; }
.detail-grid .detail-pillars { grid-column: 1 / -1; }
.dk { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.dv { color: var(--ink); font-size: 0.95rem; }
.chip {
  display: inline-block; background: rgba(232, 161, 58, 0.15);
  border: 1px solid rgba(232, 161, 58, 0.4); color: var(--accent);
  padding: 4px 10px; border-radius: 999px; font-size: 0.82rem; font-weight: 600; margin: 2px 0;
}

/* Membership groups */
.tier-group { margin-bottom: 40px; }
.tier-group-head {
  display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap;
  margin-bottom: 18px; padding-bottom: 10px; border-bottom: 1px solid var(--line);
}
.tier-group-head h3 { font-size: 1.25rem; margin: 0; }
.tier-group-head .gh-note { color: var(--muted); font-size: 0.9rem; }
.tier-group .tiers { margin-bottom: 0; }
.note { color: var(--muted); font-size: 0.82rem; margin-top: 8px; }
