/* ═══════════════════════════════════════════════════════════════════════════
   SOUTHSIDE CREDIT UNION — MASTER STYLESHEET
   Production-grade banking UI · Institutional design system
   ───────────────────────────────────────────────────────────────────────────
   Table of contents:
     1.  Design tokens
     2.  Reset & base
     3.  Typography
     4.  Utility bar
     5.  Navbar (public + auth)
     6.  Mobile drawer
     7.  Flash messages
     8.  Layout & grids
     9.  Buttons
    10.  Cards
    11.  Hero (dashboard + landing)
    12.  Forms
    13.  Tables
    14.  Badges / pills
    15.  Alerts
    16.  Account cards
    17.  Stat cards
    18.  Quick actions
    19.  Transaction list
    20.  Spending bars
    21.  Pending items
    22.  Messages
    23.  Tabs
    24.  Modal
    25.  Pagination
    26.  Empty states
    27.  Auth pages
    28.  Error pages
    29.  Landing page sections
    30.  Footer
    31.  Live chat
    32.  Utilities
    33.  Print
    34.  Mobile quick actions (drawer)
    35.  Mobile bottom tab bar + slide-up sheet
    36.  Notification bell dropdown
   ═══════════════════════════════════════════════════════════════════════════ */

/* ───────────────────────────────────────────────────────────────────────────
   1. DESIGN TOKENS
   ─────────────────────────────────────────────────────────────────────────── */
:root {
  --brand-primary:        #003366;
  --brand-primary-dark:   #002347;
  --brand-primary-light:  #0a4d8c;
  --brand-accent:         #117aca;
  --brand-accent-dark:    #005eb8;
  --brand-accent-light:   #e8f1f8;
  --brand-gold:           #c9a227;
  --brand-navy:           #0a2540;

  --success:        #067d3e;
  --success-bg:     #e6f5ec;
  --success-border: #b7e4c7;
  --warning:        #b45309;
  --warning-bg:     #fff4e0;
  --warning-border: #fce0b0;
  --danger:         #c8102e;
  --danger-bg:      #fee9ec;
  --danger-border:  #f7b7c1;
  --info:           #1f6feb;
  --info-bg:        #e7f0fd;
  --info-border:    #c2d8f7;

  --gray-25:  #fcfcfd;
  --gray-50:  #f7f9fb;
  --gray-100: #f1f4f8;
  --gray-200: #e4e7ec;
  --gray-300: #cfd4dc;
  --gray-400: #98a2b3;
  --gray-500: #667085;
  --gray-600: #475467;
  --gray-700: #344054;
  --gray-800: #1d2939;
  --gray-900: #101828;

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
                Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "SF Mono", "JetBrains Mono", Monaco, Consolas, monospace;

  --fs-xs:   0.75rem;
  --fs-sm:   0.8125rem;
  --fs-base: 0.9375rem;
  --fs-md:   1rem;
  --fs-lg:   1.125rem;
  --fs-xl:   1.25rem;
  --fs-2xl:  1.5rem;
  --fs-3xl:  1.875rem;
  --fs-4xl:  2.25rem;
  --fs-5xl:  3rem;

  --sp-1:  0.25rem;
  --sp-2:  0.5rem;
  --sp-3:  0.75rem;
  --sp-4:  1rem;
  --sp-5:  1.25rem;
  --sp-6:  1.5rem;
  --sp-8:  2rem;
  --sp-10: 2.5rem;
  --sp-12: 3rem;
  --sp-16: 4rem;

  --r-xs:   4px;
  --r-sm:   6px;
  --r-md:   8px;
  --r-lg:   12px;
  --r-xl:   16px;
  --r-2xl:  20px;
  --r-full: 9999px;

  --shadow-xs:  0 1px 2px rgba(16,24,40,0.05);
  --shadow-sm:  0 1px 3px rgba(16,24,40,0.08), 0 1px 2px rgba(16,24,40,0.04);
  --shadow-md:  0 4px 8px -2px rgba(16,24,40,0.10), 0 2px 4px -2px rgba(16,24,40,0.06);
  --shadow-lg:  0 12px 16px -4px rgba(16,24,40,0.08), 0 4px 6px -2px rgba(16,24,40,0.03);
  --shadow-xl:  0 20px 24px -4px rgba(16,24,40,0.10), 0 8px 8px -4px rgba(16,24,40,0.04);
  --shadow-focus: 0 0 0 3px rgba(17,122,202,0.18);

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --t-fast: 150ms;
  --t-base: 250ms;
  --t-slow: 350ms;

  --navbar-h: 68px;
  --container-max: 1280px;
  --container-pad: 24px;
}

@media (max-width: 900px) { :root { --container-pad: 20px; } }
@media (max-width: 640px) { :root { --navbar-h: 60px; --container-pad: 16px; } }

/* ───────────────────────────────────────────────────────────────────────────
   2. RESET & BASE
   ─────────────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--navbar-h) + 20px);
  /* Stop iOS/Android rubber-band bounce — fixed headers/tabbars otherwise
     visibly detach from content during overscroll, reading as "shaking". */
  overscroll-behavior-y: none;
  height: 100%;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: 1.55;
  color: var(--gray-800);
  background: var(--gray-50);
  min-height: 100vh;
  min-height: 100dvh; /* avoids resize jump when the mobile URL bar hides/shows */
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  overscroll-behavior-y: none;
  -webkit-tap-highlight-color: transparent;
}

a, button, [role="button"], input, select, textarea, summary {
  -webkit-tap-highlight-color: transparent;
}

a, button, [role="button"], .btn {
  touch-action: manipulation; /* removes the ~300ms tap delay / double-tap zoom */
}

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--gray-300); border-radius: var(--r-full); }
::-webkit-scrollbar-thumb:hover { background: var(--gray-400); }

.skip-link {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--brand-primary);
  color: #ffffff;
  padding: var(--sp-3) var(--sp-6);
  z-index: 9999;
  border-radius: 0 0 var(--r-md) var(--r-md);
  font-weight: 600;
  font-size: var(--fs-sm);
  transition: top var(--t-fast) var(--ease);
}
.skip-link:focus { top: 0; outline: 2px solid var(--brand-accent); }

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

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

button { cursor: pointer; border: none; background: none; padding: 0; }

a {
  color: var(--brand-accent);
  text-decoration: none;
  transition: color var(--t-fast) var(--ease);
}
a:hover { color: var(--brand-accent-dark); }
a:focus-visible {
  outline: 2px solid var(--brand-accent);
  outline-offset: 2px;
  border-radius: 2px;
}

hr {
  border: none;
  border-top: 1px solid var(--gray-200);
  margin: var(--sp-4) 0;
}

/* ───────────────────────────────────────────────────────────────────────────
   3. TYPOGRAPHY
   ─────────────────────────────────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--sp-3);
  font-weight: 700;
  line-height: 1.25;
  color: var(--gray-900);
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(1.75rem, 3vw, var(--fs-3xl)); }
h2 { font-size: clamp(1.375rem, 2.5vw, var(--fs-2xl)); }
h3 { font-size: var(--fs-xl); }
h4 { font-size: var(--fs-lg); }
h5 { font-size: var(--fs-md); }
h6 {
  font-size: var(--fs-sm);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gray-500);
}

p { margin: 0 0 var(--sp-3); }

.text-xs     { font-size: var(--fs-xs); }
.text-sm     { font-size: var(--fs-sm); }
.text-base   { font-size: var(--fs-base); }
.text-lg     { font-size: var(--fs-lg); }
.text-xl     { font-size: var(--fs-xl); }
.text-2xl    { font-size: var(--fs-2xl); }

.text-muted  { color: var(--gray-500); }
.text-subtle { color: var(--gray-400); }
.text-success{ color: var(--success); }
.text-warning{ color: var(--warning); }
.text-danger { color: var(--danger); }
.text-info   { color: var(--info); }
.text-center { text-align: center; }
.text-right  { text-align: right; }
.text-left   { text-align: left; }

.font-medium   { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold     { font-weight: 700; }

.mono { font-family: var(--font-mono); }

/* ───────────────────────────────────────────────────────────────────────────
   4. UTILITY BAR
   ─────────────────────────────────────────────────────────────────────────── */
.utility-bar {
  background: var(--brand-navy);
  color: rgba(255,255,255,0.85);
  font-size: var(--fs-xs);
  display: none;
}
@media (min-width: 768px) { .utility-bar { display: block; } }

.utility-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: var(--sp-2) var(--container-pad);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--sp-6);
}

.utility-left, .utility-right {
  display: flex;
  gap: var(--sp-5);
  align-items: center;
}

.utility-item {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  color: inherit;
  font-weight: 500;
  transition: color var(--t-fast) ease;
}
.utility-item:hover { color: #ffffff; }
.utility-item svg { width: 14px; height: 14px; flex-shrink: 0; }

.utility-right a {
  color: inherit;
  font-weight: 500;
  transition: color var(--t-fast) ease;
}
.utility-right a:hover { color: #ffffff; }

/* ───────────────────────────────────────────────────────────────────────────
   5. NAVBAR
   ─────────────────────────────────────────────────────────────────────────── */
.navbar {
  background: #ffffff;
  border-bottom: 1px solid var(--gray-200);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 2px rgba(16,24,40,0.02);
}

.navbar-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
  height: var(--navbar-h);
  display: flex;
  align-items: center;
  gap: var(--sp-6);
}

.navbar-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-3);
  flex-shrink: 0;
  text-decoration: none;
  transition: opacity var(--t-fast) ease;
}
.navbar-brand:hover { opacity: 0.85; }

.brand-logo {
  max-height: 38px;
  width: auto;
  object-fit: contain;
}
@media (max-width: 640px) { .brand-logo { max-height: 32px; } }

