/*
 * MMS Member Portal — Complete Style Sheet
 * DevOpt Association | v1.0 | 2026
 * ─────────────────────────────────────────
 * No Bootstrap. No external UI framework.
 * Design System: MMS Custom UI
 * Font: IBM Plex Sans (Google CDN)
 * Icons: Material Icons (Google CDN)
 */

/* ═══════════════════════════════════════════════════════════
   1. DESIGN TOKENS
══════════════════════════════════════════════════════════ */
:root {
  /* Brand */
  --brand-dark:     #0c1e3c;
  --brand-primary:  #1a4e8a;
  --brand-accent:   #3b82f6;
  --brand-light:    #dbeafe;
  --brand-gold:     #f59e0b;
  --brand-gold-2:   #d97706;
  --brand-gold-bg:  #fef9ec;
  --brand-vip:      linear-gradient(135deg, #f59e0b 0%, #d97706 100%);

  /* Surface */
  --surface:    #f1f5f9;
  --surface-2:  #e8eef7;
  --white:      #ffffff;

  /* Text */
  --text-main:  #0f172a;
  --text-sub:   #334155;
  --text-muted: #64748b;

  /* Semantic */
  --success: #10b981; --success-bg: #d1fae5;
  --warning: #f59e0b; --warning-bg: #fef3c7;
  --danger:  #ef4444; --danger-bg:  #fee2e2;
  --info:    #06b6d4; --info-bg:    #cffafe;

  /* Layout */
  --sidebar-w: 240px;
  --topbar-h:  64px;
  --nav-h:     68px;

  /* Radius */
  --r-xs: 4px; --r-sm: 8px; --r-md: 12px; --r-lg: 16px;
  --r-xl: 21px; --r-2xl: 28px; --r-full: 9999px;

  /* Shadows */
  --shadow-sm:     0 1px 3px rgba(15,23,42,.08),0 1px 2px rgba(15,23,42,.06);
  --shadow-md:     0 4px 14px rgba(15,23,42,.10),0 2px 4px rgba(15,23,42,.06);
  --shadow-lg:     0 10px 28px rgba(15,23,42,.13),0 4px 8px rgba(15,23,42,.08);
  --shadow-xl:     0 20px 60px rgba(15,23,42,.20);
  --shadow-accent: 0 4px 14px rgba(59,130,246,.35);
  --shadow-gold:   0 4px 20px rgba(245,158,11,.4);

  /* Transition */
  --t:      all .2s cubic-bezier(.4,0,.2,1);
  --t-slow: all .35s cubic-bezier(.4,0,.2,1);

  /* Fibonacci Spacing */
  --f5:5px; --f8:8px; --f13:13px; --f21:21px;
  --f34:34px; --f55:55px; --f89:89px; --f144:144px;
}

/* ═══════════════════════════════════════════════════════════
   2. BASE RESET
══════════════════════════════════════════════════════════ */
*,*::before,*::after { box-sizing: border-box; margin: 0; padding: 0 }
html { scroll-behavior: smooth }
body {
  background: var(--surface);
  color: var(--text-main);
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { text-decoration: none; color: inherit }
img { max-width: 100%; display: block }
button { cursor: pointer; font-family: inherit }

/* ═══════════════════════════════════════════════════════════
   3. PUBLIC SITE — NAV
══════════════════════════════════════════════════════════ */
.pub-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: var(--nav-h);
  display: flex; align-items: center; padding: 0 var(--f34);
  gap: var(--f21);
  transition: var(--t-slow);
}
.pub-nav.scrolled {
  background: rgba(12,30,60,.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 24px rgba(0,0,0,.3);
}
.pub-nav-brand {
  display: flex; align-items: center; gap: var(--f13);
  font-weight: 800; font-size: 18px; color: white;
}
.pub-nav-brand .brand-icon {
  width: 38px; height: 38px; border-radius: var(--r-sm);
  background: var(--brand-accent);
  display: flex; align-items: center; justify-content: center;
}
.pub-nav-brand .brand-icon .material-icons { color: white; font-size: 22px }
.pub-nav-links {
  display: flex; align-items: center; gap: var(--f5);
  margin-left: var(--f21); list-style: none; padding: 0;
}
.pub-nav-links a {
  color: rgba(255,255,255,.75); font-size: 14px; font-weight: 500;
  padding: var(--f8) var(--f13); border-radius: var(--r-sm);
  transition: var(--t);
}
.pub-nav-links a:hover { color: white; background: rgba(255,255,255,.1) }
.pub-nav-links a.active { color: white }
.pub-nav-actions { margin-left: auto; display: flex; align-items: center; gap: var(--f13) }

/* ─── Mobile hamburger ───────────────────────────────────── */
.nav-hamburger {
  display: none; background: transparent; border: none;
  color: white; cursor: pointer; padding: var(--f5); margin-left: auto;
  align-items: center; justify-content: center;
  border-radius: var(--r-sm); transition: var(--t);
}
.nav-hamburger:hover { background: rgba(255,255,255,.12) }
.nav-hamburger .material-icons { font-size: 26px; display: block }

/* ─── Full-screen mobile slide-in menu ───────────────────── */
.nav-mobile-menu {
  position: fixed; inset: 0; background: var(--brand-dark);
  z-index: 300; display: flex; flex-direction: column;
  padding: var(--f21) var(--f21) var(--f34);
  transform: translateX(100%);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
}
.nav-mobile-menu.open { transform: translateX(0) }
.nav-mobile-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: var(--f34); padding-bottom: var(--f21);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.nav-mobile-close {
  width: 42px; height: 42px; border-radius: var(--r-sm);
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12);
  color: white; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: var(--t);
}
.nav-mobile-close:hover { background: rgba(255,255,255,.18) }
.nav-mobile-close .material-icons { font-size: 20px }
.nav-mobile-links { display: flex; flex-direction: column }
.nav-mobile-link {
  display: block; padding: var(--f21) 0;
  font-size: 18px; font-weight: 600; color: rgba(255,255,255,.8);
  border-bottom: 1px solid rgba(255,255,255,.07);
  text-decoration: none; transition: var(--t);
}
.nav-mobile-link:first-child { border-top: 1px solid rgba(255,255,255,.07) }
.nav-mobile-link:hover { color: white; padding-left: var(--f8) }
.nav-mobile-backdrop {
  position: fixed; inset: 0; z-index: 299; background: rgba(0,0,0,.5);
  opacity: 0; pointer-events: none; transition: opacity .3s;
}
.nav-mobile-backdrop.visible { opacity: 1; pointer-events: auto }

/* ═══════════════════════════════════════════════════════════
   4. PUBLIC SITE — HERO
══════════════════════════════════════════════════════════ */
.pub-hero {
  min-height: 100vh;
  background: linear-gradient(135deg, #0c1e3c 0%, #0f2d5a 50%, #1a4e8a 100%);
  display: flex; flex-direction: column; justify-content: center;
  position: relative; overflow: hidden;
}
.pub-hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 70% 50%, rgba(59,130,246,.12) 0%, transparent 60%);
}
.pub-hero-bg {
  position: absolute; inset: 0; object-fit: cover; width: 100%; height: 100%;
  opacity: .12; mix-blend-mode: luminosity;
}
.pub-hero-inner {
  position: relative; z-index: 2;
  max-width: 1200px; margin: 0 auto;
  padding: calc(var(--nav-h) + var(--f55)) var(--f34) var(--f89);
  display: grid; grid-template-columns: 1fr 420px; gap: var(--f55); align-items: center;
}
.pub-hero-tag {
  display: inline-flex; align-items: center; gap: var(--f8);
  background: rgba(59,130,246,.2); border: 1px solid rgba(59,130,246,.35);
  color: #93c5fd; font-size: 12px; font-weight: 700;
  padding: var(--f5) var(--f13); border-radius: var(--r-full);
  letter-spacing: .05em; text-transform: uppercase; margin-bottom: var(--f21);
}
.pub-hero-tag .material-icons { font-size: 14px }
.pub-hero-title {
  font-size: clamp(36px, 5vw, 58px); font-weight: 800;
  color: white; line-height: 1.1; letter-spacing: -.02em;
  margin-bottom: var(--f21);
}
.pub-hero-title span { color: var(--brand-accent) }
.pub-hero-desc {
  font-size: 16px; color: rgba(255,255,255,.7);
  line-height: 1.7; max-width: 480px; margin-bottom: var(--f34);
}
.pub-hero-actions { display: flex; align-items: center; gap: var(--f13); flex-wrap: wrap; margin-bottom: var(--f55) }
.pub-hero-stats {
  display: flex; gap: var(--f34); flex-wrap: wrap;
}
.pub-hero-stat-item { display: flex; flex-direction: column; gap: 2px }
.pub-hero-stat-val {
  font-size: 26px; font-weight: 800; color: white; line-height: 1
}
.pub-hero-stat-lbl { font-size: 12px; color: rgba(255,255,255,.5); font-weight: 500 }

/* Hero floating card */
.pub-hero-card {
  background: rgba(255,255,255,.08);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--r-xl);
  padding: var(--f21);
  box-shadow: var(--shadow-xl);
}
.hero-event-card {
  border-radius: var(--r-lg); overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,.3);
  background: var(--brand-dark);
  margin-bottom: var(--f13);
}
.hero-event-cover {
  width: 100%; height: 160px; object-fit: cover;
  display: block;
}
.hero-event-body { padding: var(--f13) var(--f13) var(--f8) }
.hero-event-badge {
  display: inline-flex; align-items: center; gap: 4px;
  background: var(--brand-accent); color: white;
  font-size: 10px; font-weight: 700; padding: 3px var(--f8);
  border-radius: var(--r-full); margin-bottom: var(--f8);
}
.hero-event-title {
  font-size: 14px; font-weight: 700; color: white;
  margin-bottom: var(--f5); line-height: 1.3
}
.hero-event-meta {
  display: flex; align-items: center; gap: var(--f13);
  font-size: 12px; color: rgba(255,255,255,.55)
}
.hero-event-meta .material-icons { font-size: 13px }
.hero-event-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding: var(--f8) var(--f13); border-top: 1px solid rgba(255,255,255,.08)
}

/* ═══════════════════════════════════════════════════════════
   5. PUBLIC SITE — SECTIONS
══════════════════════════════════════════════════════════ */
.pub-section {
  padding: var(--f89) var(--f34); max-width: 1200px; margin: 0 auto;
}
.pub-section-dark {
  background: var(--brand-dark); width: 100%; margin: 0;
}
.pub-section-dark .pub-section { padding: var(--f89) var(--f34) }
.section-eyebrow {
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .12em; color: var(--brand-accent);
  margin-bottom: var(--f8);
}
.section-title {
  font-size: clamp(26px, 3.5vw, 36px); font-weight: 800;
  color: var(--text-main); line-height: 1.2; letter-spacing: -.01em;
  margin-bottom: var(--f13);
}
.section-title.light { color: white }
.section-desc { font-size: 15px; color: var(--text-muted); max-width: 520px; line-height: 1.7 }
.section-desc.light { color: rgba(255,255,255,.6) }
.section-header { margin-bottom: var(--f55) }
.section-header-row {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-bottom: var(--f34); flex-wrap: wrap; gap: var(--f21)
}

/* ═══════════════════════════════════════════════════════════
   6. PUBLIC SITE — EVENT CARDS (Landing)
══════════════════════════════════════════════════════════ */
.pub-event-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: var(--f21);
}
.pub-event-card {
  background: var(--white); border-radius: var(--r-lg);
  overflow: hidden; box-shadow: var(--shadow-sm);
  border: 1px solid #f1f5f9; transition: var(--t);
}
.pub-event-card:hover {
  transform: translateY(-4px); box-shadow: var(--shadow-lg);
  border-color: var(--brand-light);
}
.ec-cover {
  width: 100%; height: var(--f144); object-fit: cover;
  position: relative; display: block;
}
.ec-cover-wrap { position: relative; overflow: hidden }
.ec-cover-wrap img {
  width: 100%; height: var(--f144); object-fit: cover;
  transition: transform .4s cubic-bezier(.4,0,.2,1);
}
.pub-event-card:hover .ec-cover-wrap img { transform: scale(1.04) }
.ec-type-badge {
  position: absolute; top: var(--f13); left: var(--f13);
  background: rgba(12,30,60,.8); backdrop-filter: blur(8px);
  color: white; font-size: 11px; font-weight: 700;
  padding: 4px var(--f13); border-radius: var(--r-full);
  border: 1px solid rgba(255,255,255,.15);
}
.ec-free-badge {
  position: absolute; top: var(--f13); right: var(--f13);
  background: var(--success); color: white;
  font-size: 11px; font-weight: 700; padding: 4px var(--f13);
  border-radius: var(--r-full);
}
.ec-body { padding: var(--f21) }
.ec-date {
  font-size: 12px; font-weight: 600; color: var(--brand-accent);
  display: flex; align-items: center; gap: var(--f5);
  margin-bottom: var(--f8);
}
.ec-date .material-icons { font-size: 14px }
.ec-title {
  font-size: 16px; font-weight: 700; color: var(--text-main);
  line-height: 1.3; margin-bottom: var(--f8);
  display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}
