/* ==========================================================================
   AAMS — NGDC HSC Batch 1999 Alumni  •  public site + member portal
   Palette from the logo: navy #04274D, gold #BD8C37
   ========================================================================== */
:root {
  --navy: #04274D;
  --navy-900: #021A35;
  --navy-700: #0B3A6B;
  --navy-100: #E6ECF4;
  --gold: #BD8C37;
  --gold-600: #A47426;
  --gold-300: #E3C48A;
  --gold-100: #F7EEDC;
  --paper: #FAF7F1;
  --card: #FFFFFF;
  --ink: #0F1B2D;
  --ink-2: #33445A;
  --muted: #66758A;
  --line: #E8E1D3;
  --line-2: #EFEAE0;
  --ok: #1E8E5A;   --ok-bg: #E5F5EC;
  --warn: #B7791F; --warn-bg: #FDF3DF;
  --bad: #C0392B;  --bad-bg: #FBE9E7;
  --r: 16px;
  --r-sm: 10px;
  --shadow: 0 1px 2px rgba(4,39,77,.06), 0 8px 24px rgba(4,39,77,.07);
  --shadow-lg: 0 2px 6px rgba(4,39,77,.08), 0 24px 48px rgba(4,39,77,.14);
  --font: "Hind Siliguri", "Noto Sans Bengali", system-ui, sans-serif;
  --font-display: "Noto Serif Bengali", "Hind Siliguri", serif;
  --font-display-en: "Playfair Display", "Noto Serif Bengali", Georgia, serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 17px; line-height: 1.7; color: var(--ink); background: var(--paper); }