.navbar-nav {
  display: flex;
  align-items: center;
  gap: var(--sp-1);
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.navbar-nav::-webkit-scrollbar { display: none; }

.navbar-nav a {
  display: inline-flex;
  align-items: center;
  padding: var(--sp-2) var(--sp-3);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--gray-600);
  border-radius: var(--r-sm);
  white-space: nowrap;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.navbar-nav a:hover { background: var(--gray-100); color: var(--brand-primary); }
.navbar-nav a.active { background: var(--brand-accent-light); color: var(--brand-primary); }

.navbar-nav-public { justify-content: center; }

.navbar-right {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  flex-shrink: 0;
}
.navbar-right-public { gap: var(--sp-3); }

.nav-icon-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--r-md);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-600);
  position: relative;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.nav-icon-btn:hover { background: var(--gray-100); color: var(--brand-primary); }
.nav-icon-btn svg { width: 22px; height: 22px; }

.nav-badge {
  position: absolute;
  top: 4px; right: 4px;
  background: var(--danger);
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: var(--r-full);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #ffffff;
}

.user-menu {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-1) var(--sp-3) var(--sp-1) var(--sp-1);
  border-radius: var(--r-full);
  cursor: pointer;
  user-select: none;
  transition: background var(--t-fast) var(--ease);
}
.user-menu:hover { background: var(--gray-100); }

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: var(--r-full);
  background: var(--brand-primary);
  color: #ffffff;
  font-size: var(--fs-xs);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.user-name {
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--gray-800);
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-caret { width: 16px; height: 16px; color: var(--gray-500); }

.user-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 260px;
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xl);
  padding: var(--sp-2);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all var(--t-base) var(--ease);
  z-index: 200;
}
.user-dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-header {
  padding: var(--sp-3) var(--sp-4);
  border-bottom: 1px solid var(--gray-200);
  margin-bottom: var(--sp-2);
}
.dropdown-name  { font-weight: 700; color: var(--gray-900); font-size: var(--fs-sm); }
.dropdown-email { font-size: var(--fs-xs); color: var(--gray-500); margin-top: 2px; }

.user-dropdown a {
  display: block;
  padding: var(--sp-2) var(--sp-4);
  font-size: var(--fs-sm);
  color: var(--gray-700);
  border-radius: var(--r-sm);
  font-weight: 500;
}
.user-dropdown a:hover { background: var(--gray-100); color: var(--brand-primary); }
.user-dropdown a.text-danger { color: var(--danger); }
.user-dropdown a.text-danger:hover { background: var(--danger-bg); }

.mobile-menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  color: var(--gray-700);
  align-items: center;
  justify-content: center;
  border-radius: var(--r-md);
  transition: background var(--t-fast) ease;
}
.mobile-menu-toggle:hover { background: var(--gray-100); }
.mobile-menu-toggle svg { width: 24px; height: 24px; }

/* ───────────────────────────────────────────────────────────────────────────
   6. MOBILE DRAWER
   ─────────────────────────────────────────────────────────────────────────── */
.mobile-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(16,24,40,0.6);
  backdrop-filter: blur(3px);
  z-index: 300;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}
.mobile-drawer-backdrop.open { opacity: 1; visibility: visible; }

.mobile-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 85%;
  max-width: 340px;
  background: #ffffff;
  z-index: 301;
  transform: translateX(-100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-xl);
  overflow-y: auto;
}
.mobile-drawer.open { transform: translateX(0); }

.mobile-drawer-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--sp-4) var(--sp-5);
  border-bottom: 1px solid var(--gray-200);
  flex-shrink: 0;
}
.mobile-drawer-head .brand-logo { max-height: 28px; }