.ec-venue {
  font-size: 13px; color: var(--text-muted);
  display: flex; align-items: center; gap: var(--f5); margin-bottom: var(--f13);
}
.ec-venue .material-icons { font-size: 14px }
.ec-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: var(--f13); border-top: 1px solid var(--surface);
}
.ec-price { font-size: 16px; font-weight: 800; color: var(--text-main) }
.ec-price small { font-size: 11px; font-weight: 400; color: var(--text-muted) }
.ec-slots { font-size: 12px; color: var(--text-muted) }

/* ═══════════════════════════════════════════════════════════
   7. PUBLIC SITE — MEMBERSHIP TIERS
══════════════════════════════════════════════════════════ */
.tier-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--f21) }
.tier-card {
  border-radius: var(--r-xl); padding: var(--f34);
  border: 1px solid #e2e8f0; background: var(--white);
  transition: var(--t); position: relative; overflow: hidden;
}
.tier-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px;
}
.tier-card.community::before  { background: var(--brand-accent) }
.tier-card.professional::before{ background: var(--success) }
.tier-card.vip::before         { background: var(--brand-vip) }
.tier-card.popular {
  border-color: var(--brand-gold); box-shadow: var(--shadow-gold);
  transform: scale(1.03);
}
.tier-card:hover { transform: translateY(-4px) scale(1.01); box-shadow: var(--shadow-lg) }
.tier-card.popular:hover { transform: translateY(-4px) scale(1.04) }
.tier-popular-badge {
  display: inline-flex; align-items: center; gap: 4px;
  background: var(--brand-vip); color: white;
  font-size: 10px; font-weight: 800; padding: 4px var(--f13);
  border-radius: var(--r-full); margin-bottom: var(--f13);
  text-transform: uppercase; letter-spacing: .05em;
}
.tier-icon {
  width: 55px; height: 55px; border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: var(--f21);
}
.tier-icon.community    { background: var(--brand-light); color: var(--brand-accent) }
.tier-icon.professional { background: var(--success-bg);  color: var(--success) }
.tier-icon.vip          { background: var(--brand-gold-bg); color: var(--brand-gold) }
.tier-icon .material-icons { font-size: 28px }
.tier-name { font-size: 20px; font-weight: 800; color: var(--text-main); margin-bottom: var(--f5) }
.tier-desc { font-size: 13px; color: var(--text-muted); margin-bottom: var(--f21); line-height: 1.6 }
.tier-price {
  font-size: 34px; font-weight: 800; color: var(--text-main);
  margin-bottom: 2px; display: flex; align-items: baseline; gap: 4px;
}
.tier-price .currency { font-size: 18px; color: var(--text-muted) }
.tier-price .period { font-size: 14px; font-weight: 400; color: var(--text-muted) }
.tier-features { list-style: none; margin: var(--f21) 0; display: flex; flex-direction: column; gap: var(--f8) }
.tier-features li {
  display: flex; align-items: flex-start; gap: var(--f8);
  font-size: 13px; color: var(--text-sub);
}
.tier-features li .material-icons { font-size: 16px; color: var(--success); flex-shrink: 0; margin-top: 1px }

/* ═══════════════════════════════════════════════════════════
   8. PUBLIC FOOTER
══════════════════════════════════════════════════════════ */
.pub-footer {
  background: var(--brand-dark); color: rgba(255,255,255,.65);
  padding: var(--f55) var(--f34) var(--f34);
}
.pub-footer-inner {
  max-width: 1200px; margin: 0 auto;
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: var(--f55);
}
.pub-footer-brand { margin-bottom: var(--f21) }
.pub-footer-brand .brand-name {
  font-size: 18px; font-weight: 800; color: white; margin-bottom: var(--f8)
}
.pub-footer-brand p { font-size: 13px; line-height: 1.7 }
.pub-footer-col h4 {
  font-size: 12px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .1em; color: rgba(255,255,255,.4); margin-bottom: var(--f21)
}
.pub-footer-col a {
  display: block; font-size: 13px; margin-bottom: var(--f8);
  color: rgba(255,255,255,.65); transition: var(--t);
}
.pub-footer-col a:hover { color: white }
.pub-footer-bottom {
  max-width: 1200px; margin: var(--f34) auto 0;
  padding-top: var(--f21); border-top: 1px solid rgba(255,255,255,.08);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: var(--f13);
  font-size: 12px;
}

/* ═══════════════════════════════════════════════════════════
   9. AUTH PAGES
══════════════════════════════════════════════════════════ */
.auth-shell {
  min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr;
}
.auth-brand {
  background: linear-gradient(145deg, var(--brand-dark) 0%, #0f3464 100%);
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
  padding: var(--f55); position: relative; overflow: hidden;
}
.auth-brand::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 70%, rgba(59,130,246,.15) 0%, transparent 60%);
}
.auth-brand-inner { position: relative; z-index: 1 }
.auth-brand-logo {
  display: flex; align-items: center; gap: var(--f13); margin-bottom: var(--f55);
}
.auth-brand-logo .brand-icon {
  width: 44px; height: 44px; border-radius: var(--r-sm);
  background: var(--brand-accent); display: flex; align-items: center; justify-content: center;
}
.auth-brand-logo .brand-icon .material-icons { color: white; font-size: 24px }
.auth-brand-logo .brand-name { font-size: 20px; font-weight: 800; color: white }
.auth-brand-quote {
  font-size: clamp(22px, 3vw, 32px); font-weight: 700;
  color: white; line-height: 1.3; margin-bottom: var(--f21); letter-spacing: -.01em;
}
.auth-brand-quote span { color: var(--brand-accent) }
.auth-brand-sub { font-size: 15px; color: rgba(255,255,255,.6); margin-bottom: var(--f55); line-height: 1.6 }
.auth-brand-features { list-style: none; display: flex; flex-direction: column; gap: var(--f13) }
.auth-brand-features li {
  display: flex; align-items: center; gap: var(--f13);
  font-size: 14px; color: rgba(255,255,255,.8);
}
.auth-brand-features li .material-icons { font-size: 20px; color: var(--brand-gold) }

.auth-panel {
  background: var(--white); display: flex; align-items: center; justify-content: center;
  padding: var(--f55) var(--f55);
}
.auth-form-wrap { width: 100%; max-width: 400px }
.auth-form-title {
  font-size: 26px; font-weight: 800; color: var(--text-main);
  margin-bottom: var(--f8);
}
.auth-form-sub { font-size: 14px; color: var(--text-muted); margin-bottom: var(--f34) }
.auth-form-sub a { color: var(--brand-accent); font-weight: 600 }

/* ═══════════════════════════════════════════════════════════
   10. MEMBER PORTAL — SHELL
══════════════════════════════════════════════════════════ */
.portal-shell { display: flex; min-height: 100vh }
.portal-sidebar {
  width: var(--sidebar-w); background: var(--brand-dark);
  display: flex; flex-direction: column;
  position: fixed; top: 0; left: 0; height: 100vh;
  overflow-y: auto; overflow-x: hidden; z-index: 100;
  transition: var(--t); scrollbar-width: none;
}
.portal-sidebar::-webkit-scrollbar { display: none }
.portal-sidebar-brand {
  display: flex; align-items: center; gap: var(--f13);
  padding: 0 var(--f21); min-height: var(--topbar-h);
  border-bottom: 1px solid rgba(255,255,255,.07);
  flex-shrink: 0;
}
.portal-sidebar-brand .brand-icon {
  width: 34px; height: 34px; border-radius: var(--r-sm);
  background: var(--brand-accent);
  display: flex; align-items: center; justify-content: center;
}
.portal-sidebar-brand .brand-icon .material-icons { color: white; font-size: 20px }
.portal-sidebar-brand .brand-name { font-size: 15px; font-weight: 800; color: white }
.portal-sidebar-brand .brand-sub { font-size: 11px; color: #475569 }

.portal-member-card {
  margin: var(--f21) var(--f13); padding: var(--f13);
  background: rgba(59,130,246,.12); border: 1px solid rgba(59,130,246,.2);
  border-radius: var(--r-md);
}
.portal-member-card-inner {
  display: flex; align-items: center; gap: var(--f13);
}
.portal-member-avatar {
  width: 40px; height: 40px; border-radius: 50%; object-fit: cover;
  border: 2px solid rgba(59,130,246,.5); flex-shrink: 0;
}
.portal-member-name { font-size: 13px; font-weight: 700; color: white }
.portal-member-tier {
  font-size: 10px; font-weight: 700; padding: 2px var(--f8);
  border-radius: var(--r-full); margin-top: 3px;
  text-transform: uppercase; letter-spacing: .04em;
  display: inline-block;
}
.portal-member-tier.vip { background: var(--brand-gold); color: white }
.portal-member-tier.professional { background: var(--success); color: white }
.portal-member-tier.community { background: var(--brand-accent); color: white }

.portal-nav { flex: 1; padding: var(--f8) var(--f8); display: flex; flex-direction: column; gap: 2px }
.portal-nav-label {
  font-size: 10px; font-weight: 700; color: #334155;
  text-transform: uppercase; letter-spacing: .1em;
  padding: var(--f13) var(--f13) var(--f5); margin-top: var(--f5);
}
.portal-nav-item {
  display: flex; align-items: center; gap: var(--f13);
  padding: 10px var(--f13); border-radius: var(--r-sm);
  color: #94a3b8; font-size: 13px; font-weight: 500;
  transition: var(--t); position: relative; white-space: nowrap;
}
.portal-nav-item .material-icons { font-size: 20px; flex-shrink: 0; transition: var(--t) }
.portal-nav-item:hover { background: rgba(255,255,255,.07); color: #e2e8f0 }
.portal-nav-item:hover .material-icons { color: var(--brand-accent) }
.portal-nav-item.active { background: rgba(59,130,246,.15); color: white }
.portal-nav-item.active .material-icons { color: var(--brand-accent) }
.portal-nav-item.active::before {
  content: ''; position: absolute; left: 0; top: 6px; bottom: 6px;
  width: 3px; background: var(--brand-accent); border-radius: 0 3px 3px 0;
}
.portal-nav-badge {
  margin-left: auto; background: var(--danger); color: white;
  font-size: 10px; font-weight: 700; padding: 1px 6px;
  border-radius: 10px; min-width: 18px; text-align: center;
}

.portal-sidebar-footer {
  padding: var(--f13) var(--f8); border-top: 1px solid rgba(255,255,255,.07);
}
.portal-logout-btn {
  display: flex; align-items: center; gap: var(--f13);
  width: 100%; padding: 10px var(--f13); border-radius: var(--r-sm);
  border: none; background: transparent; color: #64748b;
  font-size: 13px; font-weight: 500; cursor: pointer; transition: var(--t);
}
.portal-logout-btn:hover { background: rgba(239,68,68,.1); color: var(--danger) }
.portal-logout-btn .material-icons { font-size: 18px }

.portal-sidebar-backdrop {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 99;
}

/* ── Portal Main ──────────────────────────────────────────── */
.portal-main {
  margin-left: var(--sidebar-w); flex: 1; min-height: 100vh;
  display: flex; flex-direction: column;
}
.portal-topbar {
  background: var(--white); height: var(--topbar-h);
  display: flex; align-items: center; padding: 0 var(--f34);
  border-bottom: 1px solid #e2e8f0;
  position: sticky; top: 0; z-index: 50;
  gap: var(--f21); box-shadow: var(--shadow-sm);
}
.portal-topbar-menu {
  width: 34px; height: 34px; border-radius: var(--r-sm); border: none;
  background: var(--surface); display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: var(--text-muted); transition: var(--t);
}
.portal-topbar-menu:hover { background: var(--surface-2); color: var(--brand-accent) }
.portal-topbar-menu .material-icons { font-size: 20px }
.portal-page-title { font-size: 16px; font-weight: 700; color: var(--text-main) }
.portal-page-sub { font-size: 12px; color: var(--text-muted) }
.portal-topbar-actions { margin-left: auto; display: flex; align-items: center; gap: var(--f13) }
.topbar-icon-btn {
  width: 34px; height: 34px; border-radius: var(--r-sm); border: none;
  background: var(--surface); display: flex; align-items: center;
  justify-content: center; cursor: pointer; transition: var(--t);
  color: var(--text-muted); position: relative;
}
.topbar-icon-btn:hover { background: var(--surface-2); color: var(--brand-accent) }
.topbar-icon-btn .material-icons { font-size: 20px }
.notif-dot {
  position: absolute; top: 6px; right: 6px;
  width: 8px; height: 8px; background: var(--danger);
  border-radius: 50%; border: 2px solid white;
}
.portal-topbar-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  object-fit: cover; cursor: pointer;
  border: 2px solid var(--surface-2); transition: var(--t);
}
.portal-topbar-avatar:hover { border-color: var(--brand-accent) }

.portal-content {
  flex: 1; padding: var(--f34);
  display: flex; flex-direction: column; gap: var(--f21);
}

/* ═══════════════════════════════════════════════════════════
   11. SHARED COMPONENTS
══════════════════════════════════════════════════════════ */

/* ── Buttons ────────────────────────────────────────────── */
.btn {
  font-family: inherit; font-size: 13px; font-weight: 600;
  border-radius: var(--r-sm); padding: var(--f8) var(--f21);
  transition: var(--t); cursor: pointer; border: none;
  display: inline-flex; align-items: center; gap: var(--f8);
  white-space: nowrap; text-decoration: none; line-height: 1;
}
.btn .material-icons { font-size: 16px }
.btn-primary {
  background: var(--brand-accent); color: white;
  box-shadow: var(--shadow-accent);
}
.btn-primary:hover {
  background: #2563eb; transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(59,130,246,.4);
}
.btn-outline {
  background: transparent; border: 1.5px solid #e2e8f0; color: var(--text-sub);
}
.btn-outline:hover {
  border-color: var(--brand-accent); color: var(--brand-accent);
  background: var(--brand-light);
}
.btn-ghost { background: var(--surface); color: var(--text-sub); border: 1px solid transparent }
.btn-ghost:hover { background: var(--surface-2); color: var(--brand-accent) }
.btn-success { background: var(--success); color: white }
.btn-success:hover { background: #059669; transform: translateY(-1px) }
.btn-danger { background: var(--danger); color: white }
.btn-danger:hover { background: #dc2626; transform: translateY(-1px) }
.btn-gold { background: var(--brand-vip); color: white; box-shadow: var(--shadow-gold) }
.btn-gold:hover { opacity: .9; transform: translateY(-1px) }
.btn-sm { font-size: 12px; padding: var(--f5) var(--f13) }
.btn-sm .material-icons { font-size: 14px }
.btn-lg { font-size: 15px; padding: var(--f13) var(--f34) }
.btn-lg .material-icons { font-size: 18px }
.btn-block { width: 100%; justify-content: center }
.btn-icon {
  padding: var(--f8); border-radius: var(--r-sm);
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer; border: none; background: transparent;
  color: var(--text-muted); transition: var(--t);
}
.btn-icon:hover { background: var(--surface); color: var(--brand-accent) }
.btn-icon .material-icons { font-size: 18px }

/* ── Badges ─────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px var(--f8); border-radius: var(--r-full);
  font-size: 11px; font-weight: 700; line-height: 1.4;
}
.badge-active    { background: var(--success-bg); color: var(--success) }
.badge-pending   { background: var(--warning-bg); color: var(--warning) }
.badge-expired   { background: #f1f5f9; color: var(--text-muted) }
.badge-cancelled { background: var(--danger-bg); color: var(--danger) }
.badge-confirmed { background: var(--success-bg); color: var(--success) }
.badge-free      { background: var(--success-bg); color: var(--success) }
.badge-paid      { background: var(--brand-light); color: var(--brand-accent) }
.badge-vip       { background: var(--brand-vip); color: white }
.badge-community { background: var(--brand-light); color: var(--brand-accent) }
.badge-professional { background: var(--success-bg); color: var(--success) }
.badge-success   { background: var(--success-bg); color: var(--success) }
.badge-warning   { background: var(--warning-bg); color: var(--warning) }
.badge-info      { background: var(--info-bg); color: var(--info) }

/* ── Cards ──────────────────────────────────────────────── */
.card {
  background: var(--white); border-radius: var(--r-md);
  border: 1px solid #f1f5f9; box-shadow: var(--shadow-sm); overflow: hidden;
}
.card-header-row {
  padding: var(--f21) var(--f21) 0;
  display: flex; align-items: center; justify-content: space-between;
}
.card-title { font-size: 15px; font-weight: 700; color: var(--text-main) }
.card-sub { font-size: 12px; color: var(--text-muted); margin-top: 2px }
.card-body { padding: var(--f21) }

/* ── Stat Cards ─────────────────────────────────────────── */
.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: var(--f21) }
.stat-card {
  background: var(--white); border-radius: var(--r-md); padding: var(--f21);
  box-shadow: var(--shadow-sm); border: 1px solid #f1f5f9;
  transition: var(--t); position: relative; overflow: hidden;
  display: flex; flex-direction: column; gap: var(--f13);
}
.stat-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  border-radius: var(--r-md) var(--r-md) 0 0;
}
.stat-card.c-accent::before  { background: var(--brand-accent) }
.stat-card.c-success::before { background: var(--success) }
.stat-card.c-warning::before { background: var(--warning) }
.stat-card.c-danger::before  { background: var(--danger) }
.stat-card.c-gold::before    { background: var(--brand-gold) }
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md) }
.stat-header { display: flex; align-items: center; justify-content: space-between }
.stat-icon {
  width: 44px; height: 44px; border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
}
.stat-icon .material-icons { font-size: 22px }
.stat-icon.c-accent  { background: var(--brand-light);    color: var(--brand-accent) }
.stat-icon.c-success { background: var(--success-bg);     color: var(--success) }
.stat-icon.c-warning { background: var(--warning-bg);     color: var(--warning) }
.stat-icon.c-danger  { background: var(--danger-bg);      color: var(--danger) }
.stat-icon.c-gold    { background: var(--brand-gold-bg);  color: var(--brand-gold) }
.stat-delta {
  font-size: 12px; font-weight: 600; padding: 2px 8px;
  border-radius: 20px; display: flex; align-items: center; gap: 3px;
}
.stat-delta.up      { background: var(--success-bg); color: var(--success) }
.stat-delta.down    { background: var(--danger-bg);  color: var(--danger) }
.stat-delta.neutral { background: var(--surface);    color: var(--text-muted) }
.stat-delta .material-icons { font-size: 13px }
.stat-value { font-size: 30px; font-weight: 800; color: var(--text-main); line-height: 1 }
.stat-label { font-size: 13px; color: var(--text-muted) }

