/* === Rundflug-Reservierung – Premium Stylesheet === */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --blue-900: #0c2d48;
    --blue-700: #145374;
    --blue-500: #2e86ab;
    --blue-400: #5aa9c8;
    --blue-100: #e8f4f8;
    --blue-50: #f0f9ff;
    --green-500: #10b981;
    --green-100: #d1fae5;
    --green-800: #065f46;
    --red-500: #ef4444;
    --red-100: #fee2e2;
    --red-800: #991b1b;
    --amber-500: #f59e0b;
    --amber-50: #fffbeb;
    --amber-200: #fde68a;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    --white: #ffffff;
    --shadow-sm: 0 1px 2px rgba(0,0,0,.05);
    --shadow: 0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,.1), 0 2px 4px -1px rgba(0,0,0,.06);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,.1), 0 4px 6px -2px rgba(0,0,0,.05);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,.1), 0 10px 10px -5px rgba(0,0,0,.04);
    --radius: 12px;
    --radius-lg: 16px;
    --radius-full: 9999px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.6;
    color: var(--gray-800);
    background: var(--gray-50);
    -webkit-font-smoothing: antialiased;
}

a { color: var(--blue-500); text-decoration: none; }
a:hover { color: var(--blue-700); }

.container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 1.25rem;
}

/* ============================================
   HERO
   ============================================ */
.hero {
    position: relative;
    background: linear-gradient(135deg, var(--blue-900) 0%, var(--blue-700) 40%, var(--blue-500) 100%);
    color: var(--white);
    padding: 4rem 0 3.5rem;
    text-align: center;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(46,134,171,.3) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 20%, rgba(90,169,200,.2) 0%, transparent 50%);
    pointer-events: none;
}
.hero::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 60px;
    background: var(--gray-50);
    clip-path: ellipse(55% 100% at 50% 100%);
}
.hero .container {
    position: relative;
    z-index: 1;
}
.hero h1 {
    font-size: 2.75rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: .5rem;
    text-shadow: 0 2px 4px rgba(0,0,0,.15);
}
.hero-sub {
    font-size: 1.2rem;
    font-weight: 400;
    opacity: .9;
    max-width: 600px;
    margin: 0 auto;
}
.hero-hint {
    display: inline-block;
    margin-top: 1rem;
    padding: .45rem 1.2rem;
    background: rgba(255,255,255,.15);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,.25);
    border-radius: var(--radius-full);
    font-size: .95rem;
    font-weight: 500;
}
.hero-badge {
    display: inline-block;
    background: rgba(255,255,255,.15);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,.2);
    padding: .4rem 1.2rem;
    border-radius: var(--radius-full);
    font-size: .85rem;
    font-weight: 500;
    margin-bottom: 1rem;
    letter-spacing: .03em;
}

/* ============================================
   INTRO SECTION
   ============================================ */
.intro-section {
    margin-top: 2rem;
}
.intro-box {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 2rem 2.5rem;
}
.intro-box h2 {
    color: var(--blue-900);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: .75rem;
}
.intro-box > p {
    color: var(--gray-600);
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}
.intro-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
}
.intro-detail {
    background: var(--blue-50);
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    border-left: 3px solid var(--blue-500);
    line-height: 1.6;
}
.intro-detail strong {
    color: var(--blue-900);
    font-size: 1rem;
}
.intro-detail small {
    color: var(--gray-500);
}

/* ============================================
   AIRCRAFT CARDS
   ============================================ */