.mobile-drawer-close {
  width: 36px;
  height: 36px;
  color: var(--gray-500);
  padding: var(--sp-2);
  border-radius: var(--r-sm);
  transition: background var(--t-fast) ease, color var(--t-fast) ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.mobile-drawer-close:hover { color: var(--gray-900); background: var(--gray-100); }
.mobile-drawer-close svg { width: 20px; height: 20px; }

.mobile-drawer-nav {
  padding: var(--sp-4) var(--sp-5);
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  flex: 1;
}

.mobile-drawer-user-info {
  padding: var(--sp-3) var(--sp-4);
  background: var(--gray-50);
  border-radius: var(--r-md);
  margin-bottom: var(--sp-3);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mobile-drawer-user-info strong { color: var(--brand-navy); font-size: var(--fs-base); }
.mobile-drawer-user-info span   { color: var(--gray-500); font-size: var(--fs-sm); }

.mobile-drawer-nav > a {
  padding: var(--sp-3) var(--sp-3);
  font-size: var(--fs-md);
  font-weight: 600;
  color: var(--gray-800);
  border-radius: var(--r-md);
  transition: background var(--t-fast) ease, color var(--t-fast) ease;
}
.mobile-drawer-nav > a:hover { background: var(--gray-50); color: var(--brand-primary); }

.mobile-drawer-actions {
  margin-top: var(--sp-4);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--gray-100);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

@media (max-width: 900px) {
  .navbar-nav { display: none; }
  .mobile-menu-toggle { display: inline-flex; }
  .btn-sm-desktop { display: none; }
}

/* ───────────────────────────────────────────────────────────────────────────
   7. FLASH MESSAGES
   ─────────────────────────────────────────────────────────────────────────── */
.flash-container {
  max-width: var(--container-max);
  margin: var(--sp-4) auto 0;
  padding: 0 var(--container-pad);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  z-index: 50;
  position: relative;
}

.flash {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--r-md);
  border-left: 4px solid;
  font-size: var(--fs-sm);
  font-weight: 500;
  box-shadow: var(--shadow-sm);
  animation: flashIn var(--t-base) var(--ease);
}

@keyframes flashIn {
  from { opacity: 0; transform: translateY(-10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.flash-success { background: var(--success-bg); color: #055a2e; border-color: var(--success); }
.flash-danger  { background: var(--danger-bg);  color: #8b0b20; border-color: var(--danger); }
.flash-warning { background: var(--warning-bg); color: #92400e; border-color: var(--warning); }
.flash-info    { background: var(--info-bg);    color: #1e4fa3; border-color: var(--info); }

.flash-text { flex: 1; }

.flash-close {
  width: 28px; height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  color: inherit;
  opacity: 0.6;
  transition: opacity var(--t-fast) ease, background var(--t-fast) ease;
}
.flash-close:hover { opacity: 1; background: rgba(0,0,0,0.08); }
.flash-close svg { width: 16px; height: 16px; }

/* ───────────────────────────────────────────────────────────────────────────
   8. LAYOUT & GRIDS
   ─────────────────────────────────────────────────────────────────────────── */
.main-content {
  flex: 1;
  width: 100%;
  padding: var(--sp-8) 0 var(--sp-12);
}

.container    { max-width: var(--container-max); margin: 0 auto; padding: 0 var(--container-pad); width: 100%; }
.container-sm { max-width: 640px; margin: 0 auto; padding: 0 var(--container-pad); width: 100%; }
.container-md { max-width: 960px; margin: 0 auto; padding: 0 var(--container-pad); width: 100%; }
.container-lg { max-width: 1200px; margin: 0 auto; padding: 0 var(--container-pad); width: 100%; }
.container-full { padding: 0; max-width: 100%; }

.stack    { display: flex; flex-direction: column; gap: var(--sp-4); }
.stack-lg { display: flex; flex-direction: column; gap: var(--sp-6); }
.stack-sm { display: flex; flex-direction: column; gap: var(--sp-2); }

.row           { display: flex; align-items: center; gap: var(--sp-3); }
.row-between   { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); }
.row-end       { display: flex; align-items: center; justify-content: flex-end; gap: var(--sp-3); }
.row-wrap      { flex-wrap: wrap; }

.grid   { display: grid; gap: var(--sp-4); }
.grid-2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.grid-auto { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .main-content { padding: var(--sp-6) 0 var(--sp-8); }
}

/* ───────────────────────────────────────────────────────────────────────────
   9. BUTTONS
   ─────────────────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-5);
  border-radius: var(--r-md);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: -0.005em;
  border: 1px solid transparent;
  white-space: nowrap;
  transition: all var(--t-fast) var(--ease);
  cursor: pointer;
  text-decoration: none;
  line-height: 1.2;
  user-select: none;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn:focus-visible { outline: 2px solid var(--brand-accent); outline-offset: 2px; }
.btn:active:not(:disabled) { transform: scale(0.98); }
.btn:disabled, .btn.disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

.btn-primary {
  background: var(--brand-primary);
  color: #ffffff;
  border-color: var(--brand-primary);
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}
.btn-primary:hover {
  background: var(--brand-primary-dark);
  border-color: var(--brand-primary-dark);
  color: #ffffff;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
}

.btn-accent {
  background: var(--brand-accent);
  color: #ffffff;
  border-color: var(--brand-accent);
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}
.btn-accent:hover {
  background: var(--brand-accent-dark);
  border-color: var(--brand-accent-dark);
  color: #ffffff;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
}

.btn-success { background: var(--success); color: #ffffff; border-color: var(--success); }
.btn-success:hover { background: #056b34; border-color: #056b34; color: #ffffff; }

.btn-danger { background: var(--danger); color: #ffffff; border-color: var(--danger); }
.btn-danger:hover { background: #a50d26; border-color: #a50d26; color: #ffffff; }

.btn-warning { background: var(--warning); color: #ffffff; border-color: var(--warning); }
.btn-warning:hover { background: #933f07; color: #ffffff; }

.btn-outline {
  background: #ffffff;
  color: var(--brand-primary);
  border-color: var(--gray-300);
}
.btn-outline:hover { background: var(--gray-50); border-color: var(--brand-primary); color: var(--brand-primary); }

.btn-outline-danger {
  background: #ffffff;
  color: var(--danger);
  border-color: var(--danger-border);
}
.btn-outline-danger:hover { background: var(--danger-bg); border-color: var(--danger); color: var(--danger); }

.btn-ghost { background: transparent; color: var(--gray-700); border-color: transparent; }
.btn-ghost:hover { background: var(--gray-100); color: var(--brand-primary); }

.btn-link { background: transparent; color: var(--brand-accent); border-color: transparent; padding: var(--sp-1) var(--sp-2); }
.btn-link:hover { color: var(--brand-accent-dark); text-decoration: underline; }

.btn-sm { padding: var(--sp-2) var(--sp-3); font-size: var(--fs-xs); border-radius: var(--r-sm); }
.btn-sm svg { width: 14px; height: 14px; }
.btn-lg { padding: var(--sp-4) var(--sp-6); font-size: var(--fs-md); border-radius: var(--r-lg); }
.btn-lg svg { width: 20px; height: 20px; }
.btn-block { width: 100%; }
.btn-icon { padding: var(--sp-2); width: 36px; height: 36px; }

/* ───────────────────────────────────────────────────────────────────────────
   10. CARDS
   ─────────────────────────────────────────────────────────────────────────── */
.card {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xs);
  padding: var(--sp-6);
  transition: box-shadow var(--t-base) var(--ease), border-color var(--t-base) var(--ease);
}
.card-hover:hover { box-shadow: var(--shadow-md); border-color: var(--gray-300); }

.card-flush { padding: 0; overflow: hidden; }

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  padding-bottom: var(--sp-4);
  margin-bottom: var(--sp-4);
  border-bottom: 1px solid var(--gray-200);
}
.card-flush .card-header {
  padding: var(--sp-5) var(--sp-6);
  margin-bottom: 0;
}
.card-header:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }

.card-title {
  font-size: var(--fs-lg);
  font-weight: 700;
  color: var(--gray-900);
  margin: 0;
  letter-spacing: -0.01em;
}
.card-subtitle { font-size: var(--fs-sm); color: var(--gray-500); margin-top: 2px; }

.card-body { padding: var(--sp-5) var(--sp-6); }
.card-flush .card-body { padding: var(--sp-5) var(--sp-6); }
.card-flush > .card-body { padding-top: 0; }

.card-footer {
  padding: var(--sp-4) var(--sp-6);
  border-top: 1px solid var(--gray-200);
  background: var(--gray-25);
  border-radius: 0 0 var(--r-lg) var(--r-lg);
}

/* ───────────────────────────────────────────────────────────────────────────
   11. HERO
   ─────────────────────────────────────────────────────────────────────────── */
.hero-card {
  background: linear-gradient(135deg, var(--brand-navy) 0%, var(--brand-primary) 55%, var(--brand-primary-light) 100%);
  color: #ffffff;
  border: none;
  border-radius: var(--r-xl);
  padding: var(--sp-8);
  box-shadow: 0 12px 24px -8px rgba(10,37,64,0.35);
  position: relative;
  overflow: hidden;
}
.hero-card::after {
  content: "";
  position: absolute;
  top: -50%;
  right: -20%;
  width: 60%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero-label {
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.85;
  margin-bottom: var(--sp-2);
}
.hero-amount {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: var(--sp-3);
  font-variant-numeric: tabular-nums;
}
.hero-meta {
  font-size: var(--fs-sm);
  opacity: 0.85;
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}
.hero-actions {
  display: flex;
  gap: var(--sp-3);
  flex-wrap: wrap;
  margin-top: var(--sp-6);
  position: relative;
  z-index: 2;
}
@media (max-width: 640px) {
  .hero-card { padding: var(--sp-6); }
  .hero-actions { flex-direction: column; }
  .hero-actions .hero-btn { width: 100%; justify-content: center; }
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-5);
  border-radius: var(--r-md);
  font-size: var(--fs-sm);
  font-weight: 600;
  background: rgba(255,255,255,0.12);
  color: #ffffff;
  border: 1px solid rgba(255,255,255,0.25);
  backdrop-filter: blur(8px);
  transition: all var(--t-fast) var(--ease);
  cursor: pointer;
}
.hero-btn:hover { background: rgba(255,255,255,0.25); color: #ffffff; transform: translateY(-1px); }
.hero-btn:active { transform: translateY(0); }
.hero-btn.solid { background: #ffffff; color: var(--brand-navy); border-color: transparent; }
.hero-btn.solid:hover { background: var(--gray-100); color: var(--brand-navy); }
.hero-btn svg { width: 18px; height: 18px; }

/* ───────────────────────────────────────────────────────────────────────────
   12. FORMS
   ─────────────────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: var(--sp-4); }
.form-group:last-child { margin-bottom: 0; }

.form-label {
  display: block;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: var(--sp-2);
}
.form-label.required::after { content: " *"; color: var(--danger); }

.form-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--sp-2);
  gap: var(--sp-3);
}
.form-label-row .form-label { margin-bottom: 0; }

.form-control {
  display: block;
  width: 100%;
  padding: var(--sp-3) var(--sp-4);
  font-size: var(--fs-base);
  color: var(--gray-900);
  background: #ffffff;
  border: 1px solid var(--gray-300);
  border-radius: var(--r-md);
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
  appearance: none;
  min-height: 44px;
}
.form-control::placeholder { color: var(--gray-400); }
.form-control:hover:not(:disabled) { border-color: var(--gray-400); }
.form-control:focus {
  outline: none;
  border-color: var(--brand-accent);
  box-shadow: var(--shadow-focus);
}
.form-control:disabled { background: var(--gray-100); color: var(--gray-500); cursor: not-allowed; }
.form-control.error { border-color: var(--danger); }
.form-control.error:focus { box-shadow: 0 0 0 3px rgba(200,16,46,0.15); }

@media (max-width: 640px) {
  /* iOS Safari auto-zooms the page on focus if an input's font-size is
     under 16px, then zooms back out on blur — reads as the page "shaking"
     on every tap into a field. Force 16px on mobile only. */
  .form-control, input, select, textarea {
    font-size: 16px;
  }
}

textarea.form-control { min-height: 110px; resize: vertical; line-height: 1.55; }

select.form-control {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23667085' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right var(--sp-3) center;
  background-size: 16px;
  padding-right: var(--sp-10);
}

.form-hint { font-size: var(--fs-xs); color: var(--gray-500); margin-top: var(--sp-1); }
.form-error { font-size: var(--fs-xs); color: var(--danger); margin-top: var(--sp-1); font-weight: 500; }

.form-row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
}

.form-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: var(--sp-4);
}
@media (max-width: 640px) { .form-grid-2 { grid-template-columns: 1fr; } }

.form-section {
  padding: var(--sp-5) 0;
  border-top: 1px solid var(--gray-200);
}
.form-section:first-child { border-top: none; padding-top: 0; }

.form-section-title {
  font-size: var(--fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gray-500);
  margin-bottom: var(--sp-4);
}

.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-3);
  font-size: var(--fs-sm);
  color: var(--gray-700);
  cursor: pointer;
  user-select: none;
  line-height: 1.5;
}
.checkbox-row input[type="checkbox"],
.checkbox-row input[type="radio"] {
  appearance: none;
  width: 18px;
  height: 18px;
  border: 1.5px solid var(--gray-400);
  border-radius: var(--r-xs);
  background: #ffffff;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 2px;
  position: relative;
  transition: all var(--t-fast) var(--ease);
}
.checkbox-row input[type="radio"] { border-radius: 50%; }
.checkbox-row input:checked { background: var(--brand-primary); border-color: var(--brand-primary); }
.checkbox-row input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 5px; top: 1.5px;
  width: 5px; height: 10px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.checkbox-row input[type="radio"]:checked::after {
  content: "";
  position: absolute;
  left: 4px; top: 4px;
  width: 6px; height: 6px;
  background: #ffffff;
  border-radius: 50%;
}
.checkbox-row input:focus-visible {
  outline: none;
  box-shadow: var(--shadow-focus);
  border-color: var(--brand-accent);
}

.checkbox-row-tall { align-items: flex-start; padding: var(--sp-2) 0; }

.input-with-toggle { position: relative; }
.input-with-toggle .form-control { padding-right: 48px; }
.input-toggle {
  position: absolute;
  top: 50%; right: 6px;
  transform: translateY(-50%);
  width: 36px; height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  color: var(--gray-500);
  transition: background var(--t-fast) ease, color var(--t-fast) ease;
}
.input-toggle:hover { background: var(--gray-100); color: var(--gray-700); }
.input-toggle svg { width: 18px; height: 18px; }

.password-strength {
  margin-top: var(--sp-2);
  opacity: 0;
  transition: opacity var(--t-base) var(--ease);
}
.password-strength.visible { opacity: 1; }

.strength-bar {
  height: 4px;
  background: var(--gray-200);
  border-radius: var(--r-full);
  overflow: hidden;
}
.strength-fill {
  display: block;
  height: 100%;
  width: 0;
  background: var(--danger);
  border-radius: var(--r-full);
  transition: width var(--t-base) var(--ease), background var(--t-base) var(--ease);
}
.password-strength[data-strength="fair"]   .strength-fill { background: var(--warning); }
.password-strength[data-strength="good"]   .strength-fill { background: var(--info); }
.password-strength[data-strength="strong"] .strength-fill { background: var(--success); }

.strength-label {
  font-size: var(--fs-xs);
  color: var(--gray-500);
  margin-top: var(--sp-1);
  text-align: right;
}

.password-requirements {
  list-style: none;
  padding: 0;
  margin: var(--sp-3) 0 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: var(--sp-2);
}
.password-requirements li {
  font-size: var(--fs-xs);
  color: var(--gray-500);
  position: relative;
  padding-left: 20px;
  line-height: 1.4;
}
.password-requirements li::before {
  content: "";
  position: absolute;
  left: 0; top: 5px;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--gray-200);
}
.password-requirements li.met { color: var(--success); font-weight: 600; }
.password-requirements li.met::before { background: var(--success); }

