/* 
 * Sheikh Hamdan Royal Services - Premium Styles & Theme System
 * Supports Light & Dark Mode via Semantic Variables
 */

:root {
    /* --- primitive colors --- */
    --c-gold: #C5A059;
    --c-gold-dark: #9A7B3E;
    --c-gold-light: #E5C585;

    --c-navy-900: #0F172A;
    --c-navy-800: #1E293B;
    --c-navy-700: #334155;

    --c-white: #FFFFFF;
    --c-slate-50: #F8FAFC;
    --c-slate-100: #F1F5F9;
    --c-slate-200: #E2E8F0;
    --c-slate-400: #94A3B8;
    --c-slate-500: #64748B;

    /* --- semantic themes (Light Mode Default) --- */
    --bg-body: var(--c-slate-50);
    --bg-surface: var(--c-white);
    --bg-surface-elevated: var(--c-white);
    --bg-glass: rgba(255, 255, 255, 0.9);

    --text-primary: var(--c-navy-900);
    --text-secondary: var(--c-slate-500);
    --text-on-accent: var(--c-white);

    --border-color: var(--c-slate-200);
    --border-highlight: var(--c-gold);

    --accent-primary: var(--c-gold);
    --accent-gradient: linear-gradient(135deg, #C5A059 0%, #E5C585 50%, #C5A059 100%);

    /* --- effects --- */
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 10px 30px -10px rgba(197, 160, 89, 0.3);

    --overlay-hero: linear-gradient(to bottom, rgba(15, 23, 42, 0.05), rgba(15, 23, 42, 0.1));
    --blur: blur(12px);

    /* --- layout --- */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Manrope', sans-serif;
    --container-padding: 2rem;
    --section-padding: 6rem;
    --radius-md: 16px;
    --radius-lg: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Dark Mode Overrides */
body.dark-mode {
    --bg-body: #0B1120;
    /* Darker than navy-900 for improved contrast */
    --bg-surface: var(--c-navy-900);
    --bg-surface-elevated: var(--c-navy-800);
    --bg-glass: rgba(15, 23, 42, 0.85);

    --text-primary: var(--c-slate-100);
    --text-secondary: var(--c-slate-400);

    --border-color: var(--c-navy-700);

    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.5);

    --overlay-hero: linear-gradient(to bottom, rgba(11, 17, 32, 0.3), rgba(11, 17, 32, 0.9));
}

/* --- Base Styles --- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-body);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.5s ease, color 0.5s ease;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--text-primary);
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    display: block;
}

ul {
    list-style: none;
}

button {
    cursor: pointer;
    border: none;
    font-family: var(--font-body);
}

.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

/* --- Typography --- */
.section-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 4rem;
}

.section-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.section-subtitle {
    font-size: 1rem;
    color: var(--accent-primary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
}

/* --- Components: Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--accent-gradient);
    color: var(--text-on-accent);
    box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -10px rgba(197, 160, 89, 0.6);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.btn-full {
    width: 100%;
}

/* --- Navbar --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: var(--transition);
}

.navbar.scrolled {
    padding: 1rem 0;
    background: var(--bg-glass);
    backdrop-filter: var(--blur);
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

.nav-logo h3 {
    margin: 0;
    font-size: 1.5rem;
}

.nav-logo span {
    font-size: 0.75rem;
    font-family: var(--font-body);
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--accent-primary);
    display: block;
}

.nav-menu {
    display: flex;
    gap: 2.5rem;
}

.nav-link {
    font-weight: 500;
    color: var(--text-primary);
    position: relative;
    opacity: 0.9;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-primary);
    opacity: 1;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-primary);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* User Menu & Auth */
.user-menu-btn {
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    width: 220px;
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: 0.5rem;
    margin-top: 1rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
}

.user-menu.active .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown a,
.user-dropdown button {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    color: var(--text-primary);
    background: transparent;
}

.user-dropdown a:hover,
.user-dropdown button:hover {
    background: var(--bg-body);
    color: var(--accent-primary);
}

/* Theme Toggle */
.theme-toggle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-surface-elevated);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.theme-toggle:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
    transform: rotate(15deg);
}

