@import url('https://fonts.googleapis.com/css2?family=Alex+Brush&family=Caveat:wght@700&family=Dancing+Script:wght@700&family=Great+Vibes&display=swap');

/* ==========================================================================
   STANDALONE TOUR ITINERARY & LUXURY QUOTATION STUDIO STYLESHEET
   Taxi Service in Ahmedabad — Internal Admin Tool
   ========================================================================== */

:root {
  --bg-main: #0a0f1a;
  --bg-card: rgba(16, 24, 42, 0.95);
  --bg-card-hover: rgba(22, 32, 54, 0.98);
  --bg-input: #0d1322;
  --bg-input-focus: #111a30;
  
  --border-color: rgba(255, 255, 255, 0.09);
  --border-gold: rgba(255, 204, 0, 0.4);
  
  --primary-gold: #FFCC00;
  --primary-gold-light: #FFE066;
  --primary-gold-dark: #E5A900;
  --primary-gold-glow: rgba(255, 204, 0, 0.3);
  
  --text-main: #F1F5F9;
  --text-muted: #94A3B8;
  --text-dim: #64748B;
  --text-bright: #FFFFFF;
  
  --success: #10B981;
  --warning: #FFCC00;
  --danger: #EF4444;
  --info: #38BDF8;
  
  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Outfit', var(--font-sans);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: var(--font-sans);
  -webkit-tap-highlight-color: transparent;
}

html {
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
}

body {
  background-color: var(--bg-main);
  background-image: radial-gradient(at 0% 0%, rgba(255, 204, 0, 0.06) 0px, transparent 50%),
                    radial-gradient(at 100% 100%, rgba(56, 189, 248, 0.03) 0px, transparent 50%);
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.5;
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
  position: relative;
}

/* Header */
.studio-header {
  background: linear-gradient(180deg, #111827 0%, #0d121f 100%);
  border-bottom: 1px solid rgba(255, 204, 0, 0.3);
  padding: 8px 20px;
  min-height: 72px;
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.studio-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
}

.btn-sidebar-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  min-width: 38px;
  min-height: 38px;
  background: rgba(255, 255, 255, 0.08);
  color: #f1f5f9;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.05rem;
  padding: 0;
  line-height: 1;
  flex-shrink: 0;
  transition: all 0.18s ease;
  outline: none;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.btn-sidebar-toggle:hover {
  background: rgba(255, 204, 0, 0.2);
  border-color: #FFCC00;
  color: #FFCC00;
  transform: translateY(-1px);
}

.btn-sidebar-toggle:active {
  transform: scale(0.95);
}

.studio-header-brand-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1 1 auto;
}

.studio-header-logo {
  height: 56px;
  width: auto;
  max-width: 220px;
  object-fit: contain;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.5));
}

.studio-header-app-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.studio-title {
  font-family: 'Outfit', sans-serif;
  font-size: 0.96rem;
  font-weight: 800;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: 0.3px;
  margin: 0;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.studio-title-icon {
  color: #FFCC00;
  font-size: 1rem;
  flex-shrink: 0;
}

.studio-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.studio-brand img {
  height: 38px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.4));
}
.studio-tag {
  background: linear-gradient(135deg, #FFCC00, #E5A900);
  color: #000;
  font-size: 9.5px;
  font-weight: 900;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}
.studio-sub {
  font-size: 11.5px;
  color: #94a3b8;
  margin-top: 1px;
}
.studio-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-new-quote-head {
  background: #FFCC00;
  color: #0a0f1a !important;
  font-weight: 800;
  border-radius: 6px;
  padding: 7px 14px;
  font-size: 0.84rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 10px rgba(255, 204, 0,0.35);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-header-reset {
  background: rgba(255, 204, 0, 0.15) !important;
  border: 1px solid #FFCC00 !important;
  color: #ffedd5 !important;
  box-shadow: none !important;
}

.btn-header-reset:hover {
  background: rgba(255, 204, 0, 0.3) !important;
  color: #ffffff !important;
}

.btn-header-records {
  background: rgba(255, 255, 255, 0.08) !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  color: #f1f5f9 !important;
  box-shadow: none !important;
}

.btn-header-records:hover {
  background: rgba(255, 255, 255, 0.16) !important;
  color: #ffffff !important;
}

.btn-new-quote-head:hover {
  background: #ff8c1a;
  transform: translateY(-1px);
}

.btn-label-mobile {
  display: none;
}
.btn-label-desktop {
  display: inline;
}

@media (max-width: 640px) {
  .studio-header {
    padding: 0 10px;
    gap: 8px;
  }
  .studio-header-left {
    gap: 8px;
    min-width: 0;
    flex-shrink: 1;
  }
  .studio-header-brand-wrap {
    gap: 6px;
  }
  .studio-header-logo {
    height: 46px;
    max-width: 160px;
  }
  .studio-header-app-title {
    display: none;
  }
  .studio-header-actions {
    gap: 6px;
  }
  .btn-new-quote-head {
    padding: 6px 10px;
    font-size: 0.78rem;
    gap: 5px;
  }
  .btn-label-desktop {
    display: none;
  }
  .btn-label-mobile {
    display: inline;
  }
}

@media (min-width: 480px) and (max-width: 640px) {
  .studio-header-app-title {
    display: inline;
    font-size: 0.90rem;
  }
}

/* Container */
.studio-container {
  max-width: 1440px;
  margin: 0 auto;
  padding: 20px 20px 80px 20px;
}

/* Quick Start Guide Banner */
.guide-banner {
  background: linear-gradient(90deg, rgba(255, 204, 0, 0.12) 0%, rgba(15, 23, 42, 0.8) 100%);
  border: 1px solid rgba(255, 204, 0, 0.3);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}
.guide-icon {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--primary-gold);
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.guide-text {
  font-size: 12px;
  color: #e2e8f0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  align-items: center;
}
.guide-text strong {
  color: var(--primary-gold);
}

/* Copilot Panel */
.panel-copilot {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.8) 0%, rgba(15, 23, 42, 0.95) 100%);
  border: 1px solid rgba(255, 204, 0, 0.3);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.panel-copilot-header {
  background: rgba(15, 23, 42, 0.9);
  padding: 12px 18px;
  border-bottom: 1px solid rgba(255, 204, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.panel-step-badge {
  background: linear-gradient(135deg, #FFCC00, #E5A900);
  color: #000;
  font-weight: 900;
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
}
.panel-step-title {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
  flex: 1;
}
.tab-switch {
  display: flex;
  gap: 6px;
}
.tab-btn {
  background: transparent;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.12);
  cursor: pointer;
  transition: all 0.2s;
}
.tab-btn.active {
  background: var(--primary-gold);
  color: #0b0f19;
  border-color: var(--primary-gold);
  font-weight: 700;
}
.panel-copilot-body {
  padding: 18px;
}

/* Presets Grid */
.presets-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
}
.preset-card {
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px 11px;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}
.preset-card:hover, .preset-card.active-preset {
  background: rgba(255, 204, 0, 0.12);
  border-color: var(--primary-gold);
  transform: translateY(-2px);
  box-shadow: 0 4px 18px rgba(0,0,0,0.4);
}
.preset-badge {
  font-size: 9px;
  font-weight: 800;
  color: var(--primary-gold);
  letter-spacing: 0.5px;
  margin-bottom: 3px;
}
.preset-name {
  font-size: 12px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 3px;
  line-height: 1.25;
}
.preset-route {
  font-size: 10px;
  color: var(--text-muted);
  margin-bottom: 5px;
  line-height: 1.3;
}
.preset-price {
  font-size: 12px;
  font-weight: 800;
  color: var(--primary-gold);
}
.preset-car {
  font-size: 10px;
  color: #94a3b8;
  font-weight: 400;
}

/* AI Form Grid */
.ai-form-grid {
  display: grid;
  grid-template-columns: 2fr 90px 1.4fr auto;
  gap: 12px;
  align-items: flex-end;
}
.btn-generate {
  height: 40px;
  padding: 0 18px;
  font-weight: 700;
  white-space: nowrap;
}
.ai-chips-wrap {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.chips-label {
  font-size: 11.5px;
  color: var(--text-muted);
  font-weight: 600;
}
.chip-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  font-size: 11px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.chip-btn:hover {
  background: rgba(255, 204, 0, 0.15);
  border-color: var(--primary-gold);
  color: #fff;
  transform: translateY(-1px);
}

/* Workspace 2-Column Grid */
.workspace-grid {
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  gap: 20px;
  align-items: start;
}
.workspace-right {
  position: sticky;
  top: 75px;
}

/* Cards & Headers */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: visible;
  box-shadow: 0 4px 20px rgba(0,0,0,0.25);
}
.card-header-styled {
  background: rgba(20, 29, 48, 0.8);
  padding: 12px 18px;
  border-bottom: 1px solid var(--border-color);
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  gap: 10px;
}
.card-header-styled.space-between {
  justify-content: space-between;
  flex-wrap: wrap;
}
.card-title {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
}
.card-body-styled {
  padding: 18px;
}
.mb-4 {
  margin-bottom: 20px;
}

/* Form Controls */
.field-label {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 5px;
}
.form-control {
  width: 100%;
  padding: 8px 12px;
  background: var(--bg-input) !important;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-main) !important;
  font-size: 13px;
  outline: none;
  transition: all 0.2s ease;
}
.form-control:focus {
  border-color: var(--primary-gold);
  box-shadow: 0 0 0 2px var(--primary-gold-glow);
  background: var(--bg-input-focus) !important;
}

/* Fix Browser Autofill turning inputs white */
.form-control:-webkit-autofill,
.form-control:-webkit-autofill:hover, 
.form-control:-webkit-autofill:focus, 
.form-control:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px #0d1322 inset !important;
  -webkit-text-fill-color: #f1f5f9 !important;
  caret-color: #f1f5f9 !important;
  border-color: var(--border-color) !important;
  transition: background-color 5000s ease-in-out 0s;
}

