/* ══════════════════════════════════════
   VOYRA — CSS DESIGN SYSTEM
   Vanilla CSS with CSS Variables & Glassmorphism
══════════════════════════════════════ */

:root {
  /* Dark Mode Tokens (Default) */
  --bg-night: #0a0e1a;
  --bg-deep: #111827;
  --bg-card: rgba(22, 29, 46, 0.65);
  --bg-card-solid: #161d2e;
  --border: rgba(255, 255, 255, 0.08);
  --text-white: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.55);
  --text-inverse: #0a0e1a;
  --line: rgba(255, 255, 255, 0.07);

  /* Shared Brand Accents */
  --gold: #c9a84c;
  --gold-light: #e6c97a;
  --gold-soft: rgba(201, 168, 76, 0.12);
  --sky: #4a9eff;
  --sky-soft: rgba(74, 158, 255, 0.12);
  --red: #ef4444;
  --red-soft: rgba(239, 68, 68, 0.1);
  --green: #22c55e;
  
  /* Fonts */
  --font-serif: 'Playfair Display', Georgia, serif;
  --font-sans: 'Instrument Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'DM Mono', monospace;

  /* Glassmorphism Details */
  --glass-bg: rgba(22, 29, 46, 0.6);
  --glass-blur: blur(12px) saturate(180%);
  --shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Light Mode Override (Warm Paper Aesthetic) */
body.light-mode {
  --bg-night: #f4f1ec;
  --bg-deep: #ede9e2;
  --bg-card: rgba(237, 233, 226, 0.85);
  --bg-card-solid: #ede9e2;
  --border: rgba(10, 14, 26, 0.1);
  --text-white: #0a0e1a;
  --text-muted: #7a7060;
  --text-inverse: #ffffff;
  --line: rgba(10, 14, 26, 0.07);
  --glass-bg: rgba(244, 241, 236, 0.8);
  --shadow: 0 8px 32px 0 rgba(10, 14, 26, 0.05);
}

/* ── BASIC RESET & GLOBAL ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  min-height: 100vh;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

body {
  background: var(--bg-night);
  color: var(--text-white);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  position: relative;
  transition: background 0.5s ease, color 0.3s ease;
}

/* Noise overlay */
.noise-overlay {
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.02'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

/* Scrollbars */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-night);
}
::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold);
}

/* Typography Utility */
.serif-title {
  font-family: var(--font-serif);
  font-weight: 700;
  letter-spacing: -0.02em;
}
.serif-title em {
  font-style: italic;
  color: var(--gold);
  font-weight: 400;
}
body.light-mode .serif-title em {
  color: var(--sky);
}

.label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-block;
  margin-bottom: 0.5rem;
}
.label.sky { color: var(--sky); }
.label.muted { color: var(--text-muted); }

/* ── BUTTONS ── */
.btn {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  justify-content: center;
  transition: var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--gold);
  color: var(--bg-night);
  font-weight: 600;
}
.btn-primary:hover {
  background: var(--gold-light);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(201, 168, 76, 0.3);
}

body.light-mode .btn-primary {
  background: var(--sky);
  color: #fff;
}
body.light-mode .btn-primary:hover {
  background: #64b5f6;
  box-shadow: 0 4px 15px rgba(74, 158, 255, 0.3);
}

.btn-outline {
  background: transparent;
  border-color: var(--border);
  color: var(--text-white);
}
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--text-white);
}
body.light-mode .btn-outline:hover {
  background: rgba(10, 14, 26, 0.05);
}

.btn-sm {
  padding: 0.45rem 1rem;
  font-size: 0.8rem;
}

.btn-block {
  width: 100%;
}

.btn-theme {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-white);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-family: var(--font-mono);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: var(--transition);
}
.btn-theme:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* Toggle icon display based on body mode */
body.light-mode .sun-icon,
body:not(.light-mode) .moon-icon {
  display: none;
}

/* ── FORM ELEMENTS ── */
.form-group {
  margin-bottom: 1.25rem;
}
.form-group label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--text-white);
}
.form-control {
  width: 100%;
  padding: 0.8rem 1rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-white);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
}
body.light-mode .form-control {
  background: rgba(10, 14, 26, 0.02);
}
.form-control:focus {
  border-color: var(--gold);
  background: rgba(255, 255, 255, 0.05);
}
body.light-mode .form-control:focus {
  border-color: var(--sky);
}
select.form-control {
  cursor: pointer;
}
select.form-control option {
  background: var(--bg-card-solid);
  color: var(--text-white);
}
body.light-mode select.form-control option {
  background: var(--bg-night);
  color: var(--text-white);
}