/* ── Forms ──────────────────────────────────────────────── */
.form-group { margin-bottom: var(--f21) }
.form-label {
  display: block; font-size: 12px; font-weight: 700;
  color: var(--text-muted); text-transform: uppercase;
  letter-spacing: .05em; margin-bottom: var(--f8);
}
.form-input, .form-select {
  width: 100%; font-family: inherit; font-size: 14px;
  padding: var(--f13) var(--f13); border: 1.5px solid #e2e8f0;
  border-radius: var(--r-sm); background: var(--surface);
  color: var(--text-main); transition: var(--t); outline: none;
}
.form-input:focus, .form-select:focus {
  border-color: var(--brand-accent); background: white;
  box-shadow: 0 0 0 3px rgba(59,130,246,.1);
}
.form-input::placeholder { color: var(--text-muted) }
.form-hint { font-size: 12px; color: var(--text-muted); margin-top: var(--f5) }
.form-2col { display: grid; grid-template-columns: 1fr 1fr; gap: var(--f21) }
.form-error { border-color: var(--danger) !important }

/* ── Filter Bar ─────────────────────────────────────────── */
.filter-bar {
  background: var(--white); border-radius: var(--r-md);
  padding: var(--f21); box-shadow: var(--shadow-sm);
  border: 1px solid #f1f5f9;
  display: flex; gap: var(--f13); align-items: flex-end; flex-wrap: wrap;
}
.filter-group { display: flex; flex-direction: column; gap: var(--f5); flex: 1; min-width: 160px }
.filter-group label {
  font-size: 11px; font-weight: 700; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: .05em;
}
.filter-input, .filter-select {
  font-family: inherit; font-size: 13px; padding: var(--f8) var(--f13);
  border: 1.5px solid #e2e8f0; border-radius: var(--r-sm);
  background: var(--surface); color: var(--text-main);
  transition: var(--t); outline: none; width: 100%;
}
.filter-input:focus, .filter-select:focus {
  border-color: var(--brand-accent); background: white;
  box-shadow: 0 0 0 3px rgba(59,130,246,.1);
}

