/* ==============================================
   SKYFLY - Diseño estilo Despegar
   Sistema de Reserva de Vuelos
   ============================================== */

:root {
  --primary: #1111B0;
  --primary-dark: #0A0A8A;
  --primary-light: #EEF0FF;
  --primary-soft: #F5F6FF;
  --accent: #FF6B35;
  --accent-hover: #E55A20;
  --accent-light: #FFF0E8;
  --secondary: #1E293B;
  --success: #10B981;
  --error: #EF4444;
  --warning: #F59E0B;
  --white: #FFFFFF;
  --bg: #F5F7FA;
  --bg-card: #FFFFFF;
  --text: #1E293B;
  --text-secondary: #64748B;
  --text-muted: #94A3B8;
  --border: #E2E8F0;
  --border-light: #F1F5F9;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  --shadow-xl: 0 20px 60px rgba(0,0,0,0.15);
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --max-w: 1180px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --header-h: 72px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font); color: var(--text); background: var(--bg); line-height: 1.5; -webkit-font-smoothing: antialiased; min-height: 100vh; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }
input, select, textarea { font-family: inherit; outline: none; }
ul { list-style: none; }
img { max-width: 100%; }
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }

/* ─── Animations ─── */
@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideDown { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes scaleIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }

.animate-fade { animation: fadeUp 0.5s ease forwards; }
.animate-fade-in { animation: fadeIn 0.5s ease forwards; }
.animate-scale { animation: scaleIn 0.3s ease forwards; }
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }

/* ─── Loading ─── */
.spinner { width: 36px; height: 36px; border: 3px solid var(--border); border-top-color: var(--primary); border-radius: 50%; animation: spin 0.7s linear infinite; margin: 32px auto; }
.loading-dots { display: flex; gap: 6px; justify-content: center; padding: 16px; }
.loading-dots span { width: 8px; height: 8px; border-radius: 50%; background: var(--primary); animation: pulse 1.4s ease infinite; }
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

/* ═══════════════════════════════════
   HEADER — ESTILO DESPEGAR
   ═══════════════════════════════════ */