/* ── SPA LAYOUT ── */
.app-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  min-height: 100vh;
  width: 100%;
  max-width: 100%;
  transition: grid-template-columns 0.3s ease;
}

/* Hide sidebar layout completely during onboarding */
.app-layout.onboarding-active {
  grid-template-columns: 1fr;
}
.app-layout.onboarding-active .sidebar {
  display: none;
}

/* ── SIDEBAR STYLE ── */
.sidebar {
  background: var(--bg-deep);
  border-right: 1px solid var(--border);
  padding: 2.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100vh;
  position: sticky;
  top: 0;
  z-index: 10;
  transition: background 0.5s ease;
}

.sidebar-logo {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  font-weight: 900;
  font-style: italic;
  color: var(--text-white);
  margin-bottom: 3rem;
  letter-spacing: -0.03em;
}
.sidebar-logo span {
  color: var(--gold);
}
body.light-mode .sidebar-logo span {
  color: var(--sky);
}

.nav-menu {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex-grow: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.8rem 1rem;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  border-radius: 8px;
  transition: var(--transition);
}
.nav-item i {
  width: 18px;
  height: 18px;
}
.nav-item:hover {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-white);
}
body.light-mode .nav-item:hover {
  background: rgba(10, 14, 26, 0.03);
}

.nav-item.active {
  background: var(--gold-soft);
  color: var(--gold);
  font-weight: 600;
}
body.light-mode .nav-item.active {
  background: var(--sky-soft);
  color: var(--sky);
}

.nav-item.disabled {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
}

.sidebar-footer {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  border-radius: 8px;
  background: var(--gold-soft);
  color: var(--gold);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
}
.user-badge.hidden {
  display: none;
}

/* ── CONTENT CONTAINER ── */
.content-container {
  padding: 3rem 4rem;
  min-height: 100vh;
  position: relative;
  overflow-y: auto;
}

.app-screen {
  display: none;
  animation: fadeUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.app-screen.screen-active {
  display: block;
}

.screen-header-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 3rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}
.map-popup-body p {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.custom-map-pin {
  display: flex;
  align-items: center;
  justify-content: center;
}
.custom-map-pin .route-num {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--bg-night);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--text-white);
  box-shadow: 0 0 15px rgba(201, 168, 76, 0.6);
  transition: var(--transition);
}
body.light-mode .custom-map-pin .route-num {
  background: var(--sky);
  color: #fff;
  box-shadow: 0 0 15px rgba(74, 158, 255, 0.6);
}
.custom-map-pin:hover .route-num {
  transform: scale(1.15);
  box-shadow: 0 0 20px var(--gold);
}
body.light-mode .custom-map-pin:hover .route-num {
  box-shadow: 0 0 20px var(--sky);
}

.screen-header-wrapper h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.1;
}

/* ── CARDS (GLASSMORPHISM) ── */
.dashboard-card {
  background: var(--bg-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--shadow);
  transition: var(--transition);
}
.dashboard-card:hover {
  border-color: rgba(255, 255, 255, 0.15);
}
body.light-mode .dashboard-card:hover {
  border-color: rgba(10, 14, 26, 0.15);
}

/* ══════════════════════════════════════
   1. ONBOARDING SCREEN
══════════════════════════════════════ */
.onboarding-container {
  max-width: 800px;
  margin: 2rem auto;
  position: relative;
}

.onboarding-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 3rem;
}

.onboarding-logo {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 900;
  font-style: italic;
  color: var(--gold);
}
body.light-mode .onboarding-logo {
  color: var(--sky);
}

.onboarding-steps {
  display: flex;
  gap: 0.5rem;
}
.step-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  transition: var(--transition);
}
.step-dot.active {
  background: var(--gold);
  transform: scale(1.3);
}
body.light-mode .step-dot.active {
  background: var(--sky);
}

.onboarding-card {
  display: none;
  animation: fadeIn 0.5s ease forwards;
}
.onboarding-card.active {
  display: block;
}

