* {

    box-sizing: border-box;

    margin: 0;

    padding: 0;

}


body {

    font-family:
        Arial,
        Helvetica,
        sans-serif;

    background: #f5f7fb;

    color: #172033;

    min-height: 100vh;

}


/* =====================================================
   NAVBAR
===================================================== */

.navbar {

    background: #10182b;

    color: white;

    padding: 17px 7%;

    display: flex;

    justify-content: space-between;

    align-items: center;

    position: sticky;

    top: 0;

    z-index: 1000;

}


.logo {

    font-size: 21px;

    font-weight: bold;

}


.nav-links {

    display: flex;

    align-items: center;

    gap: 12px;

}


.nav-links a {

    color: white;

    text-decoration: none;

    padding: 9px 14px;

    border-radius: 8px;

    background:
        rgba(255,255,255,0.08);

}


#refreshBtn {

    border: none;

    color: white;

    background: #2563eb;

    padding: 10px 15px;

    border-radius: 8px;

    font-weight: bold;

    cursor: pointer;

}


#refreshBtn:hover {

    opacity: 0.9;

}


/* =====================================================
   PAGE
===================================================== */

.page {

    width: 92%;

    max-width: 1100px;

    margin: 45px auto 70px;

}


/* =====================================================
   HEADER
===================================================== */

.page-header {

    text-align: center;

    margin-bottom: 30px;

}


.badge {

    display: inline-block;

    background: #dbeafe;

    color: #1d4ed8;

    padding: 7px 14px;

    border-radius: 20px;

    font-size: 12px;

    font-weight: bold;

}


.page-header h1 {

    font-size: 38px;

    margin-top: 13px;

}


.page-header p {

    color: #6b7280;

    margin-top: 8px;

}


/* =====================================================
   GRID
===================================================== */

.bookings-container {

    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 20px;

}


/* =====================================================
   BOOKING CARD
===================================================== */

.booking-card {

    background: white;

    border:
        1px solid #e5e7eb;

    border-radius: 17px;

    padding: 21px;

    box-shadow:
        0 6px 22px
        rgba(0,0,0,0.05);

}


.booking-top {

    display: flex;

    justify-content: space-between;

    align-items: flex-start;

    gap: 15px;

    margin-bottom: 18px;

}


.taxi-name {

    font-size: 21px;

    font-weight: bold;

    margin-bottom: 5px;

}


.booking-id {

    color: #9ca3af;

    font-size: 11px;

}


/* =====================================================
   STATUS
===================================================== */

.status {

    display: inline-block;

    padding: 7px 11px;

    border-radius: 20px;

    font-size: 12px;

    font-weight: bold;

    white-space: nowrap;

}


.status-pending {

    background: #fef3c7;

    color: #92400e;

}


.status-confirmed {

    background: #dcfce7;

    color: #166534;

}


.status-driver {

    background: #dbeafe;

    color: #1e40af;

}


.status-completed {

    background: #e0e7ff;

    color: #3730a3;

}


.status-cancelled {

    background: #fee2e2;

    color: #991b1b;

}


/* =====================================================
   ROUTE
===================================================== */

.route-box {

    background: #f8fafc;

    border-radius: 11px;

    padding: 14px;

    margin-bottom: 15px;

}


.route-row {

    display: flex;

    align-items: center;

    gap: 10px;

    font-size: 14px;

}


.route-row + .route-row {

    margin-top: 12px;

}


.route-icon {

    width: 30px;

    height: 30px;

    border-radius: 50%;

    display: flex;

    align-items: center;

    justify-content: center;

    background: #eef2ff;

}


/* =====================================================
   DETAILS
===================================================== */

.details-grid {

    display: grid;

    grid-template-columns:
        repeat(2, 1fr);

    gap: 10px;

    margin-bottom: 16px;

}


.detail {

    background: #f8fafc;

    padding: 11px;

    border-radius: 9px;

}


.detail span {

    display: block;

    color: #6b7280;

    font-size: 11px;

    margin-bottom: 4px;

}


.detail strong {

    font-size: 13px;

}


/* =====================================================
   FARE
===================================================== */

.fare-box {

    display: flex;

    justify-content: space-between;

    align-items: center;

    border-top:
        1px solid #e5e7eb;

    padding-top: 15px;

    margin-top: 5px;

}


.fare-label {

    color: #6b7280;

    font-size: 13px;

}


.fare {

    font-size: 21px;

    color: #2563eb;

    font-weight: bold;

}


/* =====================================================
   PAYMENT STATUS
===================================================== */

.payment-status {

    margin-top: 13px;

    padding: 10px 12px;

    border-radius: 9px;

    font-size: 13px;

    font-weight: bold;

}


.payment-pending {

    background: #fff7ed;

    color: #c2410c;

}


.payment-paid {

    background: #dcfce7;

    color: #166534;

}


.payment-not-required {

    background: #f3f4f6;

    color: #6b7280;

}


