/* =========================================================================
   ATLAS V2.0 — MODERN HIGH-LUMINOSITY DESIGN SYSTEM & STYLESHEET
   Aesthetics: Deep Cosmic Obsidian + Frosted Glass + Radiant Status Lighting
   ========================================================================= */

/* ---------- 1. Design Tokens ---------- */
:root {
  /* Cosmic Obsidian Dark Surfaces */
  --bg-base:          #070a12;
  --bg-base-alt:      #0b0f19;
  --bg-surface:       #0f1626;
  --bg-surface-elev:  #141d33;
  --bg-surface-hover: #1b2744;
  --bg-glass:         rgba(15, 22, 38, 0.75);
  --bg-glass-card:    rgba(20, 29, 51, 0.65);
  --bg-glass-input:   rgba(10, 15, 26, 0.7);

  /* Luminous Borders & Glass Rims */
  --line-subtle:      rgba(255, 255, 255, 0.07);
  --line-glass:       rgba(255, 255, 255, 0.12);
  --line-bright:      rgba(255, 255, 255, 0.22);
  --line-focus:       #00e5ff;

  /* Typography Colors */
  --text-pure:        #ffffff;
  --text-primary:     #f8fafc;
  --text-secondary:   #94a3b8;
  --text-muted:       #64748b;
  --text-disabled:    #475569;

  /* Radiant Status & Accent Lighting */
  --accent-emerald:   #00e676;
  --accent-emerald-glow: rgba(0, 230, 118, 0.35);
  --accent-cyan:      #00e5ff;
  --accent-cyan-glow: rgba(0, 229, 255, 0.35);
  --accent-amber:     #fbbf24;
  --accent-amber-glow: rgba(251, 191, 36, 0.35);
  --accent-purple:    #818cf8;
  --accent-danger:    #f43f5e;

  /* Cinema Status Specifics */
  --color-watched:    #00e676;
  --color-watchlist:  #00e5ff;
  --color-unmarked:   #2a354a;

  /* Typography Scales */
  --font-display:     "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  --font-body:        "Inter", system-ui, -apple-system, sans-serif;
  --font-mono:        "JetBrains Mono", "IBM Plex Mono", monospace;

  /* Radii & Shadows */
  --radius-xs:        4px;
  --radius-sm:        8px;
  --radius-md:        12px;
  --radius-lg:        16px;
  --radius-xl:        22px;
  --radius-full:      9999px;

  --shadow-glass:     0 8px 32px rgba(0, 0, 0, 0.45);
  --shadow-elevated:  0 16px 48px rgba(0, 0, 0, 0.6);
  --shadow-glow-cyan: 0 0 24px rgba(0, 229, 255, 0.2);
  --shadow-glow-emerald: 0 0 24px rgba(0, 230, 118, 0.2);

  /* Legacy Variable Aliases for Script Compatibility */
  --ink:              var(--bg-base);
  --ink-raised:       var(--bg-surface);
  --ink-panel:        var(--bg-surface-elev);
  --line:             var(--line-subtle);
  --paper:            var(--text-primary);
  --paper-dim:        var(--text-secondary);
  --brass:            var(--accent-amber);
  --brass-dim:        rgba(251, 191, 36, 0.5);
  --emerald-glow:     var(--accent-emerald-glow);
  --cyan-accent:      var(--accent-cyan);
  --blue-watchlist:   var(--accent-cyan);
  --green-watched:    var(--accent-emerald);
  --gray-none:        var(--color-unmarked);
  --red:              var(--accent-danger);
  --radius:           var(--radius-sm);
}

/* ---------- 2. Base Reset & Structure ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

[hidden] {
  display: none !important;
}

/* Lucide Icon Integration */
.lucide, svg.lucide {
  display: inline-block;
  vertical-align: middle;
  stroke-width: 2px;
  stroke: currentColor;
  fill: none;
  flex-shrink: 0;
}

.brand-emblem-icon .lucide {
  width: 20px;
  height: 20px;
  color: var(--accent-cyan, #00e5ff);
}

.tab-btn__icon .lucide {
  width: 16px;
  height: 16px;
}

.action-icon .lucide {
  width: 16px;
  height: 16px;
}

.dropdown-icon .lucide {
  width: 15px;
  height: 15px;
  color: var(--text-secondary);
}

.user-dropdown-item:hover .dropdown-icon .lucide {
  color: #ffffff;
}

.user-dropdown-item--danger .dropdown-icon .lucide {
  color: #f87171;
}

.view-hero-badge .lucide {
  width: 14px;
  height: 14px;
  margin-right: 6px;
  vertical-align: -2px;
}

.metric-icon-badge .lucide {
  width: 24px;
  height: 24px;
}

.feature-card-icon-box .lucide {
  width: 26px;
  height: 26px;
}

.modal-header-icon-wrap .lucide {
  width: 22px;
  height: 22px;
  color: var(--accent-cyan, #00e5ff);
}

.auth-modal-brand-badge .lucide {
  width: 36px;
  height: 36px;
  color: var(--accent-cyan, #00e5ff);
}

.dropzone-icon .lucide {
  width: 32px;
  height: 32px;
  color: var(--text-muted);
}

.globe-search__icon .lucide {
  width: 16px;
  height: 16px;
  color: var(--text-secondary);
}

.account-tab-btn .lucide {
  width: 15px;
  height: 15px;
}

.device-card-icon .lucide {
  width: 20px;
  height: 20px;
  color: var(--accent-cyan, #00e5ff);
}

html, body {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow: hidden;
  user-select: none;
}

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

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

:focus-visible {
  outline: 2px solid var(--accent-cyan);
  outline-offset: 2px;
}

/* Custom Sleek Dark Scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-cyan);
}

/* ---------- 3. Layout Shell ---------- */
body {
  display: flex;
  flex-direction: column;
}

.app-main {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
}

/* ---------- 4. Modern App Header & Navigation ---------- */
.app-header {
  position: relative;
  z-index: 100;
  padding: 10px 20px;
  background: rgba(7, 10, 18, 0.78);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line-subtle);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1440px;
  margin: 0 auto;
}

/* Brand Cluster */
.brand-cluster {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  text-decoration: none;
}
/* Brand Logo Emblem & Distinctive Wordmark */
.brand-cluster {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  text-decoration: none;
  user-select: none;
}

.brand-emblem {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(0, 229, 255, 0.12) 0%, rgba(15, 23, 42, 0.85) 100%);
  border: 1px solid rgba(0, 229, 255, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(0, 229, 255, 0.18), inset 0 0 12px rgba(0, 229, 255, 0.1);
  transition: all 220ms cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.brand-cluster:hover .brand-emblem {
  transform: scale(1.08) rotate(2deg);
  border-color: rgba(0, 229, 255, 0.7);
  box-shadow: 0 0 28px rgba(0, 229, 255, 0.4), inset 0 0 16px rgba(0, 229, 255, 0.2);
}

.brand-emblem-svg {
  width: 26px;
  height: 26px;
  display: block;
}

.brand-text {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Distinctive Unified Wordmark (Solid Luminous Monolithic Typography) */
.brand-wordmark {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.015em;
  line-height: 1;
  display: inline-flex;
  align-items: baseline;
  position: relative;
}

.wordmark-text {
  color: #ffffff;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 12px rgba(255, 255, 255, 0.25), 0 0 20px rgba(0, 229, 255, 0.18);
}

/* Destination Pin Dot Accent */
.wordmark-pin-dot {
  display: inline-block;
  width: 5px;
  height: 5px;
  margin-left: 4px;
  margin-bottom: 2px;
  align-self: flex-end;
  background: #00e5ff;
  border-radius: 50%;
  box-shadow: 0 0 8px #00e5ff, 0 0 16px rgba(0, 229, 255, 0.8);
  animation: pinPulse 2.4s ease-in-out infinite;
}

@keyframes pinPulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 8px #00e5ff, 0 0 14px rgba(0, 229, 255, 0.6);
  }
  50% {
    transform: scale(1.35);
    background: #38bdf8;
    box-shadow: 0 0 14px #00e5ff, 0 0 24px rgba(0, 229, 255, 0.9);
  }
}

.brand-badge {
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--accent-cyan);
  background: rgba(0, 229, 255, 0.08);
  padding: 3px 7px;
  border-radius: var(--radius-xs);
  border: 1px solid rgba(0, 229, 255, 0.22);
  box-shadow: 0 0 10px rgba(0, 229, 255, 0.1);
  text-transform: uppercase;
}

/* Center Nav Island (Pill Control) */
.nav-island, .marquee__tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(15, 22, 38, 0.65);
  border: 1px solid var(--line-glass);
  padding: 4px;
  border-radius: var(--radius-full);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}
.tab-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 16px;
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: all 180ms ease;
}
.tab-btn__icon {
  font-size: 14px;
  opacity: 0.8;
}
.tab-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
}
.tab-btn.is-active {
  color: #ffffff;
  background: linear-gradient(135deg, rgba(0, 229, 255, 0.22) 0%, rgba(14, 165, 233, 0.15) 100%);
  border: 1px solid rgba(0, 229, 255, 0.4);
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.2);
}
.tab-btn.is-active .tab-btn__icon {
  opacity: 1;
}

/* Right Nav Actions */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.btn-action-glow, .btn-icon-nav#nav-challenge {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
  border: 1px solid rgba(129, 140, 248, 0.5);
  color: #ffffff;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
  transition: transform 160ms ease, box-shadow 160ms ease;
}
.btn-action-glow:hover, .btn-icon-nav#nav-challenge:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}
.btn-action-glass, .btn-icon-nav:not(#nav-challenge) {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 13px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line-glass);
  color: var(--text-primary);
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 500;
  transition: all 160ms ease;
}
.btn-action-glass:hover, .btn-icon-nav:not(#nav-challenge):hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
  transform: translateY(-1px);
}
.btn-action-pro {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, rgba(0, 229, 255, 0.15) 0%, rgba(129, 140, 248, 0.2) 100%);
  border: 1px solid rgba(0, 229, 255, 0.4);
  color: #00e5ff;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.2);
  transition: all 160ms ease;
}
.btn-action-pro:hover {
  background: linear-gradient(135deg, #00e5ff 0%, #00b4d8 100%);
  color: #05070d;
  box-shadow: 0 0 24px rgba(0, 229, 255, 0.5);
  transform: translateY(-1px);
}
.btn-action-icon-only {
  padding: 7px 10px;
}

/* Globe Hero Value Proposition Pill */
.globe-hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(11, 16, 28, 0.85);
  border: 1px solid rgba(0, 229, 255, 0.3);
  padding: 6px 18px;
  border-radius: var(--radius-full);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.45);
  text-align: center;
  pointer-events: auto;
  white-space: nowrap;
}
.globe-hero-title {
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.01em;
}
.globe-hero-sub {
  font-size: 11px;
  color: var(--accent-cyan);
  font-weight: 600;
}