.header { position: fixed; top: 0; left: 0; right: 0; background: var(--white); border-bottom: 1px solid var(--border); z-index: 1000; height: var(--header-h); }
.header .container { display: flex; align-items: center; height: 100%; gap: 32px; }
.logo { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.logo-icon { width: 38px; height: 38px; background: var(--primary); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; color: var(--white); font-weight: 800; }

/* Nav tabs estilo Despegar */
.header-nav { display: flex; align-items: center; gap: 4px; flex: 1; }
.nav-tab { display: flex; align-items: center; gap: 8px; padding: 8px 20px; border-radius: 50px; font-size: 0.85rem; font-weight: 500; color: var(--text-secondary); transition: all var(--transition); white-space: nowrap; }
.nav-tab:hover { background: var(--primary-soft); color: var(--primary); }
.nav-tab.active { background: var(--primary); color: var(--white); font-weight: 600; }

.header-right { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.header-btn { padding: 8px 16px; border-radius: 50px; font-size: 0.82rem; font-weight: 500; color: var(--text-secondary); transition: all var(--transition); white-space: nowrap; }
.header-btn:hover { background: var(--primary-soft); color: var(--primary); }
.header-btn.primary { background: var(--primary-light); color: var(--primary); font-weight: 600; }
.header-btn.primary:hover { background: var(--primary); color: var(--white); }

.mobile-menu { display: flex; flex: 1; align-items: center; }
.mobile-toggle { display: none; flex-direction: column; gap: 4px; padding: 8px; cursor: pointer; margin-left: auto; }
.mobile-toggle span { display: block; width: 20px; height: 2px; background: var(--text); border-radius: 2px; transition: all var(--transition); }
.mobile-toggle.open span:nth-child(1) { transform: rotate(45deg) translate(4px, 4px); }
.mobile-toggle.open span:nth-child(2) { opacity: 0; }
.mobile-toggle.open span:nth-child(3) { transform: rotate(-45deg) translate(4px, -4px); }

@media (max-width: 900px) {
  .mobile-menu { display: none; position: absolute; top: var(--header-h); left: 0; right: 0; background: var(--white); box-shadow: var(--shadow); border-radius: 0 0 var(--radius) var(--radius); z-index: 999; }
  .mobile-menu.open { display: block; }
  .header-nav { display: flex; flex-direction: column; padding: 12px 12px 4px; gap: 2px; }
  .nav-tab { width: 100%; border-radius: var(--radius-sm); }
  .header-right { display: flex; flex-direction: column; padding: 4px 12px 12px; border-top: 1px solid var(--border-light); margin-top: 4px; }
  .header-right .header-btn { width: 100%; justify-content: center; border-radius: var(--radius-sm); padding: 10px 16px; }
  .mobile-toggle { display: flex; }
}

/* ═══════════════════════════════════
   HERO — ESTILO DESPEGAR
   ═══════════════════════════════════ */
.hero { margin-top: var(--header-h); position: relative; background: linear-gradient(135deg, #0A0A8A 0%, #1A1A8B 30%, #2D2DA0 60%, #1E293B 100%); min-height: 380px; display: flex; align-items: center; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; background-image: url('https://images.unsplash.com/photo-1436491865332-7a61a109cc05?w=1600&q=80'); background-size: cover; background-position: center; opacity: 0.12; mix-blend-mode: overlay; }
.hero-content { position: relative; z-index: 2; width: 100%; padding: 40px 0 50px; }
.hero h1 { font-size: 2.2rem; font-weight: 800; color: var(--white); letter-spacing: -0.5px; line-height: 1.15; margin-bottom: 6px; }
.hero p { font-size: 1rem; color: rgba(255,255,255,0.75); margin-bottom: 28px; }

/* ─── Search Box ─── */
.search-box { background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow-xl); overflow: hidden; }
.search-tabs { display: flex; gap: 0; border-bottom: 1px solid var(--border); padding: 0 20px; }
.search-tab { padding: 16px 20px; font-size: 0.82rem; font-weight: 500; color: var(--text-secondary); border-bottom: 2px solid transparent; transition: all var(--transition); margin-bottom: -1px; }
.search-tab:hover { color: var(--text); }
.search-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }

.search-body { padding: 20px; }
.search-grid { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr auto; gap: 12px; align-items: end; }
.search-field { position: relative; }
.search-field label { display: block; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-secondary); margin-bottom: 4px; }
.search-field .field-inner { position: relative; }
.search-field .field-icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); font-size: 1rem; pointer-events: none; z-index: 2; }
.search-field .field-inner select,
.search-field .field-inner input { width: 100%; padding: 11px 12px 11px 38px; background: var(--bg); border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-size: 0.9rem; color: var(--text); transition: all var(--transition); -webkit-appearance: none; appearance: none; cursor: pointer; }
.search-field .field-inner select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%2394A3B8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 32px; }
.search-field .field-inner input:focus,
.search-field .field-inner select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(17,17,176,0.08); background: var(--white); }

.search-btn-container { display: flex; align-items: end; }
.search-btn { padding: 11px 32px; background: var(--accent); color: var(--white); border-radius: var(--radius-sm); font-size: 0.95rem; font-weight: 700; transition: all var(--transition); white-space: nowrap; height: 44px; display: flex; align-items: center; gap: 8px; }
.search-btn:hover { background: var(--accent-hover); box-shadow: 0 4px 14px rgba(255,107,53,0.35); transform: translateY(-1px); }

.swap-btn { position: absolute; right: -14px; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; border-radius: 50%; background: var(--white); border: 2px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 0.75rem; cursor: pointer; transition: all var(--transition); z-index: 5; color: var(--text-muted); }
.swap-btn:hover { background: var(--primary-light); border-color: var(--primary); color: var(--primary); }