/* ───────────────────────────────────────────────────────────────────────────
   13. TABLES
   ─────────────────────────────────────────────────────────────────────────── */
.table-wrap {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  overflow: hidden;
}
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

table.table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--fs-sm);
  min-width: 640px;
}
.table thead th {
  background: var(--gray-50);
  color: var(--gray-600);
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-align: left;
  padding: var(--sp-3) var(--sp-4);
  border-bottom: 1px solid var(--gray-200);
  white-space: nowrap;
}
.table tbody td {
  padding: var(--sp-4);
  border-bottom: 1px solid var(--gray-100);
  color: var(--gray-700);
  vertical-align: middle;
}
.table tbody tr:last-child td { border-bottom: none; }
.table tbody tr:hover { background: var(--gray-25); }
.table .cell-amount { text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.table .cell-amount.positive { color: var(--success); }
.table .cell-amount.negative { color: var(--gray-800); }
.table .cell-actions { text-align: right; white-space: nowrap; }

/* ───────────────────────────────────────────────────────────────────────────
   14. BADGES / PILLS
   ─────────────────────────────────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  font-size: var(--fs-xs);
  font-weight: 600;
  border-radius: var(--r-full);
  white-space: nowrap;
  line-height: 1.5;
  border: 1px solid transparent;
}
.badge svg { width: 12px; height: 12px; }

.badge-success { background: var(--success-bg); color: var(--success); border-color: var(--success-border); }
.badge-warning { background: var(--warning-bg); color: var(--warning); border-color: var(--warning-border); }
.badge-danger  { background: var(--danger-bg);  color: var(--danger);  border-color: var(--danger-border); }
.badge-info    { background: var(--info-bg);    color: var(--info);    border-color: var(--info-border); }
.badge-muted   { background: var(--gray-100);   color: var(--gray-600); border-color: var(--gray-200); }

.badge-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
  display: inline-block;
}

/* ───────────────────────────────────────────────────────────────────────────
   15. ALERTS
   ─────────────────────────────────────────────────────────────────────────── */
.alert {
  display: flex;
  gap: var(--sp-3);
  padding: var(--sp-4);
  border-radius: var(--r-md);
  border: 1px solid;
  font-size: var(--fs-sm);
  line-height: 1.5;
}
.alert-icon { flex-shrink: 0; width: 20px; height: 20px; margin-top: 2px; }
.alert-icon svg { width: 100%; height: 100%; }
.alert-body { flex: 1; }
.alert-title { font-weight: 700; margin-bottom: var(--sp-1); }

.alert-info    { background: var(--info-bg);    border-color: var(--info-border);    color: #1e4fa3; }
.alert-success { background: var(--success-bg); border-color: var(--success-border); color: #055a2e; }
.alert-warning { background: var(--warning-bg); border-color: var(--warning-border); color: #92400e; }
.alert-danger  { background: var(--danger-bg);  border-color: var(--danger-border);  color: #8b0b20; }

/* ───────────────────────────────────────────────────────────────────────────
   16. ACCOUNT CARDS
   ─────────────────────────────────────────────────────────────────────────── */
.account-card {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  padding: var(--sp-5);
  transition: all var(--t-base) var(--ease);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  text-decoration: none;
  color: inherit;
}
.account-card:hover {
  border-color: var(--brand-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.account-card:focus-visible { outline: 2px solid var(--brand-accent); outline-offset: 2px; }

.account-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--sp-3);
}
.account-type {
  font-size: var(--fs-xs);
  font-weight: 700;
  color: var(--brand-primary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.account-number {
  font-size: var(--fs-xs);
  color: var(--gray-500);
  font-family: var(--font-mono);
  margin-top: 2px;
}
.account-icon {
  width: 40px; height: 40px;
  border-radius: var(--r-md);
  background: var(--brand-accent-light);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-primary);
  flex-shrink: 0;
}
.account-icon svg { width: 20px; height: 20px; }

.account-balance {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--brand-navy);
  letter-spacing: -0.02em;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.account-balance.negative { color: var(--danger); }
.account-meta { font-size: var(--fs-xs); color: var(--gray-500); }

.account-actions {
  display: flex;
  gap: var(--sp-2);
  margin-top: auto;
  padding-top: var(--sp-3);
  border-top: 1px solid var(--gray-100);
}
.account-actions .btn { flex: 1; }

/* ───────────────────────────────────────────────────────────────────────────
   17. STAT CARDS
   ─────────────────────────────────────────────────────────────────────────── */
.stat-card {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-left: 4px solid var(--brand-primary);
  border-radius: var(--r-lg);
  padding: var(--sp-5);
  transition: box-shadow var(--t-fast) ease;
}
.stat-card:hover { box-shadow: var(--shadow-sm); }
.stat-card.stat-warning { border-left-color: var(--warning); }
.stat-card.stat-success { border-left-color: var(--success); }
.stat-card.stat-danger  { border-left-color: var(--danger); }
.stat-card.stat-info    { border-left-color: var(--info); }

.stat-label {
  font-size: var(--fs-xs);
  color: var(--gray-500);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--sp-2);
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}
.stat-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--brand-navy);
  line-height: 1.15;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.stat-sub {
  font-size: var(--fs-xs);
  color: var(--gray-500);
  margin-top: var(--sp-1);
  display: flex;
  align-items: center;
  gap: 4px;
}
.stat-sub.up   { color: var(--success); }
.stat-sub.down { color: var(--danger); }

/* ───────────────────────────────────────────────────────────────────────────
   18. QUICK ACTIONS
   ─────────────────────────────────────────────────────────────────────────── */
.quick-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: var(--sp-3);
}
.quick-action {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  padding: var(--sp-4);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  text-align: center;
  transition: all var(--t-fast) var(--ease);
  color: var(--gray-800);
  font-weight: 600;
  font-size: var(--fs-sm);
  cursor: pointer;
  text-decoration: none;
}
.quick-action:hover, .quick-action:focus-visible {
  border-color: var(--brand-accent);
  background: var(--brand-accent-light);
  color: var(--brand-primary);
  transform: translateY(-2px);
  outline: none;
  box-shadow: var(--shadow-sm);
}
.quick-action-icon {
  width: 44px; height: 44px;
  border-radius: var(--r-md);
  background: var(--brand-accent-light);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-primary);
  transition: background var(--t-fast) var(--ease);
}
.quick-action-icon svg { width: 22px; height: 22px; }
.quick-action:hover .quick-action-icon { background: #ffffff; }

/* ───────────────────────────────────────────────────────────────────────────
   19. TRANSACTION LIST
   ─────────────────────────────────────────────────────────────────────────── */
.txn-list { display: flex; flex-direction: column; }

.txn-item {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5);
  border-bottom: 1px solid var(--gray-100);
  cursor: pointer;
  transition: background var(--t-fast) var(--ease);
  text-decoration: none;
  color: inherit;
}
.txn-item:last-child { border-bottom: none; }
.txn-item:hover, .txn-item:focus-visible { background: var(--gray-50); outline: none; }

.txn-icon {
  width: 42px; height: 42px;
  border-radius: var(--r-full);
  background: var(--gray-100);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-600);
  flex-shrink: 0;
}
.txn-icon svg { width: 18px; height: 18px; }
.txn-icon.pos      { background: var(--success-bg); color: var(--success); }
.txn-icon.neg      { background: var(--danger-bg);  color: var(--danger); }
.txn-icon.pending  { background: var(--warning-bg); color: var(--warning); }
.txn-icon.transfer { background: var(--info-bg);    color: var(--info); }

.txn-info { flex: 1; min-width: 0; }
.txn-title {
  font-weight: 600;
  color: var(--gray-900);
  margin-bottom: 2px;
  font-size: var(--fs-sm);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.txn-meta {
  font-size: var(--fs-xs);
  color: var(--gray-500);
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  flex-wrap: wrap;
}

.txn-amount {
  font-weight: 700;
  font-size: var(--fs-sm);
  color: var(--gray-900);
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
  margin-left: auto;
}
.txn-amount.pos { color: var(--success); }

@media (max-width: 640px) {
  .txn-item { padding: var(--sp-3) var(--sp-4); gap: var(--sp-3); }
  .txn-icon { width: 36px; height: 36px; }
  .txn-icon svg { width: 16px; height: 16px; }
}

/* ───────────────────────────────────────────────────────────────────────────
   20. SPENDING BARS
   ─────────────────────────────────────────────────────────────────────────── */
.spend-row {
  display: grid;
  grid-template-columns: 160px 1fr 100px;
  align-items: center;
  gap: var(--sp-4);
  padding: var(--sp-3) 0;
}
@media (max-width: 640px) {
  .spend-row { grid-template-columns: 1fr; gap: var(--sp-2); }
}

.spend-label { font-size: var(--fs-sm); font-weight: 600; color: var(--gray-700); }
.spend-bar {
  height: 8px;
  background: var(--gray-100);
  border-radius: var(--r-full);
  overflow: hidden;
  position: relative;
}
.spend-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-accent));
  border-radius: var(--r-full);
  transition: width var(--t-slow) var(--ease);
}
.spend-amount {
  font-size: var(--fs-sm);
  font-weight: 700;
  text-align: right;
  color: var(--gray-900);
  font-variant-numeric: tabular-nums;
}

/* ───────────────────────────────────────────────────────────────────────────
   21. PENDING ITEMS
   ─────────────────────────────────────────────────────────────────────────── */
.pending-item {
  background: var(--warning-bg);
  border: 1px solid var(--warning-border);
  border-radius: var(--r-md);
  padding: var(--sp-4);
  margin-bottom: var(--sp-3);
  transition: transform var(--t-fast) ease, box-shadow var(--t-fast) ease;
}
.pending-item:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.pending-item:last-child { margin-bottom: 0; }