.onboarding-card h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  line-height: 1.2;
  margin: 0.5rem 0 1rem 0;
}
.onboarding-card .subtitle {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 2.5rem;
}

.onboarding-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

/* Profile Select grid */
.profile-select-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
}

.profile-select-card {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.25rem 1rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  background: rgba(255, 255, 255, 0.02);
}
.profile-select-card .prof-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  display: block;
}
.profile-select-card h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.2rem;
}
.profile-select-card p {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.profile-select-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.04);
}
.profile-select-card.selected {
  border-color: var(--gold);
  background: var(--gold-soft);
  box-shadow: 0 0 15px rgba(201, 168, 76, 0.15);
}
body.light-mode .profile-select-card.selected {
  border-color: var(--sky);
  background: var(--sky-soft);
  box-shadow: 0 0 15px rgba(74, 158, 255, 0.15);
}

/* Budget options */
.budget-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.budget-card input {
  display: none;
}
.budget-card-content {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem 1.5rem;
  text-align: center;
  cursor: pointer;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}
.budget-card-content .budget-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}
.budget-card-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}
.budget-card-content p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
  flex-grow: 1;
  margin-bottom: 1rem;
}
.budget-card-content .price-indicator {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--gold);
  font-weight: 700;
}
body.light-mode .budget-card-content .price-indicator {
  color: var(--sky);
}
.budget-card input:checked + .budget-card-content {
  border-color: var(--gold);
  background: var(--gold-soft);
  box-shadow: 0 0 20px rgba(201, 168, 76, 0.15);
}
body.light-mode .budget-card input:checked + .budget-card-content {
  border-color: var(--sky);
  background: var(--sky-soft);
}

/* Onboarding form inputs */
.onboarding-form {
  max-width: 500px;
  margin: 0 auto;
}

.interests-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.interest-chip input {
  display: none;
}
.interest-chip span {
  padding: 0.45rem 1rem;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 0.85rem;
  cursor: pointer;
  display: inline-block;
  transition: var(--transition);
  background: rgba(255, 255, 255, 0.02);
}
.interest-chip input:checked + span {
  background: var(--gold-soft);
  border-color: var(--gold);
  color: var(--gold);
}
body.light-mode .interest-chip input:checked + span {
  background: var(--sky-soft);
  border-color: var(--sky);
  color: var(--sky);
}

/* ══════════════════════════════════════
   2. HOME SCREEN
══════════════════════════════════════ */
.home-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2.5rem;
}

.primary-trip-card {
  min-height: 250px;
  background: linear-gradient(135deg, var(--bg-card-solid) 0%, rgba(74, 158, 255, 0.05) 100%);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.primary-trip-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--gold);
}
body.light-mode .primary-trip-card::before {
  background: var(--sky);
}

.empty-state {
  text-align: center;
  padding: 2rem;
}
.empty-state .large-icon {
  width: 48px;
  height: 48px;
  color: var(--text-muted);
  margin-bottom: 1rem;
}
.empty-state h3 {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}
.empty-state p {
  color: var(--text-muted);
  font-size: 0.9rem;
  max-width: 45ch;
  margin: 0 auto 1.5rem;
}

/* Active Trip Info design */
.active-trip-info {
  position: relative;
  z-index: 2;
}
.active-trip-info h4 {
  font-size: 0.95rem;
  color: var(--gold);
}
body.light-mode .active-trip-info h4 {
  color: var(--sky);
}
.active-trip-info h2 {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  line-height: 1.1;
  margin: 0.25rem 0 1rem 0;
}
.active-trip-info p {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}
.active-trip-stats {
  display: flex;
  gap: 2rem;
  border-top: 1px solid var(--border);
  padding-top: 1.25rem;
}
.active-trip-stat {
  display: flex;
  flex-direction: column;
}
.active-trip-stat strong {
  font-size: 1.1rem;
}
.active-trip-stat span {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Recommendations */
.home-section-title {
  margin-top: 3rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.5rem;
}
.home-section-title h3 {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.home-section-title h3 span {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

.recommendations-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.rec-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  transition: var(--transition);
  cursor: pointer;
}
.rec-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold);
}
body.light-mode .rec-card:hover {
  border-color: var(--sky);
}
.rec-card-image-placeholder {
  height: 120px;
  background: linear-gradient(to bottom, var(--bg-deep), rgba(74, 158, 255, 0.1));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
}
.rec-card-body {
  padding: 1.25rem;
}
.rec-card-body h4 {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}
.rec-card-body p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 0.75rem;
}