@media (max-width: 900px) {
  .hero { min-height: auto; }
  .hero h1 { font-size: 1.5rem; }
  .search-grid { grid-template-columns: 1fr 1fr; }
  .search-btn-container { grid-column: 1 / -1; }
  .search-btn { width: 100%; justify-content: center; }
  .swap-btn { display: none; }
}
@media (max-width: 600px) {
  .search-grid { grid-template-columns: 1fr; }
  .search-tab { padding: 12px 14px; font-size: 0.78rem; }
}

/* ═══════════════════════════════════
   OFFERS / DESTINOS
   ═══════════════════════════════════ */
.section { padding: 48px 0; }
.section-header { margin-bottom: 28px; }
.section-header h2 { font-size: 1.5rem; font-weight: 700; letter-spacing: -0.3px; }
.section-header h2 span { color: var(--primary); }
.section-header p { color: var(--text-secondary); font-size: 0.9rem; margin-top: 4px; }

.offers-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.offer-card { background: var(--white); border-radius: var(--radius); overflow: hidden; transition: all var(--transition); cursor: pointer; border: 1px solid var(--border); }
.offer-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.offer-img { height: 160px; background-size: cover; background-position: center; position: relative; }
.offer-badge { position: absolute; top: 12px; left: 12px; padding: 4px 12px; border-radius: 4px; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; }
.offer-badge.nac { background: var(--primary-light); color: var(--primary); }
.offer-badge.int { background: var(--accent-light); color: var(--accent); }
.offer-body { padding: 16px; }
.offer-body h3 { font-size: 1rem; font-weight: 700; }
.offer-body p { font-size: 0.82rem; color: var(--text-secondary); margin-top: 2px; }
.offer-price { margin-top: 12px; display: flex; align-items: baseline; gap: 4px; }
.offer-price .amount { font-size: 1.3rem; font-weight: 800; color: var(--primary); }
.offer-price .label { font-size: 0.72rem; color: var(--text-muted); }

/* Aerolíneas */
.aero-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; }
.aero-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 12px; text-align: center; transition: all var(--transition); }
.aero-card:hover { border-color: var(--primary); box-shadow: var(--shadow); }
.aero-card .flag { font-size: 2rem; margin-bottom: 6px; display: block; }
.aero-card .name { font-size: 0.78rem; font-weight: 600; color: var(--text-secondary); }

/* ═══════════════════════════════════
   BUTTONS
   ═══════════════════════════════════ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 24px; border-radius: var(--radius-sm); font-size: 0.88rem; font-weight: 600; transition: all var(--transition); white-space: nowrap; }
.btn-primary { background: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(17,17,176,0.3); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }
.btn-accent { background: var(--accent); color: var(--white); }
.btn-accent:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(255,107,53,0.3); }
.btn-outline { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: var(--white); }
.btn-ghost { background: transparent; color: var(--text-secondary); }
.btn-ghost:hover { background: var(--bg); color: var(--text); }
.btn-sm { padding: 8px 16px; font-size: 0.8rem; }
.btn-lg { padding: 14px 32px; font-size: 0.95rem; }
.btn-block { width: 100%; }
.btn-icon { width: 40px; height: 40px; padding: 0; border-radius: 50%; display: flex; align-items: center; justify-content: center; }

/* Tags */
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 4px; font-size: 0.7rem; font-weight: 600; }
.tag-primary { background: var(--primary-light); color: var(--primary); }
.tag-accent { background: var(--accent-light); color: var(--accent); }
.tag-success { background: #D1FAE5; color: #065F46; }
.tag-warning { background: #FEF3C7; color: #92400E; }
.tag-error { background: #FEE2E2; color: #991B1B; }

/* ═══════════════════════════════════
   RESULTS PAGE — ESTILO DESPEGAR
   ═══════════════════════════════════ */
.results-page { margin-top: var(--header-h); padding: 24px 0 60px; }
.results-topbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; padding: 16px 20px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); }
.results-topbar .info { font-size: 0.9rem; }
.results-topbar .info strong { color: var(--primary); }
.results-topbar .info span { color: var(--text-secondary); }
.results-topbar .actions { display: flex; gap: 8px; align-items: center; }
.sort-select { padding: 8px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 0.82rem; background: var(--white); cursor: pointer; }

.filter-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; }
.filter-chip { padding: 6px 16px; border-radius: 50px; font-size: 0.78rem; font-weight: 500; border: 1px solid var(--border); color: var(--text-secondary); transition: all var(--transition); cursor: pointer; background: var(--white); }
.filter-chip:hover { border-color: var(--primary); color: var(--primary); }
.filter-chip.active { background: var(--primary); color: var(--white); border-color: var(--primary); }