.moon-icon {
    display: none;
}

body.dark-mode .moon-icon {
    display: block;
}

body.dark-mode .sun-icon {
    display: none;
}

/* Mobile Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    background: transparent;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu-toggle span {
    width: 100%;
    height: 2px;
    background-color: var(--text-primary);
    border-radius: 4px;
    transition: var(--transition);
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px;
}

.hero-background {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: var(--bg-body);
}

.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--overlay-hero);
    pointer-events: none;
}

.hero-content {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    align-items: center;
    gap: 4rem;
    position: relative;
    z-index: 2;
    padding: 0 var(--container-padding);
}

.main-title {
    font-size: 5vw;
    /* Responsive font size */
    font-weight: 700;
    margin: 1rem 0 2rem;
    line-height: 1.1;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 600px;
}

.image-container {
    border-radius: 200px 200px 0 0;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    position: relative;
    border: 4px solid var(--bg-surface);
}

.hero-img {
    width: 100%;
    transition: transform 1.5s ease;
}

.image-container:hover .hero-img {
    transform: scale(1.05);
}

/* --- Sections Generic --- */
section {
    padding: var(--section-padding) 0;
}

section:nth-child(even) {
    background-color: var(--bg-surface-elevated);
}

/* --- Cards --- */
.about-card,
.service-card,
.flight-form-container,
.meet-greet-content {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 2.5rem;
    transition: var(--transition);
}

.about-card:hover,
.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-highlight);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.service-card {
    text-align: center;
    position: relative;
    overflow: hidden;
}

.card-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--bg-surface-elevated);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
    transition: var(--transition);
}

.service-card:hover .card-icon {
    background: var(--accent-primary);
    color: var(--text-on-accent);
}

.price {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: 2rem;
    font-family: var(--font-heading);
}

/* Card Tiers Colors */
.royal-card.silver {
    border-top: 4px solid #C0C0C0;
}

.royal-card.gold {
    border-top: 4px solid #FFD700;
}

.royal-card.platinum {
    border-top: 4px solid #E5E4E2;
    background: linear-gradient(to bottom, var(--bg-surface), var(--bg-surface-elevated));
}

/* --- Forms --- */
.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    background: var(--bg-body);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 1rem;
    border-radius: 8px;
    font-family: var(--font-body);
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(197, 160, 89, 0.1);
}

