/* ============================================================================
   OPTION SPECTRUM — RESEARCH CENTER
   research.css
   Extends the existing Option Spectrum design system.
   Design tokens (fonts, colors, spacing, radius, motion) are reused exactly
   from the production homepage — do not introduce new brand values here.
   ============================================================================ */

/* ----------------------------------------------------------------------------
   1. DESIGN TOKENS (CSS Custom Properties)
   Single source of truth for the whole page. Every color / spacing / radius
   / timing value used anywhere below should trace back to one of these.
---------------------------------------------------------------------------- */
:root {
  /* Brand colors */
  --color-bg:        #09090C;   /* page background */
  --color-surface:   #0F1015;   /* section / nav / sidebar background */
  --color-card:      #161820;   /* card background */
  --color-blue:      #2A8FCE;   /* primary brand blue */
  --color-blue-dim:  #2A8FCE33; /* blue at low opacity, for glows/borders */
  --color-red:       #ED2024;   /* secondary brand red */
  --color-red-dim:   #ED202433;
  --color-text:      #EEEEF2;   /* primary text */
  --color-muted:     #9698AC;   /* secondary / muted text */
  --color-white:     #FFFFFF;

  /* Utility semantic colors (ratings, positive/negative indicators) */
  --color-positive: #34D399;
  --color-warning:  #FACC15;

  /* --------------------------------------------------------------------
     REAL SITE ALIASES — the exact variable names used in optionspectrum.com's
     own stylesheet (pulled from OS_Website.zip). The nav and footer CSS
     below is copied verbatim from the live site, so it references these
     exact names rather than our --color-* naming. Keeping both systems
     side by side (instead of renaming the copied CSS) means we can
     re-sync with the real site's nav/footer in the future by just
     diffing and re-pasting, with no translation step.
  -------------------------------------------------------------------- */
  --obs:  #09090C;
  --surf: #0F1015;
  --card: #161820;
  --card2:#1C1E27;
  --bdr:  #242630;
  --bdr2: #2E3040;
  --blue: #2A8FCE;
  --red:  #ED2024;
  --text: #EEEEF2;
  --muted:#9698AC;
  --dim:  #5A5B6E;
  --t: .25s ease;
  --r: 14px;

  /* Derived surface tones (kept strictly within the brand's greyscale) */
  --color-card-hover: #1B1E29;
  --color-border:      rgba(238, 238, 242, 0.08);
  --color-border-soft: rgba(238, 238, 242, 0.05);
  --color-glass:        rgba(22, 24, 32, 0.55);
  --color-glass-strong: rgba(15, 16, 21, 0.75);

  /* Typography */
  --font-display: 'Fraunces', serif;
  --font-body:    'Hanken Grotesk', sans-serif;

  /* Spacing scale (matches homepage 8px base rhythm) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;

  /* Radius scale */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 999px;

  /* Shadows / glow */
  --shadow-card:      0 8px 24px rgba(0, 0, 0, 0.35);
  --shadow-card-hover: 0 16px 40px rgba(0, 0, 0, 0.5);
  --glow-blue: 0 0 0 1px var(--color-blue-dim), 0 0 32px -4px rgba(42, 143, 206, 0.55);
  --glow-red:  0 0 0 1px var(--color-red-dim), 0 0 32px -4px rgba(237, 32, 36, 0.5);

  /* Motion (single speed system, matches homepage) */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --duration-fast: 180ms;
  --duration-base: 320ms;
  --duration-slow: 640ms;

  /* Layout */
  --nav-height: 76px; /* kept for the mobile drawer breakpoint below */
  --nav-clearance: 108px; /* vertical space needed so content clears the fixed floating nav pill */
  --sidebar-width: 260px;
  --sidebar-width-collapsed: 76px;
  --content-max: 1320px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul { list-style: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

::selection { background: var(--color-blue-dim); color: var(--color-white); }

/* Respect reduced motion preference across every animation in this file */
@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;
  }
}