.info-section {
    margin: 2.5rem 0;
}
.aircraft-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}
.aircraft-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    transition: transform .25s ease, box-shadow .25s ease;
}
.aircraft-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}
.aircraft-card .card-img {
    position: relative;
    overflow: hidden;
}
.aircraft-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform .4s ease;
}
.aircraft-card:hover img {
    transform: scale(1.05);
}
.card-img .card-price {
    position: absolute;
    bottom: .75rem;
    right: .75rem;
    background: var(--blue-900);
    color: var(--white);
    padding: .35rem .9rem;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: .95rem;
    box-shadow: var(--shadow-lg);
}
.aircraft-card .card-body {
    padding: 1.25rem 1.5rem 1.5rem;
}
.aircraft-card h3 {
    color: var(--blue-900);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: .35rem;
}
.aircraft-card .card-details {
    color: var(--gray-500);
    font-size: .95rem;
    display: flex;
    gap: .75rem;
    flex-wrap: wrap;
}
.card-detail-item {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
}
.card-detail-item svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* ============================================
   EVENT SECTIONS
   ============================================ */
.event-section {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 0;
    margin-bottom: 2rem;
    overflow: hidden;
}
.event-header {
    background: linear-gradient(135deg, var(--blue-900), var(--blue-700));
    color: var(--white);
    padding: 1.5rem 2rem;
}
.event-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: .15rem;
}
.event-subtitle {
    opacity: .85;
    font-size: .95rem;
}
.event-body {
    padding: 1.5rem 2rem 2rem;
}
.event-desc {
    color: var(--gray-500);
    margin-bottom: 1.25rem;
    font-size: .95rem;
}

/* ============================================
   SLOT GRID
   ============================================ */
.slot-grid {
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    overflow: hidden;
}
.slot-header {
    display: grid;
    grid-template-columns: 70px 110px 1fr 90px 90px;
    padding: .65rem 1rem;
    font-weight: 600;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--gray-500);
    background: var(--gray-100);
    border-bottom: 1px solid var(--gray-200);
}
.slot-row {
    display: grid;
    grid-template-columns: 70px 110px 1fr 90px 90px;
    padding: .7rem 1rem;
    border-bottom: 1px solid var(--gray-100);
    align-items: center;
    transition: all .2s ease;
    font-size: .95rem;
}
.slot-row:last-child {
    border-bottom: none;
}
.slot-row.available {
    cursor: pointer;
}
.slot-row.available:hover {
    background: var(--blue-50);
    padding-left: 1.25rem;
}
.slot-row.booked {
    opacity: .45;
    background: var(--gray-50);
}
.slot-round {
    font-weight: 600;
    color: var(--gray-400);
}
.slot-time {
    font-weight: 600;
    color: var(--blue-700);
    font-variant-numeric: tabular-nums;
}
.slot-aircraft {
    color: var(--gray-700);
}
.slot-price {
    font-weight: 600;
    color: var(--gray-700);
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    padding: .2rem .75rem;
    border-radius: var(--radius-full);
    font-size: .78rem;
    font-weight: 600;
    letter-spacing: .02em;
}
.badge-free {
    background: var(--green-100);
    color: var(--green-800);
}
.badge-free::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--green-500);
    animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: .4; }
}
.badge-booked {
    background: var(--red-100);
    color: var(--red-800);
}

/* ============================================
   MODAL
   ============================================ */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(15,23,42,.6);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    animation: fadeIn .2s ease;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
.modal-content {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    max-width: 520px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2rem;
    position: relative;
    animation: slideUp .3s ease;
}
@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
.modal-content h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--blue-900);
}
.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-100);
    border: none;
    border-radius: 50%;
    font-size: 1.3rem;
    cursor: pointer;
    color: var(--gray-500);
    transition: all .15s;
    line-height: 1;
}
.modal-close:hover {
    background: var(--gray-200);
    color: var(--gray-800);
}

/* Slot Summary in Modal */
.slot-summary {
    background: linear-gradient(135deg, var(--blue-50), var(--blue-100));
    padding: 1rem 1.25rem;
    border-radius: var(--radius);
    margin: 1rem 0 1.25rem;
    border-left: 4px solid var(--blue-500);
    font-size: .95rem;
    line-height: 1.7;
}

.seats-info {
    display: inline-block;
    margin-top: .3rem;
    font-weight: 600;
    color: var(--green-800);
}