/* ── Tables ─────────────────────────────────────────────── */
.table-card { overflow: hidden }
.data-table { width: 100%; border-collapse: collapse; font-size: 13px }
.data-table thead th {
  background: var(--surface); padding: var(--f13) var(--f21);
  text-align: left; font-size: 11px; font-weight: 700;
  color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em;
  border-bottom: 1px solid var(--surface-2); white-space: nowrap;
}
.data-table tbody td {
  padding: var(--f13) var(--f21); border-bottom: 1px solid #f8fafc;
  color: var(--text-sub); vertical-align: middle;
}
.data-table tbody tr:last-child td { border-bottom: none }
.data-table tbody tr:hover td { background: #fafbfd }
.data-table tbody tr { transition: var(--t) }

/* ── Pagination ─────────────────────────────────────────── */
.pagination { display: flex; align-items: center; gap: 4px }
.page-btn {
  width: 32px; height: 32px; border: 1.5px solid #e2e8f0;
  border-radius: var(--r-sm); background: white; cursor: pointer;
  font-size: 13px; font-weight: 600; color: var(--text-muted);
  transition: var(--t); display: flex; align-items: center; justify-content: center;
  font-family: inherit;
}
.page-btn:hover { border-color: var(--brand-accent); color: var(--brand-accent) }
.page-btn.active {
  background: var(--brand-accent); border-color: var(--brand-accent);
  color: white; box-shadow: var(--shadow-accent);
}
.page-btn:disabled { opacity: .4; cursor: not-allowed }
.page-btn .material-icons { font-size: 16px }

/* ── Tabs ───────────────────────────────────────────────── */
.tab-bar {
  display: flex; gap: 2px; background: var(--surface);
  padding: var(--f5); border-radius: var(--r-md);
}
.tab-btn {
  flex: 1; padding: var(--f8) var(--f13); border-radius: var(--r-sm); border: none;
  background: transparent; color: var(--text-muted);
  font-size: 13px; font-weight: 600; cursor: pointer;
  transition: var(--t); white-space: nowrap; font-family: inherit;
}
.tab-btn.active { background: var(--white); color: var(--brand-accent); box-shadow: var(--shadow-sm) }

/* ── Timeline ───────────────────────────────────────────── */
.timeline { display: flex; flex-direction: column; gap: 0 }
.tl-item {
  display: flex; gap: var(--f13); position: relative;
  padding-bottom: var(--f21);
}
.tl-item::before {
  content: ''; position: absolute; left: 8px; top: 18px;
  bottom: 0; width: 1px; background: var(--surface-2);
}
.tl-item:last-child { padding-bottom: 0 }
.tl-item:last-child::before { display: none }
.tl-dot {
  width: 18px; height: 18px; border-radius: 50%; flex-shrink: 0;
  border: 2px solid var(--white); margin-top: 2px;
  box-shadow: 0 0 0 2px var(--surface-2);
}
.tl-body { flex: 1 }
.tl-title { font-size: 13px; font-weight: 600; color: var(--text-main); margin-bottom: 2px }
.tl-meta { font-size: 12px; color: var(--text-muted) }

/* ── Activity Feed ──────────────────────────────────────── */
.activity-list { display: flex; flex-direction: column; gap: var(--f13) }
.activity-item { display: flex; align-items: flex-start; gap: var(--f13) }
.activity-dot {
  width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; margin-top: 4px
}
.activity-dot.c-accent  { background: var(--brand-accent) }
.activity-dot.c-success { background: var(--success) }
.activity-dot.c-warning { background: var(--warning) }
.activity-dot.c-danger  { background: var(--danger) }
.activity-dot.c-gold    { background: var(--brand-gold) }
.activity-text { font-size: 13px; color: var(--text-sub); line-height: 1.4 }
.activity-time { font-size: 11px; color: var(--text-muted); margin-top: 2px }

/* ── Info Rows ──────────────────────────────────────────── */
.info-row {
  display: flex; justify-content: space-between; align-items: flex-start;
  padding: var(--f13) 0; border-bottom: 1px solid #f8fafc;
}
.info-row:last-child { border-bottom: none }
.info-lbl { font-size: 12px; color: var(--text-muted); font-weight: 600; min-width: 140px }
.info-val { font-size: 13px; color: var(--text-main); font-weight: 500; text-align: right }

/* ═══════════════════════════════════════════════════════════
   12. MEMBER-SPECIFIC COMPONENTS
══════════════════════════════════════════════════════════ */

/* ── Membership Card (credit card style) ────────────────── */
.membership-card {
  border-radius: var(--r-xl); padding: var(--f21) var(--f34);
  color: white; position: relative; overflow: hidden;
  min-height: 188px; display: flex; flex-direction: column; justify-content: space-between;
  box-shadow: var(--shadow-xl);
}
.membership-card.community {
  background: linear-gradient(135deg, #1a4e8a 0%, #3b82f6 100%);
}
.membership-card.professional {
  background: linear-gradient(135deg, #065f46 0%, #10b981 100%);
}
.membership-card.vip {
  background: linear-gradient(135deg, #78350f 0%, #f59e0b 100%);
}
.membership-card::before {
  content: ''; position: absolute; top: -40px; right: -40px;
  width: 160px; height: 160px; border-radius: 50%;
  background: rgba(255,255,255,.07);
}
.membership-card::after {
  content: ''; position: absolute; bottom: -50px; right: 40px;
  width: 200px; height: 200px; border-radius: 50%;
  background: rgba(255,255,255,.05);
}
.mc-top { display: flex; justify-content: space-between; align-items: flex-start; position: relative; z-index: 1 }
.mc-org { font-size: 12px; font-weight: 700; opacity: .7; text-transform: uppercase; letter-spacing: .1em }
.mc-tier-badge {
  font-size: 11px; font-weight: 800; padding: 4px var(--f13);
  border-radius: var(--r-full); background: rgba(255,255,255,.2);
  backdrop-filter: blur(8px); border: 1px solid rgba(255,255,255,.3);
  text-transform: uppercase; letter-spacing: .06em;
}
.mc-chip {
  width: 44px; height: 34px; background: rgba(255,255,255,.25);
  border-radius: var(--r-xs); margin: var(--f13) 0;
  position: relative; z-index: 1;
  background-image: repeating-linear-gradient(
    90deg, rgba(255,255,255,.1) 0 2px, transparent 2px 6px
  ),
  repeating-linear-gradient(
    0deg, rgba(255,255,255,.1) 0 2px, transparent 2px 6px
  );
}
.mc-bottom { position: relative; z-index: 1 }
.mc-number {
  font-size: 14px; font-weight: 700; letter-spacing: .2em;
  opacity: .85; margin-bottom: var(--f8); font-feature-settings: "tnum";
}
.mc-name { font-size: 15px; font-weight: 800; margin-bottom: 2px }
.mc-expiry { font-size: 11px; opacity: .65 }
.mc-expiry span { font-weight: 700 }
.mc-hub-icon {
  position: absolute; bottom: var(--f21); right: var(--f21);
  font-size: 40px; opacity: .15;
}

/* ── Portal Event Cards ─────────────────────────────────── */
.portal-event-card {
  background: var(--white); border-radius: var(--r-lg);
  overflow: hidden; border: 1px solid #f1f5f9;
  box-shadow: var(--shadow-sm); transition: var(--t);
}
.portal-event-card:hover {
  transform: translateY(-4px); box-shadow: var(--shadow-lg);
  border-color: var(--brand-light);
}
.pec-cover-wrap { position: relative; overflow: hidden }
.pec-cover-wrap img { width: 100%; height: 180px; object-fit: cover; display: block; transition: transform .4s }
.portal-event-card:hover .pec-cover-wrap img { transform: scale(1.05) }
.pec-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.5) 0%, transparent 60%);
}
.pec-badges {
  position: absolute; top: var(--f13); left: var(--f13); right: var(--f13);
  display: flex; justify-content: space-between; align-items: flex-start;
}
.pec-type {
  background: rgba(12,30,60,.8); backdrop-filter: blur(6px);
  color: white; font-size: 10px; font-weight: 700;
  padding: 4px var(--f8); border-radius: var(--r-full);
  border: 1px solid rgba(255,255,255,.15);
  text-transform: uppercase; letter-spacing: .05em;
}
.pec-price {
  background: var(--brand-accent); color: white;
  font-size: 11px; font-weight: 800;
  padding: 4px var(--f8); border-radius: var(--r-full);
}
.pec-body { padding: var(--f13) var(--f21) var(--f21) }
.pec-date {
  font-size: 12px; font-weight: 600; color: var(--brand-accent);
  display: flex; align-items: center; gap: 4px; margin-bottom: var(--f5);
}
.pec-date .material-icons { font-size: 13px }
.pec-title {
  font-size: 15px; font-weight: 700; color: var(--text-main);
  line-height: 1.3; margin-bottom: var(--f8);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.pec-venue {
  font-size: 12px; color: var(--text-muted);
  display: flex; align-items: center; gap: 4px; margin-bottom: var(--f13);
}
.pec-venue .material-icons { font-size: 13px }
.pec-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: var(--f13); border-top: 1px solid var(--surface);
}
.pec-slots { font-size: 12px; color: var(--text-muted) }

/* ── Ticket Cards ───────────────────────────────────────── */
.ticket-card {
  background: var(--white); border-radius: var(--r-lg);
  box-shadow: var(--shadow-md); overflow: hidden;
  display: flex; flex-direction: column;
  border: 1px solid var(--surface-2);
}
.ticket-header {
  background: linear-gradient(135deg, var(--brand-dark), var(--brand-primary));
  color: white; padding: var(--f21); position: relative; overflow: hidden;
}
.ticket-header::before {
  content: ''; position: absolute; top: -30px; right: -30px;
  width: 100px; height: 100px; border-radius: 50%;
  background: rgba(255,255,255,.05);
}
.ticket-event-name { font-size: 15px; font-weight: 800; margin-bottom: var(--f5) }
.ticket-event-date { font-size: 12px; opacity: .75; display: flex; align-items: center; gap: 4px }
.ticket-event-date .material-icons { font-size: 13px }
.ticket-divider {
  display: flex; align-items: center; position: relative;
  margin: 0 -1px;
}
.ticket-divider::before {
  content: ''; flex: 1; height: 1px;
  background: repeating-linear-gradient(90deg, var(--surface-2) 0 6px, transparent 6px 12px);
}
.ticket-circle {
  width: 20px; height: 20px; border-radius: 50%;
  background: var(--surface); border: 1px solid var(--surface-2);
  flex-shrink: 0;
}
.ticket-body { padding: var(--f21) }
.ticket-field { margin-bottom: var(--f13) }
.ticket-field-label { font-size: 10px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 2px }
.ticket-field-value { font-size: 13px; font-weight: 700; color: var(--text-main) }
.ticket-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--f13) }
.ticket-footer {
  padding: var(--f13) var(--f21); background: var(--surface);
  border-top: 1px solid var(--surface-2);
  display: flex; justify-content: space-between; align-items: center;
}
.ticket-number { font-size: 11px; color: var(--text-muted); font-family: monospace }
.ticket-qr {
  width: 55px; height: 55px; background: var(--text-main);
  border-radius: var(--r-xs); display: flex; align-items: center; justify-content: center;
}
.ticket-qr img { width: 44px; height: 44px }

/* ── Cert Cards ─────────────────────────────────────────── */
.cert-card {
  background: var(--white); border-radius: var(--r-lg);
  border: 1.5px solid var(--surface-2); box-shadow: var(--shadow-sm);
  overflow: hidden; transition: var(--t);
}
.cert-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--brand-light) }
.cert-preview {
  height: 120px; background: linear-gradient(135deg, var(--brand-dark), var(--brand-primary));
  display: flex; align-items: center; justify-content: center; position: relative;
}
.cert-preview .material-icons { font-size: 55px; color: rgba(255,255,255,.2) }
.cert-preview-text {
  position: absolute; text-align: center; color: rgba(255,255,255,.6); font-size: 12px;
}
.cert-body { padding: var(--f21) }
.cert-title { font-size: 14px; font-weight: 700; color: var(--text-main); margin-bottom: var(--f5) }
.cert-meta { font-size: 12px; color: var(--text-muted) }
.cert-actions { display: flex; gap: var(--f8); margin-top: var(--f13) }