/* ----------------------------------------------------------------------------
   3. UTILITY LAYOUT
---------------------------------------------------------------------------- */
.container {
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--space-5);
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

/* Reveal-on-scroll base state — JS toggles .is-visible via IntersectionObserver */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal-scale { opacity: 0; transform: scale(0.94); }
.reveal-scale.is-visible { opacity: 1; transform: scale(1); }
.reveal-left  { opacity: 0; transform: translateX(-28px); }
.reveal-left.is-visible { opacity: 1; transform: translateX(0); }

/* Stagger children reveal via inline --delay custom property */
.reveal { transition-delay: var(--delay, 0ms); }

/* ----------------------------------------------------------------------------
   4. TOP NAVIGATION — copied verbatim from optionspectrum.com (OS_Website.zip)
   so the Research Center's header is pixel-identical to the main site,
   not an approximation of it. Uses the real site's own class names
   (nav-bar, nav-pill, nav-cta-btn, burger, mob, etc.) — see the alias
   variables in the tokens section above for how colors resolve.
---------------------------------------------------------------------------- */
#nav { position: fixed; inset: 14px 0 auto; z-index: 300; padding: 0 28px; transition: inset .35s cubic-bezier(.22,.61,.36,1); }
.nav-bar { max-width: 1280px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 0 32px; }
.nav-logo { flex-shrink: 0; display: flex; align-items: center; transition: opacity .3s; }
.nav-logo img { height: 68px; width: auto; }
.nav-pill {
  display: inline-flex; justify-content: center;
  background: rgba(15,16,21,.72); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,.06); border-radius: 100px;
  box-shadow: 0 8px 32px rgba(0,0,0,.4); padding: 0 8px; height: 58px; align-items: center;
  transition: height .35s, box-shadow .35s, background .35s, border-color .35s;
}
.nav-links { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; }
.nav-links a { display: block; padding: 9px 16px; font-size: 15px; font-weight: 500; color: var(--muted); border-radius: 100px; transition: color var(--t), background var(--t); }
.nav-links a:hover { color: var(--text); background: rgba(255,255,255,.05); }
.nav-links a.active { color: var(--text); }
.nav-cta-btn {
  flex-shrink: 0; background: var(--blue); color: #fff; padding: 13px 24px; border-radius: 100px;
  font-weight: 600; font-size: 15px; transition: opacity .3s, transform var(--t), box-shadow var(--t);
  white-space: nowrap;
}
.nav-cta-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(42,143,206,.45); }

/* Scrolled state: logo + button fade out, only the centered pill remains */
#nav.on { inset: 10px 0 auto; }
#nav.on .nav-bar { justify-content: center; }
#nav.on .nav-logo { opacity: 0; pointer-events: none; width: 0; overflow: hidden; }
#nav.on .nav-cta-btn { opacity: 0; pointer-events: none; width: 0; padding: 0; overflow: hidden; }
#nav.on .nav-pill { background: #0F1015; border: 1.5px solid rgba(255,255,255,.2); box-shadow: 0 8px 30px rgba(0,0,0,.65); height: 54px; }

.burger { display: none; flex-direction: column; gap: 5px; cursor: pointer; background: none; border: none; padding: 8px; }
.burger span { display: block; width: 24px; height: 2px; background: var(--text); border-radius: 2px; }

/* Mobile: pill nav becomes a burger, opening a full-screen vertical menu */
@media (max-width: 900px) {
  .burger { display: flex !important; }
  .nav-pill { display: none !important; }
  .nav-cta-btn { display: none !important; }
  .nav-logo img { height: 52px; }
  #nav { padding: 0; }
  #nav.on .nav-pill { display: none !important; }
}