.flight-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 24px; margin-bottom: 12px; transition: all var(--transition); cursor: pointer; animation: fadeUp 0.4s ease forwards; opacity: 0; }
.flight-card:hover { border-color: var(--primary); box-shadow: var(--shadow); }
.flight-card.selected { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(17,17,176,0.15); }
.flight-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.flight-airline { display: flex; align-items: center; gap: 10px; }
.airline-badge { width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 0.7rem; color: var(--white); }
.flight-airline .name { font-size: 0.85rem; font-weight: 600; }
.flight-airline .code { font-size: 0.72rem; color: var(--text-muted); }
.flight-body { display: flex; align-items: center; gap: 16px; }
.flight-time { text-align: center; min-width: 72px; }
.flight-time .time { font-size: 1.3rem; font-weight: 800; line-height: 1.2; }
.flight-time .airport { font-size: 0.7rem; color: var(--text-secondary); font-weight: 500; margin-top: 2px; }
.flight-route { flex: 1; text-align: center; position: relative; padding: 0 12px; }
.flight-route .duration { font-size: 0.7rem; color: var(--text-muted); margin-bottom: 4px; }
.flight-route .line { height: 2px; background: var(--border); position: relative; margin: 0 6px; }
.flight-route .line::before { content: '●'; position: absolute; left: -4px; top: 50%; transform: translateY(-50%); font-size: 0.45rem; color: var(--primary); }
.flight-route .line::after { content: '●'; position: absolute; right: -4px; top: 50%; transform: translateY(-50%); font-size: 0.45rem; color: var(--primary); }
.flight-route .line .plane { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 0.85rem; }
.flight-bottom { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; padding-top: 14px;  border-top: 1px solid var(--border-light); }
.btn-arrow { display: inline-block; transition: transform var(--transition); }
.btn:hover .btn-arrow { transform: translateX(4px); }
.flight-price { }
.flight-price .from { font-size: 0.7rem; color: var(--text-muted); }
.flight-price .amount { font-size: 1.4rem; font-weight: 800; color: var(--primary); line-height: 1; }
.flight-price .amount small { font-size: 0.65rem; font-weight: 400; color: var(--text-muted); }

@media (max-width: 600px) {
  .flight-body { flex-direction: column; gap: 10px; }
  .flight-time { display: flex; align-items: center; gap: 8px; min-width: auto; }
  .flight-bottom { flex-direction: column; gap: 12px; align-items: stretch; }
}

/* ═══════════════════════════════════
   BOOKING STEPS
   ═══════════════════════════════════ */
.steps { display: flex; align-items: center; justify-content: center; gap: 0; margin-bottom: 28px; }
.step { display: flex; align-items: center; gap: 8px; padding: 8px 16px; font-size: 0.8rem; font-weight: 500; color: var(--text-muted); }
.step .num { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; background: var(--border); color: var(--text-muted); transition: all var(--transition); }
.step.active { color: var(--text); }
.step.active .num { background: var(--primary); color: var(--white); }
.step.done { color: var(--success); }
.step.done .num { background: var(--success); color: var(--white); }
.step-line { width: 32px; height: 2px; background: var(--border); }
.step-line.done { background: var(--success); }