/* ── Resource Cards ─────────────────────────────────────── */
.resource-card {
  background: var(--white); border-radius: var(--r-md);
  border: 1px solid var(--surface-2); box-shadow: var(--shadow-sm);
  padding: var(--f21); transition: var(--t);
  display: flex; align-items: flex-start; gap: var(--f21);
}
.resource-card:hover { box-shadow: var(--shadow-md); border-color: var(--brand-light) }
.resource-icon {
  width: 44px; height: 44px; border-radius: var(--r-sm); flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.resource-icon.pdf  { background: #fee2e2; color: var(--danger) }
.resource-icon.doc  { background: var(--brand-light); color: var(--brand-accent) }
.resource-icon.video{ background: var(--warning-bg); color: var(--warning) }
.resource-icon.link { background: var(--info-bg); color: var(--info) }
.resource-icon .material-icons { font-size: 22px }
.resource-info { flex: 1 }
.resource-title { font-size: 14px; font-weight: 700; color: var(--text-main); margin-bottom: var(--f5) }
.resource-desc { font-size: 12px; color: var(--text-muted); line-height: 1.5; margin-bottom: var(--f8) }
.resource-meta { display: flex; align-items: center; gap: var(--f13); font-size: 11px; color: var(--text-muted) }

/* ── Chat ───────────────────────────────────────────────── */
.chat-layout { display: grid; grid-template-columns: 300px 1fr; height: calc(100vh - var(--topbar-h) - var(--f34)*2); }
.chat-sidebar { border-right: 1px solid var(--surface-2); overflow-y: auto }
.chat-sidebar-header { padding: var(--f21); border-bottom: 1px solid var(--surface-2) }
.conv-item {
  padding: var(--f13) var(--f21); cursor: pointer; transition: var(--t);
  border-bottom: 1px solid #f8fafc;
}
.conv-item:hover { background: var(--surface) }
.conv-item.active { background: var(--brand-light) }
.conv-name { font-size: 13px; font-weight: 700; color: var(--text-main) }
.conv-preview { font-size: 12px; color: var(--text-muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis }
.chat-main { display: flex; flex-direction: column }
.chat-main-header { padding: var(--f21); border-bottom: 1px solid var(--surface-2); background: var(--white) }
.chat-messages { flex: 1; overflow-y: auto; padding: var(--f21); display: flex; flex-direction: column; gap: var(--f13) }
.msg-row { display: flex; gap: var(--f13) }
.msg-row.out { flex-direction: row-reverse }
.msg-bubble {
  max-width: 70%; padding: var(--f13) var(--f21);
  border-radius: var(--r-xl); font-size: 13px; line-height: 1.5;
}
.msg-bubble.in { background: var(--surface); color: var(--text-main); border-radius: var(--r-sm) var(--r-xl) var(--r-xl) var(--r-xl) }
.msg-bubble.out { background: var(--brand-accent); color: white; border-radius: var(--r-xl) var(--r-sm) var(--r-xl) var(--r-xl) }
.msg-time { font-size: 10px; margin-top: 4px; opacity: .6 }
.chat-input-bar { border-top: 1px solid var(--surface-2); padding: var(--f21); display: flex; gap: var(--f13); background: var(--white) }

/* ── Progress ───────────────────────────────────────────── */
.progress { height: 6px; background: var(--surface-2); border-radius: var(--r-full); overflow: hidden }
.progress-bar { height: 100%; border-radius: var(--r-full); transition: width .6s cubic-bezier(.4,0,.2,1) }
.progress-bar.accent   { background: var(--brand-accent) }
.progress-bar.success  { background: var(--success) }
.progress-bar.warning  { background: var(--warning) }
.progress-bar.danger   { background: var(--danger) }
.progress-bar.gold     { background: var(--brand-vip) }

/* ── Divider ────────────────────────────────────────────── */
.divider { height: 1px; background: var(--surface-2); margin: var(--f21) 0 }
.divider-text {
  display: flex; align-items: center; gap: var(--f13);
  font-size: 12px; color: var(--text-muted); font-weight: 600; margin: var(--f21) 0;
}
.divider-text::before, .divider-text::after {
  content: ''; flex: 1; height: 1px; background: var(--surface-2);
}

/* ── Alert / Notice ─────────────────────────────────────── */
.alert {
  padding: var(--f13) var(--f21); border-radius: var(--r-sm);
  display: flex; align-items: flex-start; gap: var(--f13); font-size: 13px;
}
.alert .material-icons { font-size: 18px; flex-shrink: 0; margin-top: 1px }
.alert-info    { background: var(--info-bg);    color: var(--info);    border-left: 3px solid var(--info) }
.alert-success { background: var(--success-bg); color: var(--success); border-left: 3px solid var(--success) }
.alert-warning { background: var(--warning-bg); color: var(--warning); border-left: 3px solid var(--warning) }
.alert-danger  { background: var(--danger-bg);  color: var(--danger);  border-left: 3px solid var(--danger) }

/* ── Stepper ────────────────────────────────────────────── */
.stepper { display: flex; align-items: center; justify-content: center; gap: 0; margin-bottom: var(--f34) }
.stepper-step { display: flex; align-items: center; gap: var(--f8) }
.stepper-step-circle {
  width: 34px; height: 34px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 800; transition: var(--t);
  border: 2px solid var(--surface-2); background: var(--white); color: var(--text-muted);
}
.stepper-step.active .stepper-step-circle {
  background: var(--brand-accent); border-color: var(--brand-accent);
  color: white; box-shadow: var(--shadow-accent);
}
.stepper-step.done .stepper-step-circle { background: var(--success); border-color: var(--success); color: white }
.stepper-step-label { font-size: 13px; font-weight: 600; color: var(--text-muted) }
.stepper-step.active .stepper-step-label { color: var(--brand-accent) }
.stepper-step.done .stepper-step-label  { color: var(--success) }
.stepper-conn { width: 55px; height: 2px; background: var(--surface-2); margin: 0 var(--f5) }
.stepper-conn.done { background: var(--success) }

/* ── Cover Hero (Event Detail) ──────────────────────────── */
.event-hero {
  position: relative; height: 360px; overflow: hidden;
  background: var(--brand-dark);
}
.event-hero img {
  width: 100%; height: 100%; object-fit: cover;
  opacity: .5;
}
.event-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(12,30,60,.95) 0%, rgba(12,30,60,.4) 60%, transparent 100%);
}
.event-hero-body {
  position: absolute; bottom: var(--f34); left: var(--f34); right: var(--f34);
  color: white;
}
.event-hero-tag {
  display: inline-flex; align-items: center; gap: 4px;
  background: var(--brand-accent); color: white;
  font-size: 11px; font-weight: 700; padding: 4px var(--f13);
  border-radius: var(--r-full); margin-bottom: var(--f13);
  text-transform: uppercase; letter-spacing: .06em;
}
.event-hero-title {
  font-size: clamp(24px, 4vw, 40px); font-weight: 800;
  line-height: 1.15; letter-spacing: -.01em; margin-bottom: var(--f13);
}
.event-hero-meta {
  display: flex; gap: var(--f21); flex-wrap: wrap; font-size: 14px; opacity: .85
}
.event-hero-meta span { display: flex; align-items: center; gap: var(--f5) }
.event-hero-meta .material-icons { font-size: 16px }

/* ── Ticket Type Cards ──────────────────────────────────── */
.ticket-type-card {
  border: 2px solid var(--surface-2); border-radius: var(--r-lg);
  padding: var(--f21); transition: var(--t); cursor: pointer;
  background: var(--white);
}
.ticket-type-card:hover { border-color: var(--brand-accent) }
.ticket-type-card.selected { border-color: var(--brand-accent); background: var(--brand-light) }
.ticket-type-card.vip { border-color: var(--brand-gold) }
.ticket-type-card.vip.selected { background: var(--brand-gold-bg) }
.ttc-top { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: var(--f13) }
.ttc-badge {
  font-size: 10px; font-weight: 800; padding: 3px var(--f8);
  border-radius: var(--r-full); text-transform: uppercase;
}
.ttc-price { font-size: 22px; font-weight: 800; color: var(--text-main) }
.ttc-price small { font-size: 12px; font-weight: 400; color: var(--text-muted) }
.ttc-name { font-size: 16px; font-weight: 800; margin-bottom: 4px }
.ttc-desc { font-size: 13px; color: var(--text-muted); line-height: 1.5; margin-bottom: var(--f13) }
.ttc-perks { display: flex; flex-direction: column; gap: var(--f5) }
.ttc-perk {
  display: flex; align-items: center; gap: var(--f8); font-size: 12px; color: var(--text-sub)
}
.ttc-perk .material-icons { font-size: 14px; color: var(--success) }

/* ── Order Summary ──────────────────────────────────────── */
.order-summary-card {
  background: var(--white); border-radius: var(--r-lg);
  border: 1px solid var(--surface-2); box-shadow: var(--shadow-sm); overflow: hidden;
}
.order-summary-header {
  background: linear-gradient(135deg, var(--brand-dark), var(--brand-primary));
  color: white; padding: var(--f21);
}
.order-summary-body { padding: var(--f21) }
.order-row { display: flex; justify-content: space-between; align-items: center; padding: var(--f8) 0 }
.order-row.total { border-top: 1.5px solid var(--surface-2); margin-top: var(--f8); padding-top: var(--f13) }
.order-row.total .order-label { font-weight: 800; font-size: 15px }
.order-row.total .order-amount { font-weight: 800; font-size: 18px; color: var(--brand-accent) }
.order-label { font-size: 13px; color: var(--text-sub) }
.order-amount { font-size: 14px; font-weight: 700 }

/* ── Payment Methods ────────────────────────────────────── */
.payment-method {
  border: 2px solid var(--surface-2); border-radius: var(--r-md);
  padding: var(--f13) var(--f21); cursor: pointer; transition: var(--t);
  display: flex; align-items: center; gap: var(--f13);
}
.payment-method:hover { border-color: var(--brand-accent) }
.payment-method.selected { border-color: var(--brand-accent); background: var(--brand-light) }
.payment-method-icon {
  width: 40px; height: 28px; border-radius: var(--r-xs);
  background: var(--surface); display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 800; color: var(--text-sub); flex-shrink: 0;
}
.payment-method-name { font-size: 13px; font-weight: 700; color: var(--text-main) }
.payment-method-sub { font-size: 11px; color: var(--text-muted) }
.payment-radio { margin-left: auto }

/* ── Profile Hero ───────────────────────────────────────── */
.profile-hero {
  height: 180px; background: linear-gradient(135deg, var(--brand-dark), #0f3464);
  position: relative; overflow: hidden;
}
.profile-hero::before {
  content: ''; position: absolute; top: -40px; right: -40px;
  width: 200px; height: 200px; border-radius: 50%; background: rgba(59,130,246,.1);
}
.profile-hero-body {
  position: absolute; bottom: -40px; left: var(--f34);
  display: flex; align-items: flex-end; gap: var(--f21);
}
.profile-avatar-wrap { position: relative }
.profile-avatar {
  width: 89px; height: 89px; border-radius: 50%; object-fit: cover;
  border: 4px solid var(--white); box-shadow: var(--shadow-md);
}
.profile-avatar-edit {
  position: absolute; bottom: 0; right: 0;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--brand-accent); border: 2px solid white;
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.profile-avatar-edit .material-icons { font-size: 14px; color: white }
.profile-hero-meta { padding-bottom: var(--f13); color: white }
.profile-hero-name { font-size: 22px; font-weight: 800 }
.profile-hero-sub { font-size: 13px; opacity: .7 }

/* ── Success / Confirmation ─────────────────────────────── */
.success-icon {
  width: 89px; height: 89px; border-radius: 50%;
  background: var(--success-bg); display: flex;
  align-items: center; justify-content: center; margin: 0 auto;
}
.success-icon .material-icons { font-size: 44px; color: var(--success) }

/* ── Expiry Countdown ───────────────────────────────────── */
.expiry-badge {
  display: flex; align-items: center; gap: var(--f8);
  padding: var(--f8) var(--f13); border-radius: var(--r-md);
  font-size: 13px; font-weight: 600;
}
.expiry-badge.danger  { background: var(--danger-bg);  color: var(--danger) }
.expiry-badge.warning { background: var(--warning-bg); color: var(--warning) }
.expiry-badge.success { background: var(--success-bg); color: var(--success) }
.expiry-badge .material-icons { font-size: 18px }

/* ═══════════════════════════════════════════════════════════
   13. TYPOGRAPHY UTILITIES
══════════════════════════════════════════════════════════ */
.text-xs    { font-size: 11px }
.text-sm    { font-size: 12px }
.text-base  { font-size: 14px }
.text-md    { font-size: 16px }
.text-lg    { font-size: 18px }
.text-xl    { font-size: 22px }
.text-muted { color: var(--text-muted) }
.text-main  { color: var(--text-main) }
.text-accent{ color: var(--brand-accent) }
.text-gold  { color: var(--brand-gold) }
.text-success{color: var(--success) }
.text-danger{ color: var(--danger) }
.fw-500  { font-weight: 500 }
.fw-600  { font-weight: 600 }
.fw-700  { font-weight: 700 }
.fw-800  { font-weight: 800 }
.truncate{ overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.amount-positive { color: var(--success); font-weight: 700 }
.amount-negative { color: var(--danger);  font-weight: 700 }
.code-tag {
  font-family: 'IBM Plex Mono', monospace; font-size: 12px;
  background: var(--surface-2); padding: 2px var(--f8);
  border-radius: var(--r-xs); color: var(--brand-primary);
}

/* ═══════════════════════════════════════════════════════════
   14. ANIMATIONS
══════════════════════════════════════════════════════════ */
@keyframes animate-in {
  from { opacity: 0; transform: translateY(16px) }
  to   { opacity: 1; transform: translateY(0) }
}
.animate-in { animation: animate-in .4s cubic-bezier(.4,0,.2,1) both }
.animate-in-delay-1 { animation-delay: .1s }
.animate-in-delay-2 { animation-delay: .2s }
.animate-in-delay-3 { animation-delay: .3s }

@keyframes fade-in { from { opacity: 0 } to { opacity: 1 } }
.fade-in { animation: fade-in .3s ease both }

@keyframes spin { to { transform: rotate(360deg) } }
.icon-spin { animation: spin 2s linear infinite !important }

@keyframes pulse { 0%,100% { opacity: 1 } 50% { opacity: .5 } }
.icon-pulse { animation: pulse 2s ease-in-out infinite }

@keyframes bounce-y { 0%,100% { transform: translateY(0) } 50% { transform: translateY(-4px) } }
.icon-bounce { animation: bounce-y 1.5s ease-in-out infinite }

@keyframes float {
  0%,100% { transform: translateY(0) }
  50% { transform: translateY(-10px) }
}
.float-anim { animation: float 4s ease-in-out infinite }

/* ═══════════════════════════════════════════════════════════
   15. LAYOUT HELPERS
══════════════════════════════════════════════════════════ */
.layout-2col    { display: grid; grid-template-columns: 1fr 1fr; gap: var(--f21) }
.layout-3col    { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--f21) }
.layout-4col    { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--f21) }
.layout-content-sidebar { display: grid; grid-template-columns: 1fr 320px; gap: var(--f21) }
.layout-content-wide    { display: grid; grid-template-columns: 1fr 360px; gap: var(--f21) }
.event-grid  { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: var(--f21) }
.cert-grid   { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: var(--f21) }
.ticket-grid-outer { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: var(--f21) }
.sticky-sidebar { position: sticky; top: calc(var(--topbar-h) + var(--f21)); align-self: start }

/* ═══════════════════════════════════════════════════════════
   16. RESPONSIVE
══════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .portal-sidebar { transform: translateX(-100%) }
  .portal-sidebar.open { transform: translateX(0) }
  .portal-sidebar-backdrop.visible { display: block }
  .portal-main { margin-left: 0 }
  .layout-content-sidebar { grid-template-columns: 1fr }
  .layout-content-wide    { grid-template-columns: 1fr }
  .layout-3col { grid-template-columns: 1fr 1fr }
  .layout-4col { grid-template-columns: 1fr 1fr }
  .tier-grid   { grid-template-columns: 1fr }
  .pub-hero-inner { grid-template-columns: 1fr }
  .pub-footer-inner { grid-template-columns: 1fr 1fr }
  .auth-shell { grid-template-columns: 1fr }
}
@media (max-width: 768px) {
  .pub-hero-inner { padding: calc(var(--nav-h) + var(--f34)) var(--f21) var(--f55) }
  .pub-section { padding: var(--f55) var(--f21) }
  .portal-content { padding: var(--f21) }
  .portal-topbar { padding: 0 var(--f21) }
  .layout-2col { grid-template-columns: 1fr }
  .layout-3col { grid-template-columns: 1fr }
  .layout-4col { grid-template-columns: 1fr 1fr }
  .form-2col { grid-template-columns: 1fr }
  .stepper { gap: var(--f5) }
  .stepper-conn { width: var(--f21) }
  .chat-layout { grid-template-columns: 1fr; }
  .auth-brand { display: none }
  .pub-footer-inner { grid-template-columns: 1fr }
  .stat-row { grid-template-columns: 1fr 1fr }
  /* Mobile nav */
  .pub-nav-links { display: none !important }
  .pub-nav-cta { display: none }
  .nav-hamburger { display: flex }
}
@media (max-width: 480px) {
  .stat-row { grid-template-columns: 1fr }
  .layout-4col { grid-template-columns: 1fr }
  .pub-nav { padding: 0 var(--f21) }
  .pub-hero-actions { flex-direction: column }
  .pub-hero-actions .btn { width: 100%; justify-content: center }
  .pub-hero-stats { flex-wrap: wrap; gap: var(--f13) }
}
@media (max-width: 360px) {
  .pub-section { padding: var(--f34) var(--f13) }
  .pub-hero-inner { padding: calc(var(--nav-h) + var(--f21)) var(--f13) var(--f34) }
  .hero-stat-num { font-size: 20px }
  .pub-hero-card-wrap { display: none }
  .pub-footer-inner { gap: var(--f21) }
}
@media (max-width: 280px) {
  .pub-nav { padding: 0 var(--f13) }
  .pub-nav-inner { gap: var(--f8) }
  .pub-nav-brand span { display: none }
  .pub-section { padding: var(--f21) var(--f8) }
  .pub-hero-headline { font-size: 26px }
  .pub-hero-actions .btn { font-size: 13px; padding: var(--f8) var(--f13) }
}
@media (max-width: 240px) {
  .pub-nav-logo { width: 30px; height: 30px }
  .pub-nav-logo .material-icons { font-size: 18px }
  .pub-hero-headline { font-size: 22px }
  .pub-hero-desc { font-size: 13px }
  .hero-stat { display: none }
}

/* ── Sidebar JS Toggle ──────────────────────────────────── */
.sidebar-open .portal-sidebar { transform: translateX(0) }
.sidebar-open .portal-sidebar-backdrop { display: block }

/* ═══════════════════════════════════════════════════════════
   13. CSS PATCHES — ALIASES & MISSING CLASSES (v1.1)
══════════════════════════════════════════════════════════ */