.mob {
  display: none; position: fixed; inset: 78px 0 0; z-index: 290;
  background: rgba(9,9,12,.98); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 0;
  padding: 18px 22px 40px; overflow-y: auto;
}
.mob.open { display: flex; }
.mob a {
  font-family: 'Fraunces', Georgia, serif; font-size: 1.5rem; font-weight: 600; color: var(--text);
  text-align: left; padding: 16px 8px; border-bottom: 1px solid var(--bdr);
  transition: color var(--t), padding-left var(--t);
}
.mob a:hover, .mob a:active { color: var(--blue); padding-left: 16px; }
.mob a.mob-cta {
  margin-top: 20px; border: none; background: var(--blue); color: #fff; text-align: center;
  border-radius: 100px; font-size: 1.05rem; padding: 15px 24px; font-family: 'Hanken Grotesk', sans-serif; font-weight: 600;
}
.mob a.mob-cta:hover { padding-left: 24px; }

/* ----------------------------------------------------------------------------
   5. APP SHELL — persistent left sidebar + main content column
   Only "Mutual Funds" is enabled; every other item is a disabled
   "Coming Soon" state, styled consistently rather than hidden.
---------------------------------------------------------------------------- */
.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  min-height: calc(100vh - var(--nav-clearance));
  padding-top: var(--nav-clearance); /* nav is fixed/out-of-flow, so the shell needs its own clearance */
}

.sidebar {
  position: sticky;
  top: var(--nav-clearance);
  height: calc(100vh - var(--nav-clearance));
  background: var(--color-surface);
  border-right: 1px solid var(--color-border);
  padding: var(--space-6) var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
  overflow-y: auto;
}

.sidebar-label {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted);
  padding-inline: var(--space-3);
  margin-bottom: var(--space-2);
}

.sidebar-nav { display: flex; flex-direction: column; gap: var(--space-1); }

.sidebar-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: 11px var(--space-3);
  border-radius: var(--radius-sm);
  color: var(--color-muted);
  font-size: 0.92rem;
  font-weight: 500;
  transition: background var(--duration-fast) var(--ease-out), color var(--duration-fast) var(--ease-out);
}

.sidebar-item .item-left { display: flex; align-items: center; gap: var(--space-3); }
.sidebar-item .icon { width: 18px; height: 18px; flex-shrink: 0; opacity: 0.85; }

.sidebar-item.is-enabled:hover,
.sidebar-item.is-enabled.is-active {
  background: var(--color-card);
  color: var(--color-text);
}
.sidebar-item.is-enabled.is-active { box-shadow: inset 2px 0 0 var(--color-blue); }

.sidebar-item.is-disabled {
  cursor: not-allowed;
  color: #5B5D6E;
}

.badge-soon {
  font-size: 0.62rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  background: rgba(150, 152, 172, 0.12);
  color: var(--color-muted);
  white-space: nowrap;
}

.sidebar-footer-note {
  margin-top: auto;
  font-size: 0.78rem;
  color: var(--color-muted);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: var(--color-card);
  border: 1px solid var(--color-border-soft);
}

.main-content {
  min-width: 0; /* prevents grid blowout with wide children */
  position: relative;
}

/* ----------------------------------------------------------------------------
   6. HERO SECTION — animated gradient backdrop + floating financial glyphs
---------------------------------------------------------------------------- */
.hero {
  position: relative;
  padding: var(--space-9) var(--space-5) var(--space-8);
  overflow: hidden;
  isolation: isolate;
  text-align: center;
}

/* Ambient animated gradient glow, layered behind all hero content */
.hero-backdrop {
  position: absolute;
  inset: -10% -10% auto -10%;
  height: 620px;
  z-index: -2;
  background:
    radial-gradient(480px 320px at 22% 20%, rgba(42, 143, 206, 0.28), transparent 70%),
    radial-gradient(420px 300px at 78% 30%, rgba(237, 32, 36, 0.18), transparent 70%);
  filter: blur(10px);
  animation: drift 16s ease-in-out infinite alternate;
}

@keyframes drift {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  100% { transform: translate3d(2%, 3%, 0) scale(1.06); }
}