.form-control:-webkit-autofill:focus {
  border-color: var(--primary-gold) !important;
  -webkit-box-shadow: 0 0 0 1000px #111a30 inset, 0 0 0 2px var(--primary-gold-glow) !important;
}
.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}
.form-grid-4 {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}
.form-group-wrap {
  margin-bottom: 12px;
}
.vehicle-select {
  font-weight: 700;
  background: #131b2e;
  border-color: rgba(255, 204, 0, 0.4);
}

/* Day Wise Itinerary Editor */
.day-controls {
  display: flex;
  gap: 6px;
}
.days-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.itinerary-day-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.2s ease;
}
.itinerary-day-card:hover {
  border-color: rgba(255, 204, 0, 0.3);
}
.history-item-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: all 0.2s ease;
}
.history-item-card:hover {
  border-color: rgba(255, 204, 0, 0.5) !important;
  background: rgba(255, 255, 255, 0.06) !important;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
  transform: translateY(-2px);
}
.history-sidebar-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 10400;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.history-sidebar-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}
.history-sidebar-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 500px;
  max-width: 100vw;
  background: #0a101f;
  border-left: 1.5px solid rgba(255, 204, 0, 0.35);
  box-shadow: -10px 0 40px rgba(0, 0, 0, 0.85);
  z-index: 10450;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}