/* --- Responsive Media Queries --- */
@media (max-width: 1024px) {
    .section-title {
        font-size: 2.5rem;
    }

    .main-title {
        font-size: 3rem;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .hero-image {
        order: -1;
        max-width: 500px;
        margin: 0 auto;
    }

    .nav-menu,
    .nav-actions .user-menu,
    .nav-actions .auth-buttons,
    .nav-actions #theme-toggle {
        /* On mobile, we might hide these in favor of a slide-out drawer, 
           but for now we'll just show the toggle and hamburger */
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: var(--bg-surface);
        flex-direction: column;
        padding: 6rem 2rem;
        box-shadow: -10px 0 20px rgba(0, 0, 0, 0.2);
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1000;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-actions {
        /* Keep theme toggle visible on mobile in header, or move to menu? */
        /* Let's keep toggle visible next to hamburger */
    }

    .mobile-menu-toggle {
        display: flex;
    }

    /* Hide desktop auth/user in favor of mobile menu items (logic handled in JS or CSS) */
    .nav-actions .user-menu,
    .nav-actions .auth-buttons {
        display: none;
    }

    .about-content {
        grid-template-columns: 1fr;
    }

    .about-image {
        order: -1;
        margin-bottom: 2rem;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 1.5rem;
    }

    .section-padding {
        padding: 4rem 0;
    }

    .main-title {
        font-size: 2.5rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Animations & Utilities --- */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.flight-preview-page,
.booking-preview-page {
    background: var(--bg-body);
}

.step-label {
    color: var(--text-primary);
}

.step-number {
    background: var(--bg-surface-elevated);
    color: var(--text-secondary);
}

.step.active .step-number {
    background: var(--accent-primary);
    color: var(--text-on-accent);
}

/* --- Gallery Section --- */
.gallery {
    padding: var(--section-padding) 0;
    background: var(--bg-surface);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    grid-auto-flow: dense;
    margin-top: 2rem;
}

.gallery-item {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    height: 300px;
    cursor: pointer;
    box-shadow: var(--shadow-md);
}

.gallery-item.wide {
    grid-column: span 2;
}

.gallery-item.tall {
    grid-row: span 2;
    height: 616px;
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.9), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
    display: flex;
    align-items: flex-end;
    padding: 2rem;
}

.gallery-item:hover .gallery-img {
    transform: scale(1.1);
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-caption {
    transform: translateY(20px);
    transition: transform 0.4s ease;
}

.gallery-item:hover .gallery-caption {
    transform: translateY(0);
}

.gallery-caption h4 {
    color: var(--c-gold);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.gallery-caption p {
    color: var(--c-slate-200);
    font-size: 0.9rem;
}

/* --- Floating Label Forms --- */
.form-group-floating {
    position: relative;
    margin-bottom: 1.5rem;
}

.form-group-floating input,
.form-group-floating select,
.form-group-floating textarea {
    width: 100%;
    padding: 1.5rem 1rem 0.5rem;
    font-size: 1rem;
    background: var(--bg-body);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    transition: all 0.2s ease;
    appearance: none;
}

.form-group-floating textarea {
    min-height: 150px;
}

.form-group-floating label {
    position: absolute;
    top: 1rem;
    left: 1rem;
    color: var(--text-secondary);
    pointer-events: none;
    transition: all 0.2s ease;
    font-size: 1rem;
    background: transparent;
    transform-origin: left top;
}

/* Float logic */
.form-group-floating input:focus~label,
.form-group-floating input:not(:placeholder-shown)~label,
.form-group-floating select:focus~label,
.form-group-floating select:not([value=""]):valid~label,
.form-group-floating textarea:focus~label,
.form-group-floating textarea:not(:placeholder-shown)~label {
    transform: translateY(-0.75rem) scale(0.85);
    color: var(--accent-primary);
    font-weight: 600;
}

.form-group-floating input:focus,
.form-group-floating select:focus,
.form-group-floating textarea:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(197, 160, 89, 0.1);
    outline: none;
}

/* --- Services / Plans Grid --- */
.services-grid {
    display: grid;
    /* Force 3 columns on desktop for side-by-side layout */
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    align-items: start;
    /* Align tops */
    margin-top: 2rem;
}

.service-card {
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2.5rem 2rem;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--accent-primary);
}

.service-card .card-icon {
    color: var(--accent-primary);
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: center;
}

.service-card h3 {
    font-family: var(--font-heading);
    color: var(--text-primary);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.service-card .price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--c-gold);
    margin-bottom: 1.5rem;
}

.service-card .features {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem 0;
    flex-grow: 1;
    /* Pushes button down */
    color: var(--text-secondary);
}

.service-card .features li {
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.service-card .features li:last-child {
    border-bottom: none;
}

/* --- Responsive adjustment for Service Grid --- */
@media (max-width: 900px) {
    .services-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Flight Search Widget (Real World Style) --- */
.flight-widget-container {
    background: var(--bg-surface-elevated);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-color);
    max-width: 1200px;
    margin: 0 auto;
}

.flight-options-bar {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.option-pill {
    background: var(--bg-body);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    cursor: pointer;
    border: 1px solid var(--border-color);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.option-pill select {
    border: none;
    background: transparent;
    color: var(--text-primary);
    font-size: 0.9rem;
    outline: none;
    cursor: pointer;
}

/* Active State for Flight Type Buttons */
.option-pill.active {
    background: var(--accent-primary);
    color: var(--text-on-accent);
    border-color: var(--accent-primary);
    font-weight: 600;
}

.option-pill:hover {
    border-color: var(--accent-primary);
}

.search-bar-row {
    display: grid;
    grid-template-columns: 2fr 40px 2fr 2fr 1.5fr;
    gap: 0.5rem;
    background: var(--bg-body);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.5rem;
    align-items: center;
}

.search-field {
    position: relative;
    padding: 0.5rem 1rem;
}

.search-field label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.search-field input {
    width: 100%;
    border: none;
    background: transparent;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    padding: 0;
}

.search-field input::placeholder {
    color: var(--text-muted);
    opacity: 0.5;
}

.search-field input:focus {
    outline: none;
}

.swap-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: var(--accent-primary);
}

.swap-btn:hover {
    transform: rotate(180deg);
    border-color: var(--accent-primary);
}

.search-btn-container {
    height: 100%;
}

.search-btn-container .btn {
    height: 100%;
    width: 100%;
    border-radius: 8px;
    /* Square off slightly to fit bar */
    font-size: 1.1rem;
}

/* Vertical divider between inputs */
.field-divider {
    width: 1px;
    height: 60%;
    background: var(--border-color);
    position: absolute;
    right: 0;
    top: 20%;
}

/* --- Flight Ticket Summary Card --- */
.flight-ticket-card {
    background: var(--bg-surface-elevated);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
}

.ticket-header {
    background: var(--bg-surface);
    padding: 1rem 2rem;
    border-bottom: 1px dashed var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.airline-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.airline-logo {
    width: 40px;
    height: 40px;
    background: var(--c-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.ticket-body {
    padding: 2rem;
}

.flight-route-visual {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.city-node {
    text-align: center;
    flex: 1;
}

.city-node .time {
    font-size: 2rem;
    font-weight: 700;
    /* Playfair removed for times generally, keeping readable sans */
    color: var(--text-primary);
    display: block;
}

.city-node .airport {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    display: block;
}

.duration-segment {
    flex: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 1rem;
}

.duration-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.duration-line {
    width: 100%;
    height: 2px;
    background: var(--border-color);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.duration-line::before,
.duration-line::after {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--border-color);
    border-radius: 50%;
    position: absolute;
}

.duration-line::before {
    left: 0;
}

.duration-line::after {
    right: 0;
}

.plane-icon-travel {
    background: var(--bg-surface-elevated);
    padding: 0 0.5rem;
    color: var(--accent-primary);
}

/* Wrapper for Ticket Details Grid */
.ticket-details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    background: var(--bg-body);
    padding: 1.5rem;
    border-radius: 8px;
}

.ticket-detail-item label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 0.25rem;
}

.ticket-detail-item span {
    font-weight: 600;
    color: var(--text-primary);
}

@media (max-width: 900px) {
    .search-bar-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .field-divider {
        display: none;
    }

    .swap-btn {
        transform: rotate(90deg);
        margin: 0 auto;
    }
}

/* =========================================
   Refined Flight Widget (Wakanow Style)
   ========================================= */
.refined-widget {
    background: transparent;
    padding: 1rem 0;
    max-width: 100%;
}

.widget-top-bar {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 2rem;
    margin-bottom: 1rem;
    padding-left: 0.5rem;
}

.trip-type-tabs {
    display: flex;
    gap: 0.5rem;
    background: #f0f2f5;
    padding: 4px;
    border-radius: 8px;
}

.trip-tab {
    position: relative;
    cursor: pointer;
}

.trip-tab input {
    display: none;
}

.trip-tab span {
    display: block;
    padding: 0.5rem 1.2rem;
    border-radius: 6px;
    font-size: 0.9rem;
    color: #4b5563;
    font-weight: 500;
    transition: all 0.2s;
}

.trip-tab input:checked+span {
    background: #fff;
    color: var(--accent-primary);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    font-weight: 600;
}

.trip-tab.disabled span {
    opacity: 0.5;
    cursor: not-allowed;
}

.widget-dropdowns {
    display: flex;
    gap: 1rem;
}

.minimal-select {
    border: 1px solid transparent;
    background: transparent;
    font-size: 0.95rem;
    color: #374151;
    font-weight: 500;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
}

.minimal-select:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Integrated Search Bar */
.search-bar-integrated {
    display: grid;
    grid-template-columns: 2.5fr 40px 2.5fr 2fr 1.5fr;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    /* For rounded corners */
    align-items: center;
}

@media (max-width: 900px) {
    .search-bar-integrated {
        grid-template-columns: 1fr;
        gap: 1rem;
        background: transparent;
        box-shadow: none;
    }

    .search-segment,
    .search-btn-wrapper {
        background: #fff;
        border-radius: 8px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    }

    .swap-icon-btn {
        display: none;
        /* Hide on mobile to stack */
    }
}

.search-segment {
    display: flex;
    flex-direction: column;
    padding: 1rem 1.5rem;
    border-right: 1px solid #e5e7eb;
    position: relative;
}

.search-segment:last-of-type {
    border-right: none;
}

.search-segment label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #9ca3af;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.search-segment input {
    border: none;
    outline: none;
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
    width: 100%;
    padding: 0;
    background: transparent;
}

.search-segment input::placeholder {
    color: #d1d5db;
    font-weight: 400;
}

.swap-icon-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
    cursor: pointer;
    margin: 0 -16px;
    /* Overlap */
    z-index: 2;
    transition: transform 0.2s;
}

.swap-icon-btn:hover {
    transform: rotate(180deg);
    background: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.search-btn-wrapper {
    padding: 0.5rem;
    height: 100%;
}

.cta-search-btn {
    width: 100%;
    height: 100%;
    border: none;
    background: #00aeff;
    /* Wakanow Blue roughly */
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
    min-height: 50px;
}

.cta-search-btn:hover {
    background: #0099e0;
}


/* =========================================
   Refined Preview Ticket (Wakanow Style)
   ========================================= */
.ticket-wrapper {
    max-width: 900px;
    margin: 2rem auto;
    font-family: 'Manrope', sans-serif;
}

.ticket-header-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 1rem;
}

.ticket-header-row h2 {
    font-size: 1.5rem;
    color: #1f2937;
}

.btn-link {
    background: none;
    border: none;
    color: #00aeff;
    cursor: pointer;
    font-size: 0.9rem;
}

.flight-ticket-card.wakanow-style {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    border: 1px solid #e5e7eb;
}

.ticket-top-info {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #f3f4f6;
    display: flex;
    gap: 1rem;
    align-items: center;
    font-size: 0.9rem;
}

.flight-icon {
    color: #6b7280;
}

.highlight-text {
    color: #00aeff;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
}

.ticket-date-text {
    font-weight: 600;
    color: #374151;
}

.fare-rules {
    margin-left: auto;
    color: #00aeff;
    text-decoration: none;
    font-size: 0.85rem;
}

.ticket-main-body {
    display: flex;
    padding: 2rem 1.5rem;
    gap: 2rem;
}

@media (max-width: 768px) {
    .ticket-main-body {
        flex-direction: column;
        gap: 1.5rem;
    }
}

.airline-column {
    flex: 0 0 200px;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.airline-logo-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d0021b;
    /* Air Peace red ish */
}

.airline-details {
    display: flex;
    flex-direction: column;
}

.airline-name {
    font-weight: 700;
    color: #111827;
}

.flight-code {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
}

.baggage-info {
    display: flex;
    gap: 0.8rem;
    font-size: 0.8rem;
    color: #6b7280;
}

.baggage-info span {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Route Column */
.route-column {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.city-time-group {
    text-align: center;
    min-width: 120px;
}

.flight-date-small {
    display: block;
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 0.2rem;
}

.flight-time-big {
    font-size: 1.75rem;
    font-weight: 800;
    color: #111827;
    margin-bottom: 0.2rem;
}

.airport-name {
    font-size: 0.85rem;
    color: #4b5563;
    line-height: 1.4;
    max-width: 150px;
    margin: 0 auto;
}

.visual-duration {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 1rem;
    margin-top: 1.5rem;
}

.duration-text {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 0.3rem;
}

.duration-line-graphic {
    width: 100%;
    height: 2px;
    background: #e5e7eb;
    position: relative;
    margin-bottom: 0.3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.duration-line-graphic .dot {
    width: 8px;
    height: 8px;
    background: #d1d5db;
    border-radius: 50%;
}

.class-text {
    font-size: 0.8rem;
    color: #9ca3af;
}

/* Footer */
.ticket-footer-action {
    padding: 1rem 1.5rem;
    background: #f9fafb;
    border-top: 1px solid #f3f4f6;
    display: flex;
    justify-content: flex-end;
}