/* ==========================================================================
   APBDA Platform — stylesheet
   Palette is fixed by the brand: navy #051143 / #06123d, gold #bc9c25,
   grey #545350, brown-gold #6d6034.
   The interlocking chevron from the mark is the structural device throughout.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400&display=swap');

:root {
  --navy: #051143;
  --navy-deep: #06123d;
  --navy-lift: #0b1c56;
  --gold: #bc9c25;
  --gold-bright: #d8b431;
  --brown-gold: #6d6034;
  --grey: #545350;
  --ink: #14162b;
  --body: #45464f;
  --muted: #74757e;
  --line: #e2e3e8;
  --line-soft: #eceef2;
  --surface: #ffffff;
  --surface-alt: #f6f7f9;
  --surface-sink: #eef0f4;
  --danger: #a8261f;
  --danger-bg: #fbeceb;
  --ok: #1d6b47;
  --ok-bg: #e8f4ee;
  --warn: #8a6314;
  --warn-bg: #fbf3de;

  --radius: 4px;
  --radius-lg: 8px;
  --shadow-sm: 0 1px 2px rgba(5, 17, 67, .06), 0 2px 8px rgba(5, 17, 67, .05);
  --shadow-md: 0 4px 12px rgba(5, 17, 67, .09), 0 12px 32px rgba(5, 17, 67, .07);
  --shadow-lg: 0 18px 50px rgba(5, 17, 67, .16);

  --wrap: 1200px;
  --wrap-narrow: 760px;
  --font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

[data-theme="dark"] {
  --ink: #f2f3f7;
  --body: #c3c6d2;
  --muted: #8f93a3;
  --line: #1d2a5c;
  --line-soft: #16224d;
  --surface: #0a1747;
  --surface-alt: #061239;
  --surface-sink: #050f30;
  --navy: #0a1747;
  --danger-bg: #3a1614;
  --ok-bg: #0d2f20;
  --warn-bg: #33270c;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16.5px;
  line-height: 1.65;
  color: var(--body);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
}

[data-theme="dark"] body { background: var(--surface-alt); }

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

a { color: var(--navy); text-decoration: none; }
a:hover { color: var(--gold); }
[data-theme="dark"] a { color: var(--gold-bright); }

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 2px;
}

h1, h2, h3, h4, h5 {
  font-family: var(--font);
  color: var(--ink);
  margin: 0 0 .5em;
  line-height: 1.15;
  letter-spacing: -.02em;
  font-weight: 800;
}

h1 { font-size: clamp(2.15rem, 5.2vw, 3.6rem); letter-spacing: -.035em; }
h2 { font-size: clamp(1.65rem, 3.4vw, 2.5rem); letter-spacing: -.028em; }
h3 { font-size: 1.3rem; font-weight: 700; }
h4 { font-size: 1.05rem; font-weight: 700; }

p { margin: 0 0 1.05em; }
p:last-child { margin-bottom: 0; }

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

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--gold); color: var(--navy-deep); padding: 12px 20px; font-weight: 700;
}
.skip:focus { left: 0; }

/* ------------------------------------------------------------------ chevron motif */

.chev-field {
  position: absolute; inset: 0; overflow: hidden; pointer-events: none;
  opacity: .5;
}
.chev-field svg { position: absolute; right: -60px; top: -40px; width: 720px; height: auto; }

.chev-rule {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 18px;
}
.chev-rule::before {
  content: ''; width: 26px; height: 13px; flex: none;
  background: var(--gold);
  clip-path: polygon(0 100%, 50% 0, 100% 100%, 74% 100%, 50% 46%, 26% 100%);
}
.chev-rule span {
  font-size: .82rem; font-weight: 700; color: var(--brown-gold); letter-spacing: .02em;
}
[data-theme="dark"] .chev-rule span { color: var(--gold); }

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