.history-sidebar-drawer.active {
  transform: translateX(0);
}
.itinerary-day-header {
  padding: 10px 14px;
  background: rgba(30, 41, 59, 0.6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.day-badge {
  background: var(--primary-gold);
  color: #0b0f19;
  font-weight: 800;
  font-size: 10.5px;
  padding: 2px 7px;
  border-radius: 4px;
  flex-shrink: 0;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* Pricing Card & Breakdown */
.pricing-card {
  border: 1px solid rgba(255, 204, 0, 0.35);
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
}
.badge-live {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.4);
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
}
.fare-summary-box {
  background: rgba(10, 15, 26, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 12px 14px;
  margin-top: 14px;
  margin-bottom: 16px;
}
.fare-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #cbd5e1;
  margin-bottom: 7px;
}
.fare-row strong {
  color: #ffffff;
}
.fare-discount {
  color: #10b981;
}
.fare-total-row {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 10px;
  margin-top: 6px;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.fare-total-label {
  font-size: 12.5px;
  font-weight: 700;
  color: #ffffff;
  text-transform: uppercase;
}
.fare-total-note {
  font-size: 10px;
  color: var(--primary-gold);
}
.fare-total-price {
  font-family: 'Outfit', sans-serif;
  font-size: 24px;
  font-weight: 900;
  color: var(--primary-gold);
}

/* Dispatch Actions */
.action-buttons-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.actions-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.btn-block {
  width: 100%;
}
.btn-whatsapp {
  background: #25D366;
  color: #ffffff;
  font-weight: 700;
}
.btn-whatsapp:hover {
  background: #1ebc57;
  color: #ffffff;
}

/* Common Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 14px;
  font-size: 12.5px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn-primary {
  background: linear-gradient(135deg, #FFCC00 0%, #D95F00 100%);
  color: #0b0f19;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(255, 204, 0, 0.3);
}
.btn-primary:hover {
  background: linear-gradient(135deg, #FF8C1A 0%, #FFCC00 100%);
  transform: translateY(-1px);
}
.btn-secondary {
  background: #1e293b;
  color: #f1f5f9;
  border: 1px solid rgba(255,255,255,0.1);
}
.btn-secondary:hover {
  background: #334155;
  color: #fff;
}
.btn-outline {
  background: transparent;
  color: #f1f5f9;
  border: 1px solid rgba(255, 255, 255, 0.2);
}
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.35);
}
.btn-sm {
  padding: 4px 10px;
  font-size: 11.5px;
}
.btn-lg {
  padding: 10px 20px;
  font-size: 14px;
}

/* Text helpers */
.text-gold { color: var(--primary-gold); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(8px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-box {
  max-width: 900px;
  width: 100%;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  background: #111827;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 204, 0,0.4);
  box-shadow: 0 20px 60px rgba(0,0,0,0.7);
}
.modal-header {
  padding: 14px 20px;
  background: #1f2937;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.modal-title {
  font-size: 15px;
  font-weight: 700;
  margin: 0;
  color: #fff;
}
.modal-close-btn {
  background: transparent;
  border: none;
  color: #9ca3af;
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all 0.2s;
}
.modal-close-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.modal-body {
  padding: 16px;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1 1 auto;
  min-height: 0;
  background: #0b0f19;
  -webkit-overflow-scrolling: touch;
}
.pdf-preview-scroller {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  overflow-y: visible;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.pdf-zoom-viewport {
  position: relative;
  overflow: visible;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.7);
  border-radius: 6px;
  transform-origin: top left;
  -webkit-transform-origin: top left;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Preview Modal Header & Zoom Toolbar */
.pdf-preview-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 18px;
  background: #1e293b;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}

.modal-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.pdf-modal-zoom-controls, .pdf-floating-zoom-bar {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 204, 0, 0.45);
  border-radius: 9999px;
  padding: 3px 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
  user-select: none;
  flex-shrink: 0;
}

.pdf-modal-zoom-controls .zoom-btn, .pdf-floating-zoom-bar .zoom-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #f8fafc;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11.5px;
  cursor: pointer;
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0;
  line-height: 1;
}

.pdf-modal-zoom-controls .zoom-btn:hover, .pdf-floating-zoom-bar .zoom-btn:hover {
  background: rgba(255, 204, 0, 0.25);
  border-color: #FFCC00;
  color: #FFCC00;
  transform: translateY(-1px);
}

.pdf-modal-zoom-controls .zoom-btn:active, .pdf-floating-zoom-bar .zoom-btn:active {
  transform: scale(0.92);
}

.pdf-modal-zoom-controls .zoom-level-indicator, .pdf-floating-zoom-bar .zoom-level-indicator {
  font-size: 11.5px;
  font-weight: 800;
  color: #FFCC00;
  min-width: 44px;
  text-align: center;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
  letter-spacing: 0.3px;
  font-family: monospace, -apple-system, sans-serif;
  transition: all 0.15s ease;
}

.pdf-modal-zoom-controls .zoom-level-indicator:hover, .pdf-floating-zoom-bar .zoom-level-indicator:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.pdf-modal-zoom-controls .zoom-fit-btn, .pdf-floating-zoom-bar .zoom-fit-btn {
  width: auto;
  height: 28px;
  border-radius: 9999px;
  padding: 0 10px;
  font-size: 11px;
  font-weight: 700;
  gap: 4px;
  background: rgba(255, 204, 0, 0.18);
  border-color: rgba(255, 204, 0, 0.4);
  color: #FFCC00;
}

.pdf-modal-zoom-controls .zoom-fit-btn:hover, .pdf-floating-zoom-bar .zoom-fit-btn:hover {
  background: #FFCC00;
  color: #ffffff;
}
#pdf-doc-node, .pdf-page {
  -webkit-font-smoothing: antialiased !important;
  -moz-osx-font-smoothing: grayscale !important;
  text-rendering: optimizeLegibility !important;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
}
.modal-footer {
  padding: 12px 20px;
  background: #1f2937;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.modal-footer-note {
  font-size: 11.5px;
  color: #94a3b8;
}

/* Toast */
.toast-container {
  display: none !important;
  visibility: hidden !important;
}
.toast {
  background: #1e293b;
  color: #fff;
  padding: 12px 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.5);
  border-left: 4px solid var(--primary-gold);
  animation: toastSlide 0.3s ease forwards;
}
.toast-success { border-left-color: #10b981; }
.toast-error { border-left-color: #ef4444; }
.toast-warning { border-left-color: #f59e0b; }
.toast-info { border-left-color: #38bdf8; }
.toast.hiding {
  opacity: 0;
  transform: translateX(100%);
  transition: all 0.3s ease;
}
@keyframes toastSlide {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
.toast-close {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 16px;
  cursor: pointer;
  margin-left: auto;
}

/* Responsive Breakpoints & Mobile Optimization */

/* ---- TABLET (≤1024px) ---- */
@media (max-width: 1024px) {
  .workspace-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .workspace-right {
    position: static;
  }
  .ai-form-grid {
    grid-template-columns: 1fr 1fr;
  }
  .modal-box {
    max-width: 95vw;
  }
  .presets-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ---- SMALL TABLET / LARGE PHONE (≤768px) ---- */
@media (max-width: 768px) {
  .studio-container {
    padding: 14px 10px 80px 10px;
  }
  .modal-overlay {
    padding: 0;
    align-items: stretch;
  }
  .pdf-preview-modal-header {
    flex-wrap: wrap;
    padding: 8px 12px;
    gap: 6px;
    justify-content: space-between;
  }
  .pdf-modal-zoom-controls {
    order: 3;
    width: 100%;
    justify-content: center;
    margin-top: 2px;
    padding: 3px 10px;
  }
  .modal-box {
    width: 100vw;
    max-width: 100vw;
    height: 100dvh;
    height: 100vh;
    max-height: 100dvh;
    max-height: 100vh;
    border-radius: 0;
    border: none;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .modal-header {
    flex-shrink: 0;
    padding: 10px 14px;
    padding-top: max(10px, env(safe-area-inset-top));
    gap: 8px;
  }
  .modal-title {
    font-size: 13px;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .modal-body {
    flex: 1 1 auto;
    min-height: 0;
    padding: 8px 4px;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .pdf-preview-scroller {
    width: 100%;
    padding: 4px 0;
    overflow-x: hidden;
    overflow-y: visible;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .modal-footer {
    flex-shrink: 0;
    padding: 8px 10px;
    padding-bottom: max(10px, env(safe-area-inset-bottom));
    flex-direction: column;
    gap: 6px;
    align-items: stretch;
  }
  .modal-footer-note {
    text-align: center;
    font-size: 10.5px;
  }
  .modal-footer div[style*="display: flex"] {
    width: 100%;
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    gap: 6px !important;
  }
  .modal-footer .btn {
    width: 100%;
    min-height: 40px;
    padding: 8px 6px;
    font-size: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .modal-footer .btn-primary {
    grid-column: 1 / -1;
  }
  .presets-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  .form-grid-2, .form-grid-4, .form-row {
    grid-template-columns: 1fr !important;
    gap: 10px;
  }
  .ai-form-grid {
    grid-template-columns: 1fr !important;
    gap: 10px;
  }

  /* Day card header — stack title/inputs vertically */
  .itinerary-day-header {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 10px 12px;
  }
  .itinerary-day-title-wrap {
    width: 100%;
    flex-wrap: wrap;
  }
  .itinerary-day-title-wrap input.form-control {
    width: 100% !important;
    flex: unset !important;
    min-width: 0;
  }

  /* Activity rows — stack vertically on phone */
  .activity-row {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
    padding: 10px !important;
  }
  .activity-row > div:first-child {
    display: flex;
    gap: 8px;
    align-items: center;
  }
  .activity-row > div:first-child select {
    flex: 1;
  }
  .activity-row > div:last-child {
    display: flex;
    justify-content: flex-end;
  }
}

/* ---- PHONE (≤640px) ---- */
@media (max-width: 640px) {
  .studio-header {
    padding: 8px 12px;
    height: auto;
    min-height: 52px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
  }
  .studio-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    flex: 1;
  }
  .studio-title {
    font-size: 0.85rem !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .studio-title span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .studio-header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
  }
  .btn-new-quote-head {
    padding: 6px 10px !important;
    font-size: 0.76rem !important;
    gap: 4px !important;
    border-radius: 6px !important;
  }

  /* Guide Banner */
  .guide-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 12px;
  }
  .guide-text {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    font-size: 11px;
  }

  /* Copilot / Step Panels */
  .panel-copilot-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 12px;
  }
  .panel-copilot-body {
    padding: 12px 10px;
  }
  .panel-step-title {
    font-size: 13px;
  }
  .tab-switch {
    width: 100%;
  }
  .tab-btn {
    flex: 1;
    text-align: center;
    padding: 7px 6px;
    font-size: 11px;
  }

  /* Presets — single column on phone */
  .presets-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .preset-card {
    padding: 10px 12px;
  }
  .preset-name {
    font-size: 13px;
  }
  .preset-route {
    font-size: 11px;
  }
  .preset-price {
    font-size: 13px;
  }

  /* AI form — single column */
  .ai-form-grid {
    grid-template-columns: 1fr !important;
    gap: 10px;
  }
  .btn-generate {
    width: 100%;
    height: 44px;
    font-size: 13px;
  }

  /* All form grids — single column */
  .form-grid-2, .form-grid-4, .form-row {
    grid-template-columns: 1fr !important;
    gap: 10px;
  }

  /* Card headers & bodies — tighter on mobile */
  .card-header-styled {
    padding: 10px 12px;
    flex-wrap: wrap;
    gap: 8px;
  }
  .card-body-styled {
    padding: 12px 10px;
  }
  .card-title {
    font-size: 13px;
  }

  /* Day card header — stack everything vertically */
  .itinerary-day-header {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 10px 12px;
  }
  .itinerary-day-title-wrap {
    width: 100%;
    flex-direction: column !important;
    gap: 6px !important;
  }
  .itinerary-day-title-wrap .day-badge {
    align-self: flex-start;
  }
  .itinerary-day-title-wrap input.form-control {
    width: 100% !important;
    flex: unset !important;
    min-width: 0;
    font-size: 12px !important;
    padding: 6px 8px !important;
  }

  /* Day meta (KM + delete + arrow) */
  .itinerary-day-header > div:last-child {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
  }

  /* Day body */
  .itinerary-day-body {
    padding: 10px !important;
  }

  /* Activity rows — full stack on phone */
  .activity-row {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
    padding: 10px !important;
  }
  .activity-row > div:first-child {
    grid-column: 1 / -1;
  }
  .activity-row > div:last-child {
    display: flex;
    justify-content: flex-end;
  }

  /* Day controls (Expand All / Collapse All / Add Day) */
  .day-controls {
    width: 100%;
    margin-top: 8px;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 4px;
  }
  .day-controls .btn {
    padding: 6px 4px;
    font-size: 10.5px;
    text-align: center;
    justify-content: center;
  }

  /* Fare calc */
  .fare-summary-box {
    padding: 10px;
  }
  .fare-row {
    font-size: 11.5px;
  }
  .fare-total-price {
    font-size: 20px;
  }

  /* Dispatch action buttons — stacked */
  .actions-grid-2 {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .action-buttons-wrap .btn {
    font-size: 12px;
    padding: 10px 12px;
    min-height: 44px;
  }

  /* Toast notifications — full width on mobile */
  .toast-container {
    left: 10px;
    right: 10px;
    bottom: 14px;
    max-width: calc(100vw - 20px);
  }
  .toast {
    padding: 10px 12px;
    font-size: 12px;
  }

  /* Inclusions/Exclusions textareas */
  textarea.form-control {
    font-size: 12px;
    min-height: 80px;
  }

  /* Ensure all inputs have proper touch targets */
  .form-control {
    min-height: 40px;
    font-size: 14px;
    padding: 8px 10px;
  }
  select.form-control {
    min-height: 42px;
  }
}

/* Collapsible Inclusions & Terms Panel */
.terms-details-collapse {
  background: transparent;
  border-radius: var(--radius-md);
  overflow: hidden;
}
.terms-summary-heading {
  padding: 14px 18px;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
  background: rgba(255, 255, 255, 0.02);
  transition: background 0.2s ease;
}
.terms-summary-heading::-webkit-details-marker {
  display: none;
}
.terms-summary-heading:hover {
  background: rgba(255, 255, 255, 0.04);
}
.badge-terms-auto {
  background: rgba(16, 185, 129, 0.15);
  color: #10B981;
  border: 1px solid rgba(16, 185, 129, 0.35);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
}
.terms-chevron {
  font-size: 0.72rem;
  color: #94A3B8;
  transition: transform 0.2s ease;
}
details[open] .terms-chevron {
  transform: rotate(180deg);
}

@media (max-width: 480px) {
  .studio-container {
    padding: 10px 6px 70px 6px;
  }
  .studio-header {
    padding: 8px 10px;
  }
  .studio-title {
    font-size: 12px;
  }
  .studio-tag {
    font-size: 8px;
    padding: 1px 5px;
  }

  .panel-copilot-body {
    padding: 10px 8px;
  }
  .card-body-styled {
    padding: 10px 8px;
  }

  .preset-card {
    padding: 8px 10px;
  }
  .preset-name {
    font-size: 12px;
  }
  .preset-badge {
    font-size: 8px;
  }

  .btn {
    font-size: 11.5px;
    padding: 7px 10px;
  }

  .day-controls {
    grid-template-columns: 1fr 1fr;
  }

  /* Fare total */
  .fare-total-price {
    font-size: 18px;
  }
  .fare-total-label {
    font-size: 11px;
  }
}

/* ==========================================================================
   Itinerary Studio - Custom Material Date Picker Luxury Orange Theme
   ========================================================================== */
.mat-picker-overlay {
  background: rgba(10, 15, 26, 0.82) !important;
  backdrop-filter: blur(8px) !important;
}

.mat-picker-modal {
  background: #111827 !important;
  border: 1px solid rgba(255, 204, 0, 0.35) !important;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 204, 0, 0.25) !important;
  color: #f8fafc !important;
}

.mat-picker-header {
  background: linear-gradient(135deg, #0a0f1a 0%, #1e293b 100%) !important;
  border-bottom: 3px solid #FFCC00 !important;
  color: #ffffff !important;
}

.mat-date-header-year {
  color: #FFCC00 !important;
  font-weight: 800 !important;
}

.mat-date-header-date {
  color: #ffffff !important;
  font-weight: 900 !important;
}

.mat-picker-body {
  background: #111827 !important;
  color: #e2e8f0 !important;
}

.mat-month-label {
  color: #ffffff !important;
  font-weight: 800 !important;
}

.mat-nav-btn {
  background: #1e293b !important;
  border-color: #334155 !important;
  color: #cbd5e1 !important;
}

.mat-nav-btn:hover {
  background: #FFCC00 !important;
  border-color: #FFCC00 !important;
  color: #ffffff !important;
}

.mat-weekdays {
  color: #94a3b8 !important;
  font-weight: 700 !important;
}

.mat-day-cell {
  color: #cbd5e1 !important;
  font-weight: 600 !important;
}

.mat-day-cell:hover:not(.disabled):not(.selected) {
  background: rgba(255, 204, 0, 0.2) !important;
  color: #ff8c1a !important;
}

/* Selected Date, Range Start, Range End, and In-Between Dates */
.mat-day-cell.selected,
.mat-day-cell.range-start,
.mat-day-cell.range-end,
.mat-day-cell.in-range {
  background: linear-gradient(135deg, #FFCC00 0%, #ff8c1a 100%) !important;
  color: #0a0f1a !important;
  font-weight: 900 !important;
  box-shadow: 0 2px 10px rgba(255, 204, 0, 0.45) !important;
}

.mat-day-cell.selected:not(.range-start):not(.range-end):not(.in-range) {
  border-radius: 50% !important;
}

.mat-day-cell.range-start {
  border-radius: 50% 0 0 50% !important;
}

.mat-day-cell.in-range {
  border-radius: 0 !important;
}

.mat-day-cell.range-end {
  border-radius: 0 50% 50% 0 !important;
}

.mat-day-cell.range-start.range-end {
  border-radius: 50% !important;
}

.mat-day-cell.today:not(.selected):not(.in-range):not(.range-start):not(.range-end) {
  border: 2px solid #FFCC00 !important;
  color: #ff8c1a !important;
  font-weight: 800 !important;
}

.mat-day-cell.disabled {
  color: #475569 !important;
  opacity: 0.45 !important;
}

.mat-picker-actions {
  background: #0f172a !important;
  border-top: 1px solid #1e293b !important;
}

.mat-action-btn#matDateCancel {
  color: #94a3b8 !important;
}

.mat-action-btn#matDateCancel:hover {
  background: rgba(255, 255, 255, 0.05) !important;
  color: #f1f5f9 !important;
}

.mat-action-btn#matDateOk {
  background: linear-gradient(135deg, #FFCC00 0%, #ff8c1a 100%) !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  box-shadow: 0 4px 14px rgba(255, 204, 0, 0.4) !important;
}

.mat-action-btn#matDateOk:hover {
  background: linear-gradient(135deg, #E5A900 0%, #FFCC00 100%) !important;
}

/* ==========================================================================
   PORTAL SIDEBAR LAYOUT & FULL-SCREEN 24H LOGIN SCREEN
   ========================================================================== */

/* Full-Screen Login Gate */
.itin-login-gate-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  background: radial-gradient(circle at top right, rgba(255, 204, 0, 0.12) 0%, #070b14 60%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(12px);
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.itin-login-card {
  background: #0f172a;
  border: 1px solid rgba(255, 204, 0, 0.3);
  border-radius: 16px;
  width: 100%;
  max-width: 440px;
  padding: 36px 30px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 30px rgba(255, 204, 0, 0.12);
  position: relative;
  text-align: center;
}

.itin-login-logo {
  max-height: 48px;
  width: auto;
  margin-bottom: 14px;
}

.itin-login-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.35rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.3px;
  margin: 0;
}

.itin-login-tagline {
  font-size: 0.82rem;
  color: #94a3b8;
  margin: 6px 0 24px 0;
}

.itin-login-form-group {
  text-align: left;
  margin-bottom: 16px;
}

.itin-login-form-group label {
  display: block;
  font-size: 0.80rem;
  font-weight: 700;
  color: #cbd5e1;
  margin-bottom: 6px;
}

.itin-login-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  padding: 11px 14px;
  color: #ffffff;
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.itin-login-input:focus {
  border-color: #FFCC00;
  box-shadow: 0 0 0 3px rgba(255, 204, 0, 0.2);
}

.itin-login-submit-btn {
  width: 100%;
  background: linear-gradient(135deg, #FFCC00 0%, #ff8c1a 100%);
  color: #0a0f1a;
  font-weight: 900;
  font-size: 0.95rem;
  padding: 12px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 15px rgba(255, 204, 0, 0.35);
  transition: transform 0.15s ease, filter 0.15s ease;
}

.itin-login-submit-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.itin-login-session-note {
  font-size: 0.75rem;
  color: #64748b;
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* PORTAL APP LAYOUT */
.itin-portal-layout {
  display: flex;
  min-height: 100vh;
  background: var(--bg-main);
}

/* PORTAL SIDEBAR */
.itin-portal-sidebar {
  width: 260px;
  min-width: 260px;
  max-width: 260px;
  background: #0b1120;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 1000;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-header-brand {
  padding: 20px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.2);
}

.sidebar-header-brand img {
  width: 100%;
  max-width: 260px;
  max-height: 90px;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.4));
  transition: transform 0.2s ease;
}

.sidebar-header-brand img:hover {
  transform: scale(1.02);
}

.sidebar-nav-menu {
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  overflow-y: auto;
}

.sidebar-nav-section-title {
  font-size: 0.68rem;
  font-weight: 800;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 8px 12px 4px 12px;
}

.sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  color: #94a3b8;
  font-size: 0.86rem;
  font-weight: 600;
  text-decoration: none;
  background: transparent;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.18s ease;
  width: 100%;
  text-align: left;
}

.sidebar-nav-item i {
  font-size: 1rem;
  width: 20px;
  text-align: center;
  color: #64748b;
  transition: color 0.18s ease;
}

.sidebar-nav-item:hover {
  background: rgba(255, 255, 255, 0.04);
  color: #f8fafc;
}

.sidebar-nav-item:hover i {
  color: #FFCC00;
}

.sidebar-nav-item.active {
  background: rgba(255, 204, 0, 0.12);
  border-color: rgba(255, 204, 0, 0.3);
  color: #ffffff;
  font-weight: 800;
}

.sidebar-nav-item.active i {
  color: #FFCC00;
}

.sidebar-nav-item .nav-badge {
  margin-left: auto;
  background: #FFCC00;
  color: #0a0f1a;
  font-size: 0.70rem;
  font-weight: 900;
  padding: 1px 7px;
  border-radius: 10px;
}

.sidebar-footer-profile {
  padding: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.2);
}

.sidebar-user-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.sidebar-user-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.sidebar-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 204, 0, 0.18);
  border: 1px solid rgba(255, 204, 0, 0.35);
  color: #FFCC00;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.sidebar-username {
  font-size: 0.82rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-session-tag {
  font-size: 0.68rem;
  color: #10B981;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 3px;
}

.btn-sidebar-logout {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #f87171;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.18s ease;
}

.btn-sidebar-logout:hover {
  background: #ef4444;
  color: #ffffff;
}

/* PORTAL MAIN CONTENT */
.itin-portal-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.sidebar-mobile-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 99998;
}

.sidebar-mobile-backdrop.active {
  display: block;
}

/* ==========================================================================
   COMPREHENSIVE MOBILE RESPONSIVE OPTIMIZATIONS (TABLETS & SMARTPHONES)
   ========================================================================== */
@media (max-width: 1024px) {
  .btn-sidebar-toggle,
  #btn-mobile-sidebar-toggle {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    min-height: 38px !important;
    background: rgba(255, 255, 255, 0.08) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.18) !important;
    border-radius: 8px !important;
    cursor: pointer !important;
    font-size: 1.05rem !important;
    padding: 0 !important;
    line-height: 1 !important;
    transition: background 0.15s ease, transform 0.15s ease !important;
    flex-shrink: 0 !important;
  }

  .btn-sidebar-toggle:hover,
  #btn-mobile-sidebar-toggle:hover {
    background: rgba(255, 204, 0, 0.2) !important;
    border-color: #FFCC00 !important;
    color: #FFCC00 !important;
  }

  .btn-sidebar-toggle:active,
  #btn-mobile-sidebar-toggle:active {
    transform: scale(0.95) !important;
  }

  .itin-portal-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    height: 100dvh;
    width: 280px;
    min-width: 0 !important;
    max-width: 82vw;
    z-index: 99999;
    transform: translateX(-100%);
    box-shadow: 10px 0 40px rgba(0, 0, 0, 0.85);
    background: #090e1c;
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .itin-portal-sidebar.open {
    transform: translateX(0);
  }

  .workspace-grid {
    grid-template-columns: 100% !important;
    width: 100% !important;
    max-width: 100% !important;
    gap: 16px;
  }

  .workspace-left,
  .workspace-right {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    position: static !important;
  }
}

@media (max-width: 768px) {
  .studio-container {
    padding: 12px 10px 70px 10px;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .studio-header {
    padding: 10px 14px;
  }

  .studio-title {
    font-size: 0.88rem !important;
  }

  /* Form & Input Touch Friendly */
  .form-control {
    font-size: 15px !important;
    min-height: 42px;
    border-radius: 8px;
  }

  select.form-control {
    min-height: 44px;
  }

  .form-grid-2, .form-grid-4, .form-row {
    grid-template-columns: 1fr !important;
    gap: 10px;
  }

  /* Sticky Fare Card */
  .pricing-card {
    margin-top: 10px;
  }

  .fare-total-price {
    font-size: 22px;
  }

  /* Action Buttons */
  .action-buttons-wrap .btn {
    min-height: 48px;
    font-size: 0.95rem;
    font-weight: 800;
    border-radius: 8px;
  }

  /* Modals Full Viewport on Phone */
  .modal-overlay {
    padding: 0;
    align-items: stretch;
  }

  .modal-box {
    width: 100vw;
    max-width: 100vw;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
    border: none;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }

  .modal-header {
    padding: 12px 16px;
    padding-top: max(12px, env(safe-area-inset-top));
  }

  .modal-footer {
    padding: 10px 16px;
    padding-bottom: max(12px, env(safe-area-inset-bottom));
  }
}

@media (max-width: 480px) {
  /* Login Screen on Mobile */
  .itin-login-gate-overlay {
    padding: 12px;
  }

  .itin-login-card {
    padding: 24px 18px;
    border-radius: 14px;
    max-width: 100%;
  }

  .itin-login-logo {
    max-height: 40px;
    margin-bottom: 10px;
  }

  .itin-login-title {
    font-size: 1.15rem;
  }

  .itin-login-tagline {
    font-size: 0.76rem;
    margin: 4px 0 18px 0;
  }

  .itin-login-input {
    font-size: 16px !important;
    padding: 10px 12px;
    min-height: 44px;
  }

  .itin-login-submit-btn {
    min-height: 46px;
    font-size: 0.92rem;
  }

  /* Studio Header Buttons */
  .studio-header {
    padding: 8px 12px;
  }

  .studio-title span {
    font-size: 0.82rem;
  }

  /* Floating Zoom Bar */
  .pdf-floating-zoom-bar {
    padding: 3px 8px;
    gap: 4px;
  }

  .pdf-floating-zoom-bar .zoom-btn {
    width: 30px;
    height: 30px;
    font-size: 12px;
  }

  .pdf-floating-zoom-bar .zoom-level-indicator {
    font-size: 11px;
    min-width: 42px;
  }

  /* Tariff Toggles */
  .tariff-toggle-card {
    padding: 8px 10px !important;
  }

  /* History Drawer */
  .history-sidebar-drawer {
    width: 100vw;
    max-width: 100vw;
  }
}

/* ==========================================================================
   ROUTE PLANNER & CONNECTED TIMELINE STYLES
   ========================================================================== */
.rp-stops-container {
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

.rp-stops-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  gap: 12px;
  flex-wrap: wrap;
  width: 100%;
}

.rp-stops-label {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.rp-header-icon {
  color: var(--rp-primary);
  font-size: 1.05rem;
}

.rp-header-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.2px;
}

.rp-header-hint {
  font-size: 0.76rem;
  color: #94A3B8;
  font-weight: 500;
}

.rp-roundtrip-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  user-select: none;
  font-size: 0.80rem;
  font-weight: 700;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 5px 12px;
  border-radius: 7px;
  transition: all 0.2s ease;
  margin-left: auto;
}

.rp-roundtrip-toggle:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.rp-roundtrip-toggle input[type="checkbox"] {
  accent-color: var(--rp-primary);
  width: 15px;
  height: 15px;
  cursor: pointer;
}

/* Timeline Route Flow */
.rp-route-timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  width: 100%;
  box-sizing: border-box;
}