/* Home side column */
.home-side-col {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.stats-card h3, .favorites-card h3 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  margin-bottom: 1.25rem;
}
.stats-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  text-align: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1.5rem;
}
.stat-item {
  display: flex;
  flex-direction: column;
}
.stat-num {
  font-family: var(--font-mono);
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold);
}
body.light-mode .stat-num {
  color: var(--sky);
}
.stat-lbl {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.profile-summary {
  padding-top: 1.25rem;
}
.profile-badge-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.prof-badge {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.6rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-muted);
}

.favorites-teaser-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.fav-teaser-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--line);
}
.fav-teaser-item:last-child {
  border-bottom: none;
}
.fav-teaser-emoji {
  font-size: 1.2rem;
}
.fav-teaser-info h5 {
  font-size: 0.85rem;
  font-weight: 600;
}
.fav-teaser-info p {
  font-size: 0.7rem;
  color: var(--text-muted);
}
.empty-text {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  font-style: italic;
}

/* ══════════════════════════════════════
   3. CREATE TRIP SCREEN
══════════════════════════════════════ */
.create-trip-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2.5rem;
}

.create-card {
  background: var(--bg-card);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2.5rem;
}

.form-row {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1.25rem;
}
.form-row .flex-1 { flex: 1; }
.form-row .flex-2 { flex: 2; }

.dates-row .form-group {
  flex: 1;
}

.btn-generate-trip {
  margin-top: 1.5rem;
  padding: 1rem;
  font-size: 1rem;
}

.tips-panel {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.tip-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  gap: 1rem;
}
.tip-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.03);
}
.gold-color { color: var(--gold); }
.sky-color { color: var(--sky); }

.tip-content h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}
.tip-content p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ── MODALS & LOADING OVERLAYS ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 14, 26, 0.85);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.loading-content {
  text-align: center;
  max-width: 400px;
  padding: 2rem;
}
.spinner-outer {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 3px solid rgba(201, 168, 76, 0.1);
  border-top-color: var(--gold);
  animation: rotate 1.5s linear infinite;
  margin: 0 auto 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
body.light-mode .spinner-outer {
  border-color: rgba(74, 158, 255, 0.1);
  border-top-color: var(--sky);
}
.spinner-inner {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 3px solid transparent;
  border-bottom-color: var(--sky);
  animation: rotate-reverse 1s linear infinite;
}
body.light-mode .spinner-inner {
  border-bottom-color: var(--gold);
}

.loading-content h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}
.loading-content p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}
.progress-bar-container {
  width: 100%;
  height: 6px;
  background: var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.progress-bar-container.mini {
  height: 4px;
}
.progress-bar-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold) 0%, var(--sky) 100%);
  transition: width 0.2s ease;
}

@keyframes rotate {
  100% { transform: rotate(360deg); }
}
@keyframes rotate-reverse {
  100% { transform: rotate(-360deg); }
}

/* ══════════════════════════════════════
   4. DAILY ITINERARY SCREEN
══════════════════════════════════════ */
.itinerary-banner {
  height: 250px;
  border-radius: 12px;
  position: relative;
  overflow: hidden;
  margin-bottom: 2rem;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
  padding: 3rem;
  box-shadow: var(--shadow);
}
.banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10, 14, 26, 0.95) 0%, rgba(10, 14, 26, 0.3) 100%);
}
body.light-mode .banner-overlay {
  background: linear-gradient(to top, rgba(244, 241, 236, 0.95) 0%, rgba(244, 241, 236, 0.3) 100%);
}
.banner-content {
  position: relative;
  z-index: 2;
}
.banner-tags {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}
.badge {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.25rem 0.65rem;
  border-radius: 4px;
  border: 1px solid transparent;
}
.badge.gold { border-color: rgba(201, 168, 76, 0.3); color: var(--gold-light); background: var(--gold-soft); }
.badge.sky { border-color: rgba(74, 158, 255, 0.3); color: var(--sky); background: var(--sky-soft); }

.itinerary-meta {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  margin-top: 0.25rem;
}