/* App Legal & Compliance Glass Footer */
.app-glass-footer {
  margin-top: 48px;
  padding: 24px 28px;
  background: rgba(11, 16, 28, 0.65);
  border: 1px solid var(--line-subtle);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}
.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.footer-tagline {
  font-size: 12px;
  color: var(--text-muted);
}
.footer-nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.footer-nav-links a {
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.15s ease;
  display: flex;
  align-items: center;
  gap: 5px;
}
.footer-nav-links a:hover {
  color: #00e5ff;
}
.footer-nav-links .footer-pro-link {
  color: #00e5ff;
  font-weight: 700;
}

/* ---------- 6. General View System ---------- */
.view {
  position: absolute;
  inset: 0;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 220ms ease, visibility 220ms ease;
}
.view.is-active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.list-view {
  overflow-y: auto;
  padding: 32px 24px 60px;
  background: radial-gradient(circle at 50% 0%, #10172a 0%, #070a12 60%);
}
.list-container {
  max-width: 1280px;
  margin: 0 auto;
}

/* View Hero Header */
.view-hero-header, .list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line-subtle);
}

.view-hero-info {
  flex: 1;
  min-width: 240px;
}

.view-hero-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-cyan);
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}

.view-hero-title, .list-header h2 {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
  line-height: 1.15;
}

.view-hero-desc, .list-header p {
  color: var(--text-secondary);
  font-size: 13.5px;
  margin-top: 6px;
  line-height: 1.4;
}

.view-hero-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  justify-content: flex-end;
}

#btn-toggle-all-watched,
#btn-toggle-all-watchlist {
  min-width: 124px;
  justify-content: center;
}

@media (max-width: 960px) {
  .view-hero-header, .list-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .view-hero-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 8px;
  }
}

/* ---------- 7. Buttons Design System ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-md);
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: all 180ms ease;
  white-space: nowrap;
}
.btn-primary {
  background: linear-gradient(135deg, #00e676 0%, #00c853 100%);
  color: #061e11;
  font-weight: 700;
  border: 1px solid rgba(0, 230, 118, 0.4);
  box-shadow: 0 4px 16px var(--accent-emerald-glow);
}
.btn-primary:hover {
  transform: translateY(-1.5px);
  box-shadow: 0 6px 24px rgba(0, 230, 118, 0.45);
  background: linear-gradient(135deg, #0df582 0%, #00e676 100%);
}
.btn-glow {
  position: relative;
}
.btn-glow::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: inherit;
  filter: blur(8px);
  opacity: 0.4;
  z-index: -1;
  transition: opacity 180ms ease;
}
.btn-glow:hover::after {
  opacity: 0.7;
}
.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line-glass);
  color: var(--text-primary);
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
  transform: translateY(-1px);
}
.btn-danger {
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.4);
  color: #fda4af;
}
.btn-danger:hover {
  background: rgba(244, 63, 94, 0.28);
  border-color: rgba(244, 63, 94, 0.7);
  color: #ffffff;
}
.btn-sm {
  padding: 8px 15px;
  font-size: 12.5px;
}
.btn-xs {
  padding: 5px 10px;
  font-size: 11.5px;
  border-radius: var(--radius-sm);
}

/* ---------- 8. 3D Globe HUD & Search Bar ---------- */
#panel-globe {
  background: #000000 !important;
}
#globe-mount {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: #000000 !important;
}
#globe-mount canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
  outline: none;
}

/* Floating 3D Search Bar */
.globe-search {
  position: absolute;
  top: 20px;
  left: 24px;
  z-index: 50;
  width: 320px;
  max-width: calc(100vw - 48px);
}
.globe-search__bar {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(15, 22, 38, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-full);
  padding: 8px 16px;
  box-shadow: var(--shadow-glass);
  transition: all 200ms ease;
}
.globe-search__bar:focus-within {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 24px rgba(0, 229, 255, 0.3), var(--shadow-glass);
  background: rgba(18, 27, 48, 0.95);
}
.globe-search__icon {
  font-size: 14px;
  opacity: 0.7;
}
.globe-search__input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  color: #ffffff;
  font-size: 13.5px;
}
.globe-search__input::placeholder {
  color: var(--text-muted);
}
.globe-search__clear {
  color: var(--text-secondary);
  font-size: 13px;
  padding: 2px 6px;
  border-radius: var(--radius-full);
}
.globe-search__clear:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

/* Autocomplete Results Dropdown */
.globe-search__results {
  list-style: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: rgba(15, 22, 38, 0.95);
  backdrop-filter: blur(20px);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-lg);
  max-height: 340px;
  overflow-y: auto;
  box-shadow: var(--shadow-elevated);
  display: none;
  z-index: 99999;
}
.globe-search__results.is-open {
  display: block;
  animation: pop-in 180ms cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes pop-in {
  0% { opacity: 0; transform: translateY(-6px) scale(0.98); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
.globe-search__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  transition: background 120ms ease;
}
.globe-search__item:last-child {
  border-bottom: none;
}
.globe-search__item:hover, .globe-search__item.is-selected {
  background: rgba(0, 229, 255, 0.12);
}
.globe-search__item-left {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13.5px;
  font-weight: 500;
  color: #ffffff;
}
.globe-search__item-flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 16px;
  border-radius: 2px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.4);
}
.globe-search__item-flag-img {
  width: 22px !important;
  height: 15px !important;
  object-fit: cover !important;
  border-radius: 2px !important;
  display: inline-block !important;
  vertical-align: middle !important;
}
.globe-search__match {
  color: var(--accent-cyan);
  font-weight: 700;
}
.globe-search__item-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-emerald);
  background: rgba(0, 230, 118, 0.12);
  padding: 2px 7px;
  border-radius: var(--radius-xs);
  border: 1px solid rgba(0, 230, 118, 0.25);
}
.globe-search__item-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.globe-search__item-dot--watched {
  background: var(--accent-emerald);
  box-shadow: 0 0 8px var(--accent-emerald);
}
.globe-search__item-dot--watchlist {
  background: var(--accent-cyan);
  box-shadow: 0 0 8px var(--accent-cyan);
}
.globe-search__empty {
  padding: 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}

/* Floating Bottom HUD */
.globe-hud-bottom {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  z-index: 50;
  pointer-events: none;
  width: max-content;
  max-width: calc(100vw - 32px);
}
.globe-hud-controls-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}
.legend {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(15, 22, 38, 0.82);
  backdrop-filter: blur(16px);
  border: 1px solid var(--line-glass);
  padding: 7px 16px;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-glass);
  pointer-events: auto;
}
.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
}
.legend-swatch {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}
.legend-swatch--none { background: #111827; border: 1px solid rgba(255,255,255,0.25); }
.legend-swatch--watchlist { background: var(--accent-cyan); box-shadow: 0 0 8px var(--accent-cyan); }
.legend-swatch--watched { background: var(--accent-emerald); box-shadow: 0 0 8px var(--accent-emerald); }

.globe-hint {
  background: rgba(15, 22, 38, 0.7);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line-subtle);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 12px;
  color: var(--text-secondary);
  box-shadow: var(--shadow-glass);
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: auto;
  transition: opacity 300ms ease;
}
.hint-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-cyan);
  box-shadow: 0 0 6px var(--accent-cyan);
}

/* Floating Projection Toggle (3D Globe vs 2D Map) */
.globe-projection-toggle {
  position: absolute;
  top: 20px;
  right: 24px;
  z-index: 50;
}

@media (max-width: 768px) {
  .globe-projection-toggle {
    top: 76px;
    right: 16px;
  }
  .globe-search {
    top: 16px;
    left: 16px;
    right: 16px;
    width: auto;
  }
}