.rp-timeline-step {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 14px;
  padding: 12px 16px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  box-sizing: border-box;
  width: 100%;
}

.rp-timeline-step:hover {
  background: rgba(15, 23, 42, 0.95);
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
}

.rp-timeline-step.is-start {
  background: linear-gradient(135deg, rgba(255, 204, 0, 0.12) 0%, rgba(15, 23, 42, 0.88) 100%) !important;
  border: 1.5px solid rgba(255, 204, 0, 0.4) !important;
  box-shadow: 0 4px 16px rgba(255, 204, 0, 0.08);
}

.rp-timeline-step.is-start:hover {
  border-color: rgba(255, 204, 0, 0.65) !important;
}

.rp-timeline-step.is-intermediate {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.08) 0%, rgba(15, 23, 42, 0.88) 100%) !important;
  border: 1px solid rgba(56, 189, 248, 0.25) !important;
}

.rp-timeline-step.is-intermediate:hover {
  border-color: rgba(56, 189, 248, 0.45) !important;
}

.rp-timeline-step.is-return {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.12) 0%, rgba(15, 23, 42, 0.88) 100%) !important;
  border: 1.5px solid rgba(34, 197, 94, 0.4) !important;
  box-shadow: 0 4px 16px rgba(34, 197, 94, 0.08);
}

.rp-timeline-step.is-return:hover {
  border-color: rgba(34, 197, 94, 0.65) !important;
}

.rp-step-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
}

.rp-step-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 800;
  flex-shrink: 0;
}

.rp-step-icon.is-start {
  background: rgba(255, 204, 0, 0.18);
  border: 1.5px solid #FFCC00;
  color: #FFCC00;
  box-shadow: 0 0 12px rgba(255, 204, 0, 0.3);
}

.rp-step-icon.is-stop {
  background: rgba(56, 189, 248, 0.18);
  border: 1.5px solid #38BDF8;
  color: #38BDF8;
  font-size: 13.5px;
}

.rp-step-icon.is-return {
  background: rgba(34, 197, 94, 0.18);
  border: 1.5px solid #22C55E;
  color: #22C55E;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.3);
}

.rp-step-title-wrap {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
  gap: 2px;
}

.rp-step-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.rp-step-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.25;
}

.rp-step-title.is-return {
  color: #22C55E;
}

.rp-step-badge {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.3px;
}

.rp-step-badge.is-start {
  background: rgba(255, 204, 0, 0.2);
  color: #FFCC00;
  border: 1px solid rgba(255, 204, 0, 0.4);
}

.rp-step-badge.is-stop {
  background: rgba(56, 189, 248, 0.2);
  color: #38BDF8;
  border: 1px solid rgba(56, 189, 248, 0.4);
}