/* ── Public Nav Wrappers ─────────────────────────────────── */
.pub-nav-inner {
  display: flex; align-items: center; width: 100%;
  max-width: 1200px; margin: 0 auto; gap: var(--f21);
}
.pub-nav-logo {
  width: 38px; height: 38px; border-radius: var(--r-sm);
  background: var(--brand-accent);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.pub-nav-logo .material-icons { color: white; font-size: 22px }

/* ─── Tier Swiper ────────────────────────────────────────── */
.tier-swiper { overflow: hidden }
.tier-swiper .swiper-wrapper { align-items: flex-start }
.tier-swiper .swiper-slide { height: auto; box-sizing: border-box }
.tier-pagination { text-align: center }
.tier-pagination .swiper-pagination-bullet { background: rgba(255,255,255,.35); opacity: 1 }
.tier-pagination .swiper-pagination-bullet-active { background: var(--brand-gold) }
@media (min-width: 769px) { .tier-pagination { display: none } }

/* ── Hero Aliases ────────────────────────────────────────── */
.pub-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(135deg,rgba(12,30,60,.88) 0%,rgba(15,45,90,.72) 50%,rgba(26,78,138,.62) 100%);
  z-index: 1;
}
.pub-hero-copy { position: relative; z-index: 2 }
.pub-hero-headline {
  font-size: clamp(34px,5vw,56px); font-weight: 800; color: white;
  line-height: 1.1; letter-spacing: -.02em; margin-bottom: var(--f21);
}
.pub-hero-headline span { color: var(--brand-gold) }
.accent-gold { color: var(--brand-gold) }
.pub-hero-eyebrow {
  display: inline-flex; align-items: center; gap: var(--f8);
  background: rgba(245,158,11,.2); border: 1px solid rgba(245,158,11,.35);
  color: #fde68a; font-size: 12px; font-weight: 700;
  padding: var(--f5) var(--f13); border-radius: var(--r-full);
  letter-spacing: .05em; text-transform: uppercase; margin-bottom: var(--f21);
}
.pub-hero-desc { font-size: 17px; color: rgba(255,255,255,.8); line-height: 1.7; margin-bottom: var(--f34) }
.pub-hero-actions { display: flex; gap: var(--f13); flex-wrap: wrap; margin-bottom: var(--f34) }
.btn-outline-white {
  background: transparent; border: 1.5px solid rgba(255,255,255,.4); color: white;
}
.btn-outline-white:hover { background: rgba(255,255,255,.12); border-color: white }
.pub-hero-stats { display: flex; align-items: center; gap: var(--f21) }
.hero-stat { display: flex; flex-direction: column; gap: 2px }
.hero-stat-num { font-size: 26px; font-weight: 800; color: white; line-height: 1 }
.hero-stat-lbl { font-size: 12px; color: rgba(255,255,255,.55); font-weight: 500 }
.hero-stat-div { width: 1px; background: rgba(255,255,255,.18); margin: 4px 0 }
.pub-hero-card-wrap { position: relative; z-index: 2; align-self: center }

/* ── Hero Floating Card (phc-*) ─────────────────────────── */
.pub-hero-card {
  background: rgba(255,255,255,.09); backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,.14); border-radius: var(--r-xl);
  padding: var(--f21); box-shadow: var(--shadow-xl);
}
.phc-badge {
  display: inline-flex; align-items: center; gap: 4px;
  background: var(--brand-gold); color: white;
  font-size: 11px; font-weight: 700; padding: 4px var(--f13);
  border-radius: var(--r-full); margin-bottom: var(--f13);
}
.phc-img {
  width: 100%; height: 170px; object-fit: cover;
  border-radius: var(--r-md); margin-bottom: var(--f13); display: block;
}
.phc-body { padding: 0 }
.phc-tag {
  display: inline-block; font-size: 11px; font-weight: 700;
  color: var(--brand-accent); text-transform: uppercase;
  letter-spacing: .06em; margin-bottom: var(--f5);
}
.phc-title { font-size: 15px; font-weight: 800; color: white; margin-bottom: var(--f8); line-height: 1.3 }
.phc-meta {
  font-size: 12px; color: rgba(255,255,255,.6);
  display: flex; align-items: center; gap: var(--f5);
  margin-bottom: var(--f13); flex-wrap: wrap;
}
.phc-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: var(--f13); border-top: 1px solid rgba(255,255,255,.14);
}
.phc-price { font-size: 18px; font-weight: 800; color: white }
.phc-seats { font-size: 11px; color: rgba(255,255,255,.5); margin-top: 2px }

/* ── Public Eyebrow / Section Labels ───────────────────── */
.pub-eyebrow {
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .12em; color: var(--brand-accent); margin-bottom: var(--f8);
  display: inline-flex; align-items: center; gap: var(--f5);
}

/* ── Stepper (register.html) ────────────────────────────── */
.stepper {
  display: flex; align-items: flex-start; justify-content: center; gap: 0;
}
.stepper-dot {
  width: 34px; height: 34px; border-radius: 50%;
  border: 2px solid #e2e8f0; background: white;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: var(--text-muted); flex-shrink: 0;
}
.stepper-step.active .stepper-dot { background: var(--brand-accent); border-color: var(--brand-accent); color: white }
.stepper-step.done   .stepper-dot { background: var(--success); border-color: var(--success); color: white }
.stepper-label { font-size: 12px; font-weight: 600; color: var(--text-muted); margin-top: var(--f5) }
.stepper-step.active .stepper-label { color: var(--brand-accent) }
.stepper-step.done   .stepper-label { color: var(--success) }
.stepper-line {
  flex: 1; height: 2px; background: #e2e8f0; min-width: 55px;
  margin: 0 var(--f8); margin-bottom: var(--f21); align-self: flex-start; margin-top: 16px;
}

