/* ========================================
   Editable Plane Ticket Generator - Styles
   Premium Redesign v2.1 - Layout Optimized
   ======================================== */

:root {
    --primary-color: #0066cc;
    --primary-dark: #003366;
    --secondary-color: #003366;
    --accent-color: #00aaff;
    --accent-gold: #d4af37;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --error-color: #ef4444;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --bg-light: #f8fafc;
    --bg-dark: #1e293b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --transition: all 0.2s ease;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    /* Pass background for perforation notches */
    --pass-bg: #e8f4fc;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-light);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

/* ========== Layout ========== */
.main-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 16px;
}

/* ========== Compact Hero Section ========== */
.hero-section {
    position: relative;
    background: linear-gradient(135deg, #0a1628 0%, #1a365d 40%, #2563eb 100%);
    border-radius: var(--radius-lg);
    margin-bottom: 20px;
    padding: 32px 24px;
    overflow: hidden;
    min-height: auto;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
}

.hero-world-map {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.5;
}

.hero-clouds {
    position: absolute;
    top: 0;
    left: 0;
    width: 200%;
    height: 100%;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 20'%3E%3Cellipse cx='20' cy='10' rx='15' ry='6' fill='rgba(255,255,255,0.05)'/%3E%3Cellipse cx='60' cy='8' rx='20' ry='8' fill='rgba(255,255,255,0.03)'/%3E%3Cellipse cx='85' cy='12' rx='12' ry='5' fill='rgba(255,255,255,0.04)'/%3E%3C/svg%3E") repeat-x;
    animation: cloudDrift 60s linear infinite;
}

@keyframes cloudDrift {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

.hero-plane-trail {
    position: absolute;
    top: 30%;
    left: -100px;
    width: 40px;
    height: 40px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='rgba(255,255,255,0.8)'%3E%3Cpath d='M21 16v-2l-8-5V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5z'/%3E%3C/svg%3E") no-repeat center;
    background-size: contain;
    animation: planeFly 15s linear infinite;
    filter: drop-shadow(0 0 10px rgba(255,255,255,0.5));
}

@keyframes planeFly {
    0% { left: -100px; top: 40%; opacity: 0; }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { left: 110%; top: 25%; opacity: 0; }
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: white;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(10px);
    padding: 6px 16px;
    border-radius: 30px;
    margin-bottom: 12px;
    border: 1px solid rgba(255,255,255,0.2);
}

.badge-icon {
    font-size: 16px;
}

.badge-text {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.hero-title {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 8px;
    text-shadow: 0 2px 20px rgba(0,0,0,0.3);
    background: linear-gradient(135deg, #ffffff 0%, #e0e7ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 16px;
    line-height: 1.5;
}

.hero-subtitle br {
    display: none;
}

.hero-features {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.hero-feature {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 500;
}

.feature-icon {
    width: 20px;
    height: 20px;
    background: var(--accent-gold);
    color: #1a1a2e;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
}

/* ========== Editor Layout - Stacked ========== */
.editor-layout {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.editor-layout.stacked {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ========== Compact Form Panel ========== */
.form-panel {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.form-panel-header {
    background: var(--bg-light);
    padding: 14px 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.form-panel-header h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.form-panel-body {
    padding: 16px 20px;
    max-height: none;
    overflow-y: visible;
}

/* ========== Compact Field Groups ========== */
.field-group {
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-color);
}

.field-group:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.field-group-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.field-group-icon {
    width: 28px;
    height: 28px;
    background: var(--primary-color);
    color: white;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.field-group-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ========== Compact Form Controls ========== */
.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 12px;
}

.form-row:last-child {
    margin-bottom: 0;
}

.form-row.single {
    grid-template-columns: 1fr;
}

.form-row.triple {
    grid-template-columns: repeat(3, 1fr);
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.form-group input,
.form-group select {
    padding: 8px 12px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-family: inherit;
    transition: var(--transition);
    background: white;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.form-group input.error,
.form-group select.error {
    border-color: var(--error-color);
    background-color: #fef2f2;
}

.form-group input.valid {
    border-color: var(--success-color);
}

.form-group input.warning,
.form-group select.warning {
    border-color: var(--warning-color);
    background-color: #fffbeb;
}

.form-group .help-text {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 3px;
}

.form-group .error-text {
    font-size: 10px;
    color: var(--error-color);
    margin-top: 3px;
}

/* ========== Autocomplete ========== */
.autocomplete-wrapper {
    position: relative;
}

.autocomplete-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    display: none;
}

.autocomplete-results.active {
    display: block;
}

.autocomplete-item {
    padding: 10px 12px;
    cursor: pointer;
    border-bottom: 1px solid var(--border-color);
    transition: background 0.15s ease;
}

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

.autocomplete-item:hover,
.autocomplete-item.selected {
    background: var(--bg-light);
}

.autocomplete-item .primary {
    font-weight: 500;
    color: var(--text-primary);
    font-size: 13px;
}

.autocomplete-item .secondary {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.autocomplete-item .route-badge {
    display: inline-block;
    background: var(--success-color);
    color: white;
    font-size: 9px;
    padding: 2px 5px;
    border-radius: 3px;
    margin-left: 6px;
    font-weight: 600;
}

.autocomplete-item .route-info {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ========== Compact Pricing Section ========== */
.pricing-section {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 2px solid #bae6fd;
    border-radius: var(--radius-md);
    margin-top: 16px;
    overflow: hidden;
}

.pricing-header {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    padding: 10px 16px;
}

.pricing-header h3 {
    font-size: 13px;
    font-weight: 600;
    margin: 0;
}

.pricing-body {
    padding: 12px 16px;
}

.pricing-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    font-size: 13px;
}

.pricing-amount {
    font-weight: 600;
    color: var(--text-primary);
}

.pricing-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0 0;
    margin-top: 8px;
    border-top: 2px dashed #bae6fd;
    font-size: 14px;
    font-weight: 700;
}

.pricing-total-amount {
    font-size: 20px;
    color: var(--primary-color);
}

.add-passenger-section {
    padding: 12px 16px;
    background: rgba(255,255,255,0.5);
    border-top: 1px solid #bae6fd;
    display: flex;
    align-items: center;
    gap: 12px;
}

.passenger-limit-text {
    font-size: 11px;
    color: var(--text-muted);
}

/* ========== Preview Panel - Full Width ========== */
.preview-panel {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.preview-panel.full-width {
    width: 100%;
    margin-top: 0;
}

.preview-panel-header {
    background: var(--bg-light);
    padding: 14px 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.preview-panel-header h2 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.preview-theme-selector {
    display: flex;
    gap: 6px;
}

.theme-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid transparent;
    background: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.theme-btn:hover,
.theme-btn.active {
    border-color: var(--primary-color);
    transform: scale(1.1);
}

/* Preview Panel Body - Centered pass with subtle background */
.preview-panel-body {
    padding: 32px 24px;
    background: linear-gradient(135deg, #e8f4fc 0%, #f0f7fb 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 380px;
}

/* ========== LARGE Boarding Pass Design ========== */
.boarding-pass-container {
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
}

.boarding-pass {
    display: flex;
    width: 100%;
    background: white;
    border-radius: 12px;
    box-shadow:
        0 20px 60px rgba(0,0,0,0.12),
        0 8px 25px rgba(0,0,0,0.08);
    overflow: visible;
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-height: 320px;
}

.boarding-pass:hover {
    transform: translateY(-3px);
    box-shadow:
        0 25px 70px rgba(0,0,0,0.15),
        0 12px 35px rgba(0,0,0,0.1);
}

.destination-photo {
    position: absolute;
    top: 0;
    right: 180px;
    width: 150px;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0.1;
    pointer-events: none;
}

/* Main Pass Section - 75% width */
.pass-main {
    flex: 3;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: 12px 0 0 12px;
}

/* Pass Header */
.pass-header {
    background: linear-gradient(135deg, #003366 0%, #004d99 100%);
    color: white;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 12px 0 0 0;
}

.pass-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.airline-logo {
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.2);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.airline-name {
    font-size: 20px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.pass-header-right {
    text-align: right;
}

.pass-title {
    display: block;
    font-size: 10px;
    letter-spacing: 2px;
    opacity: 0.8;
    margin-bottom: 4px;
}

.pass-class {
    display: inline-block;
    background: var(--accent-gold);
    color: #1a1a2e;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Passenger Row */
.pass-passenger-row {
    padding: 14px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px dashed #e2e8f0;
    background: white;
}

.passenger-field .pass-label {
    font-size: 9px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.passenger-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.priority-tag {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: white;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Route Section - LARGE airport codes */
.pass-route-section {
    padding: 20px 24px;
    position: relative;
    background: white;
}

.route-map-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0.2;
    pointer-events: none;
}

.route-path-svg {
    width: 100%;
    height: 100%;
}

.route-endpoints {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 1;
}

.route-point {
    text-align: center;
    flex: 0 0 140px;
}

/* HUGE airport codes like competitor */
.airport-code {
    font-size: 52px;
    font-weight: 800;
    color: var(--primary-dark);
    line-height: 1;
    letter-spacing: -2px;
}

.airport-city {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
}

.route-arrow {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 16px;
}

.plane-svg {
    width: 50px;
    height: 20px;
    color: var(--text-muted);
}

/* Details Grid */
.pass-details-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    padding: 12px 24px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    border-bottom: 1px solid #e2e8f0;
}

.pass-field {
    text-align: center;
    padding: 6px 4px;
}

.pass-label {
    font-size: 8px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 3px;
}

.pass-value {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
}

/* Seat Section - Prominent boxes */
.pass-seat-section {
    display: flex;
    padding: 16px 24px;
    gap: 16px;
    align-items: stretch;
    background: white;
}

.seat-box {
    background: linear-gradient(135deg, #003366 0%, #004d99 100%);
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    text-align: center;
    min-width: 90px;
}

.seat-box .pass-label {
    color: rgba(255,255,255,0.7);
    margin-bottom: 4px;
}

.seat-number {
    font-size: 32px;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 4px;
}

.seat-class {
    font-size: 10px;
    opacity: 0.8;
    text-transform: uppercase;
}

.zone-box {
    background: #f1f5f9;
    padding: 12px 20px;
    border-radius: 8px;
    text-align: center;
    border: 2px solid #e2e8f0;
    min-width: 80px;
}

.zone-box .pass-label {
    margin-bottom: 4px;
}

.zone-number {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-dark);
}

.confirmation-box {
    flex: 1;
    text-align: right;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.confirmation-box .pass-label {
    margin-bottom: 4px;
}

.confirmation-code {
    font-size: 20px;
    font-weight: 700;
    font-family: 'Courier New', monospace;
    letter-spacing: 3px;
    color: var(--text-primary);
}

/* Barcode Section */
.pass-barcode-section {
    padding: 12px 24px 16px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    border-radius: 0 0 0 12px;
}

.barcode {
    height: 45px;
    display: flex;
    gap: 1px;
    justify-content: flex-start;
}

.barcode-line {
    background: var(--text-primary);
    height: 100%;
}

/* ========== Perforation Line - Realistic ========== */
.pass-perforation {
    width: 3px;
    background: repeating-linear-gradient(
        to bottom,
        transparent 0px,
        transparent 8px,
        #cbd5e1 8px,
        #cbd5e1 16px
    );
    position: relative;
    flex-shrink: 0;
}

/* Notch circles at top and bottom */
.pass-perforation::before {
    content: '';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 24px;
    height: 24px;
    background: var(--pass-bg);
    border-radius: 50%;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
}

.pass-perforation::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 24px;
    height: 24px;
    background: var(--pass-bg);
    border-radius: 50%;
    box-shadow: inset 0 -2px 4px rgba(0,0,0,0.1);
}

/* ========== Stub Section - 25% width, attached ========== */
.pass-stub {
    flex: 1;
    min-width: 200px;
    max-width: 240px;
    background: #fafafa;
    display: flex;
    flex-direction: column;
    border-radius: 0 12px 12px 0;
}

.stub-header {
    background: linear-gradient(135deg, #003366 0%, #004d99 100%);
    color: white;
    padding: 12px 14px;
    text-align: center;
    border-radius: 0 12px 0 0;
}

.stub-airline {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
}

.stub-content {
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
}

.stub-field {
    text-align: center;
}

.stub-label {
    font-size: 7px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.stub-value {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stub-route {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    padding: 8px 6px;
    background: #f1f5f9;
    border-radius: 4px;
}

.stub-code {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-dark);
}

.stub-arrow {
    color: var(--text-muted);
    font-size: 12px;
}

.stub-seat-box {
    background: var(--primary-dark);
    color: white;
    padding: 10px 8px;
    border-radius: 6px;
    text-align: center;
}

.stub-seat-box .stub-label {
    color: rgba(255,255,255,0.7);
}

.stub-seat {
    font-size: 22px;
    font-weight: 800;
}

.stub-barcode {
    height: 35px;
    display: flex;
    gap: 1px;
    justify-content: center;
    margin-top: auto;
    padding-top: 8px;
}

/* ========== Buttons ========== */
.btn {
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), #0284c7);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 102, 204, 0.3);
}

.btn-secondary {
    background: var(--bg-light);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--border-color);
}

.btn-success {
    background: linear-gradient(135deg, var(--success-color), #059669);
    color: white;
}

.btn-success:hover {
    background: linear-gradient(135deg, #059669, #047857);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-lg {
    padding: 14px 28px;
    font-size: 15px;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* ========== Action Buttons ========== */
.action-buttons {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.action-buttons .btn {
    flex: 1;
}

/* ========== Quick Actions ========== */
.quick-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.quick-action-btn {
    padding: 6px 14px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    border: none;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.quick-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* ========== Route Info ========== */
#route-info {
    display: none;
    padding: 8px 12px;
    margin: 8px 0;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--primary-color);
    font-size: 12px;
}

#route-info .route-valid {
    color: var(--success-color);
    font-weight: 600;
    margin-right: 12px;
}

#route-info .route-warning {
    color: var(--warning-color);
    font-weight: 600;
    margin-right: 12px;
}

#route-info .route-distance,
#route-info .route-duration {
    color: var(--text-secondary);
    margin-right: 12px;
}

/* ========== Seat Info Display ========== */
.seat-info-display {
    display: none;
    gap: 8px;
    margin-top: 6px;
    padding: 6px 10px;
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border-radius: var(--radius-sm);
    font-size: 11px;
    align-items: center;
}

.seat-info-display .seat-cabin {
    background: var(--primary-color);
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-weight: 600;
}

.seat-info-display .seat-position {
    color: var(--text-secondary);
}

.seat-info-display .seat-zone {
    background: var(--bg-light);
    padding: 2px 6px;
    border-radius: 3px;
    color: var(--text-secondary);
}

.sync-indicator {
    font-size: 9px;
    color: var(--success-color);
    margin-left: 4px;
}

/* ========== Field Feedback ========== */
.field-feedback {
    font-size: 11px;
    margin-top: 3px;
    display: none;
}

.field-feedback .error-text {
    color: var(--error-color);
}

.field-feedback .warning-text {
    color: var(--warning-color);
}

/* ========== Etsy Banner ========== */
#etsy-banner {
    background: linear-gradient(135deg, #6B21A8, #4C1D95);
    color: white;
    padding: 12px 0;
    text-align: center;
}

#etsy-banner p {
    color: #FFFFFF !important;
    font-size: 14px;
}

#etsy-banner input {
    padding: 8px 12px;
    border: 2px solid white;
    border-radius: 6px;
    font-size: 14px;
    text-transform: uppercase;
    max-width: 180px;
    text-align: center;
    font-weight: 600;
}

#etsy-banner button {
    padding: 8px 20px;
    border-radius: 6px;
    font-weight: 700;
    cursor: pointer;
    font-size: 14px;
    transition: var(--transition);
}

/* ========== Loading ========== */
.loading-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.8s linear infinite;
}

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

/* ========== Result Display ========== */
#result-display {
    margin-top: 20px;
    padding: 20px;
    background: #f0f9ff;
    border-radius: 12px;
    text-align: center;
}

#result-display img {
    max-width: 100%;
    border-radius: 8px;
    box-shadow: var(--shadow-md);
}

/* ========== Responsive ========== */
@media (max-width: 900px) {
    .boarding-pass {
        flex-direction: column;
        min-height: auto;
    }

    .pass-main {
        border-radius: 12px 12px 0 0;
    }

    .pass-header {
        border-radius: 12px 12px 0 0;
    }

    .pass-barcode-section {
        border-radius: 0;
    }

    .pass-stub {
        width: 100%;
        max-width: none;
        min-width: auto;
        border-radius: 0 0 12px 12px;
    }

    .stub-header {
        border-radius: 0;
    }

    .pass-perforation {
        width: 100%;
        height: 3px;
        background: repeating-linear-gradient(
            to right,
            transparent 0px,
            transparent 8px,
            #cbd5e1 8px,
            #cbd5e1 16px
        );
    }

    .pass-perforation::before {
        top: 50%;
        left: -12px;
        transform: translateY(-50%);
    }

    .pass-perforation::after {
        top: 50%;
        left: auto;
        right: -12px;
        bottom: auto;
        transform: translateY(-50%);
    }

    .stub-content {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 12px;
        padding: 16px;
    }

    .stub-field {
        flex: 0 0 auto;
    }

    .stub-route {
        flex: 0 0 auto;
    }

    .stub-seat-box {
        flex: 0 0 auto;
        padding: 10px 16px;
    }

    .stub-barcode {
        flex: 1 0 100%;
        margin-top: 8px;
        padding-top: 8px;
        border-top: 1px dashed #e2e8f0;
    }

    .airport-code {
        font-size: 40px;
    }
}

@media (max-width: 768px) {
    .main-container {
        padding: 12px;
    }

    .hero-section {
        padding: 24px 16px;
        margin-bottom: 16px;
    }

    .hero-title {
        font-size: 22px;
    }

    .hero-subtitle {
        font-size: 13px;
    }

    .hero-features {
        gap: 12px;
    }

    .hero-feature {
        font-size: 11px;
    }

    .form-panel-body {
        padding: 14px 16px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .form-row.triple {
        grid-template-columns: 1fr;
    }

    .preview-panel-body {
        padding: 20px 16px;
        min-height: auto;
    }

    .pass-details-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .pass-seat-section {
        flex-wrap: wrap;
        gap: 10px;
        padding: 14px 16px;
    }

    .seat-box, .zone-box {
        flex: 1;
        min-width: 70px;
    }

    .confirmation-box {
        flex: 1 0 100%;
        text-align: center;
        margin-top: 8px;
    }

    .action-buttons {
        flex-direction: column;
    }

    .quick-actions {
        flex-direction: column;
    }

    .quick-action-btn {
        width: 100%;
        justify-content: center;
    }

    .airport-code {
        font-size: 36px;
    }

    .route-point {
        flex: 0 0 100px;
    }

    .airport-city {
        max-width: 100px;
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .pass-details-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .pass-header {
        padding: 12px 16px;
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .pass-header-left {
        justify-content: center;
    }

    .pass-header-right {
        text-align: center;
    }

    .airport-code {
        font-size: 32px;
    }

    .seat-number {
        font-size: 26px;
    }

    .zone-number {
        font-size: 20px;
    }

    .confirmation-code {
        font-size: 16px;
    }

    .passenger-name {
        font-size: 14px;
    }

    .airline-name {
        font-size: 16px;
    }
}

/* ========== Theme Variations ========== */
.boarding-pass.theme-navy-gold .pass-header,
.boarding-pass.theme-navy-gold .stub-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
}

.boarding-pass.theme-navy-gold .pass-class {
    background: var(--accent-gold);
}

.boarding-pass.theme-navy-gold .seat-box,
.boarding-pass.theme-navy-gold .stub-seat-box {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
}

.boarding-pass.theme-navy-gold .airport-code,
.boarding-pass.theme-navy-gold .stub-code {
    color: #1a1a2e;
}

/* Animation for preview updates */
.pass-value, .stub-value, .airport-code, .seat-number, .zone-number, .confirmation-code {
    transition: all 0.15s ease;
}

.pass-value.updated, .stub-value.updated {
    animation: highlightUpdate 0.4s ease;
}

@keyframes highlightUpdate {
    0% { background: #fef3c7; }
    100% { background: transparent; }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}