.rp-step-badge.is-return {
  background: rgba(34, 197, 94, 0.2);
  color: #22C55E;
  border: 1px solid rgba(34, 197, 94, 0.4);
}

.rp-step-sub {
  font-size: 0.78rem;
  color: #94A3B8;
  line-height: 1.35;
  word-break: break-word;
}

/* Vertical Timeline Connectors (Centered Between Cards) */
.rp-timeline-connector {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 20px;
  width: 100%;
  position: relative;
  margin: 0;
}

.rp-connector-line {
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom, rgba(255, 204, 0, 0.7), rgba(255, 204, 0, 0.2));
  border-radius: 1px;
}

.rp-connector-dot {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #FFCC00;
  box-shadow: 0 0 8px rgba(255, 204, 0, 0.9);
}

/* Action Buttons — Properly Positioned, Fixed Footprint */
.rp-hub-change-wrap {
  position: relative;
  flex-shrink: 0;
}

.btn-change-start,
#rp-btn-change-hub {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  font-size: 0.80rem !important;
  font-weight: 700 !important;
  color: #FFCC00 !important;
  background: rgba(255, 204, 0, 0.12) !important;
  border: 1px solid rgba(255, 204, 0, 0.35) !important;
  padding: 7px 14px !important;
  border-radius: 8px !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  white-space: nowrap !important;
  letter-spacing: 0.2px !important;
  outline: none !important;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2) !important;
  flex-shrink: 0 !important;
}