/* ── Auth Page Fixes ────────────────────────────────────── */
.auth-logo-link { display: flex; align-items: center; gap: var(--f13); margin-bottom: var(--f55) }
.auth-logo {
  width: 44px; height: 44px; border-radius: var(--r-sm); background: var(--brand-accent);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.auth-logo .material-icons { color: white; font-size: 24px }
.auth-logo-name { font-size: 20px; font-weight: 800; color: white }
.auth-brand-footer {
  margin-top: var(--f34); padding-top: var(--f21);
  border-top: 1px solid rgba(255,255,255,.1);
  font-size: 13px; color: rgba(255,255,255,.55);
}
.auth-brand-footer a { color: var(--brand-gold); font-weight: 600 }
.form-row { margin-bottom: var(--f21) }

/* ── Input with Icon ────────────────────────────────────── */
.input-icon-wrap { position: relative }
.input-icon {
  position: absolute; left: var(--f13); top: 50%; transform: translateY(-50%);
  color: var(--text-muted); font-size: 18px; pointer-events: none; line-height: 1;
}
.input-has-icon { padding-left: 44px !important }
.input-has-icon-right { padding-right: 44px !important }
.input-icon-right {
  position: absolute; right: var(--f8); top: 50%; transform: translateY(-50%);
  background: none; border: none; cursor: pointer; color: var(--text-muted);
  display: flex; align-items: center; padding: var(--f5); border-radius: var(--r-sm);
}
.input-icon-right:hover { color: var(--brand-accent); background: var(--surface) }

/* ── Checkbox Style ─────────────────────────────────────── */
.check-label {
  display: flex; align-items: center; gap: var(--f8);
  font-size: 13px; color: var(--text-sub); cursor: pointer; user-select: none;
}
.check-input { width: 16px; height: 16px; accent-color: var(--brand-accent); cursor: pointer; flex-shrink: 0 }

/* ── Auth Divider & Footer ──────────────────────────────── */
.auth-divider {
  display: flex; align-items: center; gap: var(--f13);
  margin: var(--f21) 0; color: var(--text-muted); font-size: 13px;
}
.auth-divider::before,.auth-divider::after { content:''; flex:1; height:1px; background:#e2e8f0 }
.auth-footer-note { text-align: center; font-size: 13px; color: var(--text-muted); margin-top: var(--f21) }
.auth-footer-note a { color: var(--brand-accent); font-weight: 600 }

/* ── Portal Sidebar Brand (pmc-* = portal member card) ──── */
.portal-brand-logo {
  width: 34px; height: 34px; border-radius: var(--r-sm); background: var(--brand-accent);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.portal-brand-logo .material-icons { color: white; font-size: 20px }
.portal-brand-name { font-size: 15px; font-weight: 800; color: white }
.portal-brand-sub  { font-size: 11px; color: #475569 }

.portal-member-card.vip {
  background: linear-gradient(135deg,rgba(120,53,15,.55) 0%,rgba(180,83,9,.45) 100%);
  border: 1px solid rgba(245,158,11,.3);
}
.pmc-chip {
  width: 42px; height: 30px; background: rgba(255,255,255,.18); border-radius: var(--r-xs);
  margin-bottom: var(--f8);
  background-image:
    repeating-linear-gradient(90deg,rgba(255,255,255,.12) 0 2px,transparent 2px 6px),
    repeating-linear-gradient(0deg,rgba(255,255,255,.12) 0 2px,transparent 2px 6px);
}
.pmc-tier   { font-size: 10px; font-weight: 800; color: var(--brand-gold); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 3px }
.pmc-name   { font-size: 13px; font-weight: 700; color: white; margin-bottom: 2px }
.pmc-number { font-size: 11px; color: rgba(255,255,255,.6); margin-bottom: 2px }
.pmc-expiry { font-size: 10px; color: rgba(255,255,255,.45) }

/* Portal nav section label */
.portal-nav-section {
  font-size: 10px; font-weight: 700; color: #334155;
  text-transform: uppercase; letter-spacing: .1em;
  padding: var(--f13) var(--f13) var(--f5); margin-top: var(--f5);
}

/* ── Portal Topbar Aliases ──────────────────────────────── */
.portal-topbar-title { font-size: 16px; font-weight: 700; color: var(--text-main) }
.portal-topbar-icon-btn {
  width: 34px; height: 34px; border-radius: var(--r-sm); border: none;
  background: var(--surface); display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: var(--text-muted); position: relative; transition: var(--t);
}
.portal-topbar-icon-btn:hover { background: var(--surface-2); color: var(--brand-accent) }
.portal-topbar-icon-btn .material-icons { font-size: 20px }

/* ── Quick Action Buttons (dashboard.html) ──────────────── */
.quick-action-btn {
  display: flex; flex-direction: column; align-items: center; gap: var(--f8);
  padding: var(--f21); background: var(--white); border-radius: var(--r-md);
  border: 1px solid #f1f5f9; box-shadow: var(--shadow-sm);
  color: var(--text-sub); font-size: 12px; font-weight: 600; text-decoration: none;
  transition: var(--t);
}
.quick-action-btn:hover { border-color: var(--brand-accent); color: var(--brand-accent); box-shadow: var(--shadow-md) }
.quick-action-btn .material-icons { font-size: 26px; color: var(--brand-accent) }

/* ── Resource Body ──────────────────────────────────────── */
.resource-body { flex: 1 }

/* ═══════════════════════════════════════════════════════════
   25. NAVBAR — BALANCE & ALWAYS-DARK VARIANT
   Override: center links between brand and CTA
══════════════════════════════════════════════════════════ */
.pub-nav-links {
  flex: 1 !important;
  justify-content: right !important;
  margin-left: 0 !important;
}

/* pub-nav-solid: always dark (no hero bg, see register.html) */
.pub-nav-solid {
  background: var(--brand-dark) !important;
  backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 rgba(255,255,255,.08);
}
.pub-nav-solid .pub-nav-brand span,
.pub-nav-solid .pub-nav-links a { color: rgba(255,255,255,.85) }
.pub-nav-solid .pub-nav-links a:hover { color: white }
.pub-nav-solid.scrolled {
  background: var(--brand-dark) !important;
  box-shadow: 0 2px 20px rgba(0,0,0,.4);
}

/* ═══════════════════════════════════════════════════════════
   26. FORM ENHANCEMENTS
   form-select-enhanced, form-textarea, form-label-link
══════════════════════════════════════════════════════════ */

/* Enhanced styled <select> with custom chevron arrow */
.form-select-enhanced {
  width: 100%;
  font-family: inherit;
  font-size: 14px;
  padding: var(--f13) calc(var(--f34) + 4px) var(--f13) var(--f13);
  border: 1.5px solid #e2e8f0;
  border-radius: var(--r-sm);
  background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24'%3E%3Cpath fill='%2364748b' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right var(--f8) center;
  appearance: none;
  -webkit-appearance: none;
  color: var(--text-main);
  transition: var(--t);
  outline: none;
  cursor: pointer;
}
.form-select-enhanced:focus {
  border-color: var(--brand-accent);
  background-color: white;
  box-shadow: 0 0 0 3px rgba(59,130,246,.1);
}
.form-select-enhanced:hover { border-color: #cbd5e1 }

/* Styled <textarea> */
.form-textarea {
  width: 100%;
  font-family: inherit;
  font-size: 14px;
  padding: var(--f13);
  border: 1.5px solid #e2e8f0;
  border-radius: var(--r-sm);
  background: var(--surface);
  color: var(--text-main);
  transition: var(--t);
  outline: none;
  resize: vertical;
  min-height: 96px;
  line-height: 1.6;
  display: block;
}
.form-textarea:focus {
  border-color: var(--brand-accent);
  background: white;
  box-shadow: 0 0 0 3px rgba(59,130,246,.1);
}
.form-textarea::placeholder { color: var(--text-muted) }

/* Link inside form label (e.g. "Forgot password?") */
.form-label-link {
  font-size: 12px;
  color: var(--brand-accent);
  text-decoration: none;
  font-weight: 600;
  margin-left: auto;
}
.form-label-link:hover { color: #2563eb; text-decoration: underline }

/* ═══════════════════════════════════════════════════════════
   27. AUTH PANEL CONTENT STYLES
══════════════════════════════════════════════════════════ */

.auth-brand-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.auth-brand-quote {
  font-size: 22px;
  font-weight: 800;
  color: white;
  line-height: 1.35;
  margin-bottom: var(--f34);
  opacity: .95;
}

.auth-brand-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--f13);
  flex: 1;
}
.auth-brand-features li {
  display: flex;
  align-items: center;
  gap: var(--f13);
  font-size: 14px;
  color: rgba(255,255,255,.85);
  line-height: 1.4;
}
.auth-brand-features li .material-icons {
  font-size: 20px;
  color: var(--brand-gold);
  flex-shrink: 0;
}

.auth-form-header { margin-bottom: var(--f34) }
.auth-form-title {
  font-size: 26px;
  font-weight: 800;
  color: var(--text-main);
  margin: 0 0 var(--f5);
  line-height: 1.2;
}
.auth-form-sub {
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════
   28. MEMBERSHIP TIER SELECTION CARDS (register.html Step 3)
══════════════════════════════════════════════════════════ */

.tier-select-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--f21);
  margin-bottom: var(--f13);
}

.tier-select-card {
  display: flex;
  flex-direction: column;
  border: 2px solid #e2e8f0;
  border-radius: var(--r-lg);
  overflow: hidden;
  cursor: pointer;
  transition: var(--t);
  background: var(--white);
  position: relative;
}
.tier-select-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: #cbd5e1;
}

/* Colour accent strip at the top of each tier card */
.tier-select-card.community  { border-top: 3px solid var(--brand-accent) }
.tier-select-card.professional{ border-top: 3px solid var(--success) }
.tier-select-card.vip         { border-top: 3px solid var(--brand-gold) }

/* Hide the native radio button visually */
.tier-radio {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

/* Floating badges (Most Popular / Premium) */
.tier-popular-badge {
  position: absolute;
  top: var(--f13);
  right: var(--f13);
  background: var(--success);
  color: white;
  font-size: 10px;
  font-weight: 800;
  padding: 3px var(--f8);
  border-radius: var(--r-full);
  text-transform: uppercase;
  letter-spacing: .04em;
  z-index: 2;
}
.tier-vip-badge {
  position: absolute;
  top: var(--f13);
  right: var(--f13);
  background: var(--brand-gold);
  color: white;
  font-size: 10px;
  font-weight: 800;
  padding: 3px var(--f8);
  border-radius: var(--r-full);
  text-transform: uppercase;
  letter-spacing: .04em;
  z-index: 2;
}

/* ── Selected state (CSS :has() — all modern browsers) ── */
.tier-select-card:has(.tier-radio:checked) {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.tier-select-card.community:has(.tier-radio:checked) {
  border-color: var(--brand-accent);
  box-shadow: 0 0 0 3px rgba(59,130,246,.15), var(--shadow-md);
}
.tier-select-card.professional:has(.tier-radio:checked) {
  border-color: var(--success);
  box-shadow: 0 0 0 3px rgba(16,185,129,.15), var(--shadow-md);
}
.tier-select-card.vip:has(.tier-radio:checked) {
  border-color: var(--brand-gold);
  box-shadow: 0 0 0 3px rgba(245,158,11,.15), var(--shadow-md);
}

/* ── Tier body ── */
.tier-select-body {
  padding: var(--f21);
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0;
  transition: background var(--t);
}
.tier-select-card.community:has(.tier-radio:checked)   .tier-select-body { background: #eff6ff }
.tier-select-card.professional:has(.tier-radio:checked) .tier-select-body { background: #f0fdf4 }
.tier-select-card.vip:has(.tier-radio:checked)          .tier-select-body { background: #fffbeb }

.tier-select-badge {
  display: inline-flex;
  align-items: center;
  font-size: 10px;
  font-weight: 800;
  padding: 3px var(--f8);
  border-radius: var(--r-full);
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: var(--f8);
  align-self: flex-start;
}
.tier-select-card.community   .tier-select-badge { background: var(--brand-light);    color: var(--brand-accent) }
.tier-select-card.professional .tier-select-badge{ background: var(--success-bg);     color: var(--success) }
.tier-select-card.vip          .tier-select-badge{ background: var(--brand-gold-bg);  color: var(--brand-gold) }

.tier-select-name {
  font-size: 17px;
  font-weight: 800;
  color: var(--text-main);
  margin: 0 0 var(--f5);
  line-height: 1.2;
}

.tier-select-price {
  font-size: 30px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: var(--f5);
}
.tier-select-price span,
.tier-select-price small {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-muted);
}
.tier-select-card.community   .tier-select-price { color: var(--brand-accent) }
.tier-select-card.professional .tier-select-price{ color: var(--success) }
.tier-select-card.vip          .tier-select-price{ color: var(--brand-gold) }

.tier-select-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: var(--f13);
}

.tier-select-divider {
  height: 1px;
  background: var(--surface-2);
  margin: var(--f13) 0;
}

.tier-select-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--f8);
  flex: 1;
}
.tier-select-features li {
  display: flex;
  align-items: flex-start;
  gap: var(--f8);
  font-size: 13px;
  color: var(--text-sub);
  line-height: 1.4;
}
.tier-select-features .material-icons,
.tier-select-feature-icon {
  font-size: 16px;
  flex-shrink: 0;
  margin-top: 1px;
}
.tier-select-card.community   .tier-select-features .material-icons,
.tier-select-card.community   .tier-select-feature-icon { color: var(--brand-accent) }
.tier-select-card.professional .tier-select-features .material-icons,
.tier-select-card.professional .tier-select-feature-icon { color: var(--success) }
.tier-select-card.vip          .tier-select-features .material-icons,
.tier-select-card.vip          .tier-select-feature-icon { color: var(--brand-gold) }

/* ── Select Footer (selection indicator row) ── */
.tier-select-footer {
  padding: var(--f13) var(--f21);
  border-top: 1px solid var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--surface);
  transition: var(--t);
}
.tier-select-card.community:has(.tier-radio:checked)   .tier-select-footer {
  background: var(--brand-light); color: var(--brand-primary);
}
.tier-select-card.professional:has(.tier-radio:checked) .tier-select-footer {
  background: var(--success-bg); color: #065f46;
}
.tier-select-card.vip:has(.tier-radio:checked)          .tier-select-footer {
  background: var(--brand-gold-bg); color: #92400e;
}

.tier-select-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--t);
  background: white;
}
.tier-select-check .material-icons { font-size: 14px; color: transparent; transition: var(--t) }
.tier-select-card.community:has(.tier-radio:checked)   .tier-select-check {
  background: var(--brand-accent); border-color: var(--brand-accent);
}
.tier-select-card.professional:has(.tier-radio:checked) .tier-select-check {
  background: var(--success); border-color: var(--success);
}
.tier-select-card.vip:has(.tier-radio:checked)          .tier-select-check {
  background: var(--brand-gold); border-color: var(--brand-gold);
}
.tier-select-card:has(.tier-radio:checked) .tier-select-check .material-icons { color: white }

@media (max-width: 768px) {
  .tier-select-row { grid-template-columns: 1fr }
}
@media (max-width: 480px) {
  .tier-select-price { font-size: 24px }
}

/* ═══════════════════════════════════════════════════════════
   29. PORTAL COMPONENT ALIASES & MISSING CLASSES
══════════════════════════════════════════════════════════ */

/* Portal sidebar brand bar */
.portal-sidebar-brand {
  display: flex;
  align-items: center;
  gap: var(--f13);
  padding: var(--f21) var(--f21) var(--f13);
  border-bottom: 1px solid rgba(255,255,255,.06);
  margin-bottom: var(--f13);
}

/* Avatar with text initials (non-img usage of portal-topbar-avatar) */
.portal-topbar-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,.15);
  background: var(--brand-primary);
  color: white;
  font-size: 12px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--t);
  text-decoration: none;
  flex-shrink: 0;
  letter-spacing: .03em;
}
.portal-topbar-avatar:hover { border-color: var(--brand-accent) }

/* Section title with icon (sec-title) */
.sec-title {
  display: flex;
  align-items: center;
  gap: var(--f8);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}
.sec-title .material-icons {
  font-size: 18px;
  color: var(--brand-accent);
}

/* Quick action buttons — horizontal row layout */
.quick-action-btn {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: var(--f13) !important;
  padding: var(--f13) !important;
  border-radius: var(--r-sm) !important;
  background: var(--surface) !important;
  border: 1px solid transparent !important;
  box-shadow: none !important;
  color: var(--text-sub) !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  transition: var(--t) !important;
  margin-bottom: var(--f5) !important;
  width: 100% !important;
}
.quick-action-btn:last-child { margin-bottom: 0 !important }
.quick-action-btn:hover {
  background: var(--brand-light) !important;
  border-color: var(--brand-light) !important;
  color: var(--brand-accent) !important;
}
.quick-action-btn .material-icons {
  font-size: 18px !important;
  color: var(--brand-accent) !important;
  flex-shrink: 0 !important;
}

/* Portal event list scroll grid */
.portal-event-scroll {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--f21);
  padding: var(--f21);
}
@media (max-width: 1024px) { .portal-event-scroll { grid-template-columns: 1fr 1fr } }
@media (max-width: 640px)  { .portal-event-scroll { grid-template-columns: 1fr; padding: var(--f13) } }

/* Alias: pec-img-wrap = pec-cover-wrap */
.pec-img-wrap {
  position: relative;
  overflow: hidden;
}
.pec-img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}
.portal-event-card:hover .pec-img { transform: scale(1.05) }

/* Alias: pec-tag = pec-type (floating chip on event image) */
.pec-tag {
  position: absolute;
  top: var(--f8);
  left: var(--f8);
  background: rgba(12,30,60,.82);
  backdrop-filter: blur(6px);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 4px var(--f8);
  border-radius: var(--r-full);
  border: 1px solid rgba(255,255,255,.15);
  text-transform: uppercase;
  letter-spacing: .05em;
}

/* ── Membership card footer aliases ── */
.mc-logo {
  display: flex;
  align-items: center;
  gap: var(--f8);
  font-size: 14px;
  font-weight: 800;
  opacity: .85;
  margin-bottom: var(--f8);
  position: relative;
  z-index: 1;
}
.mc-logo .material-icons { font-size: 22px }

.mc-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  position: relative;
  z-index: 1;
  gap: var(--f13);
}
.mc-footer > div { display: flex; flex-direction: column; gap: 2px }
.mc-lbl { font-size: 9px; text-transform: uppercase; letter-spacing: .1em; opacity: .6; font-weight: 700 }
.mc-val { font-size: 13px; font-weight: 700 }
.mc-brand .material-icons { font-size: 26px; opacity: .55 }

/* mc-chip used as tier text label inside card */
.membership-card .mc-chip:not(:empty) {
  background: rgba(255,255,255,.18);
  border-radius: var(--r-sm);
  padding: var(--f5) var(--f13);
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  width: auto;
  height: auto;
  background-image: none;
  margin-bottom: var(--f8);
}

/* ── Expiry badge for renewals.html ── */
.expiry-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--f5);
  padding: var(--f5) var(--f13);
  border-radius: var(--r-md);
  font-size: 12px;
  font-weight: 700;
}
.expiry-badge.warning { background: var(--warning-bg); color: var(--warning) }
.expiry-badge.danger  { background: var(--danger-bg);  color: var(--danger) }
.expiry-badge.success { background: var(--success-bg); color: var(--success) }

/* ─────────────────────────────────────────────────────────
   Responsive fine-tuning for small screens
───────────────────────────────────────────────────────── */
@media (max-width: 360px) {
  .stepper-label { font-size: 10px }
  .stepper-conn  { min-width: var(--f21) }
  .tier-select-price { font-size: 20px }
  .tier-select-name  { font-size: 15px }
  .portal-event-scroll { grid-template-columns: 1fr; padding: var(--f8) }
}
@media (max-width: 240px) {
  .tier-select-row     { grid-template-columns: 1fr }
  .stepper-conn        { min-width: var(--f8) }
  .tier-select-price   { font-size: 18px }
}