/* 2D Flat Map Container & SVG Layer */
.map2d-mount {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: radial-gradient(ellipse at 50% 50%, #061126 0%, #020612 70%, #000208 100%);
  user-select: none;
  touch-action: none;
  cursor: grab;
}

.map2d-mount.is-panning {
  cursor: grabbing;
}

.map2d-svg {
  width: 100%;
  height: 100%;
  display: block;
  shape-rendering: geometricPrecision;
}

/* Graticule lines */
.map2d-graticule {
  stroke: rgba(0, 229, 255, 0.04);
  stroke-width: 0.8px;
  fill: none;
}

.map2d-equator {
  stroke: rgba(0, 229, 255, 0.12);
  stroke-width: 1.2px;
  stroke-dasharray: 4 3;
}

/* Country Polygons */
.map2d-country {
  transition: fill 200ms ease, stroke 180ms ease, filter 200ms ease;
  cursor: pointer;
  vector-effect: non-scaling-stroke;
}

.map2d-country.status-none {
  fill: #111d33;
  stroke: rgba(148, 163, 184, 0.22);
  stroke-width: 0.6px;
}

.map2d-country.status-watchlist {
  fill: rgba(0, 229, 255, 0.72);
  stroke: #00e5ff;
  stroke-width: 1.2px;
  filter: drop-shadow(0 0 6px rgba(0, 229, 255, 0.45));
}

.map2d-country.status-watched {
  fill: rgba(0, 230, 118, 0.82);
  stroke: #00e676;
  stroke-width: 1.4px;
  filter: drop-shadow(0 0 6px rgba(0, 230, 118, 0.5));
}

.map2d-country:hover {
  fill-opacity: 1;
  stroke: #ffffff !important;
  stroke-width: 1.8px !important;
  filter: brightness(1.25) drop-shadow(0 0 10px rgba(255, 255, 255, 0.6));
}

/* Micro-country pins on 2D map */
.map2d-micro-pin {
  cursor: pointer;
  transition: all 180ms ease;
}

.map2d-micro-pin.status-none {
  fill: #1e293b;
  stroke: rgba(148, 163, 184, 0.5);
  stroke-width: 0.8px;
}

.map2d-micro-pin.status-watchlist {
  fill: #00e5ff;
  stroke: #ffffff;
  stroke-width: 1.2px;
  filter: drop-shadow(0 0 6px #00e5ff);
}

.map2d-micro-pin.status-watched {
  fill: #00e676;
  stroke: #ffffff;
  stroke-width: 1.2px;
  filter: drop-shadow(0 0 6px #00e676);
}

.map2d-micro-pin:hover {
  r: 6;
  stroke: #ffffff;
  stroke-width: 2px;
}

/* 2D Map On-Screen Zoom Controls */
.map2d-zoom-controls {
  position: absolute;
  bottom: 24px;
  right: 24px;
  z-index: 50;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.map2d-zoom-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: rgba(15, 22, 38, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line-glass);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 160ms ease;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.map2d-zoom-btn:hover {
  background: rgba(0, 229, 255, 0.15);
  border-color: rgba(0, 229, 255, 0.4);
  color: var(--accent-cyan);
  transform: translateY(-1px);
}

.map2d-zoom-btn svg,
.map2d-zoom-btn i {
  width: 16px;
  height: 16px;
}

/* Floating Hover Tooltip (Shared across 3D Globe & 2D Map) */
.country-label {
  position: fixed !important;
  pointer-events: none !important;
  z-index: 99999 !important;
  background: rgba(10, 15, 26, 0.92) !important;
  backdrop-filter: blur(14px) !important;
  -webkit-backdrop-filter: blur(14px) !important;
  border: 1px solid rgba(0, 229, 255, 0.6) !important;
  color: #ffffff !important;
  padding: 6px 14px !important;
  border-radius: var(--radius-full) !important;
  font-family: var(--font-display) !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  letter-spacing: 0.01em !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6), 0 0 16px rgba(0, 229, 255, 0.25) !important;
  transform: translate(-50%, -140%) !important;
  white-space: nowrap !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 7px !important;
}

.country-label[hidden] {
  display: none !important;
}

/* ---------- 9. Empty States (High Luminosity Cards) ---------- */
.empty-state-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: radial-gradient(circle at 50% 30%, rgba(0, 229, 255, 0.08) 0%, rgba(15, 22, 38, 0.7) 100%);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-xl);
  padding: 64px 32px;
  margin: 32px 0;
  box-shadow: var(--shadow-glass);
  position: relative;
  overflow: hidden;
}
.empty-state-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0, 229, 255, 0.6), transparent);
}
.empty-state-icon-box {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-lg);
  background: rgba(0, 229, 255, 0.1);
  border: 1px solid rgba(0, 229, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  margin-bottom: 20px;
  box-shadow: 0 0 24px rgba(0, 229, 255, 0.2);
}
.empty-state-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 8px;
}
.empty-state-desc {
  font-size: 14.5px;
  color: var(--text-secondary);
  max-width: 520px;
  line-height: 1.6;
  margin-bottom: 28px;
}
.empty-state-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ---------- 10. Country Groups (Collapsible Accordion & Stacked Thumbnails) ---------- */
.country-groups {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.country-group {
  background: var(--bg-glass-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--line-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.28);
  transition: border-color 220ms ease, box-shadow 220ms ease, background 220ms ease;
}

.country-group:hover {
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.country-group.is-open {
  border-color: rgba(0, 229, 255, 0.25);
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.45), 0 0 20px rgba(0, 229, 255, 0.05);
}

.country-group__head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 22px;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  user-select: none;
  transition: background 180ms ease;
}

.country-group__head:hover {
  background: rgba(255, 255, 255, 0.025);
}

.country-group.is-open .country-group__head {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.015);
}

.country-group__left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.country-group__flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 20px;
  border-radius: 3px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
  flex-shrink: 0;
}

.country-group__flag-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.country-group__name {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.country-group__right {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.country-group__preview-box {
  display: flex;
  align-items: center;
}

/* Stacked Thumbnails Preview */
.country-group__thumbnails {
  display: flex;
  align-items: center;
  padding-left: 6px;
}

.stacked-thumb {
  width: 24px;
  height: 36px;
  object-fit: cover;
  border-radius: 4px;
  border: 1.5px solid #0f172a;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.55);
  background: #1e293b;
  transition: transform 180ms ease, z-index 180ms ease;
  flex-shrink: 0;
}

.stacked-thumb:not(:first-child) {
  margin-left: -12px;
}

.stacked-thumb-1 { z-index: 3; }
.stacked-thumb-2 { z-index: 2; }
.stacked-thumb-3 { z-index: 1; }

.country-group__head:hover .stacked-thumb-1 {
  transform: translateY(-2px);
}
.country-group__head:hover .stacked-thumb-2 {
  transform: translateY(-2px) rotate(3deg);
}
.country-group__head:hover .stacked-thumb-3 {
  transform: translateY(-2px) rotate(6deg);
}

.country-group__count {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-cyan);
  background: rgba(0, 229, 255, 0.08);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(0, 229, 255, 0.22);
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.country-group__chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  transition: transform 240ms cubic-bezier(0.16, 1, 0.3, 1), background 180ms ease, color 180ms ease;
}

.country-group__chevron svg,
.country-group__chevron i {
  width: 16px;
  height: 16px;
  transition: transform 240ms cubic-bezier(0.16, 1, 0.3, 1);
}

.country-group__head:hover .country-group__chevron {
  background: rgba(0, 229, 255, 0.12);
  color: var(--accent-cyan);
}

.country-group.is-open .country-group__chevron svg,
.country-group.is-open .country-group__chevron i {
  transform: rotate(180deg);
  color: var(--accent-cyan);
}

.country-group__body {
  padding: 20px 22px 24px 22px;
  animation: expandFadeIn 220ms ease-out forwards;
}

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

/* List Live Search Bar (Watched & Watchlist) */
.list-search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.list-search-icon {
  position: absolute;
  left: 11px;
  color: var(--accent-cyan);
  pointer-events: none;
  display: flex;
  align-items: center;
}

.list-search-icon svg,
.list-search-icon i {
  width: 14px;
  height: 14px;
}

.list-search-input {
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-full);
  padding: 7px 28px 7px 32px;
  color: #ffffff;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 500;
  outline: none;
  width: 160px;
  transition: all 220ms ease;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

.list-search-input:focus {
  width: 210px;
  border-color: var(--accent-cyan);
  background: rgba(15, 23, 42, 0.98);
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.2), 0 4px 14px rgba(0, 0, 0, 0.4);
}

.list-search-input::placeholder {
  color: var(--text-muted);
  font-size: 12px;
}

.list-search-clear {
  position: absolute;
  right: 8px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 15px;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 50%;
  line-height: 1;
}

.list-search-clear:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

/* Segmented View Mode Switcher [ By Country | All Films ] */
.view-mode-segmented {
  display: inline-flex;
  align-items: center;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 2px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.view-mode-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  transition: all 180ms ease;
  white-space: nowrap;
  user-select: none;
}

.view-mode-btn svg,
.view-mode-btn i {
  width: 14px;
  height: 14px;
}

.view-mode-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
}

.view-mode-btn.is-active {
  background: rgba(0, 229, 255, 0.15);
  color: var(--accent-cyan);
  box-shadow: 0 2px 10px rgba(0, 229, 255, 0.22);
  border-color: rgba(0, 229, 255, 0.35);
  font-weight: 700;
}

/* Custom Luxury Select Component */
.lux-custom-select {
  position: relative;
  display: inline-block;
}

.lux-select-trigger {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  color: #ffffff;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  transition: all 180ms ease;
  user-select: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.lux-select-trigger:hover,
.lux-custom-select.is-open .lux-select-trigger {
  background: rgba(15, 23, 42, 0.95);
  border-color: var(--accent-cyan);
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.18), 0 4px 14px rgba(0, 0, 0, 0.4);
}

.lux-select-icon {
  color: var(--accent-cyan);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.lux-select-icon svg,
.lux-select-icon i {
  width: 15px;
  height: 15px;
}

.lux-select-label {
  letter-spacing: -0.01em;
}

.lux-select-chevron {
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 200ms ease;
  margin-left: 2px;
}

.lux-select-chevron svg,
.lux-select-chevron i {
  width: 14px;
  height: 14px;
}

.lux-custom-select.is-open .lux-select-chevron {
  transform: rotate(180deg);
  color: var(--accent-cyan);
}

.lux-select-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 270px;
  background: rgba(11, 17, 33, 0.96);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-lg);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.7), 0 0 24px rgba(0, 229, 255, 0.1);
  padding: 6px;
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 3px;
  animation: luxMenuFadeIn 180ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.lux-select-menu[hidden] {
  display: none !important;
}

@keyframes luxMenuFadeIn {
  from {
    opacity: 0;
    transform: translateY(-8px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.lux-select-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  background: transparent;
  border: none;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 140ms ease;
  width: 100%;
}

.lux-select-option:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #ffffff;
}

.lux-select-option.is-selected {
  background: rgba(0, 229, 255, 0.12);
  color: var(--accent-cyan);
  font-weight: 700;
}

.lux-select-option .opt-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: inherit;
  opacity: 0.85;
}

.lux-select-option .opt-icon svg,
.lux-select-option .opt-icon i {
  width: 15px;
  height: 15px;
}

.lux-select-option .opt-label {
  flex: 1;
  white-space: nowrap;
}

.lux-select-option .opt-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  color: var(--accent-cyan);
  transition: opacity 140ms ease;
}

.lux-select-option .opt-check svg,
.lux-select-option .opt-check i {
  width: 14px;
  height: 14px;
}

