/*
 * ZYYO Admin Panel - Stylesheet
 * Design language consistent with the main homepage
 * Uses same glassmorphism, gradients, and dark theme
 */

/* === Fonts === */
@font-face {
    font-family: "admin-sans";
    src: url(../../../static/fonts/Ubuntu-Regular.ttf);
    font-display: swap;
}

@font-face {
    font-family: "admin-title";
    src: url(../../../static/fonts/Pacifico-Regular.ttf);
    font-display: swap;
}

/* === CSS Variables (matching homepage theme) === */
:root {
    --gradient: linear-gradient(120deg, #bd34fe, #e0321b 30%, #41d1ff 60%);
    --purple-text: #747bff;
    --bg-dark: #0a0a0f;
    --bg-card: rgba(15, 15, 25, 0.85);
    --bg-card-hover: rgba(25, 25, 40, 0.9);
    --bg-input: rgba(20, 20, 35, 0.8);
    --bg-sidebar: rgba(10, 10, 18, 0.95);
    --text-primary: #e8e8f0;
    --text-secondary: #8888a0;
    --text-muted: #5a5a70;
    --border-color: rgba(255, 255, 255, 0.06);
    --border-light: rgba(255, 255, 255, 0.1);
    --accent-blue: #41d1ff;
    --accent-purple: #bd34fe;
    --accent-green: #4ade80;
    --accent-orange: #fb923c;
    --accent-red: #f87171;
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.3);
    --shadow-modal: 0 20px 60px rgba(0, 0, 0, 0.5);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --sidebar-width: 240px;
    --header-height: 64px;
    --transition: all 0.2s ease;
}

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

/* === Base === */
body {
    font-family: "admin-sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* === Scrollbar === */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }

/* ============================
   LOGIN PAGE
   ============================ */
.login-body {
    min-height: 100vh;
    background: var(--bg-dark);
    background-image: url(../../../static/img/background.jpg);
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.login-bg-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 0;
}

.login-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 420px;
    padding: 20px;
}

.login-card {
    background: var(--bg-card);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 40px 36px;
    box-shadow: var(--shadow-modal);
}

.login-logo {
    text-align: center;
    margin-bottom: 32px;
}

.login-logo-circle {
    width: 72px;
    height: 72px;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: var(--gradient);
    opacity: 0.9;
    animation: pulse-glow 3s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% { transform: scale(1); opacity: 0.9; }
    50% { transform: scale(1.05); opacity: 1; }
}

.login-title {
    font-family: "admin-title", cursive;
    font-size: 36px;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    background-size: 200%;
    animation: gradient-shift 8s ease infinite;
}

@keyframes gradient-shift {
    0% { background-position: 0%; }
    50% { background-position: 100%; }
    100% { background-position: 0%; }
}

.gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.login-subtitle {
    color: var(--text-secondary);
    font-size: 14px;
    margin-top: 4px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.login-error {
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.3);
    color: var(--accent-red);
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    text-align: center;
}

.login-footer {
    text-align: center;
    margin-top: 24px;
    color: var(--text-muted);
    font-size: 12px;
}

/* ============================
   ADMIN LAYOUT
   ============================ */
.admin-body {
    min-height: 100vh;
    background: var(--bg-dark);
    background-image: url(../../../static/img/background.jpg);
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.admin-layout {
    display: flex;
    min-height: 100vh;
    position: relative;
}

/* === Sidebar === */
.admin-sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: var(--bg-sidebar);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: transform 0.3s ease;
}

.sidebar-header {
    padding: 24px 20px 16px;
    display: flex;
    align-items: baseline;
    gap: 8px;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-logo {
    font-family: "admin-title", cursive;
    font-size: 28px;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.sidebar-nav {
    flex: 1;
    padding: 12px 10px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: var(--transition);
    cursor: pointer;
}

.nav-item svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    opacity: 0.7;
    transition: var(--transition);
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-primary);
}

.nav-item:hover svg { opacity: 1; }

.nav-item.active {
    background: rgba(189, 52, 254, 0.1);
    color: var(--accent-purple);
}

.nav-item.active svg {
    opacity: 1;
    stroke: var(--accent-purple);
}