.pending-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-bottom: var(--sp-2);
}
.pending-title  { font-weight: 700; color: #92400e; font-size: var(--fs-sm); }
.pending-amount { font-weight: 700; color: #92400e; font-variant-numeric: tabular-nums; }
.pending-meta   { font-size: var(--fs-xs); color: #a16207; margin-bottom: var(--sp-3); }

/* ───────────────────────────────────────────────────────────────────────────
   22. MESSAGES
   ─────────────────────────────────────────────────────────────────────────── */
.message-list { display: flex; flex-direction: column; }

.message-item {
  display: flex;
  gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5);
  border-bottom: 1px solid var(--gray-100);
  cursor: pointer;
  transition: background var(--t-fast) var(--ease);
  text-decoration: none;
  color: inherit;
  position: relative;
}
.message-item:hover, .message-item:focus-visible { background: var(--gray-25); outline: none; }
.message-item:last-child { border-bottom: none; }
.message-item.unread { background: #fcfcfd; }
.message-item.unread::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-accent);
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
}

.message-avatar {
  width: 42px; height: 42px;
  border-radius: var(--r-md);
  background: var(--brand-accent-light);
  color: var(--brand-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex-shrink: 0;
}

.message-info { flex: 1; min-width: 0; }
.message-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-bottom: var(--sp-1);
}
.message-sender  { font-weight: 700; color: var(--gray-900); font-size: var(--fs-sm); }
.message-time    { font-size: var(--fs-xs); color: var(--gray-500); }
.message-subject { font-weight: 600; color: var(--gray-700); font-size: var(--fs-sm); margin-bottom: 2px; }
.message-preview {
  font-size: var(--fs-xs);
  color: var(--gray-500);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.message-thread { display: flex; flex-direction: column; gap: var(--sp-5); }

.message-bubble { display: flex; gap: var(--sp-3); }
.message-bubble.me { flex-direction: row-reverse; }

.message-bubble-avatar {
  width: 36px; height: 36px;
  border-radius: var(--r-full);
  background: var(--brand-primary);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: var(--fs-xs);
  flex-shrink: 0;
}
.message-bubble.me .message-bubble-avatar { background: var(--brand-accent); }

.message-bubble-content { flex: 1; max-width: 80%; }
.message-bubble-head {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  margin-bottom: var(--sp-1);
  font-size: var(--fs-xs);
  color: var(--gray-500);
}
.message-bubble.me .message-bubble-head { justify-content: flex-end; }
.message-bubble-sender { font-weight: 700; color: var(--gray-700); }

.message-bubble-body {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  padding: var(--sp-4);
  font-size: var(--fs-sm);
  line-height: 1.6;
  color: var(--gray-800);
  white-space: pre-wrap;
  word-break: break-word;
  box-shadow: 0 1px 2px rgba(0,0,0,0.02);
}
.message-bubble.me .message-bubble-body {
  background: var(--brand-accent-light);
  border-color: #cfe3f4;
  color: var(--brand-navy);
}

/* ───────────────────────────────────────────────────────────────────────────
   23. TABS
   ─────────────────────────────────────────────────────────────────────────── */
.tabs {
  display: flex;
  gap: var(--sp-1);
  border-bottom: 1px solid var(--gray-200);
  margin-bottom: var(--sp-6);
  overflow-x: auto;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }

.tab {
  padding: var(--sp-3) var(--sp-4);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--gray-500);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
  transition: all var(--t-fast) var(--ease);
  text-decoration: none;
}
.tab:hover, .tab:focus-visible { color: var(--brand-primary); outline: none; }
.tab.active { color: var(--brand-primary); border-bottom-color: var(--brand-primary); }

/* ───────────────────────────────────────────────────────────────────────────
   24. MODAL
   ─────────────────────────────────────────────────────────────────────────── */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(16,24,40,0.6);
  backdrop-filter: blur(3px);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-4);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-base) var(--ease);
}
.modal-backdrop.open { opacity: 1; visibility: visible; }

.modal {
  background: #ffffff;
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  max-height: 90dvh;
  overflow-y: auto;
  transform: translateY(12px) scale(0.98);
  transition: transform var(--t-base) var(--ease);
  display: flex;
  flex-direction: column;
}
.modal-backdrop.open .modal { transform: translateY(0) scale(1); }
.modal-lg { max-width: 800px; }
.modal-xl { max-width: 1100px; }

.modal-header {
  padding: var(--sp-5) var(--sp-6);
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  background: #ffffff;
  z-index: 10;
  border-radius: var(--r-xl) var(--r-xl) 0 0;
}
.modal-title { font-size: var(--fs-lg); font-weight: 700; margin: 0; }
.modal-close {
  width: 32px; height: 32px;
  border-radius: var(--r-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-500);
  transition: background var(--t-fast) ease, color var(--t-fast) ease;
}
.modal-close:hover { background: var(--gray-100); color: var(--gray-900); }

.modal-body { padding: var(--sp-6); flex: 1; }
.modal-footer {
  padding: var(--sp-4) var(--sp-6);
  border-top: 1px solid var(--gray-200);
  display: flex;
  justify-content: flex-end;
  gap: var(--sp-3);
  background: var(--gray-25);
  border-radius: 0 0 var(--r-xl) var(--r-xl);
  position: sticky;
  bottom: 0;
  z-index: 10;
}

/* ───────────────────────────────────────────────────────────────────────────
   25. PAGINATION
   ─────────────────────────────────────────────────────────────────────────── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-1);
  margin-top: var(--sp-6);
  flex-wrap: wrap;
}
.pagination a, .pagination span {
  min-width: 36px;
  height: 36px;
  padding: 0 var(--sp-3);
  border-radius: var(--r-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--gray-700);
  border: 1px solid var(--gray-200);
  background: #ffffff;
  text-decoration: none;
  transition: all var(--t-fast) ease;
}
.pagination a:hover, .pagination a:focus-visible {
  background: var(--gray-50);
  border-color: var(--brand-accent);
  color: var(--brand-primary);
  outline: none;
}
.pagination .active {
  background: var(--brand-primary);
  color: #ffffff;
  border-color: var(--brand-primary);
}
.pagination .disabled { opacity: 0.4; pointer-events: none; }

/* ───────────────────────────────────────────────────────────────────────────
   26. EMPTY STATES
   ─────────────────────────────────────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: var(--sp-12) var(--sp-6);
  background: #ffffff;
  border: 1px dashed var(--gray-300);
  border-radius: var(--r-lg);
}
.empty-icon {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: var(--gray-100);
  color: var(--gray-500);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--sp-4);
}
.empty-icon svg { width: 28px; height: 28px; }
.empty-title { font-size: var(--fs-lg); font-weight: 700; color: var(--gray-800); margin-bottom: var(--sp-2); }
.empty-text  { font-size: var(--fs-sm); color: var(--gray-500); max-width: 400px; margin: 0 auto var(--sp-5); }

/* ───────────────────────────────────────────────────────────────────────────
   27. AUTH PAGES
   ─────────────────────────────────────────────────────────────────────────── */
.auth-page { background: var(--gray-50); }

.auth-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: calc(100vh - var(--navbar-h));
}
@media (max-width: 900px) {
  .auth-wrapper { grid-template-columns: 1fr; min-height: auto; }
  .auth-side { display: none !important; }
}

.auth-side {
  background: linear-gradient(160deg, var(--brand-navy) 0%, var(--brand-primary) 60%, var(--brand-primary-light) 100%);
  color: #ffffff;
  padding: var(--sp-12) var(--sp-16);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}
@media (max-width: 1200px) { .auth-side { padding: var(--sp-10) var(--sp-12); } }

.auth-side::after {
  content: "";
  position: absolute;
  right: -30%;
  bottom: -30%;
  width: 70%;
  height: 70%;
  background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.auth-side-inner {
  max-width: 480px;
  margin: auto 0;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: var(--sp-8);
}

.auth-side-brand { display: flex; align-items: center; gap: var(--sp-3); }
.brand-text { display: flex; flex-direction: column; }
.brand-name-lg { font-size: var(--fs-xl); font-weight: 700; letter-spacing: -0.01em; }
.brand-tagline { font-size: var(--fs-xs); opacity: 0.75; font-weight: 500; }

.auth-side-headline {
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin: 0;
  color: #ffffff;
}
.auth-side-sub {
  font-size: var(--fs-base);
  line-height: 1.65;
  opacity: 0.88;
  margin: 0;
}

.auth-side-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
}
.auth-side-features li { display: flex; gap: var(--sp-4); align-items: flex-start; }
.feature-icon {
  width: 40px; height: 40px;
  border-radius: var(--r-md);
  background: rgba(255,255,255,0.12);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.feature-icon svg { width: 20px; height: 20px; }
.feature-text { display: flex; flex-direction: column; gap: 2px; }
.feature-text strong { font-size: var(--fs-sm); font-weight: 700; }
.feature-text span   { font-size: var(--fs-xs); opacity: 0.78; line-height: 1.5; }

.auth-side-footer {
  padding-top: var(--sp-6);
  border-top: 1px solid rgba(255,255,255,0.15);
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}
.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--fs-xs);
  font-weight: 600;
  opacity: 0.9;
}
.trust-badge svg { width: 16px; height: 16px; }
.trust-badge-sub { font-size: var(--fs-xs); opacity: 0.65; }

.auth-main {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-12) var(--sp-6);
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-2xl);
  box-shadow: var(--shadow-lg);
  padding: var(--sp-10);
}
.auth-card-wide { max-width: 560px; }
@media (max-width: 640px) {
  .auth-card { padding: var(--sp-6); border-radius: var(--r-xl); }
}

.auth-brand { text-align: center; margin-bottom: var(--sp-8); }
.auth-logo {
  width: 52px; height: 52px;
  margin: 0 auto var(--sp-4);
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-primary-light));
  color: #ffffff;
  font-weight: 800;
  font-size: 26px;
  border-radius: var(--r-lg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 16px -4px rgba(0,51,102,0.25);
}
.auth-brand h1 {
  font-size: var(--fs-2xl);
  margin-bottom: var(--sp-2);
  color: var(--brand-navy);
}
.auth-brand p { font-size: var(--fs-sm); color: var(--gray-500); margin: 0; }