.lux-select-option.is-selected .opt-check {
  opacity: 1;
}

/* Flat Stream View Header */
.flat-stream-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  background: var(--bg-glass-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--line-subtle);
  border-radius: var(--radius-md);
  margin-bottom: 20px;
  box-shadow: var(--shadow-glass);
}

.flat-stream-count {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--accent-cyan);
  background: rgba(0, 229, 255, 0.1);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(0, 229, 255, 0.25);
  letter-spacing: 0.04em;
}

.flat-stream-count svg,
.flat-stream-count i {
  width: 13px;
  height: 13px;
}

.flat-stream-sub {
  font-size: 12.5px;
  color: var(--text-muted);
}

@media (max-width: 600px) {
  .country-group__head {
    padding: 13px 15px;
    gap: 10px;
  }
  .country-group__name {
    font-size: 15.5px;
  }
  .stacked-thumb {
    width: 20px;
    height: 30px;
  }
  .stacked-thumb:not(:first-child) {
    margin-left: -9px;
  }
  .country-group__right {
    gap: 8px;
  }
  .country-group__count {
    font-size: 10px;
    padding: 3px 8px;
  }
  .country-group__chevron {
    width: 24px;
    height: 24px;
  }
  .lux-select-menu {
    min-width: 230px;
  }
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 18px;
}
.movie-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-surface-elev);
  border: 1px solid var(--line-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  transition: all 200ms cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}
.movie-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-cyan);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.5), 0 0 16px rgba(0, 229, 255, 0.2);
}
.movie-card__poster-wrap {
  position: relative;
  width: 100%;
  padding-top: 150%; /* 2:3 aspect ratio */
  background: #0d1320;
  overflow: hidden;
}
.movie-card__poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 240ms ease;
}
.movie-card:hover .movie-card__poster {
  transform: scale(1.04);
}

/* Floating Flag Badge on Poster */
.movie-card__flag-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 17px;
  border-radius: 3px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.22);
  z-index: 2;
  transition: transform 180ms ease;
}

.movie-card__flag-badge img,
.movie-card__flag-badge svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.movie-card:hover .movie-card__flag-badge {
  transform: scale(1.08);
}

.movie-card__info {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.movie-card__title {
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-card__meta {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.movie-card__meta-flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 11px;
  border-radius: 2px;
  overflow: hidden;
  flex-shrink: 0;
}

.movie-card__meta-flag img,
.movie-card__meta-flag svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.movie-card__meta-country {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-card__meta-dot {
  color: rgba(255, 255, 255, 0.25);
  font-weight: bold;
}

/* ---------- 11. Passport & Stats Dashboard ---------- */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}
.metric-card {
  background: var(--bg-glass-card);
  backdrop-filter: blur(16px);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-glass);
  position: relative;
  overflow: hidden;
  transition: transform 180ms ease, border-color 180ms ease;
}
.metric-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.25);
}
.metric-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
}
.metric-card--gauge {
  flex-direction: row;
  align-items: center;
  gap: 20px;
}
.metric-gauge-wrapper {
  position: relative;
  width: 84px;
  height: 84px;
  flex-shrink: 0;
}
.metric-gauge-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.metric-gauge-text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 800;
  color: var(--accent-emerald);
}
.metric-number {
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: 800;
  line-height: 1;
  color: #ffffff;
}
.metric-number--rank {
  font-size: 26px;
  color: var(--accent-amber);
}
.metric-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 6px;
}
.metric-sub-badge {
  display: inline-block;
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-cyan);
  background: rgba(0, 229, 255, 0.1);
  padding: 2px 8px;
  border-radius: var(--radius-xs);
  border: 1px solid rgba(0, 229, 255, 0.25);
}
.metric-footer-text {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}
.metric-icon-badge {
  font-size: 22px;
  margin-bottom: 12px;
}

/* Feature Cards (Roll, Challenge, Data) */
.feature-card {
  background: var(--bg-glass-card);
  backdrop-filter: blur(16px);
  border: 1px solid var(--line-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-glass);
}
.feature-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.feature-card-icon-box {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: rgba(0, 229, 255, 0.1);
  border: 1px solid rgba(0, 229, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}
.feature-card-icon-box--purple {
  background: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.4);
}
.feature-card-text {
  flex: 1;
  min-width: 260px;
}
.feature-card-title {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 700;
  color: #ffffff;
}
.feature-card-desc {
  font-size: 13.5px;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* ---------- 2-Step Roll the Globe & Film Roulette ---------- */
.suggestion-tray {
  margin-top: 20px;
  padding: 0;
  background: transparent;
  border: none;
}
.roll-country-card {
  padding: 22px;
  background: rgba(10, 16, 28, 0.92);
  border: 1px solid rgba(0, 229, 255, 0.25);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 20px rgba(0, 229, 255, 0.08);
  animation: fadeIn 300ms cubic-bezier(0.16, 1, 0.3, 1);
}
.roll-country-top {
  display: flex;
  align-items: center;
  gap: 18px;
}
.roll-country-flag {
  font-size: 48px;
  line-height: 1;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
}
.roll-country-meta {
  flex: 1;
}
.roll-step-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-cyan);
  letter-spacing: 0.08em;
}
.roll-country-title {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  margin: 2px 0 6px;
}
.roll-country-sub {
  display: flex;
  align-items: center;
  gap: 8px;
}
.roll-divider {
  height: 1px;
  background: linear-gradient(90deg, rgba(0, 229, 255, 0.3), rgba(255, 255, 255, 0.06), transparent);
  margin: 18px 0;
}
.roll-step2-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.roll-step2-prompt {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(15, 23, 42, 0.6);
  padding: 12px 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line-subtle);
}
.roll-step2-icon {
  font-size: 28px;
}
.roll-step2-title {
  font-size: 14.5px;
  font-weight: 700;
  color: #ffffff;
}
.roll-step2-desc {
  font-size: 12.5px;
  color: var(--text-secondary);
}
.roll-actions-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.roll-winner-card {
  display: flex;
  gap: 20px;
  margin-top: 18px;
  padding: 18px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(0, 230, 118, 0.3);
  border-radius: var(--radius-md);
  box-shadow: 0 0 24px rgba(0, 230, 118, 0.12);
  animation: slideUp 300ms cubic-bezier(0.16, 1, 0.3, 1);
}
.roll-winner-poster-wrap {
  width: 110px;
  min-width: 110px;
  height: 165px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.15);
}
.roll-winner-poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.roll-winner-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.roll-winner-tag {
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 700;
  color: var(--accent-emerald);
  letter-spacing: 0.08em;
}
.roll-winner-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: #ffffff;
  margin: 4px 0 8px;
}
.roll-winner-badges {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.roll-winner-overview {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-secondary);
  margin-bottom: 14px;
}
.roll-winner-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.btn-emerald {
  background: #00e676 !important;
  color: #0b0f16 !important;
  font-weight: 700 !important;
  box-shadow: 0 0 16px rgba(0, 230, 118, 0.35) !important;
}
.btn-cyan {
  background: #00e5ff !important;
  color: #0b0f16 !important;
  font-weight: 700 !important;
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.35) !important;
}
.roll-roulette-display {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  margin-top: 10px;
  background: rgba(15, 23, 42, 0.8);
  border-radius: var(--radius-md);
  border: 1px solid var(--accent-cyan);
}
.roll-ticker-flag {
  font-size: 32px;
}
.roll-ticker-name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--accent-cyan);
}
.roll-movie-loading {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px;
  margin-top: 14px;
  background: rgba(15, 23, 42, 0.6);
  border-radius: var(--radius-md);
}
@media (max-width: 600px) {
  .roll-winner-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .roll-winner-badges, .roll-winner-actions {
    justify-content: center;
  }
}

/* Data Actions Row */
.data-actions-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
  flex-wrap: wrap;
}

/* ---------- 12. Modals & Drawers ---------- */
.scrim, .modal-scrim {
  position: fixed;
  inset: 0;
  background: rgba(3, 6, 12, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 1000;
  transition: opacity 250ms ease;
}
.scrim[hidden], .modal-scrim[hidden] {
  display: none !important;
}

.modal-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 1001;
}
.modal-overlay[hidden] {
  display: none !important;
}
.modal-card {
  width: 100%;
  max-width: 480px;
  background: #0d1527;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--line-bright);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.85), 0 0 32px rgba(0, 229, 255, 0.15);
  overflow: hidden;
  position: relative;
  z-index: 1002;
  animation: modal-enter 220ms cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes modal-enter {
  0% { opacity: 0; transform: scale(0.95) translateY(8px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-card--import {
  max-width: 540px;
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line-subtle);
}
.modal-header-icon-wrap {
  font-size: 24px;
}
.modal-header-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: #ffffff;
}
.modal-header-sub {
  font-size: 12.5px;
  color: var(--text-secondary);
  margin-top: 2px;
}
.modal-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 20px;
  transition: all 150ms ease;
}
.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}
.modal-body-form {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}
/* Searchable Country Picker */
.searchable-country-picker {
  position: relative;
  width: 100%;
}

.country-picker-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-glass-input);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  color: #ffffff;
  font-family: inherit;
  font-size: 13.5px;
  cursor: pointer;
  outline: none;
  transition: all 180ms ease;
  text-align: left;
}

.country-picker-trigger:hover,
.searchable-country-picker.is-open .country-picker-trigger {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.2);
}

.country-picker-flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 16px;
  border-radius: 2px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
  flex-shrink: 0;
}

.country-picker-flag img,
.country-picker-flag svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.country-picker-name {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #ffffff;
}

.country-picker-name.is-placeholder {
  color: var(--text-muted);
}

.country-picker-chevron {
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 200ms ease;
}

.country-picker-chevron svg,
.country-picker-chevron i {
  width: 15px;
  height: 15px;
}

.searchable-country-picker.is-open .country-picker-chevron {
  transform: rotate(180deg);
  color: var(--accent-cyan);
}