/* Floating financial particle field — populated by JS with ₹ / % / ▲ / chart glyphs */
.particle-field {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.particle {
  position: absolute;
  color: var(--color-blue);
  opacity: 0.14;
  font-family: var(--font-display);
  font-weight: 600;
  will-change: transform, opacity;
  animation: floatParticle linear infinite;
}
.particle.is-red { color: var(--color-red); }

@keyframes floatParticle {
  0%   { transform: translateY(0) rotate(0deg); opacity: 0; }
  10%  { opacity: 0.16; }
  90%  { opacity: 0.16; }
  100% { transform: translateY(-140px) rotate(12deg); opacity: 0; }
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 7px 16px;
  border-radius: var(--radius-pill);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  color: var(--color-muted);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: var(--space-5);
}
.hero-eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--color-blue);
  box-shadow: 0 0 8px 1px var(--color-blue);
  animation: pulseDot 1.8s ease-in-out infinite;
}
@keyframes pulseDot { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  max-width: 880px;
  margin-inline: auto;
  color: var(--color-text);
}

.hero h1 .accent { color: var(--color-blue); }

.hero-subtitle {
  margin-top: var(--space-4);
  font-size: 1.15rem;
  color: var(--color-muted);
  max-width: 620px;
  margin-inline: auto;
}

.hero-tagline {
  margin-top: var(--space-3);
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--color-text);
}
.hero-tagline::before, .hero-tagline::after { content: '"'; color: var(--color-blue); }

.hero-actions {
  margin-top: var(--space-6);
  display: flex;
  gap: var(--space-4);
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 13px 26px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform var(--duration-fast) var(--ease-out), box-shadow var(--duration-fast) var(--ease-out), background var(--duration-fast) var(--ease-out);
}
.btn-primary { background: var(--color-blue); color: var(--color-white); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--glow-blue); }
.btn-secondary { background: transparent; color: var(--color-text); border: 1px solid var(--color-border); }
.btn-secondary:hover { border-color: var(--color-red); color: var(--color-red); box-shadow: var(--glow-red); }

/* ----------------------------------------------------------------------------
   7. RISK PROFILE GATE — appears right after the hero; search stays
   locked until the client selects and submits a risk profile.
---------------------------------------------------------------------------- */
.risk-gate-section { padding: 0 var(--space-5) var(--space-7); display: flex; justify-content: center; }

.risk-gate-card {
  max-width: 620px;
  width: 100%;
  background: var(--color-card);
  border: 1px solid var(--color-border-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: var(--space-6);
  text-align: center;
}
.risk-gate-card h2 { font-size: 1.4rem; color: var(--color-text); margin-bottom: var(--space-2); }
.risk-gate-sub { color: var(--color-muted); font-size: 0.92rem; margin-bottom: var(--space-5); line-height: 1.55; }

#riskProfileSelect {
  width: 100%;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 0.95rem;
  margin-bottom: var(--space-4);
  transition: border-color var(--duration-fast) var(--ease-out);
}
#riskProfileSelect:focus { outline: none; border-color: var(--color-blue); box-shadow: var(--glow-blue); }
#riskProfileSelect option { background: var(--color-surface); color: var(--color-text); }

#riskProfileSubmit { width: 100%; justify-content: center; }
#riskProfileSubmit:disabled { opacity: 0.45; cursor: not-allowed; }
#riskProfileSubmit:disabled:hover { transform: none; box-shadow: none; }

.risk-profile-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0 auto var(--space-4);
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: var(--color-card);
  border: 1px solid var(--color-blue-dim);
  color: var(--color-blue);
  font-size: 0.85rem;
  font-weight: 600;
  width: fit-content;
}
.risk-profile-badge button {
  color: var(--color-muted);
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: underline;
}
.risk-profile-badge button:hover { color: var(--color-text); }

/* ----------------------------------------------------------------------------
   8. SEARCH AREA
---------------------------------------------------------------------------- */
.search-section { padding: 0 var(--space-5) var(--space-8); }