.auth-form { display: flex; flex-direction: column; gap: var(--sp-4); }

.auth-secure-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  margin-top: var(--sp-2);
  font-size: var(--fs-xs);
  color: var(--gray-500);
}
.auth-secure-note svg { width: 14px; height: 14px; color: var(--success); }

.auth-divider {
  text-align: center;
  margin: var(--sp-6) 0;
  position: relative;
}
.auth-divider::before {
  content: "";
  position: absolute;
  top: 50%; left: 0; right: 0;
  border-top: 1px solid var(--gray-200);
}
.auth-divider span {
  position: relative;
  background: #ffffff;
  padding: 0 var(--sp-3);
  font-size: var(--fs-xs);
  color: var(--gray-500);
  font-weight: 500;
}

.auth-footer {
  text-align: center;
  margin-top: var(--sp-6);
  font-size: var(--fs-xs);
  color: var(--gray-500);
  line-height: 1.6;
}

.auth-support-note {
  margin-top: var(--sp-6);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--gray-200);
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: center;
}
.support-label { font-size: var(--fs-xs); font-weight: 700; color: var(--gray-600); text-transform: uppercase; letter-spacing: 0.05em; }
.support-info  { font-size: var(--fs-sm); color: var(--gray-700); font-weight: 500; }

/* ───────────────────────────────────────────────────────────────────────────
   28. ERROR PAGES
   ─────────────────────────────────────────────────────────────────────────── */
.error-wrapper {
  max-width: 480px;
  margin: 6rem auto;
  text-align: center;
  padding: var(--sp-8);
}
.error-code {
  font-size: 6rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.05em;
  color: var(--brand-primary);
  opacity: 0.15;
  margin-bottom: var(--sp-4);
}
.error-wrapper h1 { font-size: var(--fs-3xl); margin-bottom: var(--sp-3); color: var(--brand-navy); }
.error-wrapper p  { color: var(--gray-500); margin-bottom: var(--sp-6); }

/* ───────────────────────────────────────────────────────────────────────────
   29. LANDING PAGE SECTIONS
   ─────────────────────────────────────────────────────────────────────────── */
.landing-hero {
  background: linear-gradient(135deg, var(--brand-navy) 0%, var(--brand-primary) 55%, var(--brand-primary-light) 100%);
  color: #ffffff;
  padding: var(--sp-16) var(--container-pad);
  position: relative;
  overflow: hidden;
}
.landing-hero::after {
  content: "";
  position: absolute;
  top: -40%;
  right: -15%;
  width: 60%;
  height: 180%;
  background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
  pointer-events: none;
}
@media (max-width: 768px) { .landing-hero { padding: var(--sp-12) var(--container-pad); } }

.landing-hero-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: var(--sp-12);
  align-items: center;
  position: relative;
  z-index: 1;
}
@media (max-width: 900px) {
  .landing-hero-inner { grid-template-columns: 1fr; gap: var(--sp-8); text-align: center; }
}

.landing-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 6px 14px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--r-full);
  font-size: var(--fs-xs);
  font-weight: 600;
  margin-bottom: var(--sp-5);
  backdrop-filter: blur(8px);
}

.landing-hero h1 {
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: #ffffff;
  margin-bottom: var(--sp-5);
}

.landing-hero-sub {
  font-size: var(--fs-lg);
  line-height: 1.6;
  opacity: 0.9;
  margin-bottom: var(--sp-8);
  max-width: 540px;
}
@media (max-width: 900px) { .landing-hero-sub { margin-left: auto; margin-right: auto; } }

.landing-hero-cta {
  display: flex;
  gap: var(--sp-3);
  flex-wrap: wrap;
}
@media (max-width: 900px) { .landing-hero-cta { justify-content: center; } }
@media (max-width: 480px) {
  .landing-hero-cta { flex-direction: column; }
  .landing-hero-cta .btn { width: 100%; justify-content: center; }
}

.landing-hero-visual {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--r-xl);
  padding: var(--sp-6);
  backdrop-filter: blur(12px);
  box-shadow: 0 24px 48px -12px rgba(0,0,0,0.35);
}

.landing-hero-note {
  font-size: var(--fs-xs);
  opacity: 0.7;
  margin-top: var(--sp-4);
}

.rate-snapshot {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--r-xl);
  padding: var(--sp-6);
  backdrop-filter: blur(12px);
}
.rate-snapshot-header {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.7;
  margin-bottom: var(--sp-4);
}
.rate-snapshot-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--sp-3) 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.rate-snapshot-row:last-of-type { border-bottom: none; }
.rate-snapshot-label {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  font-size: var(--fs-sm);
  opacity: 0.9;
}
.rate-snapshot-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.rate-snapshot-icon svg { width: 14px; height: 14px; }
.rate-snapshot-value {
  font-size: var(--fs-lg);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.rate-snapshot-value span {
  font-size: var(--fs-xs);
  font-weight: 500;
  opacity: 0.7;
  margin-left: 2px;
}
.rate-snapshot-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: var(--sp-4);
  color: rgba(255,255,255,0.9);
  font-size: var(--fs-sm);
  font-weight: 600;
}
.rate-snapshot-link:hover { color: #ffffff; }
.rate-snapshot-link svg { width: 14px; height: 14px; }

.quick-access-bar {
  background: #ffffff;
  border-bottom: 1px solid var(--gray-200);
  padding: var(--sp-5) 0;
}
.quick-access-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-4);
}
.quick-access-item {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--r-md);
  background: var(--gray-50);
  color: var(--gray-800);
  font-size: var(--fs-sm);
  font-weight: 600;
  transition: all var(--t-fast) ease;
}
.quick-access-item:hover {
  background: var(--brand-accent-light);
  color: var(--brand-primary);
  transform: translateY(-1px);
}
.quick-access-item svg {
  width: 20px;
  height: 20px;
  color: var(--brand-accent);
}
@media (max-width: 768px) {
  .quick-access-grid { grid-template-columns: repeat(2, 1fr); }
}

.trust-bar {
  background: #ffffff;
  border-bottom: 1px solid var(--gray-200);
  padding: var(--sp-6) var(--container-pad);
}
.trust-bar-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-around;
  gap: var(--sp-8);
  flex-wrap: wrap;
}
.trust-bar-item {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  font-size: var(--fs-sm);
  color: var(--gray-700);
  font-weight: 500;
}
.trust-bar-item svg { width: 20px; height: 20px; color: var(--brand-accent); flex-shrink: 0; }
@media (max-width: 640px) {
  .trust-bar-item { font-size: var(--fs-xs); }
  .trust-bar-inner { gap: var(--sp-4); }
}

.landing-section {
  padding: var(--sp-16) var(--container-pad);
}
.landing-section-alt { background: var(--gray-50); }
@media (max-width: 768px) { .landing-section { padding: var(--sp-12) var(--container-pad); } }

.landing-section-head {
  max-width: 720px;
  margin: 0 auto var(--sp-12);
  text-align: center;
}
.landing-section-head h2 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 800;
  color: var(--brand-navy);
  letter-spacing: -0.02em;
  margin-bottom: var(--sp-3);
}
.landing-section-head p {
  font-size: var(--fs-lg);
  color: var(--gray-500);
  margin: 0;
}

.rates-tabs {
  display: flex;
  gap: var(--sp-2);
  margin-bottom: var(--sp-6);
  justify-content: center;
}
.rates-tab {
  padding: var(--sp-3) var(--sp-5);
  border-radius: var(--r-md);
  font-size: var(--fs-sm);
  font-weight: 600;
  background: var(--gray-100);
  color: var(--gray-600);
  border: 1px solid transparent;
  transition: all var(--t-fast) ease;
}
.rates-tab:hover { background: var(--gray-200); }
.rates-tab.active {
  background: var(--brand-primary);
  color: #ffffff;
  border-color: var(--brand-primary);
}
.rates-panel { display: none; }
.rates-panel.active { display: block; }

.rate-card {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  padding: var(--sp-6);
  text-align: center;
  transition: all var(--t-base) var(--ease);
  position: relative;
  overflow: hidden;
}
.rate-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-accent));
}
.rate-card:hover {
  border-color: var(--brand-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}
.rate-label {
  font-size: var(--fs-xs);
  font-weight: 700;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--sp-2);
}
.rate-value {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--brand-primary);
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: var(--sp-1);
  font-variant-numeric: tabular-nums;
}
.rate-value sup { font-size: 1.25rem; top: -0.75em; }
.rate-name { font-size: var(--fs-sm); color: var(--gray-600); font-weight: 600; }
.rate-note { font-size: var(--fs-xs); color: var(--gray-500); margin-top: var(--sp-2); }