.country-picker-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: rgba(11, 17, 33, 0.98);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(0, 229, 255, 0.25);
  border-radius: var(--radius-lg);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.8), 0 0 24px rgba(0, 229, 255, 0.1);
  padding: 8px;
  z-index: 1050;
  display: flex;
  flex-direction: column;
  gap: 6px;
  animation: countryDropdownFadeIn 180ms ease-out forwards;
}

.country-picker-dropdown[hidden] {
  display: none !important;
}

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

.country-search-box {
  position: relative;
  display: flex;
  align-items: center;
}

.country-search-icon {
  position: absolute;
  left: 10px;
  color: var(--accent-cyan);
  pointer-events: none;
  display: flex;
  align-items: center;
}

.country-search-icon svg,
.country-search-icon i {
  width: 14px;
  height: 14px;
}

.country-search-input {
  width: 100%;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-md);
  padding: 8px 30px 8px 32px;
  color: #ffffff;
  font-size: 13px;
  outline: none;
  transition: border-color 150ms ease;
}

.country-search-input:focus {
  border-color: var(--accent-cyan);
}

.country-search-clear {
  position: absolute;
  right: 8px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 16px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 50%;
}

.country-search-clear:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

.country-picker-list {
  max-height: 200px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-right: 4px;
}

.country-picker-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: none;
  color: #e2e8f0;
  font-size: 13px;
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: all 120ms ease;
}

.country-picker-item:hover,
.country-picker-item.is-highlighted {
  background: rgba(0, 229, 255, 0.12);
  color: var(--accent-cyan);
}

.country-picker-item.is-selected {
  background: rgba(0, 229, 255, 0.2);
  color: var(--accent-cyan);
  font-weight: 700;
}

.country-picker-item-flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 14px;
  border-radius: 2px;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

.country-picker-item-flag img,
.country-picker-item-flag svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.country-picker-item-name {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.country-picker-empty {
  padding: 12px;
  text-align: center;
  font-size: 12.5px;
  color: var(--text-muted);
}

.form-input, .form-select {
  background: var(--bg-glass-input);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  color: #ffffff;
  font-size: 13.5px;
  outline: none;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
.form-input:focus, .form-select:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.25);
}
.form-hint {
  font-size: 11px;
  color: var(--text-muted);
}
.file-dropzone {
  position: relative;
  border: 2px dashed var(--line-glass);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  background: rgba(10, 15, 26, 0.5);
  transition: border-color 150ms ease, background 150ms ease;
}
.file-dropzone:hover {
  border-color: var(--accent-cyan);
  background: rgba(0, 229, 255, 0.04);
}
.file-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}
.dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  pointer-events: none;
}
.dropzone-icon {
  font-size: 28px;
}
.dropzone-text {
  font-size: 13.5px;
  font-weight: 600;
  color: #ffffff;
}
.dropzone-sub {
  font-size: 11px;
  color: var(--text-secondary);
}
.segmented-control {
  display: flex;
  background: var(--bg-glass-input);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-md);
  overflow: hidden;
  padding: 3px;
  gap: 4px;
}
.segmented__opt {
  flex: 1;
  padding: 8px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: all 150ms ease;
}
.segmented__opt.is-active {
  background: var(--bg-surface-elev);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
/* Live Movie Database Search & Autocomplete in Modal */
.movie-search-container {
  position: relative;
}
.movie-search-field-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.movie-search-field-wrap .form-input {
  width: 100%;
  padding-right: 36px;
}
.movie-search-loader {
  position: absolute;
  right: 12px;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(0, 229, 255, 0.2);
  border-top-color: var(--accent-cyan);
  border-radius: 50%;
  animation: spin-loader 600ms linear infinite;
  pointer-events: none;
}
@keyframes spin-loader {
  to { transform: rotate(360deg); }
}

/* Movie Autocomplete Results Dropdown */
.movie-search-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: rgba(13, 21, 39, 0.98);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--accent-cyan);
  border-radius: var(--radius-md);
  max-height: 290px;
  overflow-y: auto;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.8), 0 0 24px rgba(0, 229, 255, 0.2);
  z-index: 99999;
}
.movie-search-dropdown-item {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 14px !important;
  padding: 8px 12px !important;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: background 120ms ease;
  box-sizing: border-box;
}
.movie-search-dropdown-item:last-child {
  border-bottom: none;
}
.movie-search-dropdown-item:hover, .movie-search-dropdown-item.is-selected {
  background: rgba(0, 229, 255, 0.16) !important;
}
.movie-search-item-poster {
  width: 40px !important;
  min-width: 40px !important;
  max-width: 40px !important;
  height: 58px !important;
  border-radius: var(--radius-xs);
  background: #182235;
  overflow: hidden !important;
  flex-shrink: 0 !important;
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
}
.movie-search-item-poster img {
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: cover !important;
  display: block !important;
}
.movie-search-item-poster-empty {
  font-size: 20px;
}
.movie-search-item-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
}
.movie-search-item-title {
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 700;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.movie-search-item-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  color: var(--text-secondary);
  flex-wrap: wrap;
}
.search-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
}
.search-tag--country {
  color: #cbd5e1;
  font-weight: 500;
}
.search-tag--year {
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.08);
  padding: 1px 5px;
  border-radius: var(--radius-xs);
}
.search-tag--rating {
  color: #fbbf24;
  font-weight: 600;
}
.search-tag--status-watched {
  color: #00e676;
  background: rgba(0, 230, 118, 0.15);
  border: 1px solid rgba(0, 230, 118, 0.35);
  padding: 1px 6px;
  border-radius: var(--radius-xs);
  font-weight: 700;
  letter-spacing: 0.02em;
}
.search-tag--status-watchlist {
  color: #00e5ff;
  background: rgba(0, 229, 255, 0.15);
  border: 1px solid rgba(0, 229, 255, 0.35);
  padding: 1px 6px;
  border-radius: var(--radius-xs);
  font-weight: 700;
  letter-spacing: 0.02em;
}

/* Movie Selected Preview Box */
.movie-card-preview {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(0, 229, 255, 0.06);
  border: 1px solid rgba(0, 229, 255, 0.3);
  border-radius: var(--radius-md);
  padding: 12px;
  position: relative;
  margin-top: 4px;
  margin-bottom: 8px;
  animation: pop-in 180ms ease;
}
.preview-poster-img {
  width: 48px;
  height: 72px;
  object-fit: cover;
  border-radius: var(--radius-xs);
  box-shadow: 0 4px 12px rgba(0,0,0,0.5);
  flex-shrink: 0;
}
.preview-meta-wrap {
  flex: 1;
  min-width: 0;
}
.preview-movie-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.preview-movie-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  flex-wrap: wrap;
}
.preview-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}
.preview-badge--year {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}
.preview-badge--country {
  background: rgba(0, 229, 255, 0.15);
  color: var(--accent-cyan);
  border: 1px solid rgba(0, 229, 255, 0.3);
}
.preview-badge--rating {
  background: rgba(251, 191, 36, 0.15);
  color: #fbbf24;
}
.preview-clear-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all 120ms ease;
}
.preview-clear-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

.modal-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding: 16px 24px;
  border-top: 1px solid var(--line-subtle);
  background: rgba(10, 15, 26, 0.6);
}

/* Import Progress Console */
.import-progress-box {
  background: #080c14;
  border: 1px solid var(--line-subtle);
  border-radius: var(--radius-md);
  padding: 14px;
}
.progress-track {
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 8px;
}
.progress-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #00e5ff, #00e676);
  transition: width 150ms ease;
}
.progress-status-text {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}
.progress-log-console {
  height: 110px;
  overflow-y: auto;
  font-family: var(--font-mono);
  font-size: 11px;
  color: #94a3b8;
  white-space: pre-wrap;
  line-height: 1.4;
}

/* Country Detail Sidebar (Drawer) */
.sidebar {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 400px;
  max-width: 90vw;
  background: rgba(15, 22, 38, 0.95);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-left: 1px solid var(--line-bright);
  box-shadow: -8px 0 32px rgba(0, 0, 0, 0.6);
  z-index: 1001;
  display: flex;
  flex-direction: column;
  animation: drawer-in 240ms cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes drawer-in {
  0% { transform: translateX(100%); }
  100% { transform: translateX(0); }
}
.sidebar__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line-subtle);
}
.sidebar__region {
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 700;
  color: var(--accent-cyan);
  letter-spacing: 0.08em;
}
.sidebar__title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: #ffffff;
  margin-top: 2px;
}
.sidebar__close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 20px;
}
.sidebar__close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}
.sidebar__subtabs {
  display: flex;
  background: rgba(10, 15, 26, 0.7);
  border-bottom: 1px solid var(--line-subtle);
}
.ticket-tab {
  flex: 1;
  padding: 12px;
  border-radius: 0;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}
.ticket-tab.is-active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
  border-bottom: 2px solid var(--accent-cyan);
}
.sidebar__body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.side-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg-surface-elev);
  border: 1px solid var(--line-subtle);
  border-radius: var(--radius-md);
  padding: 10px;
}
.side-card__poster {
  width: 48px;
  height: 72px;
  object-fit: cover;
  border-radius: var(--radius-xs);
  flex-shrink: 0;
}
.side-card__body {
  flex: 1;
  min-width: 0;
}
.side-card__title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.side-card__actions button {
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
}
.sidebar__actions {
  padding: 20px 24px;
  border-top: 1px solid var(--line-subtle);
  background: rgba(10, 15, 26, 0.7);
}

