* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background: #fff8f1;
    color: #1e293b;
    padding-top: 90px;
    padding-bottom: 70px;
}

.admin-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 90px;
    background: rgba(255, 248, 241, 0.96);
    border-bottom: 1px solid #f1dcc8;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 7%;
    z-index: 1000;
    box-shadow: 0 8px 24px rgba(91, 55, 28, 0.08);
}

.admin-logo {
    font-size: 34px;
    font-weight: 900;
    color: #1e293b;
}

.admin-logo::after {
    content: ".";
    color: #f97316;
}

.admin-header nav a {
    color: #334155;
    text-decoration: none;
    margin-left: 14px;
    font-weight: 700;
    padding: 11px 16px;
    border-radius: 999px;
}

.admin-header nav a:hover {
    background: #f97316;
    color: white;
}

.admin-main {
    min-height: calc(100vh - 160px);
    padding: 45px 8%;
}

.admin-hero {
    background: linear-gradient(135deg, #1e293b, #334155);
    color: white;
    border-radius: 34px;
    padding: 46px;
    margin-bottom: 32px;
    box-shadow: 0 24px 55px rgba(30, 41, 59, 0.22);
}

.admin-hero h1 {
    font-size: 42px;
    margin-bottom: 12px;
}

.admin-hero p {
    color: #cbd5e1;
    font-size: 18px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 24px;
    margin-bottom: 34px;
}

.stat-card {
    background: white;
    border: 1px solid #f1dcc8;
    border-radius: 28px;
    padding: 32px;
    box-shadow: 0 18px 40px rgba(91, 55, 28, 0.08);
}

.stat-card span {
    color: #64748b;
    font-weight: 800;
}

.stat-card h2 {
    font-size: 44px;
    margin-top: 12px;
    color: #f97316;
}

.admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.admin-actions a {
    background: #f97316;
    color: white;
    padding: 15px 26px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 900;
}

.admin-actions a:hover {
    background: #ea580c;
}

.auth-main {
    min-height: calc(100vh - 160px);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 50px 20px;
}

.auth-card {
    width: 100%;
    max-width: 460px;
    background: white;
    border: 1px solid #f1dcc8;
    border-radius: 30px;
    padding: 42px;
    box-shadow: 0 24px 55px rgba(91, 55, 28, 0.12);
}

.auth-label {
    display: inline-block;
    background: #fff0df;
    color: #f97316;
    padding: 9px 16px;
    border-radius: 999px;
    font-weight: 800;
    margin-bottom: 18px;
}

.auth-card h1 {
    font-size: 38px;
    margin-bottom: 12px;
}

.auth-card p {
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 26px;
}

.auth-card label {
    display: block;
    font-weight: 700;
    margin-bottom: 8px;
    margin-top: 16px;
}

.auth-card input {
    width: 100%;
    padding: 15px;
    border: 1px solid #f1dcc8;
    border-radius: 14px;
    font-size: 15px;
}

.auth-card button {
    width: 100%;
    margin-top: 24px;
    padding: 15px;
    border: none;
    border-radius: 999px;
    background: #f97316;
    color: white;
    font-weight: 900;
    font-size: 16px;
    cursor: pointer;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    padding: 13px;
    border-radius: 14px;
    margin-bottom: 18px;
    font-weight: 700;
}

.alert-success {
    background: #dcfce7;
    color: #166534;
    padding: 13px;
    border-radius: 14px;
    margin-bottom: 18px;
    font-weight: 700;
}

.admin-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 248, 241, 0.96);
    border-top: 1px solid #f1dcc8;
    color: #334155;
    text-align: center;
    padding: 20px;
    z-index: 1000;
    font-size: 14px;
    font-weight: 700;
}

@media (max-width: 768px) {
    body {
        padding-top: 145px;
    }

    .admin-header {
        height: auto;
        flex-direction: column;
        gap: 14px;
        padding: 18px 6%;
    }

    .admin-header nav {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
    }

    .admin-header nav a {
        margin: 4px;
        font-size: 14px;
    }

    .admin-main {
        padding: 30px 6%;
    }

    .admin-hero {
        padding: 32px 24px;
    }

    .admin-hero h1 {
        font-size: 30px;
    }
}
.page-header {
    background: linear-gradient(135deg, #1e293b, #334155);
    color: white;
    border-radius: 30px;
    padding: 38px;
    margin-bottom: 28px;
    box-shadow: 0 24px 55px rgba(30, 41, 59, 0.18);
}

.page-header h1 {
    font-size: 36px;
    margin-bottom: 10px;
}

.page-header p {
    color: #cbd5e1;
}

.admin-card {
    background: white;
    border: 1px solid #f1dcc8;
    border-radius: 28px;
    padding: 30px;
    margin-bottom: 28px;
    box-shadow: 0 18px 40px rgba(91, 55, 28, 0.08);
}

.admin-card h2 {
    margin-bottom: 22px;
    color: #1e293b;
}

.admin-form label {
    display: block;
    font-weight: 800;
    margin-bottom: 8px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
}

.admin-form input,
.admin-form select {
    width: 100%;
    padding: 14px;
    border: 1px solid #f1dcc8;
    border-radius: 14px;
    font-size: 15px;
}

.admin-form button {
    margin-top: 22px;
    background: #f97316;
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 999px;
    font-weight: 900;
    cursor: pointer;
}

.table-wrap {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 15px;
    border-bottom: 1px solid #f1dcc8;
    text-align: left;
}

.admin-table th {
    color: #64748b;
    font-size: 14px;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 13px;
}

.status-badge.active {
    background: #dcfce7;
    color: #166534;
}

.status-badge.inactive {
    background: #fee2e2;
    color: #991b1b;
}

.delete-link {
    color: #dc2626;
    font-weight: 800;
    text-decoration: none;
}
.admin-form textarea {
    width: 100%;
    min-height: 110px;
    padding: 14px;
    border: 1px solid #f1dcc8;
    border-radius: 14px;
    font-size: 15px;
    resize: vertical;
}

.product-thumb {
    width: 68px;
    height: 68px;
    object-fit: cover;
    border-radius: 14px;
    border: 1px solid #f1dcc8;
}
.status-badge.pending {
    background: #fef3c7;
    color: #92400e;
}

.status-badge.paid,
.status-badge.delivered,
.status-badge.success {
    background: #dcfce7;
    color: #166534;
}

.status-badge.failed,
.status-badge.cancelled {
    background: #fee2e2;
    color: #991b1b;
}

.status-badge.refunded {
    background: #e0e7ff;
    color: #3730a3;
}

.status-badge.placed,
.status-badge.confirmed,
.status-badge.packed {
    background: #dbeafe;
    color: #1e40af;
}

.status-badge.out_for_delivery {
    background: #ffedd5;
    color: #9a3412;
}

.order-update-form {
    display: grid;
    gap: 8px;
    min-width: 180px;
}

.order-update-form select,
.order-update-form input {
    width: 100%;
    padding: 10px;
    border: 1px solid #f1dcc8;
    border-radius: 12px;
    font-size: 14px;
}

.order-update-form button {
    background: #f97316;
    color: white;
    border: none;
    padding: 10px;
    border-radius: 999px;
    font-weight: 900;
    cursor: pointer;
}

.order-update-form button:hover {
    background: #ea580c;
}

.order-items-list {
    list-style: none;
    padding: 0;
    margin: 0;
    min-width: 180px;
}

.order-items-list li {
    background: #fff8f1;
    border: 1px solid #f1dcc8;
    border-radius: 14px;
    padding: 10px;
    margin-bottom: 8px;
}