.itinerary-layout {
  display: grid;
  grid-template-columns: 2.5fr 1fr;
  gap: 2.5rem;
}

/* Day tabs scroll */
.day-tabs-scroll {
  overflow-x: auto;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}
.day-tabs {
  display: flex;
  gap: 0.5rem;
}
.day-tab-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 0.5rem 1.25rem;
  border-radius: 8px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
}
.day-tab-btn:hover {
  color: var(--text-white);
  border-color: var(--text-white);
}
.day-tab-btn.active {
  background: var(--text-white);
  color: var(--text-inverse);
  border-color: var(--text-white);
  font-weight: 600;
}

/* Day summary card */
.day-summary-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.25rem 2rem;
  margin-bottom: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
}
.summary-stat {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.summary-stat i {
  color: var(--gold);
}
body.light-mode .summary-stat i {
  color: var(--sky);
}
.summary-val {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 700;
  display: block;
}
.summary-lbl {
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* Timeline */
.timeline {
  position: relative;
  padding-left: 2rem;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 5px;
  top: 0.5rem;
  bottom: 0.5rem;
  width: 2px;
  background: var(--border);
}

.timeline-item {
  position: relative;
  margin-bottom: 2rem;
}
.timeline-item::before {
  content: '';
  position: absolute;
  left: -2rem;
  top: 0.5rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg-night);
  border: 2px solid var(--gold);
  transform: translateX(-50%);
  transition: var(--transition);
}
body.light-mode .timeline-item::before {
  border-color: var(--sky);
}
.timeline-item:hover::before {
  background: var(--gold);
  box-shadow: 0 0 10px var(--gold);
}
body.light-mode .timeline-item:hover::before {
  background: var(--sky);
  box-shadow: 0 0 10px var(--sky);
}

.time-tag {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--gold);
  font-weight: 500;
  margin-bottom: 0.25rem;
  display: block;
}
body.light-mode .time-tag {
  color: var(--sky);
}

.timeline-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
  transition: var(--transition);
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
}
.timeline-card:hover {
  border-color: rgba(255, 255, 255, 0.15);
}
body.light-mode .timeline-card:hover {
  border-color: rgba(10, 14, 26, 0.15);
}
.timeline-body {
  flex-grow: 1;
}
.timeline-body h4 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.timeline-body p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.timeline-actions {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-end;
  flex-shrink: 0;
}
.timeline-cost {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 600;
}
.action-icon-row {
  display: flex;
  gap: 0.5rem;
}
.btn-icon {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 4px;
  transition: var(--transition);
}
.btn-icon:hover {
  color: var(--text-white);
  background: rgba(255, 255, 255, 0.05);
}
body.light-mode .btn-icon:hover {
  background: rgba(10, 14, 26, 0.05);
}
.btn-icon.fav-active {
  color: #fbbf24;
}

/* Sidebar itinerary details */
.itinerary-sidebar {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.quick-nav-card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
}
.quick-nav-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.quick-btn-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-white);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: var(--transition);
}
.quick-btn-link:hover {
  border-color: var(--gold);
  background: var(--gold-soft);
}
body.light-mode .quick-btn-link:hover {
  border-color: var(--sky);
  background: var(--sky-soft);
}

.budget-breakdown-card {
  padding: 1.5rem;
}
.budget-chart-rows {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.chart-row {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.chart-row-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
}
.chart-row-meta span {
  color: var(--text-muted);
}
.chart-bar-bg {
  height: 4px;
  background: var(--border);
  border-radius: 2px;
}
.chart-bar-fill {
  height: 100%;
  background: var(--gold);
  border-radius: 2px;
}
body.light-mode .chart-bar-fill {
  background: var(--sky);
}

.budget-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--border);
  padding-top: 1rem;
  font-size: 0.9rem;
}
.budget-total-row strong {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  color: var(--gold);
}
body.light-mode .budget-total-row strong {
  color: var(--sky);
}

/* Modals */
.modal-card {
  background: var(--bg-card-solid);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  width: 90%;
  max-width: 500px;
  box-shadow: var(--shadow);
  position: relative;
  animation: modalScale 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}
.modal-header h3 {
  font-family: var(--font-serif);
  font-size: 1.3rem;
}
.btn-close-modal {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.7rem;
  cursor: pointer;
  line-height: 1;
}