.btn-change-start:hover,
#rp-btn-change-hub:hover {
  background: rgba(255, 204, 0, 0.25) !important;
  border-color: #FFCC00 !important;
  color: #ffffff !important;
  box-shadow: 0 0 12px rgba(255, 204, 0, 0.35) !important;
  transform: translateY(-1px) !important;
}

.btn-change-return,
#rp-btn-change-return {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  font-size: 0.80rem !important;
  font-weight: 700 !important;
  color: #22C55E !important;
  background: rgba(34, 197, 94, 0.12) !important;
  border: 1px solid rgba(34, 197, 94, 0.35) !important;
  padding: 7px 14px !important;
  border-radius: 8px !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  white-space: nowrap !important;
  letter-spacing: 0.2px !important;
  outline: none !important;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2) !important;
  flex-shrink: 0 !important;
}

.btn-change-return:hover,
#rp-btn-change-return:hover {
  background: rgba(34, 197, 94, 0.25) !important;
  border-color: #22C55E !important;
  color: #ffffff !important;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.35) !important;
  transform: translateY(-1px) !important;
}

.rp-step-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.btn-reorder-stop {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 28px !important;
  height: 28px !important;
  font-size: 10px !important;
  color: #cbd5e1 !important;
  background: rgba(255, 255, 255, 0.06) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  border-radius: 6px !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  outline: none !important;
}

.btn-reorder-stop:hover {
  background: rgba(255, 255, 255, 0.15) !important;
  color: #ffffff !important;
}

.btn-remove-stop {
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  font-size: 0.76rem !important;
  font-weight: 700 !important;
  color: #EF4444 !important;
  background: rgba(239, 68, 68, 0.12) !important;
  border: 1px solid rgba(239, 68, 68, 0.35) !important;
  padding: 6px 12px !important;
  border-radius: 7px !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  outline: none !important;
}

.btn-remove-stop:hover {
  background: rgba(239, 68, 68, 0.24) !important;
  border-color: #EF4444 !important;
  color: #ffffff !important;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.35) !important;
  transform: translateY(-1px) !important;
}

/* Add Destination Stop Button — Clean Full Width Card */
.rp-add-stop-timeline-wrap {
  display: flex;
  justify-content: center;
  width: 100%;
  margin: 2px 0;
  box-sizing: border-box;
}

.rp-btn-add-stop-timeline {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  width: 100% !important;
  background: rgba(255, 204, 0, 0.08) !important;
  border: 1.5px dashed rgba(255, 204, 0, 0.6) !important;
  color: #FFCC00 !important;
  padding: 10px 18px !important;
  border-radius: 10px !important;
  font-weight: 700 !important;
  font-size: 0.88rem !important;
  cursor: pointer !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
  outline: none !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2) !important;
  box-sizing: border-box !important;
}

.rp-btn-add-stop-timeline:hover {
  background: rgba(255, 204, 0, 0.2) !important;
  border-color: #FFCC00 !important;
  color: #ffffff !important;
  box-shadow: 0 0 16px rgba(255, 204, 0, 0.35) !important;
  transform: translateY(-1px) !important;
}

/* Tour Duration Box */
.rp-metrics-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-top: 14px;
  width: 100%;
}

.rp-metric-box {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
  background: linear-gradient(135deg, rgba(255, 204, 0, 0.08) 0%, rgba(15, 23, 42, 0.85) 100%);
  border: 1px solid rgba(255, 204, 0, 0.35);
  border-radius: 9px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  box-sizing: border-box;
}

.rp-metric-icon {
  font-size: 1.2rem;
  line-height: 1;
}

.rp-metric-content {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.rp-metric-label {
  font-size: 0.84rem;
  color: #cbd5e1;
  font-weight: 700;
}

.rp-days-input {
  width: 52px;
  height: 30px;
  background: #0f172a;
  border: 1.5px solid #FFCC00;
  color: #fff;
  font-weight: 800;
  font-size: 13.5px;
  text-align: center;
  border-radius: 6px;
  outline: none;
}

.rp-days-badge {
  font-size: 0.88rem;
  font-weight: 800;
  color: #FFCC00;
  background: rgba(255, 204, 0, 0.15);
  padding: 3px 8px;
  border-radius: 5px;
  border: 1px solid rgba(255, 204, 0, 0.3);
}

.rp-days-text {
  font-size: 0.80rem;
  font-weight: 600;
  color: #94A3B8;
}

/* Responsive Adjustments */
@media (max-width: 600px) {
  .rp-stops-header-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .rp-roundtrip-toggle {
    margin-left: 0;
  }
  .rp-timeline-step {
    padding: 10px 12px !important;
    gap: 10px !important;
    flex-wrap: wrap !important;
  }
  .rp-step-left {
    min-width: 0;
    width: 100%;
  }
  .rp-hub-change-wrap,
  .rp-step-actions {
    margin-left: auto;
  }
  .rp-step-icon {
    width: 34px !important;
    height: 34px !important;
    font-size: 14px !important;
  }
  .btn-change-start,
  #rp-btn-change-hub,
  .btn-change-return,
  #rp-btn-change-return {
    padding: 6px 10px !important;
    font-size: 0.74rem !important;
  }
  .rp-metrics-row {
    flex-direction: column;
    align-items: stretch;
  }
  .rp-metric-box {
    width: 100%;
    justify-content: space-between;
    box-sizing: border-box;
  }
}

/* Google Maps Autocomplete Modal & List Styles */
#destination-selector-modal {
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

.gmaps-autocomplete-modal {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
}

.gmaps-item {
  transition: background-color 0.15s ease;
  user-select: none;
}

.gmaps-item:hover {
  background-color: rgba(255, 255, 255, 0.06) !important;
}

.gmaps-item:active {
  background-color: rgba(255, 255, 255, 0.1) !important;
}

.gmaps-item.gmaps-selected {
  background-color: rgba(255, 204, 0, 0.16) !important;
}

.gmaps-item.gmaps-selected:hover {
  background-color: rgba(255, 204, 0, 0.24) !important;
}

#dest-modal-list-container {
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