.search-box {
  max-width: 720px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 8px 8px 8px 22px;
  border-radius: var(--radius-pill);
  background: var(--color-glass);
  border: 1px solid var(--color-border);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  transition: box-shadow var(--duration-base) var(--ease-out), border-color var(--duration-base) var(--ease-out);
}
.search-box:focus-within {
  border-color: var(--color-blue);
  box-shadow: var(--glow-blue);
}

.search-box .icon { width: 20px; height: 20px; color: var(--color-muted); flex-shrink: 0; }

.search-box input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 1rem;
  padding-block: var(--space-2);
}
.search-box input::placeholder { color: var(--color-muted); }

.search-box button {
  padding: 12px 24px;
  border-radius: var(--radius-pill);
  background: var(--color-blue);
  color: var(--color-white);
  font-weight: 600;
  font-size: 0.9rem;
  white-space: nowrap;
  transition: transform var(--duration-fast) var(--ease-out);
}
.search-box button:hover { transform: translateY(-1px); box-shadow: var(--glow-blue); }

.search-hint {
  text-align: center;
  margin-top: var(--space-3);
  font-size: 0.82rem;
  color: var(--color-muted);
}

/* ----------------------------------------------------------------------------
   9. SECTION HEADERS (shared by Quick Access + Dashboard sections)
---------------------------------------------------------------------------- */
.section { padding: var(--space-7) var(--space-5); }

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
  flex-wrap: wrap;
}

.section-header h2 { font-size: 1.6rem; color: var(--color-text); }
.section-header p  { color: var(--color-muted); margin-top: var(--space-1); font-size: 0.95rem; }

.section-link {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-blue);
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  transition: gap var(--duration-fast) var(--ease-out);
}
.section-link:hover { gap: var(--space-2); }

/* ----------------------------------------------------------------------------
   10. QUICK ACCESS CARDS
---------------------------------------------------------------------------- */
.quick-access-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-5);
}

.access-card {
  position: relative;
  padding: var(--space-6) var(--space-5);
  border-radius: var(--radius-lg);
  background: var(--color-card);
  border: 1px solid var(--color-border-soft);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out),
              border-color var(--duration-base) var(--ease-out);
}

/* Signature hover glow sweep — subtle, brand-colored, appears only on hover */
.access-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, var(--color-blue), transparent 40%);
  opacity: 0;
  transition: opacity var(--duration-base) var(--ease-out);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.access-card.is-enabled:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-card-hover), var(--glow-blue);
  border-color: transparent;
}
.access-card.is-enabled:hover::before { opacity: 1; }

.access-card.is-disabled { opacity: 0.7; }
.access-card.is-disabled:hover { transform: translateY(-2px); }

.access-icon {
  width: 48px; height: 48px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--color-blue-dim), transparent);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: var(--space-4);
}
.access-icon svg { width: 24px; height: 24px; color: var(--color-blue); }

.access-card h3 {
  font-size: 1.15rem;
  color: var(--color-text);
  margin-bottom: var(--space-2);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.access-card p {
  font-size: 0.9rem;
  color: var(--color-muted);
  line-height: 1.55;
}

.access-card .card-cta {
  margin-top: var(--space-4);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-blue);
}
.access-card.is-disabled .card-cta { color: var(--color-muted); }

/* ----------------------------------------------------------------------------
   11. DASHBOARD WIDGETS — glass cards with skeleton / shimmer loading state
---------------------------------------------------------------------------- */
.widget-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-5);
}

.widget-card {
  border-radius: var(--radius-lg);
  background: var(--color-glass);
  border: 1px solid var(--color-border-soft);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow-card);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  transition: transform var(--duration-base) var(--ease-out), box-shadow var(--duration-base) var(--ease-out);
}
.widget-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-card-hover); }

.widget-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.widget-header h4 { font-size: 1rem; color: var(--color-text); font-family: var(--font-body); font-weight: 700; }
.widget-header .widget-tag {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-muted);
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--color-border);
}