@keyframes modalScale {
  0% { transform: scale(0.9); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

/* ══════════════════════════════════════
   5. SMART MAP SCREEN
══════════════════════════════════════ */
.full-screen-map {
  padding: 0 !important; /* Full width map style */
  height: 100vh;
  position: relative;
}

.map-container-element {
  width: 100%;
  height: 100%;
  z-index: 1;
}

/* Dark theme background for Google Maps container element */
body:not(.light-mode) .map-container-element {
  background: #0d1221;
}


.map-header-overlay {
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;
  right: 1.5rem;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
}
.map-header-info {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 1.25rem;
  pointer-events: auto;
  box-shadow: var(--shadow);
}
.map-header-info h2 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  margin: 0;
}
.map-day-selector {
  display: flex;
  gap: 0.5rem;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border);
  padding: 0.35rem;
  border-radius: 8px;
  pointer-events: auto;
  box-shadow: var(--shadow);
}
.map-day-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: 0.4rem 1rem;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  cursor: pointer;
  transition: var(--transition);
}
.map-day-btn.active {
  background: var(--text-white);
  color: var(--text-inverse);
  font-weight: 600;
}

/* Map route list sidebar */
.map-sidebar-route {
  position: absolute;
  top: 7rem;
  right: 1.5rem;
  bottom: 1.5rem;
  width: 320px;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  z-index: 100;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.map-sidebar-route h3 {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.5rem;
}
.route-timeline {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  position: relative;
}
.route-step {
  display: flex;
  gap: 0.75rem;
  position: relative;
}
.route-num {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--bg-night);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
body.light-mode .route-num {
  background: var(--sky);
  color: #fff;
}
.route-details h5 {
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.15rem;
}
.route-details p {
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* Customize google maps info window overlays */
.gm-style-iw.gm-style-iw-c {
  background-color: var(--bg-card-solid) !important;
  border: 1px solid var(--border) !important;
  border-radius: 8px !important;
  padding: 8px 12px !important;
  max-width: 280px !important;
  box-shadow: var(--shadow) !important;
}
.gm-style-iw-d {
  overflow: auto !important;
  color: var(--text-white) !important;
}
.gm-style-iw-tc::after {
  background: var(--bg-card-solid) !important;
}
.gm-ui-hover-effect {
  top: 4px !important;
  right: 4px !important;
}
.gm-style-cc, .gmnoprint, a[href*="google.com/maps"] {
  display: none !important;
}
.map-popup-body h4 {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}
.map-popup-body p {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ══════════════════════════════════════
   6. ORGANIZER & DOCUMENTS SCREEN
══════════════════════════════════════ */
.organizer-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
}

.org-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--shadow);
}
.org-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}
.org-card-header h3 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Checklist specific */
.add-todo-row {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}
.todo-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.todo-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.01);
  transition: var(--transition);
}
.todo-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.todo-checkbox {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  border: 1.5px solid var(--border);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.todo-checkbox.checked {
  background: var(--gold);
  border-color: var(--gold);
}
body.light-mode .todo-checkbox.checked {
  background: var(--sky);
  border-color: var(--sky);
}
.todo-checkbox i {
  color: var(--bg-night);
  width: 12px;
  height: 12px;
}
.todo-text {
  font-size: 0.9rem;
  transition: var(--transition);
}
.todo-text.checked {
  color: var(--text-muted);
  text-decoration: line-through;
}

/* Right side col */
.org-right-col {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.reservations-card h3, .vault-card h3 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.res-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 1rem;
}
.res-group label {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.35rem;
}

/* Vault documents upload drag and drop */
.drop-zone {
  border: 2px dashed var(--border);
  border-radius: 8px;
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  margin-top: 1.25rem;
}
.drop-zone:hover {
  border-color: var(--gold);
  background: rgba(255, 255, 255, 0.02);
}
body.light-mode .drop-zone:hover {
  border-color: var(--sky);
}
.cloud-icon {
  width: 32px;
  height: 32px;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.file-list-wrapper {
  margin-top: 1.5rem;
}
.file-list-wrapper h4 {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  font-family: var(--font-mono);
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.35rem;
  margin-bottom: 0.75rem;
}
.file-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.50rem;
}
.file-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0.75rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
  border-radius: 6px;
}
.file-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
}
.file-info span {
  max-width: 180px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.file-size {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
}
.empty-files {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
  padding: 1rem;
}

/* ══════════════════════════════════════
   7. PROFILE SCREEN
══════════════════════════════════════ */
.profile-layout {
  display: grid;
  grid-template-columns: 2fr 1.25fr;
  gap: 2.5rem;
}

.profile-main {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

/* Premium card banner */
.premium-promo-card {
  position: relative;
  background: linear-gradient(135deg, #101827 0%, #1e1b4b 100%);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2.5rem;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.premium-promo-card::before {
  content: '';
  position: absolute;
  top: -100px;
  right: -100px;
  width: 250px;
  height: 250px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 168, 76, 0.15) 0%, transparent 70%);
}

.premium-promo-card.premium-active {
  background: linear-gradient(135deg, #101827 0%, #2b210f 100%);
  border-color: rgba(201, 168, 76, 0.5);
}
.premium-promo-card.premium-active::before {
  background: radial-gradient(circle, rgba(201, 168, 76, 0.35) 0%, transparent 70%);
}

.promo-content {
  position: relative;
  z-index: 2;
}
.promo-content h2 {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  line-height: 1.2;
  margin: 0.5rem 0 1rem 0;
}
.promo-content p {
  color: var(--text-muted);
  font-size: 0.95rem;
  max-width: 55ch;
  margin-bottom: 2rem;
}

.pricing-badge-row {
  display: flex;
  gap: 2.5rem;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}
.price-bubble {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.25rem 2rem;
  text-align: center;
}
.price-bubble .curr {
  font-size: 1rem;
  color: var(--gold);
}
.price-bubble .val {
  font-family: var(--font-serif);
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--gold);
  line-height: 1;
}
.price-bubble .per {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: block;
}

.features-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.features-list span {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-white);
}