@media (max-width: 768px) {
  #dest-modal-search {
    font-size: 16px !important; /* Prevents auto-zoom on mobile */
  }
  
  .gmaps-item {
    padding: 12px 14px !important;
  }
  
  #destination-selector-modal .modal-box {
    width: 95% !important;
    max-height: 90vh !important;
  }

  #dest-modal-list-container {
    max-height: 60vh !important;
  }
}

/* ── TOP PILL SEARCH BAR (MATCHING SCREENSHOT) ── */
.top-search-banner-wrap {
  position: relative;
  width: 100%;
  max-width: 820px;
  margin: 0 auto 20px auto;
  z-index: 95;
}

.top-search-pill-container {
  display: flex;
  align-items: center;
  background: #080d1a;
  border: 1.5px solid rgba(255, 255, 255, 0.18);
  border-radius: 9999px;
  height: 50px;
  padding: 3px 3px 3px 18px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.45);
  transition: all 0.25s ease;
  position: relative;
}

.top-search-pill-container:focus-within {
  border-color: #FFCC00;
  background: #0c1424;
  box-shadow: 0 0 0 3px rgba(255, 204, 0, 0.25), 0 8px 25px rgba(0, 0, 0, 0.6);
}

.top-search-icon {
  color: #94a3b8;
  font-size: 1.15rem;
  flex-shrink: 0;
  margin-right: 12px;
}

.top-search-input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  outline: none;
  color: #ffffff;
  font-family: 'Outfit', sans-serif;
  font-size: 0.98rem;
  font-weight: 500;
  padding: 0;
}

.top-search-input::placeholder {
  color: #64748b;
  font-weight: 400;
}

.top-search-clear-btn {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 1.25rem;
  cursor: pointer;
  padding: 0 10px;
  line-height: 1;
  display: flex;
  align-items: center;
}

.top-search-clear-btn:hover {
  color: #ffffff;
}

.top-search-btn-gradient {
  background: linear-gradient(90deg, #FFCC00 0%, #E5A900 100%);
  color: #0a0f1a; text-shadow: 0 1px 0 rgba(255,255,255,0.4);
  font-family: 'Outfit', sans-serif;
  font-weight: 900;
  font-size: 0.94rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  border: none;
  border-radius: 9999px;
  padding: 0 32px;
  height: 44px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 14px rgba(255, 204, 0, 0.45);
  transition: all 0.2s ease;
}

.top-search-btn-gradient:hover {
  background: linear-gradient(90deg, #FFE066 0%, #FFCC00 100%);
  box-shadow: 0 4px 20px rgba(255, 204, 0, 0.45);
  transform: translateY(-1px);
}

.top-search-btn-gradient:active {
  transform: scale(0.97);
}

/* ── SEARCH RESULTS FLOATING DROPDOWN ── */
.top-search-results-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: #0d1527;
  border: 1.5px solid rgba(255, 204, 0, 0.35);
  border-radius: 14px;
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.85);
  max-height: 420px;
  overflow-y: auto;
  z-index: 1000;
  padding: 8px;
}

.top-search-result-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: background 0.15s ease;
  cursor: pointer;
}

.top-search-result-item:last-child {
  border-bottom: none;
}

.top-search-result-item:hover {
  background: rgba(255, 204, 0, 0.12);
}

.top-search-result-meta {
  min-width: 0;
  flex: 1;
}

.top-search-result-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.top-search-result-title {
  font-size: 0.82rem;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.top-search-result-details {
  font-size: 0.76rem;
  color: #cbd5e1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}

.top-search-result-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

@media (max-width: 600px) {
  .top-search-pill-container {
    height: 46px;
    padding-left: 14px;
  }
  .top-search-btn-gradient {
    padding: 0 20px;
    font-size: 0.84rem;
    height: 40px;
  }
}

/* ==========================================================================
   CUSTOM LUXURY DIALOG MODAL (CONFIRM & ALERT)
   Replaces default browser alert() and confirm() with themed dialogs
   ========================================================================== */
.custom-dialog-overlay {
  position: fixed;
  inset: 0;
  z-index: 250000;
  background: rgba(4, 8, 18, 0.84);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.custom-dialog-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.custom-dialog-box {
  width: 100%;
  max-width: 440px;
  background: linear-gradient(165deg, #0f1a2e 0%, #080d19 100%);
  border: 1px solid rgba(255, 204, 0, 0.32);
  border-radius: 18px;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.9), 0 0 25px rgba(255, 204, 0, 0.15);
  padding: 28px 24px 22px;
  text-align: center;
  transform: scale(0.92) translateY(12px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
  opacity: 0;
  position: relative;
  overflow: hidden;
}

.custom-dialog-overlay.active .custom-dialog-box {
  transform: scale(1) translateY(0);
  opacity: 1;
}

.custom-dialog-icon-wrap {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  position: relative;
}

.custom-dialog-icon-wrap.warning {
  background: rgba(255, 204, 0, 0.15);
  border: 1.5px solid rgba(255, 204, 0, 0.4);
  color: #FFCC00;
  box-shadow: 0 0 20px rgba(255, 204, 0, 0.25);
}

.custom-dialog-icon-wrap.danger {
  background: rgba(239, 68, 68, 0.15);
  border: 1.5px solid rgba(239, 68, 68, 0.4);
  color: #ef4444;
  box-shadow: 0 0 20px rgba(239, 68, 68, 0.25);
}

.custom-dialog-icon-wrap.info {
  background: rgba(56, 189, 248, 0.15);
  border: 1.5px solid rgba(56, 189, 248, 0.4);
  color: #38bdf8;
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.25);
}

.custom-dialog-icon-wrap.success {
  background: rgba(16, 185, 129, 0.15);
  border: 1.5px solid rgba(16, 185, 129, 0.4);
  color: #10b981;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.25);
}

.custom-dialog-title {
  font-size: 1.18rem;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 10px;
  letter-spacing: -0.01em;
  font-family: inherit;
}

.custom-dialog-message {
  font-size: 0.92rem;
  color: #94a3b8;
  line-height: 1.55;
  margin: 0 0 24px;
  font-weight: 500;
  word-break: break-word;
}

.custom-dialog-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: center;
}

.custom-dialog-btn {
  flex: 1;
  padding: 12px 18px;
  border-radius: 10px;
  font-size: 0.90rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
  outline: none;
  font-family: inherit;
  box-sizing: border-box;
}

.custom-dialog-btn-cancel {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #cbd5e1;
}

.custom-dialog-btn-cancel:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.3);
}

.custom-dialog-btn-confirm {
  border: none;
}

.custom-dialog-btn-confirm.warning {
  background: linear-gradient(135deg, #FFCC00, #E5A900);
  color: #060a12;
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(255, 204, 0, 0.35);
}

.custom-dialog-btn-confirm.warning:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(255, 204, 0, 0.45);
}

.custom-dialog-btn-confirm.danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.35);
}

.custom-dialog-btn-confirm.danger:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(239, 68, 68, 0.45);
}

.custom-dialog-btn-confirm.info {
  background: linear-gradient(135deg, #38bdf8, #0284c7);
  color: #060a12;
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(56, 189, 248, 0.35);
}

.custom-dialog-btn-confirm.info:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.custom-dialog-btn-confirm.success {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #060a12;
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
}

.custom-dialog-btn-confirm.success:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}