.sidebar-footer {
    padding: 12px 10px;
    border-top: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.logout-btn:hover {
    background: rgba(248, 113, 113, 0.1) !important;
    color: var(--accent-red) !important;
}

/* === Main Content === */
.admin-main {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.admin-header {
    height: var(--header-height);
    padding: 0 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(10, 10, 18, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 50;
}

.page-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.header-user {
    display: flex;
    align-items: center;
    gap: 8px;
}

.user-name {
    font-size: 13px;
    color: var(--text-secondary);
    padding: 6px 12px;
    background: rgba(255,255,255,0.04);
    border-radius: var(--radius-sm);
}

.admin-content {
    flex: 1;
    padding: 24px 28px;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* === Sidebar Toggle (Mobile) === */
.sidebar-toggle {
    display: none;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 200;
    width: 40px;
    height: 40px;
    border: none;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    cursor: pointer;
    align-items: center;
    justify-content: center;
}

.sidebar-toggle svg { width: 20px; height: 20px; }

.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 90;
}

/* ============================
   STATS GRID
   ============================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: var(--transition);
}

.stat-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-light);
    transform: translateY(-2px);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-icon svg { width: 22px; height: 22px; }

.stat-icon-blue { background: rgba(65, 209, 255, 0.12); color: var(--accent-blue); }
.stat-icon-purple { background: rgba(189, 52, 254, 0.12); color: var(--accent-purple); }
.stat-icon-green { background: rgba(74, 222, 128, 0.12); color: var(--accent-green); }
.stat-icon-orange { background: rgba(251, 146, 60, 0.12); color: var(--accent-orange); }

.stat-number {
    font-size: 28px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
}

.stat-label {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* ============================
   CARDS
   ============================ */
.card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition);
}

.card:hover {
    border-color: var(--border-light);
}

.card-header {
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
}

.card-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.card-link {
    font-size: 13px;
    color: var(--accent-purple);
    text-decoration: none;
    transition: var(--transition);
}

.card-link:hover { color: var(--accent-blue); }

.card-body {
    padding: 20px;
}

/* ============================
   DASHBOARD GRID
   ============================ */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

/* ============================
   SETTINGS GRID
   ============================ */
.settings-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

/* ============================
   LIST TABLE (Dashboard)
   ============================ */
.list-table {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.list-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.list-row:hover {
    background: rgba(255, 255, 255, 0.03);
}

.list-row-main {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.list-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

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

/* ============================
   DATA TABLE
   ============================ */
.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    text-align: left;
    padding: 12px 16px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}

.data-table td {
    padding: 12px 16px;
    font-size: 14px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.sort-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: rgba(255,255,255,0.05);
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
}

/* ============================
   BADGES
   ============================ */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.badge-blue { background: rgba(65, 209, 255, 0.12); color: var(--accent-blue); }
.badge-purple { background: rgba(189, 52, 254, 0.12); color: var(--accent-purple); }
.badge-green { background: rgba(74, 222, 128, 0.12); color: var(--accent-green); }
.badge-red { background: rgba(248, 113, 113, 0.12); color: var(--accent-red); }
.badge-orange { background: rgba(251, 146, 60, 0.12); color: var(--accent-orange); }
.badge-gray { background: rgba(255, 255, 255, 0.06); color: var(--text-muted); }

/* ============================
   BUTTONS
   ============================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    font-family: inherit;
    white-space: nowrap;
}

.btn svg { width: 16px; height: 16px; }

.btn-primary {
    background: var(--accent-purple);
    color: #fff;
}

.btn-primary:hover {
    background: #a020e0;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(189, 52, 254, 0.3);
}

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

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.btn-block {
    width: 100%;
    justify-content: center;
    padding: 12px;
    font-size: 15px;
}

.btn-danger {
    background: rgba(248, 113, 113, 0.12);
    color: var(--accent-red);
}

.btn-danger:hover {
    background: rgba(248, 113, 113, 0.2);
}

/* Action buttons in table */
.action-btns {
    display: flex;
    gap: 6px;
}

.btn-icon {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    background: transparent;
}

.btn-icon svg { width: 15px; height: 15px; }

.btn-edit { color: var(--accent-blue); }
.btn-edit:hover { background: rgba(65, 209, 255, 0.12); }

.btn-delete { color: var(--accent-red); }
.btn-delete:hover { background: rgba(248, 113, 113, 0.12); }

/* ============================
   FORMS
   ============================ */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 16px;
}

.form-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
}

.required { color: var(--accent-red); }

.form-input {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
    transition: var(--transition);
    outline: none;
}

.form-input:focus {
    border-color: var(--accent-purple);
    box-shadow: 0 0 0 3px rgba(189, 52, 254, 0.15);
}

.form-input::placeholder {
    color: var(--text-muted);
}