/* Settings card list */
.profile-card-settings h3 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  margin-bottom: 1.25rem;
}
.settings-rows {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.settings-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 1.5rem;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
}
.settings-row:last-child {
  border-bottom: none;
}
.settings-row h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.15rem;
}
.settings-row p {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Switch toggle */
.switch-toggle {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
}
.switch-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}
.switch-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: var(--border);
  transition: .3s;
  border-radius: 34px;
}
.switch-slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 4px;
  bottom: 4px;
  background-color: var(--text-white);
  transition: .3s;
  border-radius: 50%;
}
.switch-toggle input:checked + .switch-slider {
  background-color: var(--gold);
}
body.light-mode .switch-toggle input:checked + .switch-slider {
  background-color: var(--sky);
}
.switch-toggle input:checked + .switch-slider:before {
  transform: translateX(20px);
}

/* Profile right stats */
.profile-sidebar {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.profile-card-stats {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
}
.avatar-wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1.5rem;
}
.avatar-letter {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--gold-soft);
  color: var(--gold);
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
body.light-mode .avatar-letter {
  background: var(--sky-soft);
  color: var(--sky);
}
.avatar-wrap h4 {
  font-size: 1.1rem;
  font-weight: 700;
}

.mini-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.mini-stat-box {
  text-align: center;
  background: rgba(255, 255, 255, 0.01);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 0.5rem;
}
.mini-stat-box strong {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  color: var(--gold);
  display: block;
}
body.light-mode .mini-stat-box strong {
  color: var(--sky);
}
.mini-stat-box span {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.past-trips-card h3 {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
}
.past-trips-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.past-trip-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: rgba(255,255,255,0.01);
}
.past-trip-info h5 {
  font-size: 0.85rem;
  font-weight: 600;
}
.past-trip-info p {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
}
.past-trip-badge {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  padding: 0.2rem 0.5rem;
  background: var(--border);
  border-radius: 4px;
}

/* ── KEYFRAME ANIMATIONS ── */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ── MOBILE BOTTOM NAVIGATION ── */
.mobile-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 68px;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-top: 1px solid var(--border);
  display: none; /* Hidden on desktop */
  justify-content: space-around;
  align-items: center;
  z-index: 1000;
  box-shadow: var(--shadow);
  padding: 0 0.5rem;
  transition: background 0.5s ease, border-color 0.3s ease;
}