.topbar {
  background: var(--navy-deep);
  color: rgba(255, 255, 255, .74);
  font-size: .82rem;
}
.topbar .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 38px; }
.topbar a { color: rgba(255, 255, 255, .74); }
.topbar a:hover { color: var(--gold-bright); }
.topbar-links { display: flex; gap: 18px; align-items: center; }

.masthead {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 60;
}
[data-theme="dark"] .masthead { background: var(--navy); }
.masthead .wrap { display: flex; align-items: center; gap: 28px; min-height: 78px; }

.brand { display: flex; align-items: center; flex: none; }
.brand img { height: 46px; width: auto; }
[data-theme="dark"] .brand img { filter: brightness(0) invert(1); }

.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav a {
  padding: 9px 13px; font-size: .93rem; font-weight: 600; color: var(--ink);
  border-radius: var(--radius); position: relative;
}
.nav a:hover { background: var(--surface-alt); color: var(--navy); }
[data-theme="dark"] .nav a { color: var(--ink); }
[data-theme="dark"] .nav a:hover { background: var(--navy-lift); }
.nav a.current { color: var(--navy); }
.nav a.current::after {
  content: ''; position: absolute; left: 13px; right: 13px; bottom: 2px; height: 3px; background: var(--gold);
}
[data-theme="dark"] .nav a.current { color: var(--gold-bright); }

.nav-actions { display: flex; align-items: center; gap: 10px; flex: none; }

.menu-toggle {
  display: none; background: none; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 9px 11px; cursor: pointer; color: var(--ink);
}
.menu-toggle svg { display: block; }

.theme-toggle {
  background: none; border: 1px solid var(--line); border-radius: var(--radius);
  width: 38px; height: 38px; cursor: pointer; color: var(--ink);
  display: inline-flex; align-items: center; justify-content: center;
}
.theme-toggle:hover { border-color: var(--gold); color: var(--gold); }