/* ═══════════════════════════════════════════════════════════
   30. SESSION 9 ENHANCEMENTS
   ─ Desktop sidebar collapse
   ─ Navbar right-align
   ─ Responsive 3-col grid (.pub-grid-3)
   ─ Filter bar single-row fix
   ─ Event card (pecf-*) visual polish
   ─ Profile hero refinement
   ─ Certificate header class system
   ─ Tier-select alias + .selected state
══════════════════════════════════════════════════════════ */

/* ── Desktop sidebar collapse ── */
@media (min-width: 1025px) {
  .sidebar-collapsed .portal-sidebar {
    transform: translateX(-100%);
  }
  .sidebar-collapsed .portal-main {
    margin-left: 0;
    transition: var(--t-slow);
  }
  .portal-sidebar,
  .portal-main {
    transition: transform var(--t-slow), margin-left var(--t-slow);
  }
}

/* ── Public nav — right-align menu links ── */
.pub-nav-inner {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--f21);
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  padding: 0 var(--f34);
}
.pub-nav-links {
  margin-left: auto;
  flex-shrink: 0;
}

/* ── Responsive 3-col grid ── */
.pub-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--f21);
}
@media (max-width: 900px) {
  .pub-grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 540px) {
  .pub-grid-3 { grid-template-columns: 1fr; }
}

/* ── Filter bar — single-row, horizontally scrollable on mobile ── */
.filter-bar {
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: center;
  gap: var(--f8);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 2px;
}
.filter-bar::-webkit-scrollbar { display: none; }
.filter-bar .filter-search {
  flex: 1;
  min-width: 140px;
}
.filter-bar .filter-select,
.filter-bar > select { flex-shrink: 0; }
.filter-bar > .btn   { flex-shrink: 0; white-space: nowrap; }

/* ── Event card full (pecf-*) visual polish ── */
.portal-event-card-full {
  background: var(--white);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--surface-2);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--t);
}
.portal-event-card-full:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  border-color: var(--brand-light);
}
.pecf-img-wrap {
  position: relative;
  overflow: hidden;
  height: 175px;
  background: var(--surface);
}
.pecf-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .45s ease;
}
.portal-event-card-full:hover .pecf-img { transform: scale(1.05); }
.pecf-tag {
  position: absolute;
  top: var(--f8);
  left: var(--f8);
  background: rgba(12,30,60,.82);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 4px var(--f8);
  border-radius: var(--r-full);
  border: 1px solid rgba(255,255,255,.15);
  text-transform: uppercase;
  letter-spacing: .05em;
}
.pecf-date-badge {
  position: absolute;
  top: var(--f8);
  right: var(--f8);
  background: var(--brand-accent);
  color: white;
  font-size: 15px;
  font-weight: 800;
  line-height: 1;
  padding: var(--f5) var(--f8);
  border-radius: var(--r-sm);
  text-align: center;
  min-width: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}
.pecf-body {
  padding: var(--f21);
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--f5);
}
.pecf-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.pecf-meta {
  font-size: 12px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: var(--f5);
  line-height: 1.4;
}
.pecf-meta .material-icons { font-size: 14px; color: var(--brand-accent); flex-shrink: 0; }
.pecf-footer {
  margin-top: auto;
  padding-top: var(--f13);
  border-top: 1px solid var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--f8);
}
.pecf-price {
  font-size: 18px;
  font-weight: 800;
  color: var(--brand-primary);
}

/* ── Profile hero refinement ── */
.profile-hero {
  height: auto !important;
  background: var(--white) !important;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  overflow: visible !important;
  border: 1px solid var(--surface-2);
  margin-bottom: var(--f21);
}
.profile-hero::before { display: none !important; }
.profile-hero-banner {
  height: 130px;
  background: linear-gradient(135deg, var(--brand-dark) 0%, #0f3464 55%, var(--brand-accent) 100%);
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  position: relative;
  overflow: hidden;
}
.profile-hero-banner::before {
  content: '';
  position: absolute; top: -30px; right: -30px;
  width: 160px; height: 160px; border-radius: 50%;
  background: rgba(255,255,255,.07);
}
.profile-hero-banner::after {
  content: '';
  position: absolute; bottom: -20px; left: 25%;
  width: 100px; height: 100px; border-radius: 50%;
  background: rgba(59,130,246,.12);
}
.profile-hero-body {
  position: relative !important;
  bottom: auto !important;
  left: auto !important;
  display: flex;
  align-items: flex-end;
  gap: var(--f21);
  padding: 0 var(--f34) var(--f21);
  margin-top: -46px;
  flex-wrap: wrap;
  background: var(--white);
}
.profile-avatar-wrap {
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
  z-index: 1;
}
.profile-avatar {
  width: 92px !important;
  height: 92px !important;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-accent));
  color: white;
  font-size: 26px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 4px solid var(--white);
  box-shadow: var(--shadow-md);
  object-fit: unset;
}
.profile-avatar-overlay {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(0,0,0,.45);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: var(--t);
  border: 4px solid transparent;
}
.profile-avatar-wrap:hover .profile-avatar-overlay { opacity: 1; }
.profile-avatar-overlay .material-icons { color: white; font-size: 22px; }
.profile-hero-info {
  flex: 1;
  min-width: 200px;
  padding-top: var(--f55);
}
@media (max-width: 640px) {
  .profile-hero-body  { padding: 0 var(--f21) var(--f21); margin-top: -34px; }
  .profile-avatar     { width: 68px !important; height: 68px !important; font-size: 18px; }
  .profile-hero-info  { padding-top: var(--f34); }
}

/* ── Certificate header class system ── */
.cert-header {
  padding: var(--f21);
  position: relative;
  overflow: hidden;
  min-height: 158px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.cert-header::before {
  content: '';
  position: absolute; top: -24px; right: -24px;
  width: 96px; height: 96px; border-radius: 50%;
  background: rgba(255,255,255,.08);
}
.cert-header::after {
  content: '';
  position: absolute; bottom: -18px; left: 20%;
  width: 64px; height: 64px; border-radius: 50%;
  background: rgba(255,255,255,.05);
}
.cert-header-icon {
  font-size: 38px !important;
  display: block;
  margin-bottom: var(--f8);
  position: relative;
  z-index: 1;
}
.cert-header-org {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: var(--f5);
  position: relative;
  z-index: 1;
  color: rgba(255,255,255,.72);
}
.cert-header-title {
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
  position: relative;
  z-index: 1;
}
.cert-header-date {
  font-size: 12px;
  margin-top: var(--f5);
  position: relative;
  z-index: 1;
  opacity: .9;
}

/* ── Tier-select: alias + .selected state ── */
.tier-select-inner {
  padding: var(--f21) var(--f13);
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  text-align: center;
  transition: background var(--t);
}
/* Selected highlight for .selected class (JS fallback for non-:has browsers) */
.tier-select-card.selected {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.tier-select-card.community.selected {
  border-color: var(--brand-accent);
  box-shadow: 0 0 0 3px rgba(59,130,246,.15), var(--shadow-md);
}
.tier-select-card.professional.selected {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(26,78,138,.15), var(--shadow-md);
}
.tier-select-card.vip.selected {
  border-color: var(--brand-gold);
  box-shadow: 0 0 0 3px rgba(245,158,11,.18), var(--shadow-md);
}
.tier-select-card.community.selected   .tier-select-inner { background: #eff6ff; }
.tier-select-card.professional.selected .tier-select-inner { background: #eef2ff; }
.tier-select-card.vip.selected          .tier-select-inner { background: #fffbeb; }

/* ══════════════════════════════════════════════════════════════
   Section 31 — Speaker Cards · Mini Event Cards · Filter Bar v2
   ══════════════════════════════════════════════════════════════ */

/* ── Speaker cards ── */
.speaker-card {
  display: flex;
  align-items: flex-start;
  gap: var(--f13);
  padding: var(--f13);
  background: var(--surface);
  border: 1.5px solid var(--surface-2);
  border-radius: var(--r-md);
  transition: var(--t);
  position: relative;
  overflow: hidden;
}
.speaker-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--surface-2);
  transition: var(--t);
}
.speaker-card.keynote::before  { background: var(--brand-gold); }
.speaker-card.panelist::before { background: var(--brand-accent); }
.speaker-card.workshop::before { background: var(--success); }
.speaker-card.guest::before    { background: var(--warning); }
.speaker-card:hover {
  background: var(--white);
  border-color: var(--brand-light);
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
}
.speaker-card-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 3px solid var(--surface-2);
  box-shadow: var(--shadow-sm);
}
.speaker-card.keynote  .speaker-card-avatar { border-color: var(--brand-gold); }
.speaker-card.panelist .speaker-card-avatar { border-color: var(--brand-accent); }
.speaker-card.workshop .speaker-card-avatar { border-color: var(--success); }
.speaker-card.guest    .speaker-card-avatar { border-color: var(--warning); }
.speaker-card-info { flex: 1; min-width: 0; }
.speaker-card-name {
  font-weight: 700;
  font-size: 14px;
  color: var(--text-main);
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.speaker-card-title {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin: 2px 0 var(--f5);
}
.speaker-card-org {
  font-size: 12px;
  color: var(--text-sub);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: var(--f5);
}
.speaker-card-footer { display: flex; align-items: center; gap: var(--f5); flex-wrap: wrap; }

/* ── Mini event card (similar events sidebar) ── */
.mini-event-card {
  display: flex;
  gap: var(--f13);
  padding: var(--f13);
  border-radius: var(--r-md);
  border: 1.5px solid var(--surface-2);
  background: var(--white);
  transition: var(--t);
  text-decoration: none;
  color: inherit;
}
.mini-event-card + .mini-event-card { margin-top: var(--f8); }
.mini-event-card:hover {
  border-color: var(--brand-accent);
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
}
.mini-event-card-img {
  width: 72px;
  height: 72px;
  border-radius: var(--r-sm);
  object-fit: cover;
  flex-shrink: 0;
}
.mini-event-card-body { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 3px; }
.mini-event-card-tag  { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.mini-event-card-title { font-size: 13px; font-weight: 600; color: var(--text-main); line-height: 1.35; }
.mini-event-card-meta {
  font-size: 11px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 3px;
}
.mini-event-card-meta .material-icons { font-size: 11px; }
.mini-event-card-price { font-size: 13px; font-weight: 700; }

/* ── Filter bar v2 (events page) ── */
.filter-bar-v2 {
  display: flex;
  align-items: center;
  gap: var(--f13);
  flex-wrap: wrap;
}
.fb2-search {
  flex: 1;
  min-width: 200px;
  position: relative;
}
.fb2-search .material-icons {
  position: absolute;
  left: var(--f13);
  top: 50%;
  transform: translateY(-50%);
  font-size: 18px;
  color: var(--text-muted);
  pointer-events: none;
  z-index: 1;
}
.fb2-input {
  width: 100%;
  padding: var(--f13) var(--f13) var(--f13) 42px;
  border: 1.5px solid #e2e8f0;
  border-radius: var(--r-sm);
  background: var(--surface);
  font-size: 14px;
  font-family: inherit;
  color: var(--text-main);
  transition: var(--t);
  outline: none;
}
.fb2-input:focus {
  border-color: var(--brand-accent);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(59,130,246,.1);
}
.fb2-input::placeholder { color: var(--text-muted) }
.fb2-selects { display: flex; gap: var(--f8); flex-wrap: wrap; }
.fb2-select {
  padding: var(--f13) calc(var(--f34) + 4px) var(--f13) var(--f13);
  border: 1.5px solid #e2e8f0;
  border-radius: var(--r-sm);
  background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24'%3E%3Cpath fill='%2364748b' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right var(--f8) center;
  -webkit-appearance: none;
  appearance: none;
  font-size: 14px;
  font-family: inherit;
  color: var(--text-main);
  transition: var(--t);
  outline: none;
  cursor: pointer;
  white-space: nowrap;
}
.fb2-select:focus {
  border-color: var(--brand-accent);
  background-color: var(--white);
  box-shadow: 0 0 0 3px rgba(59,130,246,.1);
}
.fb2-select:hover { border-color: #cbd5e1 }
.fb2-date {
  padding: var(--f13);
  border: 1.5px solid #e2e8f0;
  border-radius: var(--r-sm);
  background: var(--surface);
  font-size: 14px;
  font-family: inherit;
  color: var(--text-main);
  transition: var(--t);
  outline: none;
  cursor: pointer;
}
.fb2-date:focus {
  border-color: var(--brand-accent);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(59,130,246,.1);
}
.fb2-date:hover { border-color: #cbd5e1 }
.fb2-actions { display: flex; gap: var(--f8); align-items: center; }
.fb2-actions .btn {
  padding-top: var(--f13);
  padding-bottom: var(--f13);
  font-size: 13px;
}
.fb2-actions .btn .material-icons { font-size: 16px; }
@media (max-width: 768px) {
  .filter-bar-v2 { gap: var(--f8); }
  .fb2-search { min-width: 100%; flex-basis: 100%; }
  .fb2-selects { flex-basis: 100%; }
  .fb2-actions { flex-basis: 100%; }
  .fb2-select, .fb2-date { flex: 1; }
}
@media (max-width: 480px) {
  .fb2-selects { flex-direction: column; }
  .fb2-select, .fb2-date { width: 100%; }
}
