/* WBA Customer Portal — palette, type and shapes follow wbaconsulting.org
   (WBA_LLC/wordpress-theme/style.css), so the portal reads as the same brand. */
:root {
  --primary-color: #1a2332;        /* navy: header text, hero + footer backgrounds */
  --secondary-color: #d4af37;      /* gold */
  --accent-soft: #e8d4a0;
  --heading-color: #1a2332;
  --text-color: #0f172a;
  --text-secondary: #475569;
  --text-light: #64748b;
  --background: #ffffff;
  --background-alt: #f8fafc;
  --background-subtle: #fafbfc;
  --border-color: #e2e8f0;
  --border-light: #f1f5f9;
  --card-bg: #ffffff;
  --header-bg: rgba(255, 255, 255, 0.96);
  --input-bg: #ffffff;
  --ok: #15803d; --ok-bg: #dcfce7;
  --warn: #92400e; --warn-bg: #fef3c7;
  --danger-bg: #fee2e2; --danger: #991b1b;
  --shadow-sm: 0 1px 2px 0 rgba(15, 23, 42, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.08), 0 2px 4px -2px rgba(15, 23, 42, 0.06);
  --shadow-lg: 0 10px 25px -5px rgba(15, 23, 42, 0.12), 0 8px 10px -6px rgba(15, 23, 42, 0.08);
  --radius-btn: 12px;
  --radius-card: 16px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
/* Dark: follow the OS unless the reader forced light; an explicit choice wins. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --heading-color: #e8edf5; --text-color: #dbe3ee; --text-secondary: #a3b0c2; --text-light: #8595aa;
    --background: #131922; --background-alt: #1a2029; --background-subtle: #0f141b;
    --border-color: #2c3542; --border-light: #232b36; --card-bg: #1a2029; --input-bg: #131922;
    --header-bg: rgba(19, 25, 34, 0.95); --secondary-color: #e0bf4f;
    --ok: #4ade80; --ok-bg: #12301f; --warn: #fcd34d; --warn-bg: #3a2f0b; --danger-bg: #3b1515; --danger: #fca5a5;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.4); --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.55);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --heading-color: #e8edf5; --text-color: #dbe3ee; --text-secondary: #a3b0c2; --text-light: #8595aa;
  --background: #131922; --background-alt: #1a2029; --background-subtle: #0f141b;
  --border-color: #2c3542; --border-light: #232b36; --card-bg: #1a2029; --input-bg: #131922;
  --header-bg: rgba(19, 25, 34, 0.95); --secondary-color: #e0bf4f;
  --ok: #4ade80; --ok-bg: #12301f; --warn: #fcd34d; --warn-bg: #3a2f0b; --danger-bg: #3b1515; --danger: #fca5a5;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.4); --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.55);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font: 16px/1.6 var(--font); color: var(--text-color); background: var(--background-subtle);
  min-height: 100vh; display: flex; flex-direction: column;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--primary-color); text-decoration-color: var(--secondary-color); text-underline-offset: 3px; }
:root[data-theme="dark"] a { color: var(--accent-soft); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) a { color: var(--accent-soft); } }
h1, h2, h3 { color: var(--heading-color); line-height: 1.2; letter-spacing: -0.01em; }
h1 { font-size: clamp(1.75rem, 3.2vw, 2.4rem); margin: 0 0 0.5rem; font-weight: 700; }
h2 { font-size: 1.2rem; margin: 0 0 0.75rem; font-weight: 700; }
h3 { font-size: 1rem; margin: 1.25rem 0 0.5rem; }
:focus-visible { outline: 3px solid var(--secondary-color); outline-offset: 2px; border-radius: 4px; }

/* ---- header: white bar + network logo, as on the site ---- */
.site-header {
  background: var(--header-bg); border-bottom: 1px solid var(--border-color);
  position: sticky; top: 0; z-index: 10; backdrop-filter: saturate(1.4) blur(8px);
}
.header-inner {
  max-width: 1200px; margin: 0 auto; padding: 14px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.site-logo { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--heading-color); }
.site-logo img { height: 48px; width: auto; }
.logo-dark { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .logo-light { display: none; }
  :root:not([data-theme="light"]) .logo-dark { display: block; }
}
:root[data-theme="dark"] .logo-light { display: none; }
:root[data-theme="dark"] .logo-dark { display: block; }
.wordmark { font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em; }
.portal-label {
  font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--text-light); padding-left: 12px; border-left: 2px solid var(--secondary-color);
}
.header-actions { display: flex; align-items: center; gap: 16px; }
.header-actions form { margin: 0; }
.who { color: var(--text-light); font-size: 0.9rem; overflow-wrap: anywhere; }
.text-link {
  background: none; border: 0; padding: 0; font: inherit; font-weight: 500; cursor: pointer;
  color: var(--heading-color); text-decoration: underline; text-decoration-color: var(--secondary-color); text-underline-offset: 3px;
}
.theme-toggle {
  width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--border-color);
  background: transparent; color: var(--heading-color); display: grid; place-items: center; cursor: pointer;
}
.theme-toggle:hover { border-color: var(--secondary-color); }
.icon-sun { display: none; }
:root[data-theme="dark"] .icon-sun { display: block; }
:root[data-theme="dark"] .icon-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .icon-sun { display: block; }
  :root:not([data-theme="light"]) .icon-moon { display: none; }
}
@media (max-width: 640px) {
  .portal-label, .who { display: none; }
  .wordmark { font-size: 1.1rem; }
  .site-logo img { height: 40px; }
}