.product-card {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  padding: var(--sp-6);
  transition: all var(--t-base) var(--ease);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  text-decoration: none;
  color: inherit;
  height: 100%;
}
.product-card:hover {
  border-color: var(--brand-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}
.product-icon {
  width: 52px; height: 52px;
  border-radius: var(--r-md);
  background: var(--brand-accent-light);
  color: var(--brand-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.product-icon svg { width: 26px; height: 26px; }
.product-title { font-size: var(--fs-lg); font-weight: 700; color: var(--brand-navy); margin: 0; }
.product-desc  { font-size: var(--fs-sm); color: var(--gray-500); line-height: 1.6; margin: 0; flex: 1; }
.product-link {
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--brand-accent);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: var(--sp-2);
}
.product-link svg { width: 14px; height: 14px; transition: transform var(--t-fast) ease; }
.product-card:hover .product-link svg { transform: translateX(4px); }

.product-card-compact {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  padding: var(--sp-5);
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  text-decoration: none;
  color: inherit;
  transition: all var(--t-base) ease;
}
.product-card-compact:hover {
  border-color: var(--brand-accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.product-icon-sm {
  width: 44px;
  height: 44px;
  border-radius: var(--r-md);
  background: var(--brand-accent-light);
  color: var(--brand-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--sp-2);
}
.product-icon-sm svg { width: 22px; height: 22px; }
.product-card-compact h3 {
  font-size: var(--fs-base);
  font-weight: 700;
  color: var(--brand-navy);
  margin: 0;
}
.product-card-compact p {
  font-size: var(--fs-xs);
  color: var(--gray-500);
  margin: 0;
  flex: 1;
}
.product-link-sm {
  font-size: var(--fs-xs);
  font-weight: 700;
  color: var(--brand-accent);
  margin-top: var(--sp-2);
}

.feature-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: var(--sp-8);
}
@media (max-width: 900px) { .feature-row { grid-template-columns: 1fr; gap: var(--sp-6); } }

.feature-block {
  text-align: center;
  padding: var(--sp-4);
}
.feature-block-icon {
  width: 64px; height: 64px;
  border-radius: var(--r-lg);
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-accent));
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--sp-4);
  box-shadow: 0 8px 16px -6px rgba(0,51,102,0.3);
}
.feature-block-icon svg { width: 30px; height: 30px; }
.feature-block h3 { font-size: var(--fs-lg); color: var(--brand-navy); margin-bottom: var(--sp-2); }
.feature-block p  { font-size: var(--fs-sm); color: var(--gray-500); line-height: 1.65; margin: 0; }

.testimonial-card {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  padding: var(--sp-6);
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
}
.testimonial-text {
  font-size: var(--fs-sm);
  color: var(--gray-700);
  line-height: 1.7;
  font-style: italic;
  margin: 0;
  flex: 1;
}
.testimonial-author {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding-top: var(--sp-3);
  border-top: 1px solid var(--gray-100);
}
.testimonial-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--brand-primary);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: var(--fs-sm);
}
.testimonial-name {
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--gray-900);
}
.testimonial-role {
  font-size: var(--fs-xs);
  color: var(--gray-500);
}

.app-section {
  background: linear-gradient(135deg, var(--brand-navy) 0%, var(--brand-primary) 100%);
  color: #ffffff;
  border-radius: var(--r-xl);
  padding: var(--sp-12);
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: var(--sp-8);
  align-items: center;
  overflow: hidden;
  position: relative;
}
@media (max-width: 900px) {
  .app-section { grid-template-columns: 1fr; padding: var(--sp-8); text-align: center; }
}
.app-section h2 { color: #ffffff; font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: var(--sp-3); }
.app-section p  { color: rgba(255,255,255,0.85); font-size: var(--fs-md); margin-bottom: var(--sp-6); }
.app-buttons { display: flex; gap: var(--sp-3); flex-wrap: wrap; }
@media (max-width: 900px) { .app-buttons { justify-content: center; } }
.app-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-5);
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: var(--r-md);
  color: #ffffff;
  font-weight: 600;
  font-size: var(--fs-sm);
  transition: background var(--t-fast) ease;
}
.app-btn:hover { background: rgba(255,255,255,0.22); color: #ffffff; }

.cta-banner {
  text-align: center;
  padding: var(--sp-12) var(--container-pad);
  background: var(--gray-50);
  border-top: 1px solid var(--gray-200);
}
.cta-banner h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--brand-navy);
  margin-bottom: var(--sp-3);
}
.cta-banner p {
  font-size: var(--fs-lg);
  color: var(--gray-500);
  margin-bottom: var(--sp-6);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.cta-banner .btn { margin: 0 auto; }

/* ───────────────────────────────────────────────────────────────────────────
   30. FOOTER
   ─────────────────────────────────────────────────────────────────────────── */
.site-footer {
  background: var(--brand-navy);
  color: rgba(255,255,255,0.75);
  margin-top: auto;
  font-size: var(--fs-sm);
}

.footer-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: var(--sp-12) var(--container-pad);
  display: grid;
  grid-template-columns: 1.6fr 2.4fr;
  gap: var(--sp-12);
}
@media (max-width: 900px) {
  .footer-inner { grid-template-columns: 1fr; gap: var(--sp-8); padding: var(--sp-8) var(--container-pad); }
}

.footer-brand { display: flex; flex-direction: column; gap: var(--sp-2); }

.footer-logo {
  max-height: 40px;
  width: auto;
  margin-bottom: var(--sp-3);
  display: block;
}

.footer-address { color: rgba(255,255,255,0.85); margin: 0; font-size: var(--fs-sm); }
.footer-meta    { font-size: var(--fs-xs); color: rgba(255,255,255,0.6); margin: 0; }

.footer-disclosure {
  font-size: 11px;
  line-height: 1.6;
  color: rgba(255,255,255,0.55);
  margin-top: var(--sp-4);
  max-width: 420px;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: var(--sp-6);
}
@media (max-width: 640px) { .footer-links { grid-template-columns: repeat(2, minmax(0,1fr)); } }

.footer-col { display: flex; flex-direction: column; gap: var(--sp-2); }
.footer-col h4 {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #ffffff;
  margin-bottom: var(--sp-2);
  opacity: 0.9;
}
.footer-col a {
  font-size: var(--fs-xs);
  color: rgba(255,255,255,0.65);
  transition: color var(--t-fast) var(--ease);
}
.footer-col a:hover, .footer-col a:focus-visible { color: #ffffff; outline: none; text-decoration: underline; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: var(--sp-5) var(--container-pad);
}
.footer-bottom-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  flex-wrap: wrap;
  font-size: var(--fs-xs);
  color: rgba(255,255,255,0.55);
}
.footer-bottom-links { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.footer-bottom-links a { color: rgba(255,255,255,0.7); padding: 0 2px; }
.footer-bottom-links a:hover, .footer-bottom-links a:focus-visible { color: #ffffff; outline: none; text-decoration: underline; }

/* ───────────────────────────────────────────────────────────────────────────
   31. LIVE CHAT
   ─────────────────────────────────────────────────────────────────────────── */
.chat-fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: var(--r-full);
  background: var(--brand-accent);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 24px -6px rgba(17,122,202,0.5);
  cursor: pointer;
  z-index: 400;
  transition: transform var(--t-base) var(--ease), background var(--t-fast) var(--ease);
}
.chat-fab:hover, .chat-fab:focus-visible {
  transform: scale(1.06);
  background: var(--brand-accent-dark);
  outline: none;
}
.chat-fab svg { width: 24px; height: 24px; }
@media (max-width: 640px) { .chat-fab { bottom: 16px; right: 16px; width: 52px; height: 52px; } }

.chat-online-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 12px;
  height: 12px;
  background: var(--success);
  border: 2px solid #ffffff;
  border-radius: 50%;
}

.chat-window {
  position: fixed;
  bottom: 92px;
  right: 24px;
  width: 380px;
  max-width: calc(100vw - 32px);
  height: 520px;
  max-height: calc(100vh - 120px);
  background: #ffffff;
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-xl);
  display: flex;
  flex-direction: column;
  z-index: 400;
  overflow: hidden;
  animation: chatIn var(--t-base) var(--ease);
}
@media (max-width: 640px) {
  .chat-window {
    right: 16px;
    bottom: 80px;
    width: calc(100vw - 32px);
    height: calc(100vh - 140px);
    height: calc(100dvh - 140px);
    max-height: none;
  }
}

@keyframes chatIn {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-header {
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-primary-light));
  color: #ffffff;
  padding: var(--sp-4) var(--sp-5);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.chat-header-left { display: flex; flex-direction: column; gap: 2px; }
.chat-header-left strong { font-size: var(--fs-base); }
.chat-status {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--fs-xs);
  opacity: 0.9;
}
.online-dot {
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 0 3px rgba(6,125,62,0.25);
}

.chat-close {
  width: 32px;
  height: 32px;
  border-radius: var(--r-sm);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background var(--t-fast) ease;
}
.chat-close:hover, .chat-close:focus-visible { background: rgba(255,255,255,0.2); outline: none; }
.chat-close svg { width: 16px; height: 16px; }

.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: var(--sp-4);
  background: var(--gray-50);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  scrollbar-width: thin;
}

.chat-message { max-width: 85%; display: flex; flex-direction: column; gap: 2px; }
.chat-message-staff { align-self: flex-start; }
.chat-message-me    { align-self: flex-end; }

.chat-message-meta {
  font-size: 10px;
  color: var(--gray-500);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}
.chat-message-me .chat-message-meta { text-align: right; }

.chat-message-text {
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  padding: var(--sp-3) var(--sp-4);
  font-size: var(--fs-sm);
  line-height: 1.5;
  color: var(--gray-800);
  white-space: pre-wrap;
  word-break: break-word;
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}
.chat-message-me .chat-message-text {
  background: var(--brand-accent);
  color: #ffffff;
  border-color: var(--brand-accent);
  border-bottom-right-radius: 4px;
}
.chat-message-staff .chat-message-text { border-bottom-left-radius: 4px; }

.chat-input-row {
  display: flex;
  gap: var(--sp-2);
  padding: var(--sp-3);
  border-top: 1px solid var(--gray-200);
  background: #ffffff;
}
.chat-input-row input {
  flex: 1;
  padding: var(--sp-3) var(--sp-4);
  border: 1px solid var(--gray-300);
  border-radius: var(--r-md);
  font-size: var(--fs-sm);
  transition: border-color var(--t-fast) ease, box-shadow var(--t-fast) ease;
}
.chat-input-row input:focus {
  outline: none;
  border-color: var(--brand-accent);
  box-shadow: var(--shadow-focus);
}