/* Skeleton rows used as content placeholders inside widgets */
.skeleton-row {
  height: 14px;
  border-radius: var(--radius-sm);
  background: linear-gradient(90deg, var(--color-card) 25%, var(--color-card-hover) 37%, var(--color-card) 63%);
  background-size: 400% 100%;
  animation: shimmer 1.6s ease-in-out infinite;
}
.skeleton-row.w-100 { width: 100%; }
.skeleton-row.w-80  { width: 80%; }
.skeleton-row.w-60  { width: 60%; }
.skeleton-row.w-40  { width: 40%; }

@keyframes shimmer {
  0%   { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.skeleton-stack { display: flex; flex-direction: column; gap: var(--space-3); }

.widget-empty {
  font-size: 0.85rem;
  color: var(--color-muted);
  padding: var(--space-3) 0;
}

/* ----------------------------------------------------------------------------
   12. FOOTER — copied verbatim from optionspectrum.com (OS_Website.zip)
---------------------------------------------------------------------------- */
footer { background: var(--obs); border-top: 1px solid var(--bdr); padding: 64px 0 32px; }
.foot-grid { display: grid; grid-template-columns: 1.8fr 1fr 1.4fr 1fr; gap: 48px; margin-bottom: 52px; }
.foot-brand img { height: 60px; width: auto; margin-bottom: 14px; }
.foot-tagline { font-family: 'Fraunces', Georgia, serif; font-size: 1.15rem; font-style: italic; color: var(--muted); margin-bottom: 16px; line-height: 1.5; }
.arn-badge {
  display: inline-flex; align-items: center; gap: 8px; background: rgba(42,143,206,.07);
  border: 1px solid rgba(42,143,206,.16); border-radius: 6px; padding: 6px 13px;
  font-size: 12px; font-weight: 600; color: var(--blue); letter-spacing: .04em;
}
.foot-col h5 { font-family: 'Hanken Grotesk', sans-serif; font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--dim); margin-bottom: 18px; }
.foot-col ul { list-style: none; display: flex; flex-direction: column; gap: 11px; }
.foot-col a { color: var(--muted); font-size: 16px; transition: color var(--t); }
.foot-col a:hover { color: var(--text); }
.foot-contact-item { display: flex; align-items: flex-start; gap: 10px; font-size: 16px; color: var(--muted); line-height: 1.5; }
.foot-contact-item span.ic { color: var(--blue); flex-shrink: 0; }
.foot-cert { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.cert-badge { background: rgba(42,143,206,.06); border: 1px solid rgba(42,143,206,.14); border-radius: 6px; padding: 5px 12px; font-size: 12px; font-weight: 600; color: var(--blue); }
.foot-disc { border-top: 1px solid var(--bdr); padding: 24px 0; margin-top: 20px; font-size: 12px; color: var(--dim); line-height: 1.7; }
.foot-bottom { padding-top: 16px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
.foot-bottom p { font-size: 13px; color: var(--dim); }
.foot-legal-links { display: flex; flex-wrap: wrap; gap: 22px; padding-top: 24px; border-top: 1px solid var(--bdr); margin-bottom: 2px; }
.foot-legal-links a { font-size: 13.5px; color: var(--muted); font-weight: 500; transition: color var(--t); }
.foot-legal-links a:hover { color: var(--blue); }

.social-links { display: flex; gap: 12px; align-items: center; margin-top: 22px; }
.social-link {
  width: 38px; height: 38px; border-radius: 10px; background: var(--card); border: 1px solid var(--bdr);
  display: flex; align-items: center; justify-content: center; color: var(--muted);
  transition: background var(--t), border-color var(--t), color var(--t), transform var(--t);
}
.social-link:hover { transform: translateY(-3px); }
.social-link.ig:hover { background: rgba(225,48,108,.1); border-color: rgba(225,48,108,.3); color: #E1306C; }
.social-link.fb:hover { background: rgba(24,119,242,.1); border-color: rgba(24,119,242,.3); color: #1877F2; }
.social-link.li:hover { background: rgba(10,102,194,.1); border-color: rgba(10,102,194,.3); color: #0A66C2; }
.social-link.yt:hover { background: rgba(255,0,0,.1); border-color: rgba(255,0,0,.3); color: #FF0000; }
.social-link.x:hover { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.2); color: #fff; }
.social-link svg { width: 18px; height: 18px; }

/* ----------------------------------------------------------------------------
   13. RESPONSIVE — tablet & mobile
---------------------------------------------------------------------------- */
@media (max-width: 1080px) {
  .quick-access-grid { grid-template-columns: repeat(2, 1fr); }
  .widget-grid { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { grid-template-columns: 1.6fr 1fr 1fr; }
  .foot-grid .foot-col:last-child { display: none; }
}

@media (max-width: 900px) {
  .app-shell { grid-template-columns: 1fr; padding-top: calc(var(--nav-height) + var(--space-4)); }
  .sidebar {
    position: static;
    width: 100%;
    height: auto;
    border-right: none;
    border-bottom: 1px solid var(--color-border);
    padding: var(--space-4);
  }
  .sidebar-nav { flex-direction: row; overflow-x: auto; gap: var(--space-2); padding-bottom: var(--space-1); }
  .sidebar-item { flex-shrink: 0; }
  .sidebar-footer-note { display: none; } /* not useful in a horizontal mobile strip */
}

@media (max-width: 640px) {
  .quick-access-grid { grid-template-columns: 1fr; }
  .widget-grid { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-grid .foot-col:nth-child(3) { display: none; }
  .hero { padding: var(--space-7) var(--space-4) var(--space-6); }
  .section { padding: var(--space-6) var(--space-4); }
  .search-box { flex-wrap: wrap; padding: 14px; border-radius: var(--radius-lg); }
  .search-box button { width: 100%; justify-content: center; }
  .foot-bottom { flex-direction: column; align-items: flex-start; }
}

/* ----------------------------------------------------------------------------
   14. RATING TAGS — shared across Fund Detail and Mutual Fund Search pages
   so a "Strong Pick" looks identical everywhere it appears.
---------------------------------------------------------------------------- */
.rating-tag {
  display: inline-flex;
  align-items: center;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}
.tag-strong-pick       { background: rgba(52,211,153,0.15);  color: var(--color-positive); }
.tag-good-option       { background: rgba(42,143,206,0.15);  color: var(--color-blue); }
.tag-worth-considering { background: rgba(250,204,21,0.15);  color: var(--color-warning); }
.tag-caution           { background: rgba(237,32,36,0.15);   color: var(--color-red); }
.tag-insufficient      { background: rgba(150,152,172,0.15); color: var(--color-muted); }

/* ----------------------------------------------------------------------------
   15. TOAST — brief confirmation shown for "Coming Soon" interactions
---------------------------------------------------------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: var(--space-6);
  transform: translate(-50%, 16px);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 12px 20px;
  border-radius: var(--radius-pill);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-card);
  color: var(--color-text);
  font-size: 0.88rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-base) var(--ease-out), transform var(--duration-base) var(--ease-out);
  z-index: 200;
  white-space: nowrap;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.toast .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--color-blue); }

/* ----------------------------------------------------------------------------
   16. BACK TO TOP BUTTON
---------------------------------------------------------------------------- */
.back-to-top {
  position: fixed;
  right: var(--space-5);
  bottom: var(--space-5);
  width: 46px; height: 46px;
  border-radius: 50%;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-card);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity var(--duration-base) var(--ease-out), transform var(--duration-base) var(--ease-out), box-shadow var(--duration-fast) var(--ease-out);
  z-index: 80;
}
.back-to-top.is-visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.back-to-top:hover { box-shadow: var(--glow-blue); border-color: transparent; }
.back-to-top svg { width: 18px; height: 18px; }