/* =====================================================
   DRIVER
===================================================== */

.driver-box {

    margin-top: 14px;

    background: #eff6ff;

    border:
        1px solid #bfdbfe;

    border-radius: 10px;

    padding: 13px;

}


.driver-box h3 {

    font-size: 14px;

    margin-bottom: 8px;

    color: #1e40af;

}


.driver-row {

    font-size: 13px;

    margin-top: 5px;

}


/* =====================================================
   ACTIONS
===================================================== */

.booking-actions {

    display: flex;

    gap: 9px;

    margin-top: 17px;

}


.booking-actions button {

    flex: 1;

    border: none;

    padding: 11px;

    border-radius: 9px;

    font-weight: bold;

    cursor: pointer;

}


.pay-btn {

    background: #16a34a;

    color: white;

}


.pay-btn:hover {

    background: #15803d;

}


.cancel-btn {

    background: #fee2e2;

    color: #991b1b;

}


.cancel-btn:hover {

    background: #fecaca;

}


.details-btn {

    background: #eef2ff;

    color: #3730a3;

}


/* =====================================================
   STATES
===================================================== */

.loading,
.empty-state,
.error-state {

    grid-column: 1 / -1;

    background: white;

    padding: 55px;

    text-align: center;

    border-radius: 16px;

    border:
        1px solid #e5e7eb;

}


.empty-state h2,
.error-state h2 {

    margin-bottom: 8px;

}


.empty-state p,
.error-state p {

    color: #6b7280;

}


/* =====================================================
   SPINNER
===================================================== */

.spinner {

    width: 32px;

    height: 32px;

    border:
        3px solid #e5e7eb;

    border-top-color: #2563eb;

    border-radius: 50%;

    animation:
        spin 0.8s linear infinite;

    margin:
        0 auto 12px;

}


@keyframes spin {

    to {

        transform:
            rotate(360deg);

    }

}


/* =====================================================
   MODAL
===================================================== */

.modal {

    display: none;

    position: fixed;

    inset: 0;

    z-index: 3000;

    background:
        rgba(0,0,0,0.6);

    padding: 20px;

    align-items: center;

    justify-content: center;

}


.modal.show {

    display: flex;

}


.payment-box {

    width: 100%;

    max-width: 450px;

    background: white;

    border-radius: 18px;

    padding: 30px;

    position: relative;

    box-shadow:
        0 20px 60px
        rgba(0,0,0,0.2);

}


.close-btn {

    position: absolute;

    right: 15px;

    top: 15px;

    width: 34px;

    height: 34px;

    border: none;

    border-radius: 50%;

    background: #f3f4f6;

    cursor: pointer;

    font-size: 16px;

}


.payment-icon {

    width: 55px;

    height: 55px;

    border-radius: 50%;

    background: #dcfce7;

    display: flex;

    align-items: center;

    justify-content: center;

    font-size: 26px;

    margin-bottom: 15px;

}


.payment-box h2 {

    font-size: 24px;

    margin-bottom: 7px;

}


.payment-subtitle {

    color: #6b7280;

    line-height: 1.5;

    margin-bottom: 20px;

}


.payment-summary {

    background: #f8fafc;

    border-radius: 11px;

    padding: 14px;

    margin-bottom: 18px;

}


.payment-summary div {

    display: flex;

    justify-content: space-between;

    gap: 15px;

    padding: 8px 0;

}


.payment-summary span {

    color: #6b7280;

    font-size: 13px;

}


.payment-summary strong {

    text-align: right;

    font-size: 13px;

}


.payment-summary .payment-amount {

    color: #2563eb;

    font-size: 18px;

}


.pay-confirm-btn {

    width: 100%;

    border: none;

    padding: 14px;

    border-radius: 9px;

    background: #16a34a;

    color: white;

    font-size: 15px;

    font-weight: bold;

    cursor: pointer;

}


.pay-confirm-btn:hover {

    background: #15803d;

}


.pay-confirm-btn:disabled {

    opacity: 0.6;

    cursor: not-allowed;

}


.payment-message {

    text-align: center;

    margin-top: 12px;

    font-size: 13px;

}


/* =====================================================
   MOBILE
===================================================== */

@media (max-width: 800px) {

    .bookings-container {

        grid-template-columns: 1fr;

    }

}


@media (max-width: 600px) {

    .navbar {

        padding:
            14px 5%;

    }


    .logo {

        font-size: 17px;

    }


    .nav-links a,
    #refreshBtn {

        font-size: 12px;

        padding:
            8px 10px;

    }


    .page {

        width: 94%;

        margin-top: 30px;

    }


    .page-header h1 {

        font-size: 30px;

    }


    .booking-top {

        flex-direction: column;

    }


    .details-grid {

        grid-template-columns: 1fr;

    }


    .booking-actions {

        flex-direction: column;

    }


    .payment-box {

        padding: 25px 20px;

    }

}