.form-textarea {
    resize: vertical;
    min-height: 80px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

select.form-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238888a0' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

/* Toggle Switch */
.form-switch {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
}

.form-switch input {
    display: none;
}

.switch-slider {
    width: 40px;
    height: 22px;
    background: rgba(255,255,255,0.1);
    border-radius: 11px;
    position: relative;
    transition: var(--transition);
}

.switch-slider::after {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--text-secondary);
    top: 2px;
    left: 2px;
    transition: var(--transition);
}

.form-switch input:checked + .switch-slider {
    background: rgba(189, 52, 254, 0.3);
}

.form-switch input:checked + .switch-slider::after {
    background: var(--accent-purple);
    transform: translateX(18px);
}

.switch-label {
    font-size: 13px;
    color: var(--text-secondary);
}

/* ============================
   MODALS
   ============================ */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: var(--bg-card);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 520px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-modal);
    animation: modal-in 0.2s ease;
}

.modal-sm { max-width: 400px; }

@keyframes modal-in {
    from { opacity: 0; transform: scale(0.95) translateY(10px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
    padding: 20px 24px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 16px;
    font-weight: 600;
}

.modal-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.modal-close:hover {
    background: rgba(255,255,255,0.05);
    color: var(--text-primary);
}

.modal-content form {
    padding: 20px 24px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
    margin-top: 8px;
}

/* ============================
   TAGS PREVIEW
   ============================ */
.tags-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: rgba(189, 52, 254, 0.08);
    border: 1px solid rgba(189, 52, 254, 0.15);
    border-radius: var(--radius-md);
    font-size: 14px;
    color: var(--text-primary);
    transition: var(--transition);
}

.tag-item:hover {
    background: rgba(189, 52, 254, 0.12);
    border-color: rgba(189, 52, 254, 0.25);
}

.tag-actions {
    display: flex;
    gap: 2px;
    opacity: 0;
    transition: var(--transition);
}

.tag-item:hover .tag-actions { opacity: 1; }

.btn-edit-sm, .btn-delete-sm {
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 4px;
    transition: var(--transition);
}

.btn-edit-sm svg, .btn-delete-sm svg { width: 12px; height: 12px; }

.btn-edit-sm { color: var(--accent-blue); }
.btn-edit-sm:hover { background: rgba(65, 209, 255, 0.15); }

.btn-delete-sm { color: var(--accent-red); }
.btn-delete-sm:hover { background: rgba(248, 113, 113, 0.15); }

/* ============================
   PAGE ACTIONS
   ============================ */
.page-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 16px;
}

/* ============================
   UTILITIES
   ============================ */
.text-muted { color: var(--text-muted); font-size: 13px; }
.text-link { color: var(--accent-blue); text-decoration: none; font-size: 13px; }
.text-link:hover { text-decoration: underline; }
.text-date { color: var(--text-secondary); font-size: 13px; font-family: monospace; }

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: 14px;
}

/* Toast notification */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    padding: 12px 20px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    animation: toast-in 0.3s ease;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.toast-success {
    background: rgba(74, 222, 128, 0.15);
    border: 1px solid rgba(74, 222, 128, 0.3);
    color: var(--accent-green);
}

.toast-error {
    background: rgba(248, 113, 113, 0.15);
    border: 1px solid rgba(248, 113, 113, 0.3);
    color: var(--accent-red);
}

@keyframes toast-in {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Confirm dialog */
.confirm-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fade-in 0.15s ease;
}

.confirm-box {
    background: var(--bg-card);
    backdrop-filter: blur(30px);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 24px;
    max-width: 380px;
    width: 100%;
    box-shadow: var(--shadow-modal);
    animation: modal-in 0.2s ease;
}

.confirm-box h4 {
    font-size: 16px;
    margin-bottom: 8px;
}

.confirm-box p {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

@keyframes fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ============================
   RESPONSIVE
   ============================ */
@media (max-width: 1024px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .dashboard-grid { grid-template-columns: 1fr; }
    .settings-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .admin-sidebar {
        transform: translateX(-100%);
    }

    .admin-sidebar.open {
        transform: translateX(0);
    }

    .sidebar-toggle {
        display: flex;
    }

    .sidebar-overlay.active {
        display: block;
    }

    .admin-main {
        margin-left: 0;
    }

    .admin-header {
        padding-left: 64px;
    }

    .admin-content {
        padding: 16px;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .stat-card { padding: 14px; }
    .stat-number { font-size: 22px; }

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

    .modal-content {
        max-width: 100%;
        margin: 10px;
    }
}

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

    .login-card {
        padding: 28px 20px;
    }
}