img { max-width: 100%; display: block; }
a { color: var(--navy-700); text-decoration: none; }
a:hover { color: var(--gold-600); }
h1, h2, h3, h4 { line-height: 1.3; margin: 0 0 .5em; color: var(--navy); }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 3px solid var(--gold-300); outline-offset: 2px; border-radius: 6px; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; padding: .62em 1.3em; border-radius: 999px; font: 600 16px/1.2 var(--font); border: 1.5px solid transparent; cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s, color .15s; white-space: nowrap; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }
.btn-gold { background: var(--gold); color: #fff; box-shadow: 0 6px 18px rgba(189,140,55,.35); }
.btn-gold:hover { background: var(--gold-600); color: #fff; }
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--navy-700); color: #fff; }
.btn-line { border-color: var(--line); background: #fff; color: var(--navy); }
.btn-line:hover { border-color: var(--gold); color: var(--gold-600); }
.btn-ghost { border-color: rgba(255,255,255,.35); color: #fff; background: rgba(255,255,255,.06); }
.btn-ghost:hover { background: rgba(255,255,255,.14); color: #fff; }
.btn-ghost-nav { border-color: var(--line); color: var(--navy); background: #fff; }
.btn-lg { padding: .8em 1.7em; font-size: 17px; }
.btn-sm { padding: .42em .95em; font-size: 14px; }
.btn-block { width: 100%; }
.btn-danger { background: var(--bad-bg); color: var(--bad); }

/* ---------- nav ---------- */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(250,247,241,.92); backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--line); }
.nav-in { display: flex; align-items: center; gap: 24px; height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--navy); }
.brand img { width: 54px; height: auto; }
.brand-txt { display: flex; flex-direction: column; line-height: 1.2; }
.brand-txt strong { font-size: 18px; font-weight: 700; }
.brand-txt small { font-size: 13px; color: var(--gold-600); font-weight: 600; }
.nav-links { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.nav-links > a:not(.btn) { padding: 8px 12px; border-radius: 8px; color: var(--ink-2); font-weight: 500; font-size: 16px; }
.nav-links > a:not(.btn):hover, .nav-links > a.on { color: var(--navy); background: var(--gold-100); }
.nav-links .nav-login { color: var(--navy) !important; font-weight: 600 !important; }
.nav-sep { width: 1px; height: 26px; background: var(--line); margin: 0 8px; }
.nav-toggle { display: none; margin-left: auto; background: none; border: 0; font-size: 30px; color: var(--navy); cursor: pointer; }

/* ---------- flash ---------- */
.flash-wrap:empty { display: none; }
.flash-wrap { padding-top: 16px; }
.flash { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-radius: var(--r-sm); margin-bottom: 8px; font-weight: 500; animation: drop .3s ease; }
.flash-ok { background: var(--ok-bg); color: var(--ok); border: 1px solid #BFE6CF; }
.flash-err { background: var(--bad-bg); color: var(--bad); border: 1px solid #F3C4BE; }
.flash span { flex: 1; }
.flash-x { background: none; border: 0; font-size: 22px; line-height: 1; color: inherit; cursor: pointer; opacity: .6; }
@keyframes drop { from { opacity: 0; transform: translateY(-6px); } }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; color: #fff; background:
  radial-gradient(900px 500px at 85% 20%, rgba(189,140,55,.28), transparent 60%),
  radial-gradient(700px 500px at 0% 100%, rgba(11,58,107,.9), transparent 70%),
  linear-gradient(160deg, var(--navy) 0%, var(--navy-900) 100%); }
.hero::before { content: ""; position: absolute; inset: 0; opacity: .07; background-image:
  repeating-linear-gradient(115deg, #fff 0 1px, transparent 1px 28px); mask-image: linear-gradient(to bottom, #000, transparent 85%); }
.hero-in { position: relative; display: grid; grid-template-columns: 1.3fr .7fr; gap: 48px; align-items: center; padding: 72px 20px 96px; }
.ribbon { display: inline-flex; align-items: center; gap: 10px; padding: 6px 16px 6px 6px; border-radius: 999px; background: rgba(255,255,255,.08); border: 1px solid rgba(227,196,138,.35); font-size: 15px; color: var(--gold-300); font-weight: 600; }
.ribbon b { background: var(--gold); color: #fff; padding: 2px 12px; border-radius: 999px; font-weight: 600; }
.hero h1 { color: #fff; font-family: var(--font-display); font-weight: 800; font-size: clamp(34px, 4.6vw, 56px); line-height: 1.25; margin: 22px 0 18px; letter-spacing: -.01em; }
.hero h1 em { font-style: normal; color: var(--gold-300); position: relative; white-space: nowrap; }
.hero h1 em::after { content: ""; position: absolute; left: 0; right: 0; bottom: .02em; height: .12em; background: linear-gradient(90deg, var(--gold), transparent); border-radius: 4px; }
.hero-lead { font-size: 19px; color: rgba(255,255,255,.82); max-width: 560px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-trust { display: flex; align-items: center; gap: 14px; margin-top: 34px; color: rgba(255,255,255,.75); font-size: 15px; }
.stack { display: flex; }
.stack .avatar { border: 2.5px solid var(--navy); margin-left: -10px; }
.stack .avatar:first-child { margin-left: 0; }

.hero-card { position: relative; justify-self: center; width: min(420px, 100%); }
.emblem-ring { aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; position: relative;
  background: radial-gradient(circle at 50% 40%, rgba(255,255,255,.12), rgba(255,255,255,.02) 65%); border: 1px solid rgba(227,196,138,.25); }
.emblem-ring::before, .emblem-ring::after { content: ""; position: absolute; inset: 7%; border-radius: 50%; border: 1px dashed rgba(227,196,138,.3); }
.emblem-ring::after { inset: -6%; border: 1px solid rgba(255,255,255,.06); }
.emblem-ring img { width: 66%; margin-top: -16%; filter: drop-shadow(0 18px 30px rgba(0,0,0,.35)); }
.countdown { position: absolute; left: 50%; bottom: -46px; transform: translateX(-50%); width: max-content; max-width: 100%; background: #fff; color: var(--ink); border-radius: var(--r); box-shadow: var(--shadow-lg); padding: 14px 18px; text-align: center; }
.countdown small { display: block; font-size: 13px; color: var(--muted); font-weight: 600; margin-bottom: 6px; }
.countdown small b { color: var(--navy); }
.cd { display: flex; gap: 8px; justify-content: center; }
.cd div { min-width: 62px; background: var(--paper); border: 1px solid var(--line); border-radius: 10px; padding: 6px 4px; }
.cd strong { display: block; font-size: 26px; line-height: 1.1; color: var(--navy); font-weight: 700; font-variant-numeric: tabular-nums; }
.cd span { font-size: 12px; color: var(--muted); }

/* ---------- stats ---------- */
.stats { position: relative; z-index: 2; margin-top: -40px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); background: #fff; border-radius: var(--r); box-shadow: var(--shadow-lg); overflow: hidden; }
.stat { padding: 26px 24px; display: flex; gap: 16px; align-items: center; border-right: 1px solid var(--line-2); }
.stat:last-child { border-right: 0; }
.stat-ic { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; font-size: 24px; background: var(--gold-100); color: var(--gold-600); flex-shrink: 0; }
.stat:nth-child(2n) .stat-ic { background: var(--navy-100); color: var(--navy); }
.stat strong { display: block; font-size: 30px; line-height: 1.1; color: var(--navy); font-weight: 700; }
.stat div > span { color: var(--muted); font-size: 15px; line-height: 1.45; display: block; }

/* ---------- sections ---------- */
.sec { padding: 96px 0; }
.sec-alt { background: #fff; border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.sec-head { text-align: center; max-width: 680px; margin: 0 auto 48px; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; color: var(--gold-600); font-weight: 700; font-size: 15px; letter-spacing: .02em; margin-bottom: 10px; }
.eyebrow::before, .eyebrow::after { content: ""; width: 22px; height: 2px; background: var(--gold); border-radius: 2px; }
.sec-head.left { text-align: left; margin-left: 0; }
.sec-head.left .eyebrow::after { display: none; }
.sec h2 { font-family: var(--font-display); font-size: clamp(28px, 3.4vw, 40px); font-weight: 700; }
.sec-head p { color: var(--muted); font-size: 18px; }

.about { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.about-visual { position: relative; }
.about-card { background: linear-gradient(150deg, var(--navy), var(--navy-900)); border-radius: 24px; padding: 40px; color: #fff; position: relative; overflow: hidden; box-shadow: var(--shadow-lg); }
.about-card::after { content: "৯৯"; position: absolute; right: -10px; bottom: -70px; font: 800 220px/1 var(--font-display); color: rgba(189,140,55,.14); }
.about-card img { width: 220px; margin-bottom: 18px; }
.about-card blockquote { margin: 0; font-size: 20px; line-height: 1.6; color: rgba(255,255,255,.9); position: relative; z-index: 1; }
.about-card cite { display: block; margin-top: 14px; font-style: normal; color: var(--gold-300); font-weight: 600; font-size: 15px; }
.about-badge { position: absolute; right: -18px; top: 28px; background: #fff; border-radius: 14px; padding: 12px 16px; box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 10px; }
.about-badge strong { font-size: 26px; color: var(--gold-600); line-height: 1; }
.about-badge span { font-size: 13px; color: var(--muted); line-height: 1.3; }
.ticks { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; }
.ticks li { display: flex; gap: 12px; align-items: flex-start; }
.ticks i { color: var(--gold); font-size: 20px; margin-top: 2px; }
.groups { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 26px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 999px; background: var(--gold-100); color: var(--gold-600); font-weight: 600; font-size: 14px; }
.chip-navy { background: var(--navy-100); color: var(--navy); }

/* features */
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.feature { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); padding: 28px 24px; transition: transform .2s, box-shadow .2s, border-color .2s; }
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--gold-300); background: #fff; }
.feature .ic { width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; background: var(--navy); color: var(--gold-300); font-size: 22px; margin-bottom: 18px; }
.feature h3 { font-size: 19px; margin-bottom: 6px; }
.feature p { color: var(--muted); font-size: 15.5px; margin: 0; }

/* event cards */
.ev-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 380px)); justify-content: center; gap: 24px; }
.ev { background: #fff; border-radius: var(--r); border: 1px solid var(--line); overflow: hidden; display: flex; flex-direction: column; transition: transform .2s, box-shadow .2s; color: inherit; }
.ev:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); color: inherit; }
.ev-cover { height: 170px; position: relative; background: linear-gradient(135deg, var(--navy-700), var(--navy-900)); }
.ev-cover img { width: 100%; height: 100%; object-fit: cover; }
.ev-cover .ev-ph { position: absolute; inset: 0; display: grid; place-items: center; }
.ev-cover .ev-ph img { width: 120px; height: auto; object-fit: contain; opacity: .9; }
.ev-date { position: absolute; left: 16px; bottom: -26px; background: #fff; border-radius: 12px; box-shadow: var(--shadow); padding: 8px 12px; text-align: center; min-width: 64px; }
.ev-date strong { display: block; font-size: 24px; line-height: 1; color: var(--navy); }
.ev-date span { font-size: 13px; color: var(--gold-600); font-weight: 600; }
.ev-body { padding: 38px 22px 22px; flex: 1; display: flex; flex-direction: column; }
.ev-body h3 { font-size: 20px; margin-bottom: 8px; }
.ev-meta { display: grid; gap: 4px; color: var(--muted); font-size: 15px; margin-bottom: 14px; }
.ev-meta i { color: var(--gold); width: 18px; display: inline-block; }
.ev-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; padding-top: 14px; border-top: 1px dashed var(--line); }
.price { font-weight: 700; color: var(--navy); font-size: 18px; }
.price.free { color: var(--ok); }
.ev-past { filter: grayscale(.6); opacity: .8; }

/* members strip */
.mem-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.mem { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 22px 18px; text-align: center; color: inherit; transition: box-shadow .2s, transform .2s; }
a.mem:hover { box-shadow: var(--shadow); transform: translateY(-3px); color: inherit; }
.mem .avatar { margin: 0 auto 12px; }
.mem strong { display: block; color: var(--navy); font-size: 17px; line-height: 1.35; }
.mem small { display: block; color: var(--muted); font-size: 14px; line-height: 1.4; margin-top: 3px; }
.mem .chip { margin-top: 10px; font-size: 12.5px; padding: 3px 10px; }

/* notices */
.notice-list { display: grid; gap: 14px; }
.notice { display: flex; gap: 18px; padding: 20px 22px; background: #fff; border: 1px solid var(--line); border-radius: var(--r); color: inherit; transition: border-color .2s, box-shadow .2s; }
.notice:hover { border-color: var(--gold-300); box-shadow: var(--shadow); color: inherit; }
.notice-date { flex-shrink: 0; width: 64px; text-align: center; border-right: 1px solid var(--line); padding-right: 16px; }
.notice-date strong { display: block; font-size: 26px; color: var(--navy); line-height: 1.1; }
.notice-date span { font-size: 13px; color: var(--muted); }
.notice h3 { font-size: 18px; margin-bottom: 4px; }
.notice p { color: var(--muted); margin: 0; font-size: 15.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pin { color: var(--gold-600); font-size: 13px; font-weight: 600; }

/* CTA band */
.cta-band { background: linear-gradient(120deg, var(--gold-600), var(--gold) 50%, #CFA457); color: #fff; border-radius: 24px; padding: 48px 56px; display: flex; align-items: center; justify-content: space-between; gap: 24px; position: relative; overflow: hidden; }
.cta-band::after { content: ""; position: absolute; right: -60px; top: -60px; width: 260px; height: 260px; border-radius: 50%; border: 40px solid rgba(255,255,255,.1); }
.cta-band h2 { color: #fff; margin: 0 0 6px; font-family: var(--font-display); font-size: clamp(24px, 3vw, 34px); }
.cta-band p { margin: 0; color: rgba(255,255,255,.9); font-size: 18px; }
.cta-band .btn { background: var(--navy); color: #fff; position: relative; z-index: 1; }
.cta-band .btn:hover { background: var(--navy-900); }

/* contact */
.contact { display: grid; grid-template-columns: .9fr 1.1fr; gap: 40px; }
.contact-info { display: grid; gap: 14px; align-content: start; }
.ci { display: flex; gap: 14px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 18px; }
.ci i { width: 46px; height: 46px; border-radius: 12px; background: var(--gold-100); color: var(--gold-600); display: grid; place-items: center; font-size: 20px; flex-shrink: 0; }
.ci small { display: block; color: var(--muted); font-size: 14px; }
.ci strong { color: var(--navy); font-weight: 600; }

/* ---------- forms ---------- */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); }
.card-pad { padding: 28px; }
.card h2, .card h3 { font-family: var(--font); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 20px; }
.form-grid .full { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label, .lbl { font-weight: 600; font-size: 15px; color: var(--ink-2); }
.field label .req { color: var(--bad); }
.input, .field input[type=text], .field input[type=search], .field input[type=tel], .field input[type=email], .field input[type=password], .field input[type=date], .field input[type=number], .field select, .field textarea {
  width: 100%; font: 400 16px/1.5 var(--font); color: var(--ink); background: #fff; border: 1.5px solid var(--line); border-radius: var(--r-sm); padding: 10px 14px; transition: border-color .15s, box-shadow .15s; }
.field textarea { min-height: 110px; resize: vertical; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 4px rgba(189,140,55,.15); }
.field .hint { font-size: 13.5px; color: var(--muted); }
.field-validation-error, .err-txt { color: var(--bad); font-size: 14px; }
.input-validation-error { border-color: var(--bad) !important; }
.validation-summary-errors ul { margin: 0 0 16px; padding: 12px 16px 12px 34px; background: var(--bad-bg); color: var(--bad); border-radius: var(--r-sm); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 15.5px; cursor: pointer; }
.check input { width: 19px; height: 19px; margin-top: 4px; accent-color: var(--navy); flex-shrink: 0; }
.seg { display: flex; gap: 8px; flex-wrap: wrap; }
.seg label { position: relative; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span { display: inline-block; padding: 8px 18px; border: 1.5px solid var(--line); border-radius: 999px; cursor: pointer; font-weight: 500; transition: all .15s; background: #fff; }
.seg input:checked + span { border-color: var(--navy); background: var(--navy); color: #fff; }
.seg input:focus-visible + span { outline: 3px solid var(--gold-300); }
.form-sec { font-size: 17px; font-weight: 700; color: var(--navy); display: flex; align-items: center; gap: 10px; margin: 8px 0 0; padding-bottom: 10px; border-bottom: 1px solid var(--line-2); }
.form-sec i { color: var(--gold); }
.photo-pick { display: flex; align-items: center; gap: 18px; }
.photo-pick .avatar { cursor: pointer; }
.alert { padding: 12px 16px; border-radius: var(--r-sm); margin-bottom: 16px; font-size: 15.5px; }
.alert-err { background: var(--bad-bg); color: var(--bad); }
.alert-info { background: var(--navy-100); color: var(--navy); }
.alert-warn { background: var(--warn-bg); color: var(--warn); }

/* auth pages */
.auth { min-height: calc(100vh - 72px); display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: linear-gradient(160deg, var(--navy), var(--navy-900)); color: #fff; padding: 64px; display: flex; flex-direction: column; justify-content: center; position: relative; overflow: hidden; }
.auth-side::after { content: ""; position: absolute; right: -120px; bottom: -120px; width: 380px; height: 380px; border-radius: 50%; background: radial-gradient(circle, rgba(189,140,55,.35), transparent 70%); }
.auth-side img { width: 280px; margin-bottom: 30px; }
.auth-side h2 { color: #fff; font-family: var(--font-display); font-size: 32px; }
.auth-side p { color: rgba(255,255,255,.8); font-size: 18px; max-width: 460px; }
.auth-main { display: flex; align-items: center; justify-content: center; padding: 48px 20px; }
.auth-box { width: 100%; max-width: 420px; }
.auth-box h1 { font-size: 30px; margin-bottom: 6px; }
.auth-box > p { color: var(--muted); margin-bottom: 28px; }
.auth-box .field { margin-bottom: 16px; }
.auth-alt { text-align: center; margin-top: 22px; color: var(--muted); }
.pw-wrap { position: relative; }
.pw-wrap button { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); background: none; border: 0; color: var(--muted); font-size: 18px; cursor: pointer; padding: 6px; }
.otp-input { letter-spacing: .5em; text-align: center; font-size: 26px !important; font-weight: 700 !important; }

/* register page */
.page-hero { background: linear-gradient(160deg, var(--navy), var(--navy-900)); color: #fff; padding: 48px 0 88px; position: relative; overflow: hidden; }
.page-hero::before { content: ""; position: absolute; inset: 0; opacity: .06; background-image: repeating-linear-gradient(115deg, #fff 0 1px, transparent 1px 28px); }
.page-hero .wrap { position: relative; }
.page-hero h1 { color: #fff; font-family: var(--font-display); font-size: clamp(28px, 4vw, 40px); margin: 6px 0 6px; }
.page-hero p { color: rgba(255,255,255,.8); margin: 0; font-size: 18px; }
.crumb { font-size: 14px; color: var(--gold-300); }
.crumb a { color: var(--gold-300); }
.page-body { margin-top: -56px; position: relative; padding-bottom: 80px; }
.reg-layout { display: grid; grid-template-columns: 1fr 320px; gap: 24px; align-items: start; }
.side-note { position: sticky; top: 96px; display: grid; gap: 16px; }
.side-note .card { padding: 22px; }
.side-note h4 { font-size: 17px; display: flex; gap: 8px; align-items: center; }
.side-note h4 i { color: var(--gold); }
.side-note ol { padding-left: 20px; margin: 0; color: var(--ink-2); font-size: 15.5px; }
.side-note li { margin-bottom: 6px; }

/* avatars */
.avatar { border-radius: 50%; object-fit: cover; background: var(--navy-100); flex-shrink: 0; }
.avatar-ph { display: inline-grid; place-items: center; background: linear-gradient(135deg, var(--navy-700), var(--navy)); color: var(--gold-300); font-weight: 700; }
.avatar-xs { width: 32px; height: 32px; font-size: 13px; }
.avatar-sm { width: 44px; height: 44px; font-size: 16px; }
.avatar-md { width: 76px; height: 76px; font-size: 26px; }
.avatar-lg { width: 120px; height: 120px; font-size: 40px; }

/* badges */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.badge-ok { background: var(--ok-bg); color: var(--ok); }
.badge-warn { background: var(--warn-bg); color: var(--warn); }
.badge-bad { background: var(--bad-bg); color: var(--bad); }
.badge-muted { background: #EEF1F5; color: var(--muted); }
.badge-navy { background: var(--navy-100); color: var(--navy); }
.badge-gold { background: var(--gold-100); color: var(--gold-600); }

/* ---------- portal ---------- */
.portal-head { background: linear-gradient(160deg, var(--navy), var(--navy-900)); color: #fff; padding: 32px 0 0; }
.portal-id { display: flex; align-items: center; gap: 20px; padding-bottom: 24px; }
.portal-id .avatar { border: 3px solid var(--gold); }
.portal-id h1 { color: #fff; font-size: 26px; margin: 0; }
.portal-id p { margin: 2px 0 0; color: rgba(255,255,255,.75); font-size: 15.5px; }
.portal-id .badge { margin-left: 6px; }
.tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.tabs a { padding: 12px 18px; color: rgba(255,255,255,.75); font-weight: 500; border-radius: 10px 10px 0 0; white-space: nowrap; }
.tabs a:hover { color: #fff; }
.tabs a.on { background: var(--paper); color: var(--navy); font-weight: 600; }
.portal-body { padding: 28px 0 80px; }
.pgrid { display: grid; grid-template-columns: 2fr 1fr; gap: 24px; align-items: start; }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 20px; display: flex; gap: 14px; align-items: center; }
.tile i { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-size: 20px; background: var(--gold-100); color: var(--gold-600); }
.tile:nth-child(2) i { background: var(--navy-100); color: var(--navy); }
.tile strong { display: block; font-size: 24px; color: var(--navy); line-height: 1.1; }
.tile span { font-size: 14px; color: var(--muted); }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 24px; overflow: hidden; }
.panel-h { display: flex; justify-content: space-between; align-items: center; padding: 16px 22px; border-bottom: 1px solid var(--line-2); }
.panel-h h3 { margin: 0; font-size: 18px; display: flex; align-items: center; gap: 8px; }
.panel-h h3 i { color: var(--gold); }
.panel-b { padding: 20px 22px; }
.row-item { display: flex; gap: 14px; align-items: center; padding: 14px 22px; border-bottom: 1px solid var(--line-2); color: inherit; }
.row-item:last-child { border-bottom: 0; }
a.row-item:hover { background: var(--paper); color: inherit; }
.row-item .grow { flex: 1; min-width: 0; }
.row-item strong { display: block; color: var(--navy); }
.row-item small { color: var(--muted); font-size: 14px; }
.mini-date { width: 52px; text-align: center; flex-shrink: 0; border-radius: 10px; background: var(--gold-100); padding: 6px 0; }
.mini-date strong { font-size: 20px; line-height: 1; color: var(--gold-600) !important; }
.mini-date span { font-size: 12px; color: var(--gold-600); }
.empty { text-align: center; color: var(--muted); padding: 36px 20px; }
.empty i { font-size: 38px; color: var(--gold-300); display: block; margin-bottom: 8px; }
.profile-card { text-align: center; padding: 28px 22px; }
.profile-card .avatar { margin: 0 auto 14px; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; text-align: left; font-size: 15.5px; margin-top: 18px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; color: var(--ink); font-weight: 500; word-break: break-word; }
.idcard { background: linear-gradient(135deg, var(--navy), var(--navy-900)); color: #fff; border-radius: var(--r); padding: 22px; position: relative; overflow: hidden; }
.idcard::after { content: ""; position: absolute; right: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%; border: 26px solid rgba(189,140,55,.18); }
.idcard img.em { width: 70px; position: absolute; right: 18px; bottom: 18px; opacity: .9; }
.idcard small { color: var(--gold-300); font-weight: 600; letter-spacing: .04em; }
.idcard strong { display: block; font-size: 22px; margin: 4px 0; }

/* directory */
.filters { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr auto; gap: 12px; margin-bottom: 20px; }
.dir-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.pager { display: flex; gap: 6px; justify-content: center; margin-top: 28px; flex-wrap: wrap; }
.pager a, .pager span { min-width: 40px; height: 40px; display: grid; place-items: center; padding: 0 10px; border-radius: 10px; border: 1px solid var(--line); background: #fff; font-weight: 600; }
.pager .on { background: var(--navy); color: #fff; border-color: var(--navy); }

/* event detail */
.ev-hero { background: linear-gradient(160deg, var(--navy), var(--navy-900)); color: #fff; position: relative; overflow: hidden; }
.ev-hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: .22; }
.ev-hero .wrap { position: relative; padding-top: 48px; padding-bottom: 96px; }
.ev-hero h1 { color: #fff; font-family: var(--font-display); font-size: clamp(28px, 4vw, 44px); margin: 8px 0 12px; }
.ev-hero .ev-meta { color: rgba(255,255,255,.85); font-size: 17px; display: flex; gap: 22px; flex-wrap: wrap; }
.ev-layout { display: grid; grid-template-columns: 1fr 380px; gap: 24px; margin-top: -60px; position: relative; align-items: start; padding-bottom: 80px; }
.prose { white-space: pre-line; font-size: 17px; color: var(--ink-2); }
.fee-box { background: var(--paper); border-radius: var(--r-sm); padding: 14px 16px; display: grid; gap: 6px; margin-bottom: 16px; }
.fee-box div { display: flex; justify-content: space-between; }
.fee-total { border-top: 1px dashed var(--line); padding-top: 8px; font-weight: 700; color: var(--navy); font-size: 18px; }

/* error */
.err-page { text-align: center; padding: 120px 20px; }
.err-page strong { display: block; font: 800 96px/1 var(--font-display); color: var(--gold); }

/* ---------- footer ---------- */
.foot { background: var(--navy-900); color: rgba(255,255,255,.75); padding: 64px 0 0; font-size: 15.5px; }
.foot-grid { display: grid; grid-template-columns: 1fr 1.6fr 1fr 1fr; gap: 40px; }
.foot-logo { width: 170px; }
.foot h4 { color: #fff; font-size: 17px; margin-bottom: 14px; }
.foot-contact { display: grid; gap: 6px; }
.foot-contact i { color: var(--gold); margin-right: 6px; }
.foot-links { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.foot a { color: rgba(255,255,255,.75); }
.foot a:hover { color: var(--gold-300); }
.foot-bottom { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid rgba(255,255,255,.1); margin-top: 48px; padding: 20px; font-size: 14px; }
.to-top { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.08); }

/* reveal on scroll */
.rv { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.rv.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .rv { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }

/* ---------- English mode ---------- */
.lang-en { --font-display: var(--font-display-en); }
.lang-en .hero h1 { letter-spacing: -.015em; line-height: 1.12; }
.lang-sw { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px !important; border: 1.5px solid var(--line); border-radius: 999px; font-weight: 600 !important; font-size: 14.5px !important; color: var(--navy) !important; background: #fff; }
.lang-sw:hover { border-color: var(--gold); color: var(--gold-600) !important; background: #fff !important; }
.lang-sw-m { display: none; margin-left: auto; }

/* ---------- big friend photo cards ---------- */
.avatar-xl { width: 96px; height: 96px; font-size: 34px; }
.stack .avatar { width: 52px; height: 52px; font-size: 17px; border-width: 3px; margin-left: -14px; }
.fgrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.fcard { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: 20px; overflow: hidden; color: inherit; transition: transform .25s, box-shadow .25s; }
a.fcard:hover, .fgrid .fcard:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); color: inherit; }
.fcard-img { position: relative; aspect-ratio: 1 / 1; display: grid; place-items: center; overflow: hidden; background:
  radial-gradient(circle at 50% 42%, rgba(189,140,55,.30), transparent 62%), linear-gradient(160deg, var(--navy-700), var(--navy-900)); }
/* round photo, ~80% of the card width (matches the requested circle) */
.fcard-circle { position: relative; width: 80%; aspect-ratio: 1; border-radius: 50%; overflow: hidden; display: grid; place-items: center;
  background: linear-gradient(150deg, #123f70, var(--navy)); box-shadow: 0 0 0 4px var(--gold), 0 0 0 10px rgba(189,140,55,.18), 0 18px 40px rgba(0,0,0,.35); transition: transform .35s ease; }
.fcard-circle img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.fcard:hover .fcard-circle { transform: scale(1.04); }
.fcard-ph b, .fcard-circle b { font: 700 clamp(40px, 4.6vw, 60px)/1 var(--font); color: var(--gold-300); letter-spacing: .02em; }
.fcard-ph { position: absolute; inset: 0; display: grid; place-items: center; background:
  radial-gradient(circle at 50% 38%, rgba(189,140,55,.28), transparent 60%), linear-gradient(160deg, var(--navy-700), var(--navy-900)); }
.fcard-ph b { position: relative; }
.fcard-tag { position: absolute; left: 50%; transform: translateX(-50%); bottom: 14px; white-space: nowrap; z-index: 1; background: rgba(255,255,255,.92); color: var(--navy); font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: 999px; }
.fcard-blood { position: absolute; right: 12px; top: 12px; z-index: 1; background: var(--bad); color: #fff; font-size: 12.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.fcard-body { padding: 14px 16px 18px; text-align: center; }
.fcard-body strong { display: block; color: var(--navy); font-size: 17px; line-height: 1.35; }
.fcard-body small { display: block; color: var(--muted); font-size: 14px; line-height: 1.4; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- photo album ---------- */
.sec-dark { background: linear-gradient(160deg, var(--navy), var(--navy-900)); color: #fff; }
.sec-dark h2 { color: #fff; }
.sec-dark .sec-head p { color: rgba(255,255,255,.75); }
.sec-dark .eyebrow { color: var(--gold-300); }
.mosaic { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 230px; gap: 14px; grid-auto-flow: dense; }
.mosaic-item { position: relative; border-radius: 18px; overflow: hidden; background: rgba(255,255,255,.06); display: block; }
.mosaic-item.big { grid-column: span 2; grid-row: span 2; }
.mosaic-item img, .gal-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; display: block; }
.mosaic-item:hover img, .gal-item:hover img { transform: scale(1.06); }
.mosaic-cap { position: absolute; inset: auto 0 0; padding: 28px 16px 12px; background: linear-gradient(to top, rgba(2,26,53,.85), transparent); color: #fff; font-size: 15px; font-weight: 500; opacity: 0; transform: translateY(8px); transition: opacity .3s, transform .3s; }
.mosaic-item:hover .mosaic-cap, .gal-item:hover .mosaic-cap, .mosaic-item.big .mosaic-cap { opacity: 1; transform: none; }
.gal { columns: 3 340px; column-gap: 16px; }
.gal-item { position: relative; display: block; margin-bottom: 16px; border-radius: 16px; overflow: hidden; break-inside: avoid; background: var(--navy-100); box-shadow: var(--shadow); }
.gal-item img { height: auto; }
.album-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.album-tabs a { padding: 8px 18px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-weight: 600; color: var(--ink-2); }
.album-tabs a.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.about-photo { display: block; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-lg); aspect-ratio: 4 / 3.2; }
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.ev-cover-big { display: block; border-radius: var(--r); overflow: hidden; margin-bottom: 20px; box-shadow: var(--shadow); max-height: 460px; }
.ev-cover-big img { width: 100%; object-fit: cover; max-height: 460px; }

/* lightbox */
.lb { position: fixed; inset: 0; z-index: 200; background: rgba(2,14,30,.94); display: none; align-items: center; justify-content: center; padding: 56px 72px; }
.lb.open { display: flex; animation: fade .2s; }
.lb img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 10px; box-shadow: 0 30px 80px rgba(0,0,0,.5); }
.lb-cap { position: absolute; left: 0; right: 0; bottom: 16px; text-align: center; color: rgba(255,255,255,.85); font-size: 16px; padding: 0 20px; }
.lb button { position: absolute; background: rgba(255,255,255,.1); border: 0; color: #fff; width: 48px; height: 48px; border-radius: 50%; font-size: 22px; cursor: pointer; display: grid; place-items: center; }
.lb button:hover { background: rgba(255,255,255,.2); }
.lb-x { top: 16px; right: 16px; }
.lb-prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 16px; top: 50%; transform: translateY(-50%); }
.lb-n { position: absolute; top: 24px; left: 24px; color: rgba(255,255,255,.6); font-size: 14px; }
@keyframes fade { from { opacity: 0; } }

/* portal photo bits */
.portal-photo { position: relative; display: block; border-radius: 50%; }
.portal-photo .avatar { border: 3px solid var(--gold); }
.portal-photo > span { position: absolute; right: 0; bottom: 2px; width: 30px; height: 30px; border-radius: 50%; background: var(--gold); color: #fff; display: grid; place-items: center; font-size: 14px; border: 2px solid var(--navy); }
.photo-nudge { display: flex; align-items: center; gap: 18px; background: #fff; border: 1.5px dashed var(--gold-300); border-radius: var(--r); padding: 16px 20px; margin-bottom: 22px; color: var(--ink-2); }
.photo-nudge:hover { border-color: var(--gold); background: var(--gold-100); color: var(--ink-2); }
.photo-nudge strong { display: block; color: var(--navy); font-size: 17px; }
.photo-nudge > span:nth-child(2) { flex: 1; font-size: 15px; }
.photo-nudge > i { font-size: 22px; color: var(--gold); }
.idcard-top { display: flex; gap: 14px; align-items: center; margin-bottom: 12px; position: relative; z-index: 1; }
.idcard-top .avatar { border: 3px solid var(--gold); }
.idcard-top strong { font-size: 19px; }
.photo-pick-lg { align-items: flex-start; gap: 24px; }
.photo-frame { position: relative; width: 200px; aspect-ratio: 4 / 5; border-radius: 20px; overflow: hidden; cursor: pointer; flex-shrink: 0; background: linear-gradient(160deg, var(--navy-700), var(--navy-900)); box-shadow: var(--shadow); }
.photo-frame img { width: 100%; height: 100%; object-fit: cover; }
.photo-frame-ph { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; color: var(--gold-300); }
.photo-frame-ph i { font-size: 42px; }
.photo-frame-btn { position: absolute; right: 10px; bottom: 10px; width: 40px; height: 40px; border-radius: 50%; background: var(--gold); color: #fff; display: grid; place-items: center; box-shadow: var(--shadow); }
.profile-wrap { display: grid; grid-template-columns: 360px 1fr; gap: 24px; align-items: start; }
.profile-big { overflow: hidden; }
.profile-photo { display: grid; place-items: center; position: relative; aspect-ratio: 1; padding: 34px; background:
  radial-gradient(circle at 50% 45%, rgba(189,140,55,.30), transparent 62%), linear-gradient(160deg, var(--navy-700), var(--navy-900)); }
.profile-photo img, .profile-photo .pcircle { width: 100%; aspect-ratio: 1; border-radius: 50%; object-fit: cover; object-position: center 20%;
  box-shadow: 0 0 0 5px var(--gold), 0 0 0 12px rgba(189,140,55,.18), 0 20px 44px rgba(0,0,0,.35); }
.profile-photo .pcircle { display: grid; place-items: center; background: linear-gradient(150deg, #123f70, var(--navy)); }
.profile-photo .pcircle b { font: 700 88px/1 var(--font); color: var(--gold-300); }
.profile-meta { padding: 20px 22px 24px; text-align: center; }
.profile-meta h2 { font-size: 23px; margin: 0; }
.going { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 16px; }
.going a { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; color: var(--ink-2); font-size: 14px; line-height: 1.3; }
.going a:hover { color: var(--navy); }
#pv.avatar-xl, .photo-pick .avatar-xl { width: 110px; height: 110px; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .features { grid-template-columns: repeat(2, 1fr); }
  .dir-grid, .mem-grid, .fgrid { grid-template-columns: repeat(3, 1fr); }
  .mosaic { grid-template-columns: repeat(3, 1fr); }
  .foot-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 960px) {
  .nav-toggle { display: block; }
  .nav-links { display: none; position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; align-items: stretch; background: var(--paper); border-bottom: 1px solid var(--line); padding: 12px 20px 20px; box-shadow: var(--shadow); }
  .nav-open .nav-links { display: flex; }
  .nav-sep { display: none; }
  .nav-links .btn { margin-top: 6px; }
  .hero-in { grid-template-columns: 1fr; padding: 48px 20px 110px; gap: 40px; }
  .hero-card { width: min(320px, 90%); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line-2); }
  .about, .contact, .reg-layout, .pgrid, .ev-layout, .profile-wrap { grid-template-columns: 1fr; }
  .profile-big { max-width: 420px; margin: 0 auto; width: 100%; }
  .lang-sw-m { display: inline-flex; }
  .nav-links .lang-sw { display: none; }
  .nav-toggle { margin-left: 8px; }
  .about { gap: 40px; }
  .about-badge { right: 12px; }
  .auth { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .side-note { position: static; }
  .filters { grid-template-columns: 1fr 1fr; }
  .filters .q { grid-column: 1 / -1; }
  .cta-band { flex-direction: column; align-items: flex-start; padding: 36px 28px; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .sec { padding: 64px 0; }
  .wrap { padding: 0 16px; }
  .brand-txt small { display: none; }
  .stat { padding: 18px 16px; gap: 12px; }
  .stat-ic { width: 42px; height: 42px; font-size: 19px; }
  .stat strong { font-size: 24px; }
  .features, .form-grid, .tiles { grid-template-columns: 1fr; }
  .ev-grid { grid-template-columns: 1fr; }
  .dir-grid, .mem-grid, .fgrid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .fcard { border-radius: 16px; }
  .fcard-body { padding: 10px 12px 14px; }
  .fcard-body strong { font-size: 15px; }
  .mosaic { grid-template-columns: 1fr 1fr; grid-auto-rows: 160px; gap: 10px; }
  .lb { padding: 56px 10px; }
  .lb-prev, .lb-next { top: auto; bottom: 14px; transform: none; }
  .photo-pick-lg { flex-direction: column; }
  .photo-frame { width: 170px; }
  .cd div { min-width: 52px; }
  .cd strong { font-size: 22px; }
  .card-pad { padding: 20px; }
  .foot-grid { grid-template-columns: 1fr; gap: 28px; }
  .portal-id { flex-direction: column; text-align: center; gap: 12px; }
}

/* public friends page */
.friends-bar { display: flex; gap: 14px; align-items: center; padding: 14px 16px; margin-bottom: 24px; flex-wrap: wrap; }
.fitem[hidden] { display: none; }
.fitem > .fcard { height: 100%; }
/* pencil-sketch portraits sit on white paper inside the gold ring */
.fcard-circle.has-img { background: #fff; }