/* ---------- 13. Toast Notification ---------- */
.toast {
  position: fixed;
  bottom: 28px;
  right: 28px;
  background: rgba(15, 22, 38, 0.95);
  backdrop-filter: blur(16px);
  border: 1px solid var(--accent-cyan);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 20px rgba(0, 229, 255, 0.25);
  color: #ffffff;
  padding: 12px 20px;
  border-radius: var(--radius-full);
  font-size: 13.5px;
  font-weight: 600;
  z-index: 999999;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: toast-in 200ms ease;
}
@keyframes toast-in {
  0% { transform: translateY(12px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

/* ---------- 14. Responsive Layout Adjustments ---------- */
@media (max-width: 768px) {
  .app-header {
    padding: 8px 12px;
  }
  .brand-text {
    display: none;
  }
  .nav-actions .action-label {
    display: none;
  }
  .btn-action-glow, .btn-action-glass {
    padding: 7px 10px;
  }
  .tab-btn {
    padding: 6px 12px;
    font-size: 12px;
  }
  .tab-btn__label {
    display: none;
  }
  .globe-search {
    top: 12px;
    left: 12px;
    width: calc(100vw - 24px);
  }
  .globe-hud-bottom {
    bottom: 12px;
    flex-direction: column;
    gap: 8px;
  }
  .globe-hint {
    display: none;
  }
  .sidebar {
    width: 100vw;
    max-width: 100vw;
  }
}

/* =========================================================================
   15. WORLD CINEMA CHALLENGE & LIST MAKER MODAL STYLES
   ========================================================================= */
.challenge-modal-card {
  max-width: 960px;
  width: min(960px, 95vw);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  background: #0d1527 !important;
  border: 1px solid rgba(0, 229, 255, 0.35) !important;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.9), 0 0 32px rgba(0, 229, 255, 0.2) !important;
  position: relative !important;
  z-index: 1002 !important;
}
.challenge-lux-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line-subtle);
  background: rgba(10, 15, 26, 0.7);
}
.challenge-lux-title-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
}
.challenge-lux-icon-badge {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: rgba(0, 229, 255, 0.12);
  border: 1px solid rgba(0, 229, 255, 0.35);
  color: #00e5ff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.2);
}
.challenge-lux-icon-badge i {
  width: 22px;
  height: 22px;
  stroke-width: 2.2;
}
.challenge-lux-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: #ffffff;
}
.challenge-lux-subtitle {
  font-size: 12.5px;
  color: var(--text-secondary);
  margin-top: 2px;
}
.challenge-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.challenge-lux-controls {
  display: flex;
  flex-direction: column;
  gap: 18px;
  background: rgba(10, 15, 26, 0.5);
  border: 1px solid var(--line-glass);
  border-radius: var(--radius-lg);
  padding: 20px;
}
.lux-filter-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.lux-filter-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  font-weight: 700;
  color: #ffffff;
}
.lux-label-with-icon {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #ffffff;
}
.lux-label-with-icon i {
  width: 15px;
  height: 15px;
  stroke-width: 2.2;
  color: var(--accent-cyan);
}
.lux-filter-hint {
  font-size: 11px;
  font-weight: 400;
  color: var(--text-muted);
}
.lux-pills-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.lux-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line-glass);
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 600;
  transition: all 160ms ease;
  cursor: pointer;
}
.lux-pill i {
  width: 14px;
  height: 14px;
  stroke-width: 2;
  opacity: 0.85;
}
.lux-pill:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
}
.lux-pill.is-active {
  background: linear-gradient(135deg, rgba(0, 229, 255, 0.18) 0%, rgba(56, 189, 248, 0.1) 100%);
  border-color: #00e5ff;
  color: #ffffff;
  box-shadow: 0 0 12px rgba(0, 229, 255, 0.25);
}
.lux-pill.is-active i {
  color: #00e5ff;
  opacity: 1;
}

.lux-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 10px;
  border-top: 1px solid var(--line-subtle);
}
.lux-toggle-info strong {
  display: block;
  font-size: 13px;
  color: #ffffff;
}
.lux-toggle-info span {
  display: block;
  font-size: 11.5px;
  color: var(--text-muted);
}
.lux-switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}
.lux-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.lux-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: rgba(255, 255, 255, 0.15);
  transition: .2s;
  border-radius: 24px;
}
.lux-slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .2s;
  border-radius: 50%;
}
.lux-switch input:checked + .lux-slider {
  background: linear-gradient(90deg, var(--accent-cyan), #00b4d8);
  box-shadow: 0 0 12px rgba(0, 229, 255, 0.35);
}
.lux-switch input:checked + .lux-slider:before {
  transform: translateX(20px);
}

.btn-lux-hero {
  width: 100%;
  padding: 13px 24px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #00e5ff 0%, #00b4d8 100%);
  border: 1px solid rgba(0, 229, 255, 0.5);
  color: #05070d;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  box-shadow: 0 4px 20px rgba(0, 229, 255, 0.35);
  cursor: pointer;
  transition: all 180ms ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.btn-lux-hero i {
  width: 17px;
  height: 17px;
  stroke-width: 2.5;
}
.btn-lux-hero:hover {
  transform: translateY(-1.5px);
  box-shadow: 0 6px 28px rgba(0, 229, 255, 0.6);
  background: linear-gradient(135deg, #38bdf8 0%, #00e5ff 100%);
}

/* Challenge Results Section */
.challenge-results-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.challenge-results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line-subtle);
}
.challenge-itinerary-heading {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 800;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 8px;
}
.itinerary-title-icon {
  color: var(--accent-cyan);
  display: inline-flex;
  align-items: center;
}
.itinerary-title-icon i {
  width: 20px;
  height: 20px;
  stroke-width: 2.2;
}
.challenge-itinerary-sub {
  display: flex;
  align-items: center;
  margin-top: 4px;
  flex-wrap: wrap;
}
.itinerary-meta-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  background: rgba(0, 229, 255, 0.1);
  border: 1px solid rgba(0, 229, 255, 0.25);
  font-size: 11.5px;
  font-weight: 700;
  color: #00e5ff;
  font-family: var(--font-display);
}
.itinerary-sub-text {
  font-size: 12px;
  color: var(--text-secondary);
  margin-left: 8px;
}
.itinerary-progress-text {
  font-size: 12px;
  color: var(--accent-emerald);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 8px;
}
.itinerary-progress-text i {
  width: 14px;
  height: 14px;
}

.challenge-progress-bar-wrap {
  width: 160px;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 8px;
}
.challenge-progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #00e5ff 0%, #00e676 100%);
  box-shadow: 0 0 8px rgba(0, 230, 118, 0.6);
  transition: width 200ms ease;
}
.challenge-results-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.btn-challenge-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: var(--radius-md);
  background: rgba(0, 229, 255, 0.15);
  border: 1px solid rgba(0, 229, 255, 0.4);
  color: #00e5ff;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 160ms ease;
  box-shadow: 0 0 12px rgba(0, 229, 255, 0.15);
}
.btn-challenge-primary i {
  width: 15px;
  height: 15px;
  stroke-width: 2.2;
}
.btn-challenge-primary:hover {
  background: rgba(0, 229, 255, 0.28);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 0 16px rgba(0, 229, 255, 0.35);
}

.btn-challenge-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #e2e8f0;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 160ms ease;
}
.btn-challenge-action i {
  width: 14px;
  height: 14px;
  stroke-width: 2;
}
.btn-challenge-action:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  transform: translateY(-1px);
}

/* Timeline Ticket Cards - 2-Column Responsive Cinema Grid */
.challenge-timeline {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

@media (max-width: 768px) {
  .challenge-timeline {
    grid-template-columns: 1fr;
  }
}

.lux-ticket-card {
  display: flex;
  align-items: stretch;
  gap: 14px;
  background: rgba(14, 21, 37, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 12px;
  transition: all 180ms cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}
.lux-ticket-card:hover {
  background: rgba(18, 27, 48, 0.98);
  border-color: rgba(0, 229, 255, 0.35);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}

.lux-card-poster-col {
  flex-shrink: 0;
}

.lux-ticket-poster {
  width: 92px;
  height: 138px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
  background: #090e18;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.lux-ticket-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 220ms ease;
}
.lux-ticket-card:hover .lux-ticket-poster img {
  transform: scale(1.05);
}

.lux-poster-day-tag {
  position: absolute;
  top: 6px;
  left: 6px;
  padding: 2px 7px;
  background: rgba(5, 7, 13, 0.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(251, 191, 36, 0.4);
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 800;
  color: var(--accent-amber);
  letter-spacing: 0.5px;
}

.lux-card-content-col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.lux-card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.lux-card-meta-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
}
.lux-ticket-badge-country {
  color: #e2e8f0;
  font-weight: 700;
}
.lux-ticket-year {
  font-family: var(--font-mono);
  color: var(--text-muted);
}

.lux-ticket-title-row {
  margin: 4px 0 2px;
}
.lux-ticket-title {
  font-family: var(--font-display);
  font-size: 14.5px;
  font-weight: 700;
  color: #ffffff;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  line-height: 1.35;
}
.lux-ticket-title:hover {
  color: var(--accent-cyan);
}
.lux-link-icon {
  width: 13px;
  height: 13px;
  opacity: 0.6;
  stroke-width: 2;
  flex-shrink: 0;
}

.lux-ticket-director {
  font-size: 11.5px;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lux-ticket-director-spacer {
  height: 8px;
}

.lux-ticket-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
}

.btn-icon-ticket {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line-glass);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 140ms ease;
}
.btn-icon-ticket i {
  width: 13px;
  height: 13px;
}
.btn-icon-ticket:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  transform: rotate(45deg);
}

.btn-ticket-log {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #e2e8f0;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 140ms ease;
}
.btn-ticket-log i {
  width: 13px;
  height: 13px;
}
.btn-ticket-log:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.btn-ticket-watched {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(0, 230, 118, 0.15);
  border: 1px solid rgba(0, 230, 118, 0.45);
  color: #00e676;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
}
.btn-ticket-watched i {
  width: 13px;
  height: 13px;
  stroke-width: 2.5;
}

.btn-ticket-queue {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(0, 229, 255, 0.08);
  border: 1px solid rgba(0, 229, 255, 0.25);
  color: #00e5ff;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 140ms ease;
}
.btn-ticket-queue i {
  width: 13px;
  height: 13px;
}
.btn-ticket-queue:hover {
  background: rgba(0, 229, 255, 0.18);
  border-color: rgba(0, 229, 255, 0.4);
}

.btn-ticket-queued {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(0, 229, 255, 0.2);
  border: 1px solid rgba(0, 229, 255, 0.55);
  color: #00e5ff;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
}
.btn-ticket-queued i {
  width: 13px;
  height: 13px;
  stroke-width: 2.5;
}