.testmode { background: var(--warn-bg); color: var(--warn); text-align: center; padding: 8px 16px; font-size: 0.9rem; font-weight: 600; }

/* ---- navy node-field hero (same scrim + gold hairline as the site's .hero) ---- */
.page-hero, .auth-hero {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.86) 0%, rgba(23, 34, 54, 0.76) 45%, rgba(30, 41, 59, 0.9) 100%),
    url("img/home_page_hero_abtract.webp") center / cover no-repeat, #0f172a;
  color: #fff; position: relative; overflow: hidden;
}
.page-hero::before, .auth-hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(circle at 80% 15%, rgba(212, 175, 55, 0.22), transparent 55%);
}
.page-hero::after, .auth-hero::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; opacity: 0.85; pointer-events: none;
  background: linear-gradient(to right, transparent, #d4af37 35%, #e8d4a0 50%, #d4af37 65%, transparent);
}
.page-hero-inner {
  position: relative; z-index: 1; max-width: 1080px; margin: 0 auto; padding: 44px 24px 40px;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.page-hero h1 { color: #fff; margin: 0; }
.hero-sub { margin: 6px 0 0; color: #cbd5e1; }
.eyebrow { margin: 0 0 6px; font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; color: var(--text-light); }
.eyebrow.gold { color: #e0bf4f; }

/* ---- layout ---- */
main { flex: 1; width: 100%; }
.container { max-width: 1080px; margin: 0 auto; padding: 32px 24px 56px; }
.container.narrow { max-width: 520px; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.span2 { grid-column: span 2; }
@media (max-width: 760px) { .grid { grid-template-columns: 1fr; } .span2 { grid-column: auto; } }
.card {
  background: var(--card-bg); border: 1px solid var(--border-color); border-radius: var(--radius-card);
  padding: 26px; box-shadow: var(--shadow-sm);
}
.card > :last-child { margin-bottom: 0; }
.card h2 { display: flex; align-items: center; gap: 10px; }
.card h2::before { content: ""; width: 4px; height: 1.1em; border-radius: 2px; background: var(--secondary-color); }
.muted { color: var(--text-secondary); }
.small { font-size: 0.9rem; }
.center { text-align: center; }
.admin-note { background: var(--background-alt); border: 1px dashed var(--border-color); border-radius: 10px; padding: 10px 14px; font-size: 0.9rem; color: var(--text-secondary); margin: 0 0 20px; }

/* ---- buttons (12px radius, 600 weight, like the site) ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; font-size: 1rem; line-height: 1.2; cursor: pointer; text-decoration: none;
  padding: 13px 26px; border-radius: var(--radius-btn); border: 2px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-primary { background: var(--primary-color); color: #fff !important; }
.btn-secondary { background: transparent; color: var(--heading-color) !important; border-color: var(--primary-color); }
.btn-block { width: 100%; }
:root[data-theme="dark"] .btn-primary { background: var(--secondary-color); color: #1a2332 !important; }
:root[data-theme="dark"] .btn-secondary { border-color: var(--secondary-color); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .btn-primary { background: var(--secondary-color); color: #1a2332 !important; }
  :root:not([data-theme="light"]) .btn-secondary { border-color: var(--secondary-color); }
}
.btn-google {
  display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%;
  padding: 12px 20px; border-radius: var(--radius-btn); border: 1px solid #dadce0; background: #fff; color: #1f1f1f !important;
  font: 500 1rem/1.2 Roboto, var(--font); text-decoration: none; box-shadow: var(--shadow-sm);
}
.btn-google:hover { background: #f8faff; border-color: #c6dafc; }

/* ---- sign-in pages: navy panel + form card ---- */
.auth-shell {
  max-width: 1080px; margin: 40px auto 56px; padding: 0 24px;
  display: grid; grid-template-columns: 1.05fr 1fr; gap: 0;
}
.auth-hero { border-radius: var(--radius-card) 0 0 var(--radius-card); display: flex; align-items: flex-end; min-height: 520px; }
.auth-hero-copy { position: relative; z-index: 1; padding: 44px; }
.auth-hero-title { font-size: clamp(1.6rem, 2.6vw, 2.2rem); font-weight: 700; line-height: 1.2; margin: 0 0 20px; color: #fff; }
.auth-points { list-style: none; margin: 0; padding: 0; color: #dbe3ee; }
.auth-points li { padding: 6px 0 6px 26px; position: relative; }
.auth-points li::before { content: ""; position: absolute; left: 0; top: 14px; width: 12px; height: 12px; border-radius: 50%; border: 2px solid #d4af37; }
.auth-card {
  background: var(--card-bg); border: 1px solid var(--border-color); border-left: 0;
  border-radius: 0 var(--radius-card) var(--radius-card) 0; padding: 44px 40px; box-shadow: var(--shadow-lg);
}
@media (max-width: 860px) {
  .auth-shell { grid-template-columns: 1fr; margin-top: 24px; padding: 0 16px; }
  .auth-hero { display: none; }
  .auth-card { border-left: 1px solid var(--border-color); border-radius: var(--radius-card); padding: 30px 22px; }
}
.form { display: flex; flex-direction: column; gap: 8px; margin: 8px 0 18px; }
.form .btn { margin-top: 10px; }
label { font-weight: 600; font-size: 0.92rem; color: var(--heading-color); }
.label-row { display: flex; justify-content: space-between; align-items: baseline; margin-top: 8px; }
.small-link { font-size: 0.88rem; }
input[type=email], input[type=password], input[type=text], input[type=tel] {
  font: inherit; padding: 12px 14px; border: 1px solid var(--border-color); border-radius: 10px;
  background: var(--input-bg); color: var(--text-color); width: 100%;
}
input:focus { border-color: var(--secondary-color); }
.hint { margin: -2px 0 6px; font-size: 0.85rem; color: var(--text-light); }
.divider { display: flex; align-items: center; gap: 12px; color: var(--text-light); font-size: 0.85rem; margin: 20px 0 6px; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--border-color); }
.alert { background: var(--danger-bg); color: var(--danger); padding: 11px 14px; border-radius: 10px; font-weight: 500; }
.note { background: var(--warn-bg); color: var(--warn); padding: 11px 14px; border-radius: 10px; }

/* ---- badges, tables, lists ---- */
.badge { display: inline-block; padding: 4px 12px; border-radius: 999px; background: var(--border-light); color: var(--text-secondary); font-size: 0.82rem; font-weight: 700; white-space: nowrap; }
.badge.ok, .status-live, .status-complete { background: var(--ok-bg); color: var(--ok); }
.badge-hero { background: rgba(255, 255, 255, 0.12); color: #fff; border: 1px solid rgba(224, 191, 79, 0.6); }
.badge-hero.status-live { background: rgba(21, 128, 61, 0.35); }
.billing { width: 100%; border-collapse: collapse; }
.billing th, .billing td { text-align: left; padding: 12px 10px 12px 0; border-bottom: 1px solid var(--border-color); vertical-align: middle; }
.billing th { font-weight: 600; color: var(--heading-color); }
.billing form { margin: 0; }
.list { list-style: none; padding: 0; margin: 0; }
.list li { padding: 10px 0; border-bottom: 1px solid var(--border-light); }
.list li:last-child { border-bottom: 0; }
.list span { color: var(--text-light); font-size: 0.88rem; margin-right: 10px; font-variant-numeric: tabular-nums; }

/* ---- navy footer ---- */
.site-footer { background: var(--primary-color); color: #cbd5e1; margin-top: auto; position: relative; }
.site-footer::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: linear-gradient(to right, transparent, #d4af37 35%, #e8d4a0 50%, #d4af37 65%, transparent); opacity: 0.7; }
.footer-inner { max-width: 1080px; margin: 0 auto; padding: 28px 24px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 0.9rem; }
.footer-inner p { margin: 0; }
.footer-inner strong { color: #fff; }
.site-footer a { color: var(--accent-soft) !important; }
.site-logo, .site-logo:visited { color: var(--heading-color) !important; }
@media (max-width: 640px) {
  .header-actions > a.text-link { display: none; }
  .header-inner { padding: 10px 16px; }
}

/* "What's included" under each billing line */
.plan { margin-top: 6px; font-weight: 400; }
.plan summary { cursor: pointer; color: var(--text-secondary); font-size: 0.9rem; text-decoration: underline; text-decoration-color: var(--secondary-color); text-underline-offset: 3px; width: fit-content; }
.plan p { margin: 8px 0 4px; font-size: 0.92rem; color: var(--text-secondary); }
.plan ul { margin: 4px 0 6px; padding-left: 20px; font-size: 0.92rem; color: var(--text-color); }
.plan li { margin: 2px 0; }
.plan-not { font-size: 0.88rem !important; }
.billing th { width: 55%; }

.was { text-decoration: line-through; color: var(--text-light); margin-right: 4px; }
.offer { display: block; margin-top: 4px; font-size: 0.85rem; font-weight: 600; color: var(--ok); }
.billing .btn { white-space: nowrap; }

/* board review */
.steps { list-style: none; display: flex; gap: 0; padding: 0; margin: 4px 0 18px; flex-wrap: wrap; }
.steps li { flex: 1; min-width: 150px; display: flex; align-items: center; gap: 8px; color: var(--text-light); font-size: 0.9rem; font-weight: 600; padding: 8px 10px 8px 0; border-top: 3px solid var(--border-color); }
.steps .dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--border-color); flex: none; }
.steps li.done { color: var(--ok); border-top-color: var(--ok); }
.steps li.done .dot { background: var(--ok); border-color: var(--ok); }
.steps li.active { color: var(--heading-color); border-top-color: var(--secondary-color); }
.steps li.active .dot { border-color: var(--secondary-color); background: var(--secondary-color); }
.review-actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-start; }
.review-actions form { margin: 0; }
.changes { flex: 1; min-width: 260px; }
.changes summary { list-style: none; display: inline-flex; }
.changes summary::-webkit-details-marker { display: none; }
.changes[open] summary { border-color: var(--secondary-color); }
textarea { font: inherit; padding: 12px 14px; border: 1px solid var(--border-color); border-radius: 10px; background: var(--input-bg); color: var(--text-color); width: 100%; resize: vertical; }
.request { margin: 0; padding: 12px 16px; border-left: 3px solid var(--secondary-color); background: var(--background-alt); border-radius: 0 10px 10px 0; white-space: pre-line; }
.review-approved { border-color: var(--ok); }
.live-note { margin: 0; color: var(--ok); }

.feature-list { margin: 0 0 16px; padding-left: 20px; color: var(--text-secondary); }
.feature-list li { margin: 4px 0; }
.feature-list strong { color: var(--heading-color); }

/* Tutorials: "Watch how" links on the dashboard, and the tutorials page */
.watch-row { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: -4px 0 12px; font-size: 0.9rem; }
.watch { font-weight: 600; text-decoration: none; color: var(--heading-color); border-bottom: 1px solid var(--secondary-color); }
.watch:hover { color: var(--secondary-color); }
.tutorial video { display: block; width: 100%; aspect-ratio: 16 / 9; border-radius: 10px; background: #0b0f16; margin: 4px 0 12px; }
.tutorial .meta { font-size: 0.85rem; }
.tutorial details { margin-top: 8px; }
.tutorial details summary { cursor: pointer; font-weight: 600; }
.tutorial details li { margin: 4px 0; color: var(--text-secondary); }
.tutorial:target { box-shadow: 0 0 0 3px var(--secondary-color); }
.header-actions > a.text-link.nav-keep { display: inline; }
@media (max-width: 640px) { .header-actions .who { display: none; } }

/* Portal sections: Overview · Billing · Tutorials */
/* The underline is drawn inside each tab (inset shadow), so nothing sticks out of the bar: a tab that
   overhung the bottom by 1px gave the bar a tiny scrollbar. Sideways swipe still works on phones. */
.tabs { display: flex; gap: 4px; margin: 0 0 20px; box-shadow: inset 0 -1px 0 var(--border-color, rgba(26,35,50,.12));
  overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { padding: 10px 16px 12px; font-weight: 600; text-decoration: none; color: var(--text-secondary) !important; white-space: nowrap; }
.tab:hover { color: var(--heading-color) !important; }
.tab.active { color: var(--heading-color) !important; box-shadow: inset 0 -3px 0 var(--secondary-color); }
.next-step p { margin: 0 0 10px; }
.next-step p:last-child { margin-bottom: 0; }

/* Referrals */
.ref-list { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 14px; }
.ref-link { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.ref-link input { flex: 1 1 260px; min-width: 0; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.9rem; }
.btn-small { padding: 6px 14px; font-size: 0.9rem; }
.ref-status { margin: 6px 0 0; font-size: 0.9rem; color: var(--text-secondary); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.footer-note { flex-basis: 100%; margin-top: 6px !important; font-size: 0.8rem; opacity: 0.75; }
@media (max-width: 480px) { .tabs { gap: 0; } .tab { padding: 10px 8px 12px; font-size: 15px; } }
