/* ==========================================================================
   LIVE WEATHER APP - MODERN GLASSMORPHIC DESIGN SYSTEM
   ========================================================================== */

:root {
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Atmospheric theme base variables */
  --bg-gradient: linear-gradient(135deg, #0f172a 0%, #1e1b4b 50%, #090d16 100%);
  --card-bg: rgba(15, 23, 42, 0.65);
  --card-border: rgba(255, 255, 255, 0.1);
  --card-hover: rgba(30, 41, 59, 0.8);
  --glass-blur: blur(16px);
  
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  
  --accent-cyan: #38bdf8;
  --accent-blue: #3b82f6;
  --accent-indigo: #6366f1;
  --accent-amber: #f59e0b;
  --accent-emerald: #10b981;
  --accent-rose: #f43f5e;
  
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 10px 25px -3px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 20px 35px -5px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 25px rgba(56, 189, 248, 0.25);
}

/* Atmospheric dynamic theme modifiers */
body.theme-clear-day {
  --bg-gradient: linear-gradient(135deg, #0284c7 0%, #38bdf8 40%, #0369a1 100%);
  --card-bg: rgba(255, 255, 255, 0.18);
  --card-border: rgba(255, 255, 255, 0.25);
}

body.theme-clear-night {
  --bg-gradient: linear-gradient(135deg, #020617 0%, #0f172a 50%, #1e1b4b 100%);
  --card-bg: rgba(15, 23, 42, 0.65);
}

body.theme-rain {
  --bg-gradient: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f273d 100%);
  --card-bg: rgba(15, 23, 42, 0.7);
}

body.theme-storm {
  --bg-gradient: linear-gradient(135deg, #090d16 0%, #1e1b4b 50%, #180d2b 100%);
  --card-bg: rgba(15, 10, 30, 0.75);
}

body.theme-snow {
  --bg-gradient: linear-gradient(135deg, #1e293b 0%, #334155 50%, #475569 100%);
  --card-bg: rgba(30, 41, 59, 0.65);
}

body.theme-cloudy {
  --bg-gradient: linear-gradient(135deg, #1e293b 0%, #0f172a 50%, #1e293b 100%);
  --card-bg: rgba(15, 23, 42, 0.7);
}

/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  min-height: 100%;
  font-family: var(--font-sans);
  color: var(--text-primary);
  background: var(--bg-gradient);
  background-attachment: fixed;
  overflow-x: hidden;
  transition: background 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Atmospheric Background Canvas */
#weather-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
}

/* App Container */
.app-layout {
  position: relative;
  z-index: 1;
  max-width: 1400px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Glassmorphism Card Utility */
.glass-card {
  background: var(--card-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.glass-card:hover {
  border-color: rgba(255, 255, 255, 0.2);
}

/* ==========================================================================
   HEADER & NAVBAR
   ========================================================================== */

.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 0.75rem 1.25rem;
}

.brand-section {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent-cyan), var(--accent-blue));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  box-shadow: var(--shadow-glow);
}

.brand-title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(to right, #ffffff, #bae6fd);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  font-size: 0.75rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.live-indicator {
  width: 8px;
  height: 8px;
  background-color: var(--accent-emerald);
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 8px var(--accent-emerald);
  animation: pulse-dot 2s infinite ease-in-out;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

/* Search Bar & Controls */
.header-controls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
  max-width: 650px;
  justify-content: flex-end;
}

.search-box {
  position: relative;
  flex: 1;
  min-width: 200px;
}

.search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.search-input-wrapper i {
  position: absolute;
  left: 1rem;
  color: var(--text-muted);
  font-size: 1rem;
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 0.75rem 3rem 0.75rem 2.6rem;
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid var(--card-border);
  border-radius: 9999px;
  color: var(--text-primary);
  font-size: 0.925rem;
  font-family: var(--font-sans);
  outline: none;
  transition: all 0.2s ease;
}

.search-input:focus {
  background: rgba(15, 23, 42, 0.85);
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
}

.search-input::placeholder {
  color: var(--text-muted);
}

.btn-voice {
  position: absolute;
  right: 0.6rem;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 0.4rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.btn-voice:hover, .btn-voice.listening {
  color: var(--accent-cyan);
  background: rgba(56, 189, 248, 0.15);
}

.btn-voice.listening {
  animation: pulse-voice 1.5s infinite;
}

@keyframes pulse-voice {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); color: #f43f5e; }
}

/* Autocomplete Dropdown */
.search-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(20px);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  max-height: 280px;
  overflow-y: auto;
  z-index: 100;
  display: none;
}

.search-dropdown.active {
  display: block;
}

.dropdown-item {
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.15s ease;
}

.dropdown-item:last-child {
  border-bottom: none;
}

.dropdown-item:hover {
  background: rgba(56, 189, 248, 0.12);
}

.dropdown-item .city-name {
  font-weight: 600;
  color: #fff;
}

.dropdown-item .country-info {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* Action Buttons */
.btn-icon {
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid var(--card-border);
  color: var(--text-primary);
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.05rem;
  transition: all 0.2s ease;
}

.btn-icon:hover {
  background: rgba(56, 189, 248, 0.2);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  transform: translateY(-2px);
}

.unit-toggle-btn {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--card-border);
  border-radius: 9999px;
  padding: 0.35rem 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-primary);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.unit-toggle-btn:hover {
  border-color: var(--accent-cyan);
  background: rgba(56, 189, 248, 0.15);
}

.unit-toggle-btn .unit-active {
  color: var(--accent-cyan);
}

/* ==========================================================================
   MAIN DASHBOARD GRID
   ========================================================================== */

.dashboard-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 1.5rem;
}

@media (max-width: 1024px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   HERO WEATHER OVERVIEW CARD
   ========================================================================== */

.hero-weather-card {
  padding: 2rem;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1.75rem;
}

.location-bar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.location-details {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.city-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.location-title {
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.location-badge {
  background: rgba(56, 189, 248, 0.15);
  border: 1px solid rgba(56, 189, 248, 0.3);
  color: var(--accent-cyan);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.location-coords {
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.weather-time-stamp {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.location-actions {
  display: flex;
  gap: 0.5rem;
}

/* Hero Weather Main Display */
.hero-weather-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.temp-display-group {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.weather-hero-icon {
  width: 96px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 10px 15px rgba(56, 189, 248, 0.3));
}

.weather-hero-icon img, 
.weather-hero-icon svg {
  width: 100%;
  height: 100%;
}

.temp-large {
  font-family: var(--font-display);
  font-size: 4.75rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  background: linear-gradient(180deg, #ffffff 30%, #cbd5e1 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.temp-unit-symbol {
  font-size: 2.2rem;
  font-weight: 600;
  color: var(--accent-cyan);
  vertical-align: top;
  margin-left: 0.2rem;
}

.condition-details {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.condition-text {
  font-size: 1.65rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: -0.01em;
}

.feels-like-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.temp-high-low {
  font-size: 0.9rem;
  color: var(--text-secondary);
  display: flex;
  gap: 0.75rem;
}

.temp-high-low span {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* Quick Metrics Row */
.quick-metrics-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 1rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.metric-pill {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: rgba(255, 255, 255, 0.04);
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.metric-pill i {
  font-size: 1.35rem;
  color: var(--accent-cyan);
}

.metric-pill .label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  display: block;
}

.metric-pill .val {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
}

/* ==========================================================================
   HOURLY FORECAST & CHART
   ========================================================================== */

.hourly-section {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.section-title {
  font-size: 1.15rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #fff;
}

.hourly-scroll-container {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}

.hourly-scroll-container::-webkit-scrollbar {
  height: 6px;
}

.hourly-scroll-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 9999px;
}

.hourly-card {
  min-width: 78px;
  padding: 0.85rem 0.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  text-align: center;
  transition: all 0.2s ease;
}

.hourly-card.now {
  background: rgba(56, 189, 248, 0.12);
  border-color: rgba(56, 189, 248, 0.35);
}

.hourly-card:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-2px);
}

.hourly-card .time {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.hourly-card .icon {
  font-size: 1.4rem;
  color: var(--accent-cyan);
}

.hourly-card .temp {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
}

.hourly-card .precip-prob {
  font-size: 0.72rem;
  color: #60a5fa;
  display: flex;
  align-items: center;
  gap: 0.2rem;
}

/* Hourly Trend Chart Box */
.chart-container {
  height: 140px;
  width: 100%;
  position: relative;
  margin-top: 0.5rem;
}

/* ==========================================================================
   7-DAY EXTENDED FORECAST
   ========================================================================== */

.daily-section {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.daily-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.daily-row {
  display: grid;
  grid-template-columns: 85px 120px 1fr 100px;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
}

.daily-row:hover {
  background: rgba(255, 255, 255, 0.06);
}

.daily-row .day-name {
  font-weight: 600;
  font-size: 0.95rem;
}

.daily-row .condition-col {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.daily-row .condition-col i {
  font-size: 1.25rem;
  color: var(--accent-cyan);
}

.daily-row .temp-bar-container {
  display: flex;
  align-items: center;
  position: relative;
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 9999px;
  overflow: hidden;
}

.daily-row .temp-bar-fill {
  position: absolute;
  height: 100%;
  border-radius: 9999px;
  background: linear-gradient(90deg, #38bdf8, #f59e0b, #ef4444);
}

.daily-row .temp-min-max {
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
  font-size: 0.9rem;
}

.daily-row .temp-min-max .min {
  color: var(--text-secondary);
}

.daily-row .temp-min-max .max {
  font-weight: 600;
  color: #fff;
}

@media (max-width: 640px) {
  .daily-row {
    grid-template-columns: 80px 1fr 90px;
  }
  .daily-row .condition-col span {
    display: none;
  }
}

/* ==========================================================================
   METRICS DETAIL GRID (UV, Wind, Air Quality, Sun/Moon, Pressure, etc.)
   ========================================================================== */

.metrics-detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
}

.metric-detail-card {
  padding: 1.35rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
}

.card-top-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
}

.card-top-title i {
  font-size: 1.15rem;
  color: var(--accent-cyan);
}

.card-main-val {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 700;
  color: #fff;
}

.card-subtext {
  font-size: 0.825rem;
  color: var(--text-secondary);
}

/* Air Quality Card Specifics */
.aqi-gauge-bar {
  height: 8px;
  width: 100%;
  border-radius: 9999px;
  background: linear-gradient(to right, #10b981, #f59e0b, #f97316, #ef4444, #8b5cf6, #7f1d1d);
  position: relative;
  margin: 0.5rem 0;
}

.aqi-marker {
  position: absolute;
  top: -4px;
  width: 16px;
  height: 16px;
  background: #fff;
  border: 3px solid #0f172a;
  border-radius: 50%;
  transform: translateX(-50%);
  box-shadow: 0 0 5px rgba(0,0,0,0.5);
  transition: left 0.5s ease;
}

.aqi-pollutants-list {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.5rem;
  font-size: 0.75rem;
  margin-top: 0.25rem;
}

.pollutant-badge {
  background: rgba(255, 255, 255, 0.04);
  padding: 0.35rem 0.5rem;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
}

.pollutant-badge .p-name {
  color: var(--text-muted);
}

.pollutant-badge .p-val {
  font-weight: 600;
  color: #fff;
}

/* Wind Compass Card */
.wind-display-layout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.compass-container {
  width: 72px;
  height: 72px;
  position: relative;
  border-radius: 50%;
  border: 2px dashed rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
}

.compass-needle {
  width: 4px;
  height: 32px;
  background: linear-gradient(to top, rgba(255, 255, 255, 0.2), var(--accent-rose));
  position: absolute;
  border-radius: 9999px;
  transform-origin: center bottom;
  top: 4px;
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.compass-labels {
  position: absolute;
  inset: 0;
  font-size: 0.6rem;
  color: var(--text-muted);
  font-weight: 600;
}

.compass-labels .c-n { position: absolute; top: 2px; left: 50%; transform: translateX(-50%); }
.compass-labels .c-s { position: absolute; bottom: 2px; left: 50%; transform: translateX(-50%); }
.compass-labels .c-e { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); }
.compass-labels .c-w { position: absolute; left: 4px; top: 50%; transform: translateY(-50%); }

/* Solar Cycle Arc Card */
.sun-curve-container {
  height: 60px;
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.sun-arc {
  width: 100%;
  height: 50px;
  border: 2px dashed rgba(255, 255, 255, 0.15);
  border-bottom: none;
  border-top-left-radius: 100px;
  border-top-right-radius: 100px;
  position: relative;
}

.sun-icon-position {
  position: absolute;
  width: 20px;
  height: 20px;
  color: var(--accent-amber);
  background: rgba(245, 158, 11, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 10px var(--accent-amber);
  transition: all 0.5s ease;
}

.solar-times-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* ==========================================================================
   INTERACTIVE RADAR MAP CONTAINER
   ========================================================================== */

.map-card {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.map-controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.map-layer-pills {
  display: flex;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 9999px;
  padding: 0.25rem;
  gap: 0.25rem;
}

.layer-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 0.775rem;
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.layer-btn.active {
  background: var(--accent-cyan);
  color: #0f172a;
}

#leaflet-map {
  height: 380px;
  width: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  z-index: 10;
}

/* Custom GPS pin icon on Map */
.custom-gps-pin {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gps-pin-dot {
  width: 14px;
  height: 14px;
  background: var(--accent-cyan);
  border: 3px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 10px var(--accent-cyan);
  z-index: 2;
}

.gps-pulse-ring {
  position: absolute;
  width: 36px;
  height: 36px;
  border: 2px solid var(--accent-cyan);
  border-radius: 50%;
  animation: gps-ping 1.8s infinite cubic-bezier(0, 0, 0.2, 1);
  z-index: 1;
}

@keyframes gps-ping {
  0% { transform: scale(0.5); opacity: 1; }
  100% { transform: scale(1.6); opacity: 0; }
}

/* ==========================================================================
   FAVORITES & SAVED LOCATIONS MODAL / DRAWER
   ========================================================================== */

.favorites-bar {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  overflow-x: auto;
  padding: 0.25rem 0;
  scrollbar-width: none;
}

.favorites-bar::-webkit-scrollbar {
  display: none;
}

.favorite-chip {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 9999px;
  padding: 0.35rem 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.825rem;
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.favorite-chip:hover {
  background: rgba(56, 189, 248, 0.15);
  border-color: var(--accent-cyan);
  color: #fff;
}

/* Loading Overlay */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  z-index: 9999;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.loading-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(56, 189, 248, 0.2);
  border-top-color: var(--accent-cyan);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

.loading-text {
  font-size: 1.1rem;
  font-weight: 500;
  color: #fff;
}

/* Notification Toast */
.toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.toast {
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(16px);
  border: 1px solid var(--card-border);
  color: #fff;
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.9rem;
  animation: slide-in 0.3s ease;
}

@keyframes slide-in {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