/* ------------------------------------------------------------------ buttons */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px; font-family: var(--font); font-size: .95rem; font-weight: 700;
  border-radius: var(--radius); border: 2px solid transparent; cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
  text-align: center; line-height: 1.2;
}
.btn-gold { background: var(--gold); color: var(--navy-deep); border-color: var(--gold); }
.btn-gold:hover { background: var(--gold-bright); border-color: var(--gold-bright); color: var(--navy-deep); }
.btn-navy { background: var(--navy); color: #fff; border-color: var(--navy); }
.btn-navy:hover { background: var(--navy-lift); color: var(--gold-bright); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--navy); color: var(--navy); }
.btn-onnavy { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .4); }
.btn-onnavy:hover { border-color: var(--gold); color: var(--gold-bright); }
.btn-danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn-danger:hover { background: #8e1f19; color: #fff; }
.btn-sm { padding: 8px 15px; font-size: .85rem; }
.btn-block { width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; pointer-events: none; }

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

.hero {
  position: relative; overflow: hidden;
  background: linear-gradient(148deg, var(--navy-deep) 0%, var(--navy) 46%, #0d1f63 100%);
  color: #fff;
  padding: clamp(64px, 9vw, 118px) 0 clamp(56px, 8vw, 96px);
}
.hero h1 { color: #fff; max-width: 15ch; }
.hero-lede { font-size: clamp(1.05rem, 1.7vw, 1.28rem); color: rgba(255, 255, 255, .82); max-width: 56ch; margin-bottom: 32px; }
.hero-inner { position: relative; z-index: 2; max-width: 720px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; }
.hero .chev-rule span { color: var(--gold-bright); }

.hero-strip {
  position: relative; z-index: 2;
  margin-top: clamp(48px, 6vw, 76px);
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  background: rgba(255, 255, 255, .16);
  border: 1px solid rgba(255, 255, 255, .16);
}
.hero-stat { background: var(--navy-deep); padding: 24px 22px; }
.hero-stat b {
  display: block; font-size: clamp(1.9rem, 3.4vw, 2.6rem); font-weight: 800;
  color: var(--gold-bright); letter-spacing: -.03em; line-height: 1;
}
.hero-stat span { display: block; margin-top: 8px; font-size: .86rem; color: rgba(255, 255, 255, .72); }

.page-head {
  background: var(--navy-deep); color: #fff; padding: 62px 0 54px; position: relative; overflow: hidden;
}
.page-head h1 { color: #fff; font-size: clamp(1.9rem, 4vw, 2.9rem); margin-bottom: .3em; }
.page-head p { color: rgba(255, 255, 255, .78); max-width: 62ch; margin: 0; }
.page-head .wrap { position: relative; z-index: 2; }

.crumbs { font-size: .85rem; color: rgba(255, 255, 255, .6); margin-bottom: 14px; }
.crumbs a { color: rgba(255, 255, 255, .78); }
.crumbs a:hover { color: var(--gold-bright); }

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

.section { padding: clamp(56px, 7vw, 88px) 0; }
.section-alt { background: var(--surface-alt); }
.section-navy { background: var(--navy-deep); color: rgba(255, 255, 255, .8); }
.section-navy h2, .section-navy h3 { color: #fff; }

.section-head { max-width: 62ch; margin-bottom: 40px; }
.section-head p { color: var(--muted); font-size: 1.05rem; margin: 0; }
.section-navy .section-head p { color: rgba(255, 255, 255, .72); }

.head-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 36px; flex-wrap: wrap; }
.head-row .section-head { margin-bottom: 0; }

.grid { display: grid; gap: 24px; }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
.split-side { display: grid; grid-template-columns: 300px 1fr; gap: 44px; align-items: start; }

/* ------------------------------------------------------------------ cards */

.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 26px; box-shadow: var(--shadow-sm);
}
.card h3 { margin-bottom: .35em; }
.card p { color: var(--body); font-size: .96rem; }
[data-theme="dark"] .card { background: var(--navy); }

.card-link { display: block; color: inherit; }
.card-link:hover { border-color: var(--gold); color: inherit; }

.value-card { padding: 28px 26px; border-top: 4px solid var(--gold); }
.value-card h3 { font-size: 1.15rem; }

.tile {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow-sm);
}
[data-theme="dark"] .tile { background: var(--navy); }
.tile-media { aspect-ratio: 16 / 9; background: var(--navy); overflow: hidden; position: relative; }
.tile-media img { width: 100%; height: 100%; object-fit: cover; }
.tile-body { padding: 22px; flex: 1; display: flex; flex-direction: column; }
.tile-body h3 { font-size: 1.12rem; margin-bottom: .4em; }
.tile-body h3 a { color: var(--ink); }
.tile-body h3 a:hover { color: var(--gold); }
[data-theme="dark"] .tile-body h3 a { color: var(--ink); }
.tile-meta { font-size: .84rem; color: var(--muted); margin-bottom: 10px; }
.tile-foot { margin-top: auto; padding-top: 16px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }

.pill {
  display: inline-block; padding: 4px 11px; border-radius: 100px; font-size: .74rem; font-weight: 700;
  background: var(--surface-sink); color: var(--grey);
}
.pill-gold { background: rgba(188, 156, 37, .16); color: var(--brown-gold); }
.pill-navy { background: rgba(5, 17, 67, .1); color: var(--navy); }
.pill-ok { background: var(--ok-bg); color: var(--ok); }
.pill-warn { background: var(--warn-bg); color: var(--warn); }
.pill-danger { background: var(--danger-bg); color: var(--danger); }
[data-theme="dark"] .pill-navy { background: rgba(255, 255, 255, .12); color: #fff; }
[data-theme="dark"] .pill { background: rgba(255, 255, 255, .1); color: var(--body); }

.datebox {
  flex: none; width: 62px; text-align: center; background: var(--navy); color: #fff;
  border-radius: var(--radius); padding: 9px 0; line-height: 1.1;
}
.datebox b { display: block; font-size: 1.35rem; font-weight: 800; color: var(--gold-bright); }
.datebox span { display: block; font-size: .72rem; letter-spacing: .06em; }

.event-row { display: flex; gap: 18px; align-items: flex-start; padding: 20px 0; border-bottom: 1px solid var(--line); }
.event-row:last-child { border-bottom: 0; }
.event-row h3 { font-size: 1.08rem; margin-bottom: .25em; }

/* chevron list */
.chev-list { list-style: none; margin: 0; padding: 0; }
.chev-list li { position: relative; padding: 0 0 11px 26px; }
.chev-list li::before {
  content: ''; position: absolute; left: 0; top: .58em; width: 14px; height: 8px;
  background: var(--gold);
  clip-path: polygon(0 100%, 50% 0, 100% 100%, 72% 100%, 50% 42%, 28% 100%);
}
.section-navy .chev-list li { color: rgba(255, 255, 255, .82); }

/* ------------------------------------------------------------------ pricing */

.tiers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; align-items: start; }
.tier {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 28px 24px; display: flex; flex-direction: column; box-shadow: var(--shadow-sm);
}
[data-theme="dark"] .tier { background: var(--navy); }
.tier-featured { border: 2px solid var(--gold); box-shadow: var(--shadow-md); position: relative; }
.tier-flag {
  position: absolute; top: -13px; left: 24px; background: var(--gold); color: var(--navy-deep);
  font-size: .74rem; font-weight: 800; padding: 4px 12px; border-radius: 3px;
}
.tier h3 { font-size: 1.25rem; margin-bottom: .2em; }
.tier-tag { color: var(--muted); font-size: .89rem; min-height: 42px; }
.tier-price { margin: 18px 0 4px; font-size: 2.1rem; font-weight: 800; color: var(--navy); letter-spacing: -.03em; }
[data-theme="dark"] .tier-price { color: var(--gold-bright); }
.tier-per { color: var(--muted); font-size: .85rem; margin-bottom: 20px; }
.tier .chev-list { margin-bottom: 24px; font-size: .92rem; }
.tier .btn { margin-top: auto; }

.matrix { width: 100%; border-collapse: collapse; font-size: .92rem; }
.matrix th, .matrix td { padding: 13px 14px; border-bottom: 1px solid var(--line); text-align: center; }
.matrix th:first-child, .matrix td:first-child { text-align: left; }
.matrix thead th { background: var(--navy-deep); color: #fff; font-weight: 700; }
.matrix thead th:first-child { border-radius: var(--radius) 0 0 0; }
.matrix tbody tr:nth-child(even) { background: var(--surface-alt); }
.matrix .yes { color: var(--ok); font-weight: 800; }
.matrix .no { color: var(--muted); }

/* ------------------------------------------------------------------ forms */

.form-row { margin-bottom: 20px; }
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 20px; }
label { display: block; font-weight: 600; font-size: .9rem; color: var(--ink); margin-bottom: 7px; }
.hint { font-size: .84rem; color: var(--muted); margin-top: 6px; }

input[type=text], input[type=email], input[type=password], input[type=number], input[type=date],
input[type=datetime-local], input[type=tel], input[type=url], input[type=search], input[type=file], select, textarea {
  width: 100%; padding: 12px 14px; font-family: var(--font); font-size: .96rem;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
  color: var(--ink); transition: border-color .15s ease;
}
[data-theme="dark"] input, [data-theme="dark"] select, [data-theme="dark"] textarea { background: var(--surface-sink); }
input:focus, select:focus, textarea:focus { border-color: var(--navy); outline: 2px solid rgba(188, 156, 37, .45); outline-offset: 0; }
textarea { min-height: 140px; resize: vertical; line-height: 1.6; }
select { appearance: none; background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%23545350' d='M1 1l5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; background-size: 12px; padding-right: 38px; }

.check { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; }
.check input { margin-top: 4px; flex: none; width: 17px; height: 17px; accent-color: var(--gold); }
.check label { margin: 0; font-weight: 500; font-size: .93rem; color: var(--body); }

.filterbar {
  display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end;
  background: var(--surface-alt); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 18px 20px; margin-bottom: 32px;
}
.filterbar .form-row { margin: 0; flex: 1 1 180px; }
.filterbar label { font-size: .8rem; }

.auth-shell { display: grid; grid-template-columns: 1fr 1fr; min-height: calc(100vh - 78px); }
.auth-aside {
  background: linear-gradient(160deg, var(--navy-deep), #0d1f63); color: #fff;
  padding: clamp(40px, 6vw, 72px); display: flex; flex-direction: column; justify-content: center;
  position: relative; overflow: hidden;
}
.auth-aside h2 { color: #fff; }
.auth-aside > * { position: relative; z-index: 2; }
.auth-main { padding: clamp(40px, 6vw, 72px); display: flex; align-items: center; justify-content: center; }
.auth-box { width: 100%; max-width: 440px; }

/* ------------------------------------------------------------------ alerts */

.alert {
  padding: 14px 18px; border-radius: var(--radius); margin-bottom: 20px; font-size: .94rem;
  border-left: 4px solid var(--navy); background: var(--surface-alt); color: var(--ink);
}
.alert-success { border-color: var(--ok); background: var(--ok-bg); color: var(--ok); }
.alert-error { border-color: var(--danger); background: var(--danger-bg); color: var(--danger); }
.alert-warn { border-color: var(--gold); background: var(--warn-bg); color: var(--warn); }

.gate {
  border: 1px dashed var(--gold); background: var(--warn-bg); border-radius: var(--radius-lg);
  padding: 32px; text-align: center;
}
.gate h3 { color: var(--brown-gold); }

.empty {
  border: 1px dashed var(--line); border-radius: var(--radius-lg); padding: 44px 28px; text-align: center;
  color: var(--muted);
}
.empty h3 { color: var(--ink); margin-bottom: .3em; }

/* ------------------------------------------------------------------ tables */

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
[data-theme="dark"] .table-wrap { background: var(--navy); }
table.data { width: 100%; border-collapse: collapse; font-size: .92rem; }
table.data th, table.data td { padding: 13px 16px; text-align: left; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
table.data thead th { background: var(--surface-alt); font-weight: 700; color: var(--ink); white-space: nowrap; font-size: .84rem; }
table.data tbody tr:hover { background: var(--surface-alt); }
table.data td.num, table.data th.num { text-align: right; }
table.data .row-actions { display: flex; gap: 8px; justify-content: flex-end; }

.pager { display: flex; gap: 6px; margin-top: 26px; flex-wrap: wrap; }
.pager a, .pager span {
  padding: 8px 14px; border: 1px solid var(--line); border-radius: var(--radius); font-size: .9rem; font-weight: 600;
}
.pager-current { background: var(--navy); color: #fff; border-color: var(--navy); }

/* ------------------------------------------------------------------ member directory */

.person {
  display: flex; gap: 16px; padding: 20px; border: 1px solid var(--line);
  border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-sm);
}
[data-theme="dark"] .person { background: var(--navy); }
.person img, .person .avatar {
  width: 58px; height: 58px; border-radius: 50%; object-fit: cover; flex: none; border: 2px solid var(--gold);
}
.person h3 { font-size: 1.02rem; margin-bottom: .1em; }
.person .role { font-size: .87rem; color: var(--muted); margin-bottom: 8px; }
.tagset { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }

/* ------------------------------------------------------------------ member & admin shell */

.app { display: grid; grid-template-columns: 258px 1fr; min-height: calc(100vh - 78px); align-items: start; }
.side {
  background: var(--navy-deep); color: rgba(255, 255, 255, .78); padding: 26px 0; min-height: 100%;
  position: sticky; top: 78px; align-self: stretch;
}
.side-group { padding: 0 0 18px; }
.side-group h4 {
  font-size: .74rem; color: rgba(255, 255, 255, .42); font-weight: 700; letter-spacing: .04em;
  padding: 0 24px; margin-bottom: 8px;
}
.side a {
  display: flex; align-items: center; gap: 11px; padding: 10px 24px; color: rgba(255, 255, 255, .78);
  font-size: .93rem; font-weight: 500; border-left: 3px solid transparent;
}
.side a:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.side a.current { background: rgba(188, 156, 37, .14); border-left-color: var(--gold); color: #fff; font-weight: 700; }
.side a svg { flex: none; opacity: .85; }

.app-main { padding: 34px 34px 64px; min-width: 0; }
.app-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 28px; flex-wrap: wrap; }
.app-head h1 { font-size: 1.85rem; margin-bottom: .15em; }
.app-head p { color: var(--muted); margin: 0; font-size: .95rem; }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 30px; }
.stat {
  background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--gold);
  border-radius: var(--radius); padding: 20px 22px;
}
[data-theme="dark"] .stat { background: var(--navy); }
.stat b { display: block; font-size: 1.95rem; font-weight: 800; color: var(--navy); letter-spacing: -.03em; line-height: 1.1; }
[data-theme="dark"] .stat b { color: var(--gold-bright); }
.stat span { font-size: .85rem; color: var(--muted); }

.panel {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  margin-bottom: 26px; overflow: hidden;
}
[data-theme="dark"] .panel { background: var(--navy); }
.panel-head {
  padding: 17px 22px; border-bottom: 1px solid var(--line); display: flex;
  justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
}
.panel-head h2, .panel-head h3 { margin: 0; font-size: 1.05rem; font-weight: 700; }
.panel-body { padding: 22px; }
.panel-body > .table-wrap { border: 0; border-radius: 0; margin: -22px; width: calc(100% + 44px); }

.membercard {
  background: linear-gradient(140deg, var(--navy-deep), #12256e); color: #fff;
  border-radius: var(--radius-lg); padding: 26px; position: relative; overflow: hidden;
}
.membercard > * { position: relative; z-index: 2; }
.membercard .mc-no { font-size: 1.25rem; font-weight: 800; letter-spacing: .04em; color: var(--gold-bright); }
.membercard .mc-name { font-size: 1.35rem; font-weight: 800; margin: 14px 0 2px; color: #fff; }
.membercard .mc-meta { font-size: .88rem; color: rgba(255, 255, 255, .74); }

.progress { height: 9px; background: var(--surface-sink); border-radius: 100px; overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--gold); border-radius: 100px; }

.bars { display: flex; align-items: flex-end; gap: 6px; height: 150px; }
.bars div { flex: 1; background: var(--navy); border-radius: 3px 3px 0 0; min-height: 3px; position: relative; }
.bars div:hover { background: var(--gold); }
.barlabels { display: flex; gap: 6px; margin-top: 8px; }
.barlabels span { flex: 1; text-align: center; font-size: .7rem; color: var(--muted); }

/* ------------------------------------------------------------------ forum & article */

.prose { max-width: 72ch; }
.prose h2 { font-size: 1.5rem; margin-top: 1.8em; }
.prose h3 { font-size: 1.2rem; margin-top: 1.5em; }
.prose ul, .prose ol { padding-left: 22px; margin-bottom: 1.1em; }
.prose li { margin-bottom: .45em; }
.prose blockquote {
  border-left: 4px solid var(--gold); padding: 4px 0 4px 20px; margin: 1.4em 0;
  color: var(--ink); font-size: 1.08rem;
}
.prose img { border-radius: var(--radius); margin: 1.4em 0; }
.prose table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: .93rem; }
.prose th, .prose td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; }
.prose pre { background: var(--surface-sink); padding: 16px; border-radius: var(--radius); overflow-x: auto; }

.thread-post { display: flex; gap: 16px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.thread-post img, .thread-post .avatar { width: 44px; height: 44px; border-radius: 50%; flex: none; }
.thread-post .who { font-weight: 700; color: var(--ink); font-size: .95rem; }
.thread-post .when { font-size: .82rem; color: var(--muted); }

/* ------------------------------------------------------------------ verify tool */

.verify-result { border-radius: var(--radius-lg); padding: 30px; border: 2px solid var(--ok); background: var(--ok-bg); }
.verify-result.bad { border-color: var(--danger); background: var(--danger-bg); }
.verify-result h3 { color: var(--ok); }
.verify-result.bad h3 { color: var(--danger); }

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

.foot { background: var(--navy-deep); color: rgba(255, 255, 255, .68); padding: 64px 0 0; font-size: .93rem; }
.foot h4 { color: #fff; font-size: .96rem; margin-bottom: 16px; }
.foot a { color: rgba(255, 255, 255, .68); }
.foot a:hover { color: var(--gold-bright); }
.foot-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.3fr; gap: 40px; padding-bottom: 44px; }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot li { margin-bottom: 9px; }
.foot-mark img { height: 44px; filter: brightness(0) invert(1); margin-bottom: 18px; }
.foot-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12); padding: 20px 0; display: flex;
  justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .85rem;
}
.foot-social { display: flex; gap: 12px; }
.foot-social a {
  width: 36px; height: 36px; border: 1px solid rgba(255, 255, 255, .2); border-radius: var(--radius);
  display: inline-flex; align-items: center; justify-content: center;
}
.foot-social a:hover { border-color: var(--gold); }

.newsletter-inline { display: flex; gap: 10px; }
.newsletter-inline input { background: rgba(255, 255, 255, .07); border-color: rgba(255, 255, 255, .2); color: #fff; }
.newsletter-inline input::placeholder { color: rgba(255, 255, 255, .5); }

/* ------------------------------------------------------------------ utilities */

.mt0 { margin-top: 0; } .mt8 { margin-top: 8px; } .mt16 { margin-top: 16px; }
.mt24 { margin-top: 24px; } .mt32 { margin-top: 32px; } .mt40 { margin-top: 40px; }
.mb0 { margin-bottom: 0; } .mb8 { margin-bottom: 8px; } .mb16 { margin-bottom: 16px; }
.mb24 { margin-bottom: 24px; } .mb32 { margin-bottom: 32px; }
.muted { color: var(--muted); }
.small { font-size: .87rem; }
.tiny { font-size: .8rem; }
.strong { font-weight: 700; }
.center { text-align: center; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.row-end { justify-content: flex-end; }
.stack > * + * { margin-top: 16px; }
.hr { height: 1px; background: var(--line); border: 0; margin: 28px 0; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

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

@media (max-width: 1080px) {
  .g4, .tiers, .stat-grid, .hero-strip { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { grid-template-columns: repeat(2, 1fr); }
  .app { grid-template-columns: 210px 1fr; }
}

@media (max-width: 900px) {
  .masthead .wrap { min-height: 66px; }
  .menu-toggle { display: inline-flex; order: 3; }
  .nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column;
    align-items: stretch; background: var(--surface); border-bottom: 1px solid var(--line);
    padding: 12px 16px 20px; box-shadow: var(--shadow-md); gap: 2px;
  }
  [data-theme="dark"] .nav { background: var(--navy); }
  .nav.open { display: flex; }
  .nav a { padding: 12px 10px; }
  .nav a.current::after { display: none; }
  .nav a.current { background: var(--surface-alt); }
  .masthead { position: relative; }
  .g2, .g3, .split, .split-side, .auth-shell { grid-template-columns: 1fr; }
  .app { grid-template-columns: 1fr; }
  .side { position: static; padding: 16px 0; }
  .side-group { display: flex; flex-wrap: wrap; gap: 4px; padding: 0 12px 10px; }
  .side-group h4 { width: 100%; padding: 0 12px; }
  .side a { border-left: 0; border-bottom: 3px solid transparent; padding: 9px 14px; }
  .side a.current { border-left: 0; border-bottom-color: var(--gold); }
  .app-main { padding: 24px 20px 48px; }
  .topbar .wrap { justify-content: center; }
  .topbar-contact { display: none; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .g4, .tiers, .stat-grid, .hero-strip, .foot-grid, .form-grid { grid-template-columns: 1fr; }
  .hero-strip { border: 0; background: none; gap: 12px; }
  .hero-stat { border: 1px solid rgba(255, 255, 255, .18); }
  .wrap { padding: 0 18px; }
  .section { padding: 46px 0; }
  .btn { width: 100%; }
  .row .btn { width: auto; }
  .hero-cta .btn { width: 100%; }
  .card, .tile-body, .panel-body { padding: 20px; }
  .newsletter-inline { flex-direction: column; }
}

@media print {
  .masthead, .topbar, .foot, .side, .btn, .pager { display: none !important; }
  body { background: #fff; color: #000; }
  .app { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------------ FAQ disclosure */
.faq { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 34px 18px 0; position: relative;
  font-weight: 600; color: var(--navy); font-size: 1.02rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '+'; position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  font-size: 1.4rem; font-weight: 400; color: var(--gold); line-height: 1;
}
.faq[open] summary::after { content: '\2013'; }
.faq p { margin: 0 0 20px; color: var(--muted); max-width: 72ch; }

/* --------------------------------------------------------- comparison ticks */
.tick { color: var(--gold); font-size: 1.05rem; font-weight: 700; }

/* ------------------------------------------------------------------ gallery */
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.gitem {
  display: block; position: relative; overflow: hidden; border-radius: 6px;
  background: var(--surface-alt); aspect-ratio: 4 / 3; border: 1px solid var(--line);
}
.gitem img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s ease; }
.gitem:hover img, .gitem:focus-visible img { transform: scale(1.05); }
.gitem figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 12px 10px;
  background: linear-gradient(transparent, rgba(5,17,67,.85));
  color: #fff; font-size: .8rem; line-height: 1.35;
}

/* --------------------------------------------------------------- album card */
.album-card { position: relative; overflow: hidden; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); }
.album-card .cover { aspect-ratio: 16 / 10; background: var(--surface-alt); overflow: hidden; }
.album-card .cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.album-card .body { padding: 18px 20px 22px; }
.album-card h3 { margin: 0 0 4px; font-size: 1.05rem; }

/* ------------------------------------------------------------------- videos */
.video-embed { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: 8px; overflow: hidden; }
.video-embed iframe, .video-embed video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-card .thumb { position: relative; aspect-ratio: 16 / 9; border-radius: 6px; overflow: hidden; background: var(--surface-alt); }
.video-card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.video-card .thumb::after {
  content: ''; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 0; height: 0; border-style: solid; border-width: 13px 0 13px 21px;
  border-color: transparent transparent transparent #fff;
  filter: drop-shadow(0 2px 10px rgba(0,0,0,.6));
}

/* ----------------------------------------------------- admin media library */
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 14px; }
.media-tile { border: 1px solid var(--line); border-radius: 6px; overflow: hidden; background: var(--surface); }
.media-tile .shot { aspect-ratio: 4 / 3; background: var(--surface-alt); display: flex; align-items: center; justify-content: center; }
.media-tile .shot img { width: 100%; height: 100%; object-fit: cover; }
.media-tile .meta { padding: 10px 12px; font-size: .78rem; }
.media-tile .meta p { margin: 0 0 6px; word-break: break-all; }

/* ------------------------------------------------------- CMS block editing */
.block-row { border-bottom: 1px solid var(--line); padding: 20px 0; }
.block-row:last-child { border-bottom: 0; }
.block-row > label { display: block; font-weight: 600; color: var(--navy); margin-bottom: 4px; }
.block-pick { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; }
.block-pick img { max-width: 160px; border-radius: 6px; border: 1px solid var(--line); }

.matrix tbody th { font-weight: 500; text-align: left; color: inherit; background: transparent; }