.mobile-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  text-decoration: none;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 500;
  gap: 4px;
  flex: 1;
  height: 100%;
  transition: var(--transition);
  position: relative;
  border-radius: 8px;
}

.mobile-nav-item i {
  width: 20px;
  height: 20px;
  transition: var(--transition);
}

.mobile-nav-item span {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.mobile-nav-item.active {
  color: var(--gold);
}

body.light-mode .mobile-nav-item.active {
  color: var(--sky);
}

.mobile-nav-item.active i {
  transform: translateY(-2px);
}

.mobile-nav-item.disabled {
  opacity: 0.25;
  cursor: not-allowed;
  pointer-events: none;
}

/* ── RESPONSIVE ADAPTATIONS ── */
@media (max-width: 992px) {
  .app-layout {
    grid-template-columns: 80px 1fr;
  }
  .sidebar {
    padding: 2rem 0.75rem;
    align-items: center;
  }
  .sidebar-logo {
    font-size: 1.3rem;
    margin-bottom: 2rem;
  }
  .sidebar-logo span {
    display: none;
  }
  .nav-item span, .btn-theme span, #sidebar-premium-tag span {
    display: none;
  }
  .nav-item {
    justify-content: center;
    padding: 0.8rem;
  }
  .btn-theme {
    padding: 0.5rem;
    border-radius: 50%;
  }
  .content-container {
    padding: 2rem;
  }
  .home-grid, .create-trip-layout, .itinerary-layout, .organizer-layout, .profile-layout {
    grid-template-columns: 1fr;
  }
  .home-side-col, .tips-panel, .itinerary-sidebar, .org-right-col, .profile-sidebar {
    margin-top: 2rem;
  }
  .map-sidebar-route {
    display: none; /* Hide map details on small screens to save space */
  }
}

@media (max-width: 768px) {
  .app-layout {
    grid-template-columns: 1fr;
    min-height: 100vh;
  }
  .app-layout:not(.onboarding-active) {
    padding-top: 60px;
    padding-bottom: 68px;
  }
  .app-layout.onboarding-active .mobile-bottom-nav {
    display: none !important;
  }
  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    width: 100%;
    padding: 0 1.25rem;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-right: none;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
  }
  .sidebar-logo {
    margin-bottom: 0;
    font-size: 1.4rem;
  }
  .sidebar-logo span {
    display: inline;
  }
  .sidebar .nav-menu {
    display: none;
  }
  .sidebar-footer {
    border-top: none;
    padding-top: 0;
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0;
  }
  .btn-theme span, #sidebar-premium-tag span {
    display: none;
  }
  .btn-theme {
    padding: 0.5rem;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  #sidebar-premium-tag {
    padding: 0.5rem;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  .content-container {
    padding: 1.5rem 1rem;
    min-height: auto;
    overflow-x: hidden; /* Prevent horizontal container bleed */
  }
  .mobile-bottom-nav {
    display: flex;
  }
  
  /* Grid and Column stack overrides on mobile */
  .recommendations-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .res-grid {
    grid-template-columns: 1fr;
  }
  .timeline-card {
    flex-direction: column;
    gap: 1rem;
    padding: 1.25rem;
  }
  .timeline-actions {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border);
    padding-top: 0.75rem;
    margin-top: 0.25rem;
    width: 100%;
  }
  
  /* Form responsiveness */
  .form-row {
    flex-direction: column;
    gap: 0;
  }
  .budget-options {
    grid-template-columns: 1fr;
  }
  .day-summary-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  /* Map overlays and heights */
  .full-screen-map {
    height: calc(100vh - 128px) !important;
  }
  .map-header-overlay {
    top: 0.75rem;
    left: 0.75rem;
    right: 0.75rem;
    flex-direction: column;
    gap: 0.5rem;
    align-items: stretch;
  }
  .map-header-info {
    padding: 0.5rem 0.75rem;
    text-align: center;
    width: 100%;
  }
  .map-day-selector {
    justify-content: flex-start;
    overflow-x: auto;
    white-space: nowrap;
    max-width: 100%;
    padding: 0.25rem;
    -webkit-overflow-scrolling: touch;
  }
  .map-day-selector::-webkit-scrollbar {
    display: none;
  }
  .map-day-btn {
    padding: 0.4rem 0.75rem;
    font-size: 0.7rem;
    flex-shrink: 0;
  }
}