/* ============================================
   FORMS
   ============================================ */
.form-group {
    margin-bottom: 1.1rem;
}
.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: .35rem;
    font-size: .88rem;
    color: var(--gray-700);
}
.form-group input,
.form-group select {
    width: 100%;
    padding: .65rem .9rem;
    border: 1.5px solid var(--gray-300);
    border-radius: var(--radius);
    font-size: .95rem;
    font-family: inherit;
    color: var(--gray-800);
    background: var(--white);
    transition: all .2s ease;
}
.form-group input::placeholder {
    color: var(--gray-400);
}
.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--blue-500);
    box-shadow: 0 0 0 3px rgba(46,134,171,.15);
}
.form-group-inline {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .75rem;
    align-items: end;
}
.form-info {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    padding: 1rem 1.25rem;
    border-radius: var(--radius);
    font-size: .95rem;
}
.form-info strong {
    font-size: 1.1rem;
    color: var(--blue-900);
}
.weight-intro {
    font-size: .9rem;
    color: var(--gray-500);
    margin-bottom: .75rem;
    padding-bottom: .5rem;
    border-bottom: 1px dashed var(--gray-200);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    padding: .7rem 1.75rem;
    border: none;
    border-radius: var(--radius);
    font-size: .95rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    text-decoration: none;
    transition: all .2s ease;
}
.btn:active { transform: scale(.97); }

.btn-primary {
    background: linear-gradient(135deg, var(--blue-500), var(--blue-700));
    color: var(--white);
    box-shadow: 0 2px 8px rgba(20,83,116,.3);
}
.btn-primary:hover {
    background: linear-gradient(135deg, var(--blue-700), var(--blue-900));
    box-shadow: 0 4px 12px rgba(20,83,116,.4);
    color: var(--white);
    transform: translateY(-1px);
}
#btn-submit {
    width: 100%;
    padding: .85rem;
    font-size: 1.05rem;
    margin-top: .5rem;
}

.btn-secondary {
    background: var(--gray-200);
    color: var(--gray-700);
}
.btn-secondary:hover { background: var(--gray-300); color: var(--gray-700); }

.btn-danger {
    background: var(--red-500);
    color: var(--white);
    font-size: .8rem;
    padding: .3rem .75rem;
    border-radius: 8px;
}
.btn-danger:hover { background: var(--red-800); color: var(--white); }

.btn-small {
    padding: .4rem 1rem;
    font-size: .85rem;
    border-radius: 8px;
}
.btn-active {
    background: var(--blue-500);
    color: var(--white);
}
.btn-active:hover { background: var(--blue-700); color: var(--white); }

/* ============================================
   MESSAGE BOXES
   ============================================ */
.message-box {
    max-width: 600px;
    margin: 3rem auto;
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 2.5rem;
}
.success-box {
    border-top: 4px solid var(--green-500);
}
.pending-box {
    border-top: 4px solid var(--amber-500);
}
.pending-box h2 {
    color: var(--gray-800);
}
.pending-box h2::before {
    content: '\2709  ';
}
.success-box h2 {
    color: var(--green-800);
}
.success-box h2::before {
    content: '\2713  ';
}
.error-box {
    border-top: 4px solid var(--red-500);
}
.error-box h2 {
    color: var(--red-800);
}
.error-box ul {
    margin: .75rem 0 1.5rem 1.25rem;
    color: var(--red-500);
}
.error-text {
    color: var(--red-500);
    font-weight: 500;
    margin-bottom: .75rem;
}
.info-note {
    background: var(--amber-50);
    border: 1px solid var(--amber-200);
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    margin: 1.25rem 0;
    font-size: .9rem;
    line-height: 1.7;
}

/* ============================================
   DETAIL TABLE (Bestätigung)
   ============================================ */
.detail-table {
    width: 100%;
    margin: 1.25rem 0;
    border-collapse: collapse;
}
.detail-table th,
.detail-table td {
    padding: .6rem .75rem;
    text-align: left;
    border-bottom: 1px solid var(--gray-200);
}
.detail-table th {
    font-weight: 600;
    width: 40%;
    color: var(--gray-500);
    font-size: .9rem;
}
.detail-table td {
    font-weight: 500;
}

/* ============================================
   ADMIN
   ============================================ */
.admin-header {
    background: linear-gradient(135deg, var(--gray-900), var(--gray-800));
    color: var(--white);
    padding: 1.25rem 0;
    box-shadow: var(--shadow-lg);
}
.admin-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: .75rem;
}
.admin-topbar h1 {
    font-size: 1.3rem;
    font-weight: 700;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}
.stat-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    padding: 1.5rem;
    text-align: center;
    border-top: 3px solid var(--blue-500);
    transition: transform .2s;
}
.stat-card:hover {
    transform: translateY(-2px);
}
.stat-number {
    display: block;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--blue-700);
    font-variant-numeric: tabular-nums;
}
.stat-label {
    font-size: .85rem;
    color: var(--gray-500);
    font-weight: 500;
    margin-top: .2rem;
}

.admin-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: .75rem;
    margin-bottom: 1rem;
    background: var(--white);
    padding: 1rem 1.25rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}
.filter-group {
    display: flex;
    align-items: center;
    gap: .5rem;
    flex-wrap: wrap;
}
.filter-group label {
    font-weight: 600;
    color: var(--gray-600);
}

.table-wrap {
    overflow-x: auto;
    margin-bottom: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
}
.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    font-size: .88rem;
}
.admin-table th,
.admin-table td {
    padding: .65rem .75rem;
    text-align: left;
    border-bottom: 1px solid var(--gray-100);
    white-space: nowrap;
}
.admin-table th {
    background: var(--gray-50);
    font-weight: 600;
    color: var(--gray-600);
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    position: sticky;
    top: 0;
    border-bottom: 2px solid var(--gray-200);
}
.admin-table tbody tr {
    transition: background .15s;
}
.admin-table tbody tr:hover td {
    background: var(--blue-50);
}
.empty-row {
    text-align: center;
    padding: 3rem !important;
    color: var(--gray-400);
    font-style: italic;
}

/* ============================================
   FOOTER
   ============================================ */
footer {
    text-align: center;
    padding: 2rem 0;
    color: var(--gray-400);
    font-size: .88rem;
    border-top: 1px solid var(--gray-200);
    margin-top: 1rem;
}
footer a { color: var(--gray-500); }
footer a:hover { color: var(--blue-500); }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .hero { padding: 3rem 0 2.5rem; }
    .hero h1 { font-size: 1.8rem; }
    .hero-sub { font-size: 1rem; }

    .slot-header { display: none; }
    .slot-row {
        display: grid;
        grid-template-columns: auto 1fr auto;
        gap: .25rem .75rem;
        padding: .85rem 1rem;
    }
    .slot-round {
        grid-row: 1;
        grid-column: 1;
    }
    .slot-time {
        grid-row: 1;
        grid-column: 2;
    }
    .slot-status {
        grid-row: 1 / 3;
        grid-column: 3;
        align-self: center;
    }
    .slot-aircraft {
        grid-row: 2;
        grid-column: 1 / 3;
        font-size: .88rem;
    }
    .slot-price {
        display: none; /* shown in badge area on mobile */
    }

    .event-header { padding: 1.25rem 1.25rem; }
    .event-body { padding: 1.25rem; }

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

    .admin-table { font-size: .8rem; }
    .admin-table th, .admin-table td { padding: .45rem .5rem; }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .message-box {
        padding: 1.75rem;
        margin: 2rem 1rem;
    }
}

@media (max-width: 480px) {
    .aircraft-cards {
        grid-template-columns: 1fr;
    }
    .stats-grid {
        grid-template-columns: 1fr;
    }
}