@media (max-width: 600px) {
  .step { padding: 6px 10px; font-size: 0.72rem; }
  .step .label { display: none; }
  .step-line { width: 16px; }
}

/* ═══════════════════════════════════
   FORMS
   ═══════════════════════════════════ */
.form-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; margin-bottom: 16px; }
.form-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 20px; display: flex; align-items: center; gap: 8px; }
.form-card h3 .badge { width: 26px; height: 26px; border-radius: 50%; background: var(--primary-light); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
.form-grid-4 { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr; gap: 14px; }
.form-group { }
.form-group label { display: block; font-size: 0.78rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 4px; }
.form-input, .form-select { width: 100%; padding: 10px 14px; background: var(--bg); border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-size: 0.9rem; color: var(--text); transition: all var(--transition); }
.form-input:focus, .form-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(17,17,176,0.08); background: var(--white); }
.form-select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%2394A3B8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 32px; cursor: pointer; }
.form-input.error, .form-select.error { border-color: var(--error); box-shadow: 0 0 0 3px rgba(239,68,68,0.08); }
.form-error { display: none; font-size: 0.72rem; color: var(--error); margin-top: 4px; }
.form-error.visible { display: flex; align-items: center; gap: 4px; }

@media (max-width: 600px) {
  .form-grid-2, .form-grid-3, .form-grid-4 { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════
   SIDEBAR SUMMARY
   ═══════════════════════════════════ */
.sidebar-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; position: sticky; top: 90px; }
.sidebar-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--border); }
.sidebar-flight { padding: 10px 0; border-bottom: 1px solid var(--border-light); }
.sidebar-flight .route { font-size: 0.88rem; font-weight: 600; }
.sidebar-flight .details { font-size: 0.8rem; color: var(--text-secondary); margin-top: 2px; }
.sidebar-total { padding: 14px 0 0; margin-top: 10px; border-top: 2px solid var(--text); }
.sidebar-total-row { display: flex; justify-content: space-between; font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 6px; }
.sidebar-grand { display: flex; justify-content: space-between; font-size: 1.2rem; font-weight: 800; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); }

/* ═══════════════════════════════════
   EXTRAS
   ═══════════════════════════════════ */
.extras-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.extra-item { display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; transition: all var(--transition); }
.extra-item:hover { border-color: var(--primary-light); }
.extra-item.selected { border-color: var(--primary); background: var(--primary-soft); }
.extra-item input[type="checkbox"] { accent-color: var(--primary); width: 16px; height: 16px; flex-shrink: 0; }
.extra-info { flex: 1; }
.extra-info h4 { font-size: 0.82rem; font-weight: 600; }
.extra-info p { font-size: 0.72rem; color: var(--text-muted); }
.extra-price { font-size: 0.85rem; font-weight: 700; color: var(--primary); white-space: nowrap; }

/* ═══════════════════════════════════
   PAYMENT — ESTILO DESPEGAR
   ═══════════════════════════════════ */
.payment-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; max-width: 520px; margin: 0 auto; }
.payment-card h2 { font-size: 1.2rem; font-weight: 700; text-align: center; margin-bottom: 4px; }
.payment-card .sub { text-align: center; color: var(--text-secondary); font-size: 0.82rem; margin-bottom: 24px; }

.card-preview { margin: 0 auto 24px; max-width: 320px; }
.card-visual { height: 190px; border-radius: var(--radius); background: linear-gradient(135deg, #1E293B, #334155); padding: 24px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.card-visual::before { content: ''; position: absolute; top: -30px; right: -30px; width: 120px; height: 120px; border-radius: 50%; background: rgba(255,255,255,0.04); }
.card-type { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 2px; color: rgba(255,255,255,0.5); font-weight: 600; }
.card-num { font-size: 1.3rem; font-family: 'Courier New', monospace; color: var(--white); letter-spacing: 2px; text-shadow: 0 1px 2px rgba(0,0,0,0.2); }
.card-footer { display: flex; justify-content: space-between; }
.card-footer .lbl { font-size: 0.55rem; text-transform: uppercase; letter-spacing: 1px; color: rgba(255,255,255,0.4); margin-bottom: 1px; }
.card-footer .val { font-size: 0.85rem; color: var(--white); font-weight: 600; }
.card-brand-icon { position: absolute; bottom: 18px; right: 22px; font-size: 2.2rem; opacity: 0.8; }

.card-brands { display: flex; gap: 6px; justify-content: center; margin-bottom: 20px; flex-wrap: wrap; }
.card-brands span { padding: 5px 12px; border: 1px solid var(--border); border-radius: 6px; font-size: 0.7rem; font-weight: 600; color: var(--text-muted); transition: all var(--transition); }
.card-brands span.active { border-color: var(--primary); color: var(--primary); background: var(--primary-light); }

.payment-error { background: #FEE2E2; border: 1px solid #FCA5A5; border-radius: var(--radius-sm); padding: 10px 14px; color: #991B1B; font-size: 0.82rem; margin-bottom: 16px; display: none; align-items: center; gap: 8px; }
.payment-error.visible { display: flex; }
.pay-security { display: flex; align-items: center; gap: 6px; justify-content: center; font-size: 0.75rem; color: var(--text-muted); margin-top: 16px; }

/* ═══════════════════════════════════
   CONFIRMACIÓN
   ═══════════════════════════════════ */
.conf-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 48px 32px; max-width: 580px; margin: 0 auto; text-align: center; }
.conf-icon { width: 72px; height: 72px; border-radius: 50%; background: #D1FAE5; display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; font-size: 2rem; }
.conf-card h2 { font-size: 1.4rem; font-weight: 800; margin-bottom: 4px; color: var(--success); }
.conf-card .sub { color: var(--text-secondary); font-size: 0.85rem; margin-bottom: 20px; }
.conf-ref { display: inline-block; padding: 8px 24px; background: var(--primary-light); border-radius: var(--radius-sm); font-family: 'Courier New', monospace; font-size: 1.1rem; font-weight: 700; color: var(--primary); letter-spacing: 2px; margin-bottom: 20px; }
.conf-details { text-align: left; border-top: 1px solid var(--border); padding-top: 18px; margin-top: 18px; }
.conf-row { display: flex; justify-content: space-between; padding: 6px 0; font-size: 0.85rem; }
.conf-row .lbl { color: var(--text-secondary); }
.conf-row .val { font-weight: 600; }
.conf-actions { margin-top: 20px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

/* ═══════════════════════════════════
   MY BOOKINGS
   ═══════════════════════════════════ */
.search-booking-card { max-width: 480px; margin: 0 auto 32px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; text-align: center; }
.search-booking-card h2 { font-size: 1.2rem; font-weight: 700; margin-bottom: 4px; }
.search-booking-card p { color: var(--text-secondary); font-size: 0.82rem; margin-bottom: 16px; }
.search-booking-form { display: flex; gap: 10px; }
.search-booking-form input { flex: 1; }

.booking-item { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; margin-bottom: 10px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; cursor: pointer; transition: all var(--transition); }
.booking-item:hover { border-color: var(--primary); box-shadow: var(--shadow); }
.booking-item .ref { font-family: 'Courier New', monospace; font-weight: 700; color: var(--primary); }
.booking-item .route { font-weight: 600; font-size: 0.9rem; }
.booking-item .date { font-size: 0.78rem; color: var(--text-muted); }

@media (max-width: 500px) {
  .search-booking-form { flex-direction: column; }
}

/* ═══════════════════════════════════
   FOOTER
   ═══════════════════════════════════ */
.footer { background: var(--secondary); color: var(--white); padding: 48px 0 24px; margin-top: 60px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 32px; }
.footer-brand .logo-text { color: var(--white); }
.footer-desc { font-size: 0.8rem; color: rgba(255,255,255,0.4); line-height: 1.6; max-width: 300px; margin-top: 10px; }
.footer-col h4 { font-size: 0.8rem; font-weight: 700; margin-bottom: 14px; text-transform: uppercase; letter-spacing: 0.5px; color: rgba(255,255,255,0.5); }
.footer-col li { margin-bottom: 6px; }
.footer-col li a { font-size: 0.8rem; color: rgba(255,255,255,0.35); transition: all var(--transition); }
.footer-col li a:hover { color: var(--primary); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.06); padding-top: 20px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.footer-bottom p { font-size: 0.75rem; color: rgba(255,255,255,0.3); }
.footer-bottom-links { display: flex; gap: 14px; flex-wrap: wrap; }
.footer-bottom-links a { font-size: 0.72rem; color: rgba(255,255,255,0.3); transition: color var(--transition); }
.footer-bottom-links a:hover { color: var(--primary); }
@media (max-width: 768px) { .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

/* ─── Toast ─── */
.toast { position: fixed; bottom: 24px; right: 24px; padding: 12px 20px; border-radius: var(--radius-sm); font-size: 0.82rem; font-weight: 500; box-shadow: var(--shadow-lg); z-index: 9999; animation: fadeUp 0.3s ease; display: flex; align-items: center; gap: 8px; max-width: 380px; }
.toast-success { background: var(--success); color: var(--white); }
.toast-error { background: var(--error); color: var(--white); }
.toast-warning { background: var(--warning); color: var(--text); }

/* ─── Fallback Banner ─── */
.fallback-banner { display: flex; align-items: center; gap: 10px; padding: 14px 18px; background: #FFF7ED; border: 1px solid #FED7AA; border-radius: var(--radius-sm); font-size: 0.82rem; color: #9A3412; font-weight: 500; margin-bottom: 16px; animation: slideDown 0.3s ease; line-height: 1.4; }

/* ─── Empty State ─── */
.empty-state { text-align: center; padding: 48px 20px; }
.empty-state .icon { font-size: 3.5rem; margin-bottom: 12px; opacity: 0.4; }
.empty-state h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 6px; }
.empty-state p { color: var(--text-secondary); font-size: 0.85rem; max-width: 380px; margin: 0 auto; }

/* ─── grid layout helper ─── */
.grid-2 { display: grid; grid-template-columns: 1.5fr 1fr; gap: 32px; align-items: start; }
@media (max-width: 768px) { .grid-2 { grid-template-columns: 1fr; } }

/* ─── Legal pages ─── */
.legal-hero { margin-top: var(--header-h); background: linear-gradient(135deg, var(--secondary), var(--primary-dark)); padding: 48px 0; text-align: center; }
.legal-hero h1 { font-size: 1.8rem; font-weight: 800; color: var(--white); }
.legal-hero h1 span { color: var(--accent); }
.legal-hero p { color: rgba(255,255,255,0.5); margin-top: 6px; font-size: 0.85rem; }
.legal-content { padding: 48px 0; background: var(--white); }
.legal-content .container { max-width: 760px; }
.legal-section { margin-bottom: 32px; }
.legal-section h2 { font-size: 1.1rem; font-weight: 700; margin-bottom: 10px; padding-bottom: 6px; border-bottom: 2px solid var(--primary-light); }
.legal-section p { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.7; margin-bottom: 8px; }
.legal-section ul { padding-left: 20px; margin: 6px 0 12px; }
.legal-section ul li { font-size: 0.83rem; color: var(--text-secondary); line-height: 1.6; margin-bottom: 4px; list-style: disc; }
.legal-back { display: inline-flex; align-items: center; gap: 6px; font-size: 0.85rem; font-weight: 600; color: var(--primary); margin-bottom: 20px; }
.legal-back:hover { gap: 10px; }
.legal-meta { margin-top: 32px; padding: 16px 20px; background: var(--primary-light); border-radius: var(--radius); border-left: 4px solid var(--primary); }
.legal-meta p { font-size: 0.8rem; color: var(--text-secondary); margin-bottom: 2px; }