.chat-send-btn {
  width: 44px;
  height: 44px;
  border-radius: var(--r-md);
  background: var(--brand-accent);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background var(--t-fast) var(--ease), transform 0.1s ease;
}
.chat-send-btn:hover { background: var(--brand-accent-dark); }
.chat-send-btn:active { transform: scale(0.95); }
.chat-send-btn svg { width: 18px; height: 18px; }

/* ───────────────────────────────────────────────────────────────────────────
   32. UTILITIES
   ─────────────────────────────────────────────────────────────────────────── */
.hidden { display: none !important; }
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.mt-0 { margin-top: 0; } .mt-2 { margin-top: var(--sp-2); } .mt-4 { margin-top: var(--sp-4); }
.mt-6 { margin-top: var(--sp-6); } .mt-8 { margin-top: var(--sp-8); }
.mb-0 { margin-bottom: 0; } .mb-2 { margin-bottom: var(--sp-2); } .mb-4 { margin-bottom: var(--sp-4); }
.mb-6 { margin-bottom: var(--sp-6); } .mb-8 { margin-bottom: var(--sp-8); }

.p-4 { padding: var(--sp-4); } .p-6 { padding: var(--sp-6); }

.flex-1 { flex: 1; }
.w-full { width: 100%; }

.divider {
  height: 1px;
  background: var(--gray-200);
  margin: var(--sp-6) 0;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  margin-bottom: var(--sp-5);
  flex-wrap: wrap;
}
.section-heading h2 {
  font-size: var(--fs-xl);
  margin: 0;
  color: var(--brand-navy);
  letter-spacing: -0.01em;
}
.section-heading .section-link {
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--brand-accent);
}

.loading-dots { display: inline-flex; gap: 4px; }
.loading-dots span {
  width: 6px; height: 6px;
  background: var(--brand-accent);
  border-radius: 50%;
  animation: bounce 1.4s infinite ease-in-out;
}
.loading-dots span:nth-child(2) { animation-delay: 0.15s; }
.loading-dots span:nth-child(3) { animation-delay: 0.3s; }
@keyframes bounce {
  0%, 80%, 100% { opacity: 0.4; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-4px); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ───────────────────────────────────────────────────────────────────────────
   33. PRINT
   ─────────────────────────────────────────────────────────────────────────── */
@media print {
  .navbar, .utility-bar, .site-footer, .chat-fab, .chat-window,
  .flash-container, .btn, .no-print, .mobile-menu-toggle,
  .mobile-drawer, .mobile-drawer-backdrop { display: none !important; }

  .main-content { padding: 0; }
  .card { box-shadow: none; border: 1px solid #ddd; page-break-inside: avoid; }
  body { background: #ffffff; }
  a { color: #000; text-decoration: underline; }
}

/* ───────────────────────────────────────────────────────────────────────────
   34. MOBILE QUICK ACTIONS (inside drawer)
   ─────────────────────────────────────────────────────────────────────────── */
.drawer-section-label {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gray-500);
  margin: var(--sp-4) 0 var(--sp-2);
}

.drawer-quick-actions {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--sp-2);
  margin-bottom: var(--sp-3);
}
.drawer-quick-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: var(--sp-3);
  border-radius: var(--r-md);
  background: var(--gray-50);
  color: var(--brand-primary);
  font-size: var(--fs-xs);
  font-weight: 600;
  text-decoration: none;
  border: 1px solid var(--gray-200);
  transition: all var(--t-fast) var(--ease);
}
.drawer-quick-btn:hover,
.drawer-quick-btn:focus-visible {
  background: var(--brand-accent-light);
  border-color: var(--brand-accent);
  outline: none;
}
.drawer-quick-btn svg { width: 22px; height: 22px; }

/* ───────────────────────────────────────────────────────────────────────────
   35. MOBILE BOTTOM TAB BAR + SLIDE-UP USER SHEET
   ─────────────────────────────────────────────────────────────────────────── */
.mobile-tabbar { display: none; }
.tab-sheet     { display: none; }
.tab-sheet-backdrop { display: none; }

@media (max-width: 900px) {
  body.has-tabbar .main-content { padding-bottom: 88px; }
  body.has-tabbar .chat-fab     { bottom: 84px; }
  body.has-tabbar .site-footer  { padding-bottom: 72px; }

  .mobile-tabbar {
    display: flex;
    position: fixed;
    left: 0; right: 0; bottom: 0;
    height: 64px;
    background: #ffffff;
    border-top: 1px solid var(--gray-200);
    box-shadow: 0 -4px 12px -4px rgba(16,24,40,0.10);
    z-index: 250;
    justify-content: space-around;
    align-items: center;
    padding-bottom: env(safe-area-inset-bottom);
  }
  .mobile-tabbar a,
  .mobile-tabbar button {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    color: var(--gray-500);
    font-size: 10px;
    font-weight: 600;
    text-decoration: none;
    padding: var(--sp-2) 0;
    border: none;
    background: none;
    transition: color var(--t-fast) var(--ease);
  }
  .mobile-tabbar a.active,
  .mobile-tabbar a:hover,
  .mobile-tabbar button:focus-visible { color: var(--brand-primary); }
  .mobile-tabbar svg { width: 22px; height: 22px; }
  .mobile-tabbar .tab-avatar {
    width: 32px; height: 32px;
    border-radius: 50%;
    background: var(--brand-primary);
    color: #ffffff;
    font-size: 12px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .tab-sheet-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(16,24,40,0.5);
    z-index: 251;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
  }
  .tab-sheet-backdrop.open { opacity: 1; visibility: visible; }

  .tab-sheet {
    display: block;
    position: fixed;
    left: 0; right: 0; bottom: 0;
    background: #ffffff;
    border-radius: var(--r-xl) var(--r-xl) 0 0;
    box-shadow: 0 -8px 24px -8px rgba(16,24,40,0.20);
    z-index: 252;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    padding-bottom: calc(var(--sp-4) + env(safe-area-inset-bottom));
    max-height: 75vh;
    max-height: 75dvh;
    overflow-y: auto;
  }
  .tab-sheet.open { transform: translateY(0); }

  .tab-sheet-grip {
    width: 40px; height: 4px;
    background: var(--gray-300);
    border-radius: var(--r-full);
    margin: var(--sp-3) auto var(--sp-2);
  }
  .tab-sheet-head {
    padding: var(--sp-3) var(--sp-5) var(--sp-4);
    border-bottom: 1px solid var(--gray-100);
    display: flex;
    flex-direction: column;
    gap: 2px;
  }
  .tab-sheet-head strong { color: var(--brand-navy); font-size: var(--fs-md); }
  .tab-sheet-head span   { color: var(--gray-500); font-size: var(--fs-xs); }

  .tab-sheet-nav { padding: var(--sp-2) var(--sp-3) var(--sp-4); display: flex; flex-direction: column; }
  .tab-sheet-nav a {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    padding: var(--sp-3) var(--sp-3);
    border-radius: var(--r-md);
    color: var(--gray-800);
    font-size: var(--fs-sm);
    font-weight: 600;
    text-decoration: none;
    transition: background var(--t-fast) ease, color var(--t-fast) ease;
  }
  .tab-sheet-nav a:hover,
  .tab-sheet-nav a:focus-visible { background: var(--gray-50); color: var(--brand-primary); outline: none; }
  .tab-sheet-nav a svg { width: 20px; height: 20px; color: var(--gray-500); }
  .tab-sheet-nav a.text-danger { color: var(--danger); }
  .tab-sheet-nav a.text-danger svg { color: var(--danger); }
  .tab-sheet-nav hr { margin: var(--sp-2) 0; }
}

@media (min-width: 901px) {
  .mobile-tabbar,
  .tab-sheet,
  .tab-sheet-backdrop { display: none !important; }
}

/* ───────────────────────────────────────────────────────────────────────────
   36. NOTIFICATION BELL DROPDOWN
   ─────────────────────────────────────────────────────────────────────────── */
.notif-wrap {
  position: relative;
  display: inline-block;
}

.notif-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 340px;
  max-width: calc(100vw - 24px);
  max-height: 480px;
  background: #ffffff;
  border: 1px solid var(--gray-200);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xl);
  display: flex;
  flex-direction: column;
  z-index: 300;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.notif-dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.notif-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--gray-200);
  flex-shrink: 0;
}

.notif-header strong {
  font-size: 14px;
  font-weight: 700;
  color: var(--gray-900);
}

.notif-mark-all {
  font-size: 12px;
  font-weight: 600;
  color: var(--brand-accent);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 4px;
  transition: background 0.15s ease;
}

.notif-mark-all:hover {
  background: var(--gray-100);
  color: var(--brand-accent-dark);
}

.notif-body {
  flex: 1;
  overflow-y: auto;
  padding: 4px 0;
  max-height: 400px;
}

.notif-item {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--gray-100);
  text-decoration: none;
  color: inherit;
  transition: background 0.12s ease;
  cursor: pointer;
}

.notif-item:last-child { border-bottom: none; }
.notif-item:hover { background: var(--gray-50); }

.notif-item-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: var(--brand-accent-light);
  color: var(--brand-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.notif-item-icon svg {
  width: 16px;
  height: 16px;
}

.notif-item-content {
  flex: 1;
  min-width: 0;
}

.notif-item-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-900);
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notif-item-body {
  font-size: 12px;
  color: var(--gray-600);
  line-height: 1.45;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.notif-item-time {
  font-size: 11px;
  color: var(--gray-400);
}

.notif-empty {
  padding: 32px 16px;
  text-align: center;
  color: var(--gray-500);
  font-size: 13px;
}

@media (max-width: 640px) {
  .notif-dropdown {
    position: fixed;
    top: 60px;                      /* just under the sticky navbar */
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    max-height: calc(100vh - 90px);
    max-height: calc(100dvh - 90px);
    transform: translateY(-8px);
  }

  .notif-dropdown.open {
    transform: translateY(0);
  }

  .notif-body {
    max-height: calc(100vh - 160px);
    max-height: calc(100dvh - 160px);
  }
}