/* =========================================================================
   16. PWA INSTALL BANNER STYLES
   ========================================================================= */
.pwa-banner {
  position: fixed;
  bottom: 24px;
  left: 24px;
  max-width: 440px;
  background: rgba(15, 22, 38, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--line-bright);
  border-radius: var(--radius-lg);
  padding: 14px 18px;
  box-shadow: var(--shadow-elevated);
  z-index: 99999;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: all 260ms cubic-bezier(0.16, 1, 0.3, 1);
}
.pwa-banner.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.pwa-content {
  display: flex;
  align-items: center;
  gap: 14px;
}
.pwa-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: rgba(0, 229, 255, 0.12);
  border: 1px solid rgba(0, 229, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.pwa-text {
  flex: 1;
  min-width: 0;
}
.pwa-text strong {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  color: #ffffff;
}
.pwa-text span {
  display: block;
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
  line-height: 1.35;
}
.pwa-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.pwa-close-btn {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: pointer;
  transition: all 140ms ease;
}
.pwa-close-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

/* =========================================================================
   USER AUTHENTICATION & MULTI-DEVICE CLOUD SYNC
   ========================================================================= */
.nav-auth-container {
  display: flex;
  align-items: center;
}

.btn-auth-login {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(168, 85, 247, 0.25));
  border: 1px solid rgba(168, 85, 247, 0.4);
  color: #ffffff;
  padding: 6px 14px;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 12px rgba(168, 85, 247, 0.2);
}

.btn-auth-login:hover {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.4), rgba(168, 85, 247, 0.45));
  border-color: rgba(168, 85, 247, 0.7);
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.4);
  transform: translateY(-1px);
}

/* Header User Profile Menu */
.user-menu-wrapper {
  position: relative;
}

.user-menu-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 12px 4px 6px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #f3f4f6;
  cursor: pointer;
  transition: all 0.18s ease;
}

.user-menu-trigger:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
}

.user-avatar-badge {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.user-name-label {
  font-size: 13px;
  font-weight: 600;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 6px #10b981;
}

.user-sync-dot--syncing, .user-sync-dot--pending {
  background: #f59e0b;
  box-shadow: 0 0 6px #f59e0b;
  animation: pulseSync 1.2s infinite;
}

.user-sync-dot--error {
  background: #ef4444;
  box-shadow: 0 0 6px #ef4444;
}

.user-caret {
  font-size: 10px;
  opacity: 0.7;
}

@keyframes pulseSync {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(1.3); }
}

/* User Dropdown Menu */
.user-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 240px;
  background: rgba(15, 20, 32, 0.95);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.05);
  padding: 8px;
  z-index: 1000;
  animation: modalFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.user-dropdown-header {
  padding: 10px 12px;
}

.user-dropdown-name {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 2px;
}

.user-dropdown-email {
  font-size: 12px;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-dropdown-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 6px 0;
}

.user-dropdown-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: none;
  color: #e5e7eb;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
}

.user-dropdown-item:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.user-dropdown-item--danger {
  color: #f87171;
}

.user-dropdown-item--danger:hover {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
}

/* =========================================================================
   MODAL WRAPPER SYSTEM (.modal pattern — used by Auth & Account modals)
   ========================================================================= */

/* The full-screen backdrop wrapper */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1100;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(3, 6, 12, 0.82);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  animation: modalFadeIn 0.22s ease;
}

.modal.is-open,
.modal:not([hidden]) {
  display: flex;
}

/* Invisible overlay for click-outside close */
.modal__overlay {
  position: absolute;
  inset: 0;
  cursor: default;
}

/* Dialog card container */
.modal__dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  animation: modal-enter 220ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* Shared modal header */
.modal__header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 8px;
}

.modal__title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 4px 0;
  line-height: 1.2;
}

.modal__subtitle {
  font-size: 12.5px;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.4;
}

.modal__close {
  margin-left: auto;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 20px;
  transition: all 150ms ease;
  cursor: pointer;
  border: none;
  background: transparent;
}

.modal__close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

/* Scrollable body for tall modals */
.modal-body-scroll {
  flex: 1;
  overflow-y: auto;
  min-height: 0;
  padding-right: 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.1) transparent;
}

/* Auth Modal Styles */
.modal__dialog--auth {
  max-width: 420px;
  width: 92vw;
  background: linear-gradient(180deg, rgba(20, 26, 42, 0.96) 0%, rgba(11, 15, 25, 0.98) 100%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.8), 0 0 40px rgba(99, 102, 241, 0.15);
  padding: 30px;
  text-align: center;
}

.auth-modal-brand-badge {
  font-size: 36px;
  margin-bottom: 8px;
}

.auth-tabs-nav {
  display: flex;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
  border-radius: var(--radius-md);
  margin: 20px 0 16px 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.auth-tab-btn {
  flex: 1;
  padding: 8px 12px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.18s ease;
}

.auth-tab-btn.is-active {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.auth-form {
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-error-box {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: 12.5px;
  line-height: 1.4;
}

.auth-submit-btn {
  width: 100%;
  margin-top: 8px;
  padding: 12px;
  font-size: 14px;
  font-weight: 600;
}

.auth-switch-prompt {
  text-align: center;
  font-size: 12.5px;
  color: var(--text-secondary);
  margin-top: 8px;
}

.auth-switch-prompt a {
  color: var(--brand-accent, #6366f1);
  text-decoration: none;
  font-weight: 600;
}

.auth-switch-prompt a:hover {
  text-decoration: underline;
}

/* Sync Status Badges */
.sync-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 9999px;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.sync-badge--synced {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.35);
}

.sync-badge--syncing, .sync-badge--pending {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.35);
}

.sync-badge--error {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

.sync-badge--guest {
  background: rgba(99, 102, 241, 0.15);
  color: #818cf8;
  border: 1px solid rgba(99, 102, 241, 0.35);
}

.feature-card--highlight {
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.8), 0 0 24px rgba(99, 102, 241, 0.4);
  transition: all 0.3s ease;
}

/* =========================================================================
   ACCOUNT & MULTI-DEVICE MANAGEMENT MODAL STYLES
   ========================================================================= */

.modal__dialog--account {
  max-width: 580px;
  width: 94vw;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, rgba(20, 27, 45, 0.98) 0%, rgba(10, 15, 26, 0.99) 100%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.85), 0 0 40px rgba(99, 102, 241, 0.12);
  padding: 24px 28px;
  overflow: hidden;
}

.account-nav-tabs {
  display: flex;
  background: rgba(255, 255, 255, 0.05);
  padding: 4px;
  border-radius: var(--radius-md);
  margin: 16px 0 20px 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  gap: 4px;
}

.account-tab-btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 14px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.18s ease;
}

.account-tab-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
}

.account-tab-btn.is-active {
  background: rgba(99, 102, 241, 0.25);
  color: #ffffff;
  border: 1px solid rgba(99, 102, 241, 0.45);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.account-section-heading {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 12px;
  letter-spacing: 0.01em;
}

.account-form-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.account-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 20px 0;
}

.account-msg-box {
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: 12.5px;
  line-height: 1.4;
  margin-bottom: 4px;
}

.account-msg-box--success {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
}

.account-msg-box--error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
}

/* Cloud Metrics Grid */
.cloud-metrics-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 12px;
}

.cloud-metric-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 12px 10px;
  text-align: center;
}

.cloud-metric-num {
  font-family: var(--font-mono);
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
}

.cloud-metric-label {
  font-size: 11px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.cloud-sync-info-box {
  background: rgba(0, 229, 255, 0.05);
  border: 1px solid rgba(0, 229, 255, 0.2);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  font-size: 12.5px;
  color: #cbd5e1;
  line-height: 1.4;
}

.account-actions-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 14px;
}

/* Danger Zone */
.account-danger-zone {
  background: rgba(239, 68, 68, 0.05);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: var(--radius-md);
  padding: 14px;
}

.account-danger-title {
  color: #f87171;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 10px;
}

.danger-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.danger-desc {
  font-size: 11.5px;
  color: #94a3b8;
  margin-top: 2px;
}

/* Connected Devices List */
.devices-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 380px;
  overflow-y: auto;
  padding-right: 4px;
}

.device-item-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  transition: all 0.18s ease;
}

.device-item-card:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.15);
}

.device-item-card--current {
  background: rgba(99, 102, 241, 0.08);
  border-color: rgba(99, 102, 241, 0.35);
}

.device-icon-box {
  font-size: 24px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-md);
  flex-shrink: 0;
}

.device-meta-wrap {
  flex: 1;
  min-width: 0;
}

.device-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.device-title {
  font-size: 13.5px;
  font-weight: 600;
  color: #ffffff;
}

.device-badge-current {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 9999px;
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.device-sub-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 3px;
  font-size: 11.5px;
  color: var(--text-secondary);
}

.device-time-pill {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: #94a3b8;
}

.device-btn-revoke {
  flex-shrink: 0;
}

@media (max-width: 640px) {
  .modal__dialog--account {
    padding: 18px 16px;
  }
  .account-tab-btn {
    font-size: 11.5px;
    padding: 7px 6px;
  }
  .cloud-metrics-grid {
    grid-template-columns: 1fr;
  }
  .danger-row {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* =========================================================================
   10. Past Due / Grace Period Warning Banner & Notice
   ========================================================================= */
.grace-period-banner {
  position: sticky;
  top: 0;
  z-index: 99998;
  background: linear-gradient(90deg, rgba(245, 158, 11, 0.95), rgba(217, 119, 6, 0.95));
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #ffffff;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.35);
  font-family: var(--font-sans);
  font-size: 13.5px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.25);
  animation: slideDownBanner 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDownBanner {
  from { transform: translateY(-100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.grace-banner-content {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}

.grace-banner-icon {
  font-size: 18px;
  flex-shrink: 0;
}

.grace-banner-text {
  line-height: 1.45;
  color: #fffbeb;
}

.grace-banner-text strong {
  color: #ffffff;
  font-weight: 700;
}

.grace-banner-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.btn-grace-action {
  background: #ffffff !important;
  color: #b45309 !important;
  font-weight: 700 !important;
  font-size: 12.5px !important;
  padding: 6px 14px !important;
  border-radius: 9999px !important;
  border: none !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2) !important;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-grace-action:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
  background: #fffbeb !important;
}

.btn-grace-close {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.8);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  transition: color 0.15s ease;
}

.btn-grace-close:hover {
  color: #ffffff;
}

@media (max-width: 768px) {
  .grace-period-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 12px 14px;
    gap: 10px;
  }
  .grace-banner-actions {
    width: 100%;
    justify-content: space-between;
  }
}

/* =========================================================================
   11. Subscription Tab & Customer Portal Modal Styling
   ========================================================================= */
.account-subscription-wrapper {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.subscription-hero-card {
  background: radial-gradient(circle at top right, rgba(0, 229, 255, 0.12), rgba(15, 23, 42, 0.85));
  border: 1px solid rgba(0, 229, 255, 0.25);
  border-radius: var(--radius-lg, 14px);
  padding: 20px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.sub-hero-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 10px;
}

.sub-plan-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.badge-plan-free {
  background: rgba(148, 163, 184, 0.2);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.3);
}

.badge-plan-pro {
  background: rgba(0, 229, 255, 0.18);
  color: #00e5ff;
  border: 1px solid rgba(0, 229, 255, 0.4);
}

.badge-plan-lifetime {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(217, 119, 6, 0.25));
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.5);
}

.badge-plan-warning {
  background: rgba(245, 158, 11, 0.2);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.sub-plan-title {
  font-size: 18px;
  font-weight: 800;
  color: #ffffff;
  margin: 0;
  font-family: var(--font-display);
}

.sub-hero-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: rgba(0, 229, 255, 0.15);
  border: 1px solid rgba(0, 229, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #00e5ff;
  font-size: 20px;
  flex-shrink: 0;
}

.sub-plan-desc {
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 12px;
}

.sub-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 12.5px;
  margin-top: 6px;
}

.sub-meta-row--warning {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.3);
  color: #fbbf24;
}

.sub-meta-label {
  color: #94a3b8;
}

.sub-meta-row--warning .sub-meta-label {
  color: #fde68a;
}

.sub-meta-value {
  font-weight: 600;
  color: #ffffff;
}

.subscription-syncing-notice {
  margin-top: 10px;
  padding: 8px 12px;
  background: rgba(0, 229, 255, 0.12);
  border: 1px dashed rgba(0, 229, 255, 0.4);
  border-radius: 8px;
  font-size: 12px;
  color: #38bdf8;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: pulseNotice 2s infinite ease-in-out;
}

@keyframes pulseNotice {
  0%, 100% { opacity: 0.9; }
  50% { opacity: 0.55; }
}

.spinner-inline {
  width: 14px;
  height: 14px;
  border: 2px solid rgba(0, 229, 255, 0.3);
  border-top-color: #00e5ff;
  border-radius: 50%;
  animation: spinInline 0.8s linear infinite;
  display: inline-block;
}

@keyframes spinInline {
  to { transform: rotate(360deg); }
}

.sub-benefits-ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sub-benefits-ul li {
  font-size: 12.5px;
  color: #64748b;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sub-benefits-ul li.benefit-active {
  color: #e2e8f0;
}

/* =========================================================================
   FREEMIUM UX, PRO TEASER BADGES & UPGRADE MODAL STYLES
   ========================================================================= */

/* Luxury Gold & Neon PRO Micro Badges */
.badge-pro-micro {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 1px 6px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(217, 119, 6, 0.35));
  border: 1px solid rgba(245, 158, 11, 0.5);
  border-radius: 4px;
  font-family: var(--font-mono, monospace);
  font-size: 9.5px;
  font-weight: 800;
  color: #fbbf24;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  vertical-align: middle;
}

/* For Active Pro Members: Hide redundant teaser badges across all toolbars and modals */
body.is-pro-user .badge-pro-micro,
body.is-pro-user .lux-pill--pro .badge-pro-micro,
body.is-pro-user .badge-pro-gold,
body.is-pro-user .badge-pro-neon {
  display: none !important;
}

body.is-pro-user .lux-pill--pro {
  border-color: rgba(255, 255, 255, 0.12) !important;
}
body.is-pro-user .lux-pill--pro:hover {
  border-color: rgba(0, 229, 255, 0.4) !important;
  background: rgba(0, 229, 255, 0.08) !important;
}

.badge-pro-gold {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #0b0f19;
  font-family: var(--font-mono, monospace);
  font-size: 10.5px;
  font-weight: 800;
  border-radius: 9999px;
  letter-spacing: 0.5px;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.35);
}

.badge-pro-neon {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: rgba(0, 229, 255, 0.15);
  border: 1px solid rgba(0, 229, 255, 0.45);
  color: #00e5ff;
  font-family: var(--font-mono, monospace);
  font-size: 10.5px;
  font-weight: 700;
  border-radius: 9999px;
}

/* Locked Pill & Teaser Controls */
.lux-pill--pro {
  position: relative;
  border-color: rgba(245, 158, 11, 0.3) !important;
}

.lux-pill--pro:hover {
  border-color: rgba(245, 158, 11, 0.6) !important;
  background: rgba(245, 158, 11, 0.08) !important;
}

.pro-locked-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px dashed rgba(245, 158, 11, 0.4);
  color: #fbbf24;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.pro-locked-chip:hover {
  background: rgba(245, 158, 11, 0.15);
  border-style: solid;
  transform: translateY(-1px);
}

/* Glassmorphism Teaser Overlay */
.pro-teaser-container {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
}

.pro-teaser-blur {
  filter: blur(4px);
  pointer-events: none;
  user-select: none;
  opacity: 0.65;
}

.pro-teaser-lock-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(11, 16, 28, 0.7) 0%, rgba(6, 9, 17, 0.9) 100%);
  backdrop-filter: blur(6px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px;
  text-align: center;
  z-index: 10;
}

/* Upgrade Modal Overlays */
.upgrade-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(4, 6, 12, 0.82);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.upgrade-modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.upgrade-modal-card {
  width: 100%;
  max-width: 520px;
  background: linear-gradient(180deg, #111827 0%, #0b0f19 100%);
  border: 1px solid rgba(251, 191, 36, 0.35);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.7), 0 0 40px rgba(245, 158, 11, 0.15);
  border-radius: 20px;
  padding: 32px 28px 28px;
  position: relative;
  transform: scale(0.95) translateY(10px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 90vh;
  overflow-y: auto;
}

.upgrade-modal-overlay.active .upgrade-modal-card {
  transform: scale(1) translateY(0);
}

.upgrade-modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.2s;
}

.upgrade-modal-close:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  transform: rotate(90deg);
}

.upgrade-hero-icon-wrap {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(0, 229, 255, 0.2));
  border: 1px solid rgba(245, 158, 11, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fbbf24;
  font-size: 28px;
  margin: 0 auto 16px;
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.2);
}

.upgrade-hero-title {
  font-family: var(--font-display, 'Plus Jakarta Sans', sans-serif);
  font-size: 22px;
  font-weight: 800;
  color: #ffffff;
  text-align: center;
  margin: 0 0 6px;
  letter-spacing: -0.01em;
}

.upgrade-hero-subtitle {
  font-size: 13.5px;
  color: #94a3b8;
  text-align: center;
  line-height: 1.5;
  margin: 0 auto 20px;
  max-width: 420px;
}

.upgrade-feature-highlight {
  padding: 10px 14px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px dashed rgba(245, 158, 11, 0.35);
  border-radius: 10px;
  font-size: 12.5px;
  color: #fde68a;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}

.upgrade-benefits-list {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.upgrade-benefit-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: #e2e8f0;
  line-height: 1.4;
}

.upgrade-check-icon {
  color: #00e676;
  font-weight: bold;
  flex-shrink: 0;
  margin-top: 1px;
}

.upgrade-actions-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-upgrade-cta {
  width: 100%;
  padding: 14px 20px;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #0b0f19;
  font-family: var(--font-display, sans-serif);
  font-size: 15px;
  font-weight: 800;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
  text-decoration: none;
}

.btn-upgrade-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(245, 158, 11, 0.5);
  filter: brightness(1.08);
}

.btn-upgrade-secondary {
  width: 100%;
  padding: 10px;
  background: transparent;
  border: none;
  color: #64748b;
  font-size: 12.5px;
  cursor: pointer;
  transition: color 0.2s;
  text-align: center;
}

.btn-upgrade-secondary:hover {
  color: #cbd5e1;
}

.upgrade-guarantee-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 11.5px;
  color: #00e676;
  text-align: center;
  font-weight: 600;
}

/* =========================================================================
   PRO FEATURE GATES: CONTINENTAL ANALYTICS & 3D GLOBE THEMES
   ========================================================================= */
.feature-card--analytics {
  border-color: rgba(0, 229, 255, 0.2);
  background: linear-gradient(180deg, rgba(14, 21, 37, 0.9) 0%, rgba(9, 14, 26, 0.95) 100%);
}

.continent-analytics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.continent-stat-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: all 0.2s ease;
}

.continent-stat-box:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(0, 229, 255, 0.25);
}

.continent-stat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 700;
  color: #f1f5f9;
}

.continent-pct-pill {
  font-family: var(--font-mono, monospace);
  font-size: 11px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(0, 229, 255, 0.12);
  color: #00e5ff;
  border: 1px solid rgba(0, 229, 255, 0.25);
}

.continent-progress-track {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  overflow: hidden;
}

.continent-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #00e5ff 0%, #00e676 100%);
  border-radius: 3px;
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.continent-stat-sub {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11.5px;
  color: #94a3b8;
}

/* 3D Globe Theme / Skin Selector */
.globe-skin-segmented {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  background: rgba(11, 16, 28, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  margin-left: 8px;
}

.globe-skin-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: 7px;
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.16s ease;
}

.globe-skin-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.globe-skin-btn.is-active {
  background: rgba(0, 229, 255, 0.18);
  color: #00e5ff;
  font-weight: 700;
}
