/* Admin Panel — دنيا التسالي */
:root {
    --admin-sidebar: #0f172a;
    --admin-accent: #d97706;
    --admin-accent-dark: #b45309;
}

.admin-login-bg {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #78350f 100%);
}

.admin-login-card {
    background: white;
    border-radius: 1.25rem;
    padding: 2rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
}

.admin-login-logo {
    width: 72px;
    height: 72px;
    margin: 0 auto 1rem;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    box-shadow: 0 8px 20px rgba(217, 119, 6, 0.35);
}

.admin-sidebar {
    width: 280px;
    background: linear-gradient(180deg, #0c1222 0%, #111827 45%, #0f172a 100%);
    min-height: 100vh;
    height: 100vh;
    position: fixed;
    top: 0;
    right: 0;
    z-index: 50;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -8px 0 32px rgba(0, 0, 0, 0.25);
    border-left: 1px solid rgba(255, 255, 255, 0.06);
}

.admin-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1rem 0.75rem;
    flex-shrink: 0;
}

.admin-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    flex: 1;
    min-width: 0;
}

.admin-brand-icon {
    width: 46px;
    height: 46px;
    background: linear-gradient(145deg, #f59e0b 0%, #c86320 100%);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 14px rgba(217, 119, 6, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.admin-brand-icon img {
    filter: brightness(0) invert(1);
}

.admin-brand-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.admin-brand-name {
    font-weight: 800;
    font-size: 1rem;
    color: #fff;
    line-height: 1.2;
}

.admin-brand-sub {
    font-size: 0.7rem;
    color: #94a3b8;
    margin-top: 2px;
}

.admin-sidebar-close {
    display: none;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.08);
    color: #cbd5e1;
    cursor: pointer;
    font-size: 1rem;
    flex-shrink: 0;
}

.admin-sidebar-close:hover {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
}

.admin-sidebar-metrics {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 0.5rem;
    padding: 0 0.85rem 0.75rem;
    flex-shrink: 0;
}

.admin-metric {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.45rem 0.5rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 700;
    color: #cbd5e1;
}

.admin-metric-live {
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.25);
    color: #6ee7b7;
    justify-content: flex-start;
    padding-inline: 0.65rem;
}

.admin-metric-icon {
    font-size: 0.85rem;
    opacity: 0.85;
}

.admin-live-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.75rem 1rem;
    padding: 0.35rem 0.75rem;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 9999px;
    color: #6ee7b7;
    font-size: 0.75rem;
}

.live-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    animation: pulse-live 1.5s infinite;
}

@keyframes pulse-live {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.85); }
}

.admin-nav {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0.25rem 0.65rem 1rem;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}

.admin-nav::-webkit-scrollbar {
    width: 4px;
}

.admin-nav::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
}

.admin-nav-group {
    margin-bottom: 0.35rem;
}

.admin-nav-section {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.65rem;
    letter-spacing: 0.06em;
    color: #64748b;
    padding: 0.65rem 0.75rem 0.4rem;
    font-weight: 700;
    margin: 0;
}

.admin-nav-section-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #d97706;
    opacity: 0.8;
}

.admin-nav-link {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.55rem 0.7rem;
    border-radius: 12px;
    color: #94a3b8;
    font-size: 0.84rem;
    font-weight: 500;
    transition: all 0.2s ease;
    margin-bottom: 3px;
    text-decoration: none;
    position: relative;
    border: 1px solid transparent;
}

.admin-nav-link:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #f1f5f9;
    border-color: rgba(255, 255, 255, 0.05);
}

.admin-nav-link.active {
    background: linear-gradient(90deg, rgba(217, 119, 6, 0.22) 0%, rgba(217, 119, 6, 0.08) 100%);
    color: #fcd34d;
    font-weight: 700;
    border-color: rgba(251, 191, 36, 0.2);
    box-shadow: inset 3px 0 0 #f59e0b;
}

.admin-nav-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.06);
}

.admin-nav-icon-blue { background: rgba(59, 130, 246, 0.15); }
.admin-nav-icon-purple { background: rgba(168, 85, 247, 0.15); }
.admin-nav-icon-amber { background: rgba(245, 158, 11, 0.18); }
.admin-nav-icon-green { background: rgba(34, 197, 94, 0.15); }
.admin-nav-icon-teal { background: rgba(20, 184, 166, 0.15); }
.admin-nav-icon-gold { background: rgba(234, 179, 8, 0.15); }
.admin-nav-icon-red { background: rgba(239, 68, 68, 0.15); }
.admin-nav-icon-pink { background: rgba(236, 72, 153, 0.15); }
.admin-nav-icon-indigo { background: rgba(99, 102, 241, 0.18); }
.admin-nav-icon-cyan { background: rgba(6, 182, 212, 0.15); }
.admin-nav-icon-yellow { background: rgba(250, 204, 21, 0.15); }
.admin-nav-icon-orange { background: rgba(249, 115, 22, 0.15); }
.admin-nav-icon-slate { background: rgba(148, 163, 184, 0.12); }

.admin-nav-label {
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-nav-sub {
    margin: 0.15rem 0 0.5rem 0;
    padding-right: 0.5rem;
    border-right: 2px solid rgba(255, 255, 255, 0.06);
    margin-right: 1.25rem;
    display: none;
}

.admin-nav-sub.is-open {
    display: block;
}

.admin-nav-sublink {
    display: block;
    padding: 0.4rem 0.85rem;
    margin-bottom: 2px;
    border-radius: 8px;
    font-size: 0.78rem;
    color: #64748b;
    text-decoration: none;
    transition: all 0.15s;
}

.admin-nav-sublink:hover {
    color: #e2e8f0;
    background: rgba(255, 255, 255, 0.04);
}

.admin-nav-sublink.active {
    color: #fbbf24;
    background: rgba(217, 119, 6, 0.1);
    font-weight: 600;
}

.admin-sidebar-footer {
    flex-shrink: 0;
    padding: 0.85rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.2);
}

.admin-user-card {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.65rem;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    margin-bottom: 0.65rem;
}

.admin-user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, #d97706, #92400e);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1rem;
    flex-shrink: 0;
}

.admin-user-name {
    font-size: 0.85rem;
    font-weight: 700;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-user-role {
    font-size: 0.68rem;
    color: #94a3b8;
    margin-top: 1px;
}

.admin-footer-actions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.45rem;
}

.admin-footer-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.55rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    text-decoration: none;
    font-size: 1.1rem;
    transition: all 0.15s;
}

.admin-footer-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-1px);
}

.admin-footer-btn-danger:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.3);
}

.admin-nav-danger { color: #f87171 !important; }
.admin-nav-danger:hover { background: rgba(248, 113, 113, 0.1); }

.admin-badge {
    margin-right: auto;
    background: #d97706;
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 0.1rem 0.45rem;
    border-radius: 9999px;
    min-width: 1.25rem;
    text-align: center;
}

.admin-badge-alert { background: #ef4444; animation: pulse-live 2s infinite; }

.admin-main {
    margin-right: 280px;
    min-height: 100vh;
}

.admin-topbar {
    background: white;
    border-bottom: 1px solid #e2e8f0;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    position: sticky;
    top: 0;
    z-index: 40;
}

.admin-menu-btn {
    display: none;
    background: #f1f5f9;
    border: none;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 1.25rem;
    cursor: pointer;
}

.admin-page-title { font-size: 1.25rem; font-weight: 800; color: #0f172a; }
.admin-page-sub { font-size: 0.75rem; color: #94a3b8; }

.admin-topbar-user {
    margin-right: auto;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.admin-avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #d97706, #b45309);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.admin-content { padding: 1.5rem; }

.admin-panel {
    background: white;
    border-radius: 1rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    overflow: hidden;
}

.admin-panel-head {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    font-weight: 700;
    color: #0f172a;
}

.admin-stat-card {
    background: white;
    border-radius: 1rem;
    border: 1px solid #e2e8f0;
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.admin-stat-live { border-color: rgba(16, 185, 129, 0.3); background: linear-gradient(135deg, #fff, #ecfdf5); }

.admin-stat-icon { font-size: 1.75rem; }

.admin-stat-label { font-size: 0.75rem; color: #64748b; }
.admin-stat-value { font-size: 1.5rem; font-weight: 800; color: #0f172a; }

.admin-table { width: 100%; font-size: 0.875rem; border-collapse: collapse; }
.admin-table th { text-align: right; padding: 0.75rem 1rem; background: #f8fafc; color: #64748b; font-weight: 600; font-size: 0.75rem; }
.admin-table td { padding: 0.75rem 1rem; border-top: 1px solid #f1f5f9; }
.admin-table tr:hover td { background: #fafafa; }

.admin-label { display: block; font-size: 0.8rem; font-weight: 600; color: #475569; margin-bottom: 0.35rem; }
.admin-input {
    width: 100%;
    padding: 0.6rem 0.85rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.65rem;
    font-family: inherit;
    font-size: 0.875rem;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.admin-input:focus { outline: none; border-color: #d97706; box-shadow: 0 0 0 3px rgba(217,119,6,0.15); }
.admin-input-sm { padding: 0.4rem 0.6rem; border: 1px solid #e2e8f0; border-radius: 0.5rem; font-size: 0.8rem; font-family: inherit; }

.admin-btn-primary {
    background: linear-gradient(135deg, #d97706, #b45309);
    color: white;
    border: none;
    padding: 0.6rem 1.25rem;
    border-radius: 0.65rem;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: transform 0.1s, box-shadow 0.15s;
}
.admin-btn-primary:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(217,119,6,0.35); }

.admin-btn-sm {
    background: #f1f5f9;
    border: none;
    padding: 0.4rem 0.85rem;
    border-radius: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    text-decoration: none;
    display: inline-block;
    color: inherit;
}
.admin-btn-sm-edit { background: #fff7ed; color: #c2410c; }
.admin-btn-sm-edit:hover { background: #ffedd5; }
.admin-btn-sm-muted { background: #f8fafc; color: #64748b; }
.admin-btn-sm-muted:hover { background: #e2e8f0; }
.admin-btn-sm-danger { background: #fef2f2; color: #dc2626; }
.admin-btn-sm-danger:hover { background: #fee2e2; }
.admin-btn-sm-link { background: #eff6ff; color: #2563eb; padding: 0.4rem 0.55rem; }

.admin-badge-pill {
    display: inline-block;
    padding: 0.2rem 0.65rem;
    border-radius: 9999px;
    font-size: 0.7rem;
    font-weight: 700;
}
.admin-badge-pill-success { background: #dcfce7; color: #166534; }
.admin-badge-pill-muted { background: #f1f5f9; color: #64748b; }

/* Categories admin */
.cat-icon-picker {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.35rem;
}
.cat-icon-btn {
    aspect-ratio: 1;
    border: 2px solid #e2e8f0;
    border-radius: 0.65rem;
    background: #fff;
    font-size: 1.25rem;
    cursor: pointer;
    transition: all 0.15s;
}
.cat-icon-btn:hover { border-color: #fbbf24; background: #fffbeb; transform: scale(1.05); }
.cat-icon-btn.is-selected { border-color: #d97706; background: #fff7ed; box-shadow: 0 0 0 3px rgba(217,119,6,0.15); }

.cat-preview-icon { font-size: 1.75rem; margin-bottom: 0.35rem; }
.cat-preview-name { font-size: 0.75rem; font-weight: 700; color: #0f172a; line-height: 1.3; }
.cat-preview-meta { display: flex; justify-content: center; gap: 0.5rem; font-size: 0.65rem; color: #94a3b8; margin-top: 0.35rem; }
.cat-table-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #fff7ed, #ffedd5);
    border-radius: 0.65rem;
    font-size: 1.1rem;
    flex-shrink: 0;
}

/* Categories page — responsive */
.cat-page { display: flex; flex-direction: column; gap: 1rem; }

.cat-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 1rem 1.15rem;
    background: linear-gradient(135deg, #fff 0%, #fffbeb 100%);
    border: 1px solid #fde68a;
    border-radius: 1rem;
    box-shadow: 0 2px 8px rgba(217, 119, 6, 0.08);
}
.cat-toolbar-desc { font-size: 0.8rem; color: #64748b; margin-bottom: 0.5rem; }
.cat-toolbar-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.cat-chip {
    display: inline-flex;
    padding: 0.2rem 0.65rem;
    border-radius: 9999px;
    font-size: 0.7rem;
    font-weight: 700;
    background: #f1f5f9;
    color: #475569;
}
.cat-chip-success { background: #dcfce7; color: #166534; }

.cat-form-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.65rem 1.1rem;
    border: none;
    border-radius: 0.75rem;
    background: linear-gradient(135deg, #d97706, #b45309);
    color: #fff;
    font-weight: 700;
    font-size: 0.875rem;
    cursor: pointer;
    font-family: inherit;
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.3);
    white-space: nowrap;
}
.cat-form-toggle:hover { transform: translateY(-1px); }

.cat-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.65rem;
}
.cat-stat { padding: 0.85rem 1rem; }
.cat-stat .admin-stat-value { font-size: 1.25rem; }
.cat-stat .admin-stat-icon { font-size: 1.35rem; }

.cat-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    align-items: start;
}

.cat-form-panel { height: fit-content; }
.cat-form-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}
.cat-form-head h2 { margin: 0; font-size: 1rem; }
.cat-form-close {
    display: none;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 0.5rem;
    background: #f1f5f9;
    color: #64748b;
    cursor: pointer;
    font-size: 0.9rem;
}
.cat-form-body { padding: 1rem; display: flex; flex-direction: column; gap: 1rem; }
.cat-form-footer { padding: 0 1rem 1rem; }
.cat-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; align-items: end; }
.cat-form-check { padding-bottom: 0.5rem; }
.cat-check-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
    min-height: 44px;
}
.cat-hint { font-size: 0.7rem; color: #94a3b8; margin-top: 0.35rem; }
.cat-cancel-link {
    display: block;
    text-align: center;
    font-size: 0.85rem;
    color: #64748b;
    text-decoration: none;
}
.cat-cancel-link:hover { color: #d97706; }
.cat-seed-btn {
    width: 100%;
    padding: 0.65rem;
    border-radius: 0.75rem;
    border: 1px dashed #fcd34d;
    background: #fffbeb;
    color: #b45309;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}

.cat-main { display: flex; flex-direction: column; gap: 1rem; min-width: 0; }
.cat-preview-panel .admin-panel-head,
.cat-table-panel .admin-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}
.cat-panel-count { font-size: 0.75rem; font-weight: 600; color: #94a3b8; }

.cat-preview-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    padding: 0.85rem;
}
.cat-preview-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 0.85rem;
    padding: 0.75rem 0.4rem;
    text-align: center;
    transition: all 0.2s;
    text-decoration: none;
    color: inherit;
}
.cat-preview-card:hover {
    border-color: #fcd34d;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    transform: translateY(-2px);
}
.cat-preview-card.is-inactive { opacity: 0.55; filter: grayscale(0.35); }

.cat-table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.cat-slug {
    font-size: 0.7rem;
    background: #f1f5f9;
    padding: 0.15rem 0.5rem;
    border-radius: 0.35rem;
    direction: ltr;
    display: inline-block;
}
.cat-row-actions {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.cat-mobile-only { display: flex; flex-direction: column; gap: 0.65rem; }
.cat-desktop-only { display: none; }

.cat-mobile-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    padding: 1rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.cat-mobile-card.is-inactive { opacity: 0.65; }
.cat-mobile-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.65rem;
}
.cat-mobile-brand {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-width: 0;
}
.cat-mobile-brand h3 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 0.15rem;
    line-height: 1.3;
}
.cat-mobile-brand code {
    font-size: 0.65rem;
    color: #64748b;
    background: #f8fafc;
    padding: 0.1rem 0.4rem;
    border-radius: 0.25rem;
    direction: ltr;
    display: inline-block;
}
.cat-mobile-stats {
    display: flex;
    gap: 1rem;
    font-size: 0.78rem;
    color: #64748b;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #f1f5f9;
}
.cat-mobile-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}
.cat-mobile-actions form { display: inline; }
.cat-mobile-actions .admin-btn-sm {
    min-height: 38px;
    padding: 0.45rem 0.85rem;
}

.cat-empty {
    text-align: center;
    padding: 2rem 1rem;
    color: #94a3b8;
    background: #fff;
    border-radius: 1rem;
    border: 1px dashed #e2e8f0;
}

.cat-form-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 60;
    backdrop-filter: blur(2px);
}
.cat-form-backdrop.is-visible { display: block; }

body.cat-form-open { overflow: hidden; }

@media (min-width: 640px) {
    .cat-stats { grid-template-columns: repeat(4, 1fr); }
    .cat-preview-grid { grid-template-columns: repeat(4, 1fr); gap: 0.65rem; }
    .cat-stat .admin-stat-value { font-size: 1.5rem; }
}

@media (min-width: 1024px) {
    .cat-layout {
        grid-template-columns: minmax(300px, 340px) 1fr;
        gap: 1.25rem;
    }

    .cat-form-toggle { display: none; }
    .cat-form-close { display: none !important; }
    .cat-form-panel {
        position: sticky;
        top: 1rem;
    }
    .cat-form-panel.is-open,
    .cat-form-panel { display: block; }

    .cat-preview-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); }
    .cat-mobile-only { display: none; }
    .cat-desktop-only { display: block; }

    .cat-toolbar { padding: 1.15rem 1.35rem; }
}

@media (max-width: 1023px) {
    .cat-form-panel {
        display: none;
        position: fixed;
        right: 0;
        left: 0;
        bottom: 0;
        max-height: 92vh;
        z-index: 70;
        border-radius: 1.25rem 1.25rem 0 0;
        overflow-y: auto;
        box-shadow: 0 -8px 32px rgba(0,0,0,0.15);
    }
    .cat-form-panel.is-open { display: block; }
    .cat-form-close { display: flex; align-items: center; justify-content: center; }

    .admin-content { padding: 1rem; }
    .cat-toolbar-info { flex: 1; min-width: 0; }
    .cat-icon-picker { grid-template-columns: repeat(5, 1fr); }
    .cat-icon-btn { min-height: 44px; }
}

@media (min-width: 1280px) {
    .cat-preview-grid { grid-template-columns: repeat(7, 1fr); }
}

.admin-link { color: #d97706; font-weight: 600; font-size: 0.85rem; }
.admin-link:hover { text-decoration: underline; }

.admin-tag {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.7rem;
    font-weight: 600;
}
.admin-tag-green { background: #dcfce7; color: #166534; }
.admin-tag-gray { background: #f1f5f9; color: #64748b; }
.admin-tag-orange { background: #ffedd5; color: #c2410c; }
.admin-tag-alert { background: #fee2e2; color: #dc2626; }

.admin-alert {
    padding: 0.85rem 1rem;
    border-radius: 0.75rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}
.admin-alert-success { background: #dcfce7; color: #166534; border: 1px solid #bbf7d0; }
.admin-alert-error { background: #fee2e2; color: #dc2626; border: 1px solid #fecaca; }

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

/* Dashboard */
.dash-page { display: flex; flex-direction: column; gap: 1rem; }
.dash-hero {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem;
    padding: 1.15rem 1.25rem;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
    border-radius: 1.1rem; color: #fff; box-shadow: 0 8px 24px rgba(15, 23, 42, 0.25);
}
.dash-hero-greet { font-size: 0.8rem; color: #fcd34d; margin-bottom: 0.25rem; }
.dash-hero-title { font-size: 1.25rem; font-weight: 800; margin: 0 0 0.35rem; }
.dash-hero-sub { font-size: 0.78rem; color: #94a3b8; margin: 0; }
.dash-quick-actions { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.dash-action {
    display: inline-flex; align-items: center; padding: 0.55rem 0.9rem; border-radius: 0.65rem;
    background: rgba(255,255,255,0.14); border: 1px solid rgba(255,255,255,0.28);
    color: #fff; font-size: 0.8rem; font-weight: 700; text-decoration: none; transition: all 0.15s; white-space: nowrap;
}
.dash-action:hover { background: rgba(255,255,255,0.24); border-color: rgba(255,255,255,0.45); transform: translateY(-1px); }
.dash-action-alert { background: rgba(220,38,38,0.55); border-color: #fca5a5; color: #fff; }
.dash-action-alert:hover { background: rgba(220,38,38,0.7); }
.dash-alerts { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.dash-alert {
    display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.5rem 0.85rem;
    border-radius: 9999px; font-size: 0.78rem; font-weight: 700; text-decoration: none;
}
.dash-alert-dot { width: 8px; height: 8px; border-radius: 50%; animation: pulse-live 2s infinite; }
.dash-alert-amber { background: #fffbeb; color: #b45309; border: 1px solid #fde68a; }
.dash-alert-amber .dash-alert-dot { background: #f59e0b; }
.dash-alert-red { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; }
.dash-alert-red .dash-alert-dot { background: #ef4444; }
.dash-alert-yellow { background: #fefce8; color: #a16207; border: 1px solid #fef08a; }
.dash-alert-yellow .dash-alert-dot { background: #eab308; }
.dash-kpi-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.65rem; }
.dash-kpi {
    position: relative; display: flex; align-items: flex-start; gap: 0.75rem; padding: 1rem;
    background: #fff; border: 1px solid #e2e8f0; border-radius: 1rem; box-shadow: 0 1px 3px rgba(0,0,0,0.04); overflow: hidden;
}
.dash-kpi-live { border-color: rgba(16,185,129,0.35); background: linear-gradient(135deg, #fff, #ecfdf5); }
.dash-kpi-blue { border-color: rgba(59,130,246,0.25); }
.dash-kpi-green { border-color: rgba(16,185,129,0.25); }
.dash-kpi-icon { font-size: 1.5rem; flex-shrink: 0; }
.dash-kpi-body { min-width: 0; flex: 1; }
.dash-kpi-label { display: block; font-size: 0.7rem; color: #64748b; margin-bottom: 0.15rem; }
.dash-kpi-value { display: block; font-size: 1.25rem; font-weight: 800; color: #0f172a; line-height: 1.2; word-break: break-word; }
.dash-kpi-meta { display: block; font-size: 0.65rem; color: #94a3b8; margin-top: 0.25rem; }
.dash-live-pulse {
    position: absolute; top: 0.75rem; left: 0.75rem; width: 8px; height: 8px;
    border-radius: 50%; background: #10b981; animation: pulse-live 2s infinite;
}
.dash-grid-main, .dash-grid-secondary { display: grid; grid-template-columns: 1fr; gap: 1rem; }
.dash-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; flex-wrap: wrap; }
.dash-panel-head h2 { margin: 0; font-size: 0.95rem; }
.dash-panel-sub { font-size: 0.7rem; color: #94a3b8; font-weight: 600; }
.dash-link { font-size: 0.78rem; color: #d97706; font-weight: 700; text-decoration: none; }
.dash-chart-wrap { padding: 0.75rem 1rem 1rem; min-height: 220px; }
.dash-funnel { padding: 1rem; display: flex; flex-direction: column; gap: 0.85rem; }
.dash-funnel-step { display: flex; flex-direction: column; gap: 0.3rem; }
.dash-funnel-head { display: flex; justify-content: space-between; font-size: 0.82rem; }
.dash-funnel-val { font-weight: 800; color: #0f172a; }
.dash-funnel-bar { height: 8px; background: #f1f5f9; border-radius: 9999px; overflow: hidden; }
.dash-funnel-fill { height: 100%; border-radius: 9999px; transition: width 0.5s ease; }
.dash-funnel-conv { font-size: 0.65rem; color: #94a3b8; }
.dash-list-body { padding: 0.75rem 1rem 1rem; }
.dash-empty { text-align: center; color: #94a3b8; font-size: 0.85rem; padding: 1.5rem 0.5rem; }
.dash-rank-list { list-style: none; margin: 0; padding: 0; }
.dash-rank-list li {
    display: flex; align-items: center; gap: 0.65rem; padding: 0.55rem 0;
    border-bottom: 1px solid #f1f5f9; font-size: 0.82rem;
}
.dash-rank-list li:last-child { border-bottom: none; }
.dash-rank-num {
    width: 22px; height: 22px; border-radius: 6px; background: #fff7ed; color: #c2410c;
    font-size: 0.7rem; font-weight: 800; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.dash-rank-label { flex: 1; min-width: 0; color: #334155; }
.dash-rank-val { font-weight: 800; color: #d97706; white-space: nowrap; }

/* Clicks widget */
.dash-clicks-panel { overflow: hidden; }
.dash-clicks-badge {
    display: inline-flex; padding: 0.25rem 0.65rem; border-radius: 9999px;
    background: #fff7ed; color: #c2410c; font-size: 0.72rem; font-weight: 800;
    border: 1px solid #fed7aa;
}
.dash-clicks-body { padding: 0.65rem 0.85rem 0.85rem; }
.dash-clicks-empty {
    text-align: center; padding: 2rem 1rem; color: #94a3b8;
}
.dash-clicks-empty-icon { font-size: 2rem; display: block; margin-bottom: 0.5rem; opacity: 0.5; }
.dash-clicks-empty p { font-weight: 700; color: #64748b; margin: 0 0 0.25rem; }
.dash-clicks-empty span { font-size: 0.75rem; }
.dash-clicks-list { display: flex; flex-direction: column; gap: 0.55rem; }
.dash-click-item {
    display: flex; align-items: center; gap: 0.65rem;
    padding: 0.65rem 0.75rem; background: #f8fafc; border: 1px solid #e2e8f0;
    border-radius: 0.85rem; transition: all 0.15s;
}
.dash-click-item:hover { border-color: #fcd34d; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,0.04); }
.dash-click-item.is-top {
    background: linear-gradient(135deg, #fffbeb, #fff);
    border-color: #fde68a;
}
.dash-click-rank {
    width: 28px; flex-shrink: 0; text-align: center;
    font-size: 0.85rem; font-weight: 800; color: #94a3b8;
}
.dash-click-item.is-top .dash-click-rank { font-size: 1.1rem; }
.dash-click-icon {
    width: 38px; height: 38px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    border-radius: 0.65rem; font-size: 1.15rem;
    background: color-mix(in srgb, var(--click-color, #d97706) 12%, white);
    border: 1px solid color-mix(in srgb, var(--click-color, #d97706) 25%, white);
}
.dash-click-content { flex: 1; min-width: 0; }
.dash-click-top {
    display: flex; align-items: flex-start; justify-content: space-between;
    gap: 0.5rem; margin-bottom: 0.4rem;
}
.dash-click-label {
    font-size: 0.82rem; font-weight: 600; color: #334155;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.dash-click-stats { display: flex; align-items: baseline; gap: 0.35rem; flex-shrink: 0; }
.dash-click-count { font-size: 1rem; font-weight: 800; color: #0f172a; line-height: 1; }
.dash-click-pct { font-size: 0.65rem; font-weight: 700; color: #d97706; background: #fff7ed; padding: 0.1rem 0.35rem; border-radius: 4px; }
.dash-click-bar { height: 6px; background: #e2e8f0; border-radius: 9999px; overflow: hidden; }
.dash-click-fill { height: 100%; border-radius: 9999px; transition: width 0.6s ease; min-width: 4px; }
.dash-clicks-footer {
    display: block; text-align: center; margin-top: 0.75rem; padding: 0.55rem;
    font-size: 0.78rem; font-weight: 700; color: #d97706; text-decoration: none;
    border-radius: 0.65rem; background: #fffbeb; border: 1px solid #fde68a;
    transition: all 0.15s;
}
.dash-clicks-footer:hover { background: #fef3c7; }

@media (max-width: 480px) {
    .dash-click-item { padding: 0.55rem 0.6rem; gap: 0.5rem; }
    .dash-click-icon { width: 34px; height: 34px; font-size: 1rem; }
    .dash-click-label { font-size: 0.78rem; }
}

.dash-status-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.5rem; padding: 0.85rem 1rem 1rem; }
.dash-status-chip {
    display: flex; align-items: center; justify-content: space-between; padding: 0.55rem 0.75rem;
    background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 0.65rem; text-decoration: none;
    color: #475569; font-size: 0.75rem; transition: all 0.15s;
}
.dash-status-chip:hover { border-color: #fcd34d; background: #fffbeb; }
.dash-status-chip strong { font-size: 1rem; color: #0f172a; }
.dash-table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.dash-order-num { font-weight: 800; color: #c2410c; font-family: monospace; font-size: 0.85rem; }
.dash-order-phone { display: block; font-size: 0.7rem; color: #94a3b8; }
.dash-orders-mobile { display: flex; flex-direction: column; gap: 0.55rem; padding: 0.75rem 1rem 1rem; }
.dash-orders-desktop { display: none; }
.dash-order-card {
    display: block; padding: 0.85rem 1rem; background: #f8fafc; border: 1px solid #e2e8f0;
    border-radius: 0.85rem; text-decoration: none; color: inherit; transition: all 0.15s;
}
.dash-order-card:hover { border-color: #fcd34d; background: #fffbeb; }
.dash-order-card-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.35rem; }
.dash-order-price { font-weight: 800; color: #059669; }
.dash-order-card-name { font-weight: 700; color: #0f172a; font-size: 0.9rem; }
.dash-order-card-meta { display: flex; justify-content: space-between; font-size: 0.72rem; color: #94a3b8; margin-top: 0.35rem; }

@media (min-width: 640px) {
    .dash-kpi-grid { grid-template-columns: repeat(2, 1fr); }
    .dash-kpi-value { font-size: 1.45rem; }
    .dash-status-grid { grid-template-columns: repeat(3, 1fr); }
    .dash-quick-actions { gap: 0.55rem; }
}
@media (min-width: 900px) {
    .dash-kpi-grid { grid-template-columns: repeat(3, 1fr); }
    .dash-grid-main { grid-template-columns: 1.5fr 1fr; }
}
@media (min-width: 1200px) {
    .dash-kpi-grid { grid-template-columns: repeat(6, 1fr); }
    .dash-grid-secondary { grid-template-columns: repeat(3, 1fr); }
    .dash-orders-mobile { display: none; }
    .dash-orders-desktop { display: block; }
    .dash-hero-title { font-size: 1.4rem; }
}
@media (max-width: 1199px) {
    .dash-orders-mobile { display: flex; }
    .dash-orders-desktop { display: none; }
}
@media (max-width: 1023px) {
    .dash-hero { padding: 1rem; }
    .dash-quick-actions { width: 100%; }
    .dash-action { flex: 1; justify-content: center; min-width: calc(50% - 0.3rem); }
}

/* Products admin */
.prod-page { display: flex; flex-direction: column; gap: 1rem; }
.prod-toolbar {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem;
    padding: 1rem 1.15rem; background: linear-gradient(135deg, #fff 0%, #eff6ff 100%);
    border: 1px solid #bfdbfe; border-radius: 1rem; box-shadow: 0 2px 8px rgba(59,130,246,0.08);
}
.prod-toolbar-desc { font-size: 0.8rem; color: #64748b; margin-bottom: 0.45rem; }
.prod-toolbar-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.prod-chip {
    display: inline-flex; padding: 0.2rem 0.65rem; border-radius: 9999px;
    font-size: 0.7rem; font-weight: 700; background: #f1f5f9; color: #475569;
}
.prod-chip-success { background: #dcfce7; color: #166534; }
.prod-chip-warn { background: #fef3c7; color: #b45309; }
.prod-add-btn {
    display: inline-flex; align-items: center; padding: 0.65rem 1.15rem; border-radius: 0.75rem;
    background: linear-gradient(135deg, #d97706, #b45309); color: #fff; font-weight: 700;
    font-size: 0.875rem; text-decoration: none; box-shadow: 0 4px 12px rgba(217,119,6,0.3);
}
.prod-add-btn:hover { transform: translateY(-1px); }

.prod-stats {
    display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.55rem;
}
.prod-stat {
    display: flex; align-items: center; gap: 0.65rem; padding: 0.85rem 1rem;
    background: #fff; border: 1px solid #e2e8f0; border-radius: 0.85rem;
}
.prod-stat-icon { font-size: 1.35rem; }
.prod-stat-label { display: block; font-size: 0.68rem; color: #64748b; }
.prod-stat strong { font-size: 1.2rem; font-weight: 800; color: #0f172a; }
.prod-stat-green { border-color: #bbf7d0; background: linear-gradient(135deg, #fff, #f0fdf4); }
.prod-stat-warn { border-color: #fde68a; background: linear-gradient(135deg, #fff, #fffbeb); }
.prod-stat-flash { border-color: #c4b5fd; background: linear-gradient(135deg, #fff, #f5f3ff); }

.prod-filters-panel { padding: 0.85rem 1rem; }
.prod-filters { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.prod-search-wrap {
    flex: 1; min-width: 180px; position: relative; display: flex; align-items: center;
}
.prod-search-icon { position: absolute; right: 0.75rem; font-size: 0.9rem; pointer-events: none; }
.prod-search-input {
    width: 100%; padding: 0.55rem 2.25rem 0.55rem 0.75rem; border: 1px solid #e2e8f0;
    border-radius: 0.65rem; font-family: inherit; font-size: 0.85rem;
}
.prod-search-input:focus { outline: none; border-color: #d97706; box-shadow: 0 0 0 3px rgba(217,119,6,0.12); }
.prod-filter-select {
    padding: 0.55rem 0.75rem; border: 1px solid #e2e8f0; border-radius: 0.65rem;
    font-family: inherit; font-size: 0.82rem; background: #fff; min-width: 130px;
}
.prod-results-count { font-size: 0.72rem; color: #94a3b8; margin: 0.5rem 0 0; font-weight: 600; }

.prod-empty-state {
    text-align: center; padding: 3rem 1.5rem; background: #fff; border: 1px dashed #e2e8f0;
    border-radius: 1rem;
}
.prod-empty-icon { font-size: 3rem; display: block; margin-bottom: 0.75rem; opacity: 0.4; }
.prod-empty-state h3 { font-size: 1.1rem; font-weight: 800; color: #334155; margin: 0 0 0.35rem; }
.prod-empty-state p { color: #94a3b8; font-size: 0.85rem; margin-bottom: 1rem; }

.prod-grid {
    display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem;
}
.prod-card {
    background: #fff; border: 1px solid #e2e8f0; border-radius: 1rem; overflow: hidden;
    transition: all 0.2s; display: flex; flex-direction: column;
}
.prod-card:hover { border-color: #fcd34d; box-shadow: 0 6px 20px rgba(0,0,0,0.06); transform: translateY(-2px); }
.prod-card.is-inactive { opacity: 0.65; filter: grayscale(0.3); }
.prod-card-img-wrap { position: relative; aspect-ratio: 1; background: #f8fafc; overflow: hidden; }
.prod-card-img { width: 100%; height: 100%; object-fit: cover; }
.prod-card-badges {
    position: absolute; top: 0.5rem; right: 0.5rem; display: flex; flex-direction: column; gap: 0.25rem;
}
.prod-badge {
    font-size: 0.6rem; font-weight: 800; padding: 0.15rem 0.45rem; border-radius: 9999px;
    backdrop-filter: blur(4px);
}
.prod-badge-featured { background: rgba(255,251,235,0.95); color: #b45309; }
.prod-badge-flash { background: rgba(237,233,254,0.95); color: #7c3aed; }
.prod-badge-sale { background: rgba(254,226,226,0.95); color: #dc2626; }
.prod-card-body { padding: 0.75rem; display: flex; flex-direction: column; gap: 0.35rem; flex: 1; }
.prod-card-cat { font-size: 0.68rem; color: #94a3b8; font-weight: 600; }
.prod-card-name {
    font-size: 0.88rem; font-weight: 700; color: #0f172a; margin: 0; line-height: 1.35;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.prod-card-price strong { font-size: 1rem; font-weight: 800; color: #059669; }
.prod-card-price del { font-size: 0.75rem; color: #94a3b8; margin-right: 0.35rem; }
.prod-card-unit { font-size: 0.65rem; color: #94a3b8; }
.prod-card-meta { display: flex; flex-wrap: wrap; gap: 0.35rem; align-items: center; margin-top: 0.25rem; }
.prod-stock { font-size: 0.72rem; font-weight: 700; padding: 0.1rem 0.4rem; border-radius: 4px; }
.prod-stock-ok { background: #dcfce7; color: #166534; }
.prod-stock-low { background: #fef3c7; color: #b45309; }
.prod-stock-out { background: #fee2e2; color: #dc2626; }
.prod-views { font-size: 0.68rem; color: #94a3b8; }
.prod-card-actions {
    display: flex; gap: 0.35rem; margin-top: auto; padding-top: 0.5rem;
    border-top: 1px solid #f1f5f9;
}
.prod-card-actions form { display: inline; }

.prod-table-panel { display: none; }
.prod-table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.prod-table-product { display: flex; align-items: center; gap: 0.65rem; }
.prod-table-thumb {
    width: 44px; height: 44px; border-radius: 0.5rem; object-fit: cover;
    background: #f1f5f9; flex-shrink: 0;
}
.prod-table-name { display: block; font-weight: 700; color: #0f172a; font-size: 0.85rem; }
.prod-table-unit { display: block; font-size: 0.65rem; color: #94a3b8; }
.prod-table-cat { font-size: 0.8rem; }
.prod-mini-badge { font-size: 0.65rem; margin-left: 0.25rem; }
.prod-row-actions { display: flex; gap: 0.35rem; flex-wrap: wrap; }

@media (min-width: 640px) {
    .prod-stats { grid-template-columns: repeat(3, 1fr); }
    .prod-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 900px) {
    .prod-stats { grid-template-columns: repeat(6, 1fr); }
    .prod-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 1200px) {
    .prod-grid { display: none; }
    .prod-table-panel { display: block; }
}
@media (max-width: 1199px) {
    .prod-table-panel { display: none; }
}
@media (max-width: 480px) {
    .prod-grid { grid-template-columns: 1fr; }
    .prod-filters { flex-direction: column; align-items: stretch; }
    .prod-filter-select { width: 100%; }
    .prod-add-btn { width: 100%; justify-content: center; }
}

@media (max-width: 1024px) {
    .admin-sidebar { transform: translateX(100%); }
    .admin-sidebar.open { transform: translateX(0); }
    .admin-sidebar-close { display: flex; align-items: center; justify-content: center; }
    .admin-overlay.show { display: block; }
    .admin-main { margin-right: 0; }
    .admin-menu-btn { display: block; }
}

/* ── Settings pages ── */
.set-page { display: flex; flex-direction: column; gap: 1.25rem; }
.set-nav {
    display: flex; flex-wrap: wrap; gap: 0.4rem;
    padding: 0.5rem; background: #fff; border: 1px solid #e2e8f0;
    border-radius: 0.85rem; margin-bottom: 0.25rem;
}
.set-nav-link {
    padding: 0.45rem 0.85rem; border-radius: 0.55rem; font-size: 0.8rem;
    font-weight: 600; color: #64748b; text-decoration: none; transition: all 0.15s;
}
.set-nav-link:hover { background: #f8fafc; color: #0f172a; }
.set-nav-link.active { background: #fff7ed; color: #c2410c; box-shadow: inset 0 0 0 1px #fed7aa; }

.set-hero {
    display: flex; justify-content: space-between; align-items: center; gap: 1rem;
    padding: 1.25rem 1.5rem; background: linear-gradient(135deg, #0f172a, #1e293b);
    border-radius: 1rem; color: #fff;
}
.set-hero-title { font-size: 1.35rem; font-weight: 800; margin: 0 0 0.25rem; }
.set-hero-desc { font-size: 0.85rem; color: #94a3b8; margin: 0; }
.set-hero-badge {
    padding: 0.35rem 0.85rem; border-radius: 999px; font-size: 0.75rem; font-weight: 700;
    background: rgba(251,191,36,0.15); color: #fbbf24; border: 1px solid rgba(251,191,36,0.3);
}

.set-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem;
}
.set-card {
    display: flex; flex-direction: column; gap: 0.35rem; padding: 1.25rem;
    background: #fff; border: 1px solid #e2e8f0; border-radius: 1rem;
    text-decoration: none; color: inherit; transition: all 0.2s;
}
.set-card:hover { border-color: #fbbf24; box-shadow: 0 8px 24px rgba(15,23,42,0.08); transform: translateY(-2px); }
.set-card h3 { margin: 0; font-size: 1rem; font-weight: 800; color: #0f172a; }
.set-card p { margin: 0; font-size: 0.78rem; color: #64748b; line-height: 1.4; flex: 1; }
.set-card-meta { font-size: 0.72rem; font-weight: 600; color: #94a3b8; margin-top: 0.5rem; }
.set-card-meta.is-ok { color: #16a34a; }
.set-card-meta.is-warn { color: #d97706; }
.set-card-icon {
    width: 2.5rem; height: 2.5rem; border-radius: 0.65rem;
    display: flex; align-items: center; justify-content: center; font-size: 1.25rem;
}
.set-card-icon-blue { background: #dbeafe; }
.set-card-icon-green { background: #dcfce7; }
.set-card-icon-purple { background: #ede9fe; }
.set-card-icon-amber { background: #fef3c7; }
.set-card-icon-orange { background: #ffedd5; }
.set-card-icon-indigo { background: #e0e7ff; }

.set-section { margin-bottom: 0; }
.set-section-title { font-size: 1rem; font-weight: 800; margin: 0 0 0.75rem; color: #0f172a; }
.set-section-desc { font-size: 0.8rem; color: #64748b; margin: -0.35rem 0 1rem; }
.set-section-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; flex-wrap: wrap; }

.set-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.85rem; }
.set-span-2 { grid-column: span 2; }
.set-label { display: block; font-size: 0.78rem; font-weight: 600; color: #475569; margin-bottom: 0.3rem; }
.set-input {
    width: 100%; padding: 0.55rem 0.75rem; border: 1px solid #e2e8f0;
    border-radius: 0.65rem; font-size: 0.85rem; transition: border-color 0.15s;
}
.set-input:focus { outline: none; border-color: #fbbf24; box-shadow: 0 0 0 3px rgba(251,191,36,0.15); }
.set-form-stack { display: flex; flex-direction: column; gap: 0.85rem; }
.set-form-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.set-hint { font-size: 0.72rem; color: #94a3b8; margin-top: 0.25rem; }

.set-checks { display: flex; flex-direction: column; gap: 0.5rem; }
.set-checks-row { flex-direction: row; flex-wrap: wrap; gap: 1rem; }
.set-check { display: flex; align-items: center; gap: 0.5rem; font-size: 0.85rem; cursor: pointer; }
.set-check-warn { color: #b45309; }

.set-pay-methods { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 0.75rem; }
.set-pay-card {
    position: relative; display: flex; flex-direction: column; align-items: center; text-align: center;
    padding: 1rem; border: 2px solid #e2e8f0; border-radius: 0.85rem; cursor: pointer; transition: all 0.15s;
}
.set-pay-card input { position: absolute; opacity: 0; }
.set-pay-card.is-on, .set-pay-card:has(input:checked) { border-color: #16a34a; background: #f0fdf4; }
.set-pay-icon { font-size: 1.75rem; margin-bottom: 0.35rem; }
.set-pay-card strong { font-size: 0.85rem; }
.set-pay-card small { font-size: 0.68rem; color: #64748b; margin-top: 0.15rem; }

.set-toggle { display: flex; align-items: center; gap: 0.5rem; font-size: 0.85rem; font-weight: 600; cursor: pointer; }
.set-alert { padding: 0.65rem 0.85rem; border-radius: 0.65rem; font-size: 0.8rem; font-weight: 600; margin-bottom: 1rem; }
.set-alert-success { background: #dcfce7; color: #166534; }
.set-alert-warn { background: #fef3c7; color: #92400e; }
.set-webhook-box { margin-top: 1rem; padding-top: 1rem; border-top: 1px dashed #e2e8f0; }
.set-copy-row { display: flex; gap: 0.5rem; }

.set-roles-info { margin-top: 0.5rem; }
.set-roles-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.75rem; }
.set-role-card { padding: 0.85rem; background: #f8fafc; border-radius: 0.65rem; }
.set-role-card p { margin: 0.35rem 0 0; font-size: 0.75rem; color: #64748b; }
.set-role-badge {
    display: inline-block; padding: 0.2rem 0.55rem; border-radius: 999px;
    font-size: 0.7rem; font-weight: 700;
}
.set-role-super { background: #ede9fe; color: #6d28d9; }
.set-role-manager { background: #dbeafe; color: #1d4ed8; }
.set-role-support { background: #cffafe; color: #0e7490; }

.set-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.75rem; }
.set-stat { text-align: center; padding: 0.75rem; }
.set-layout-2 { display: grid; grid-template-columns: 340px 1fr; gap: 1rem; align-items: start; }

.set-team-list { display: flex; flex-direction: column; gap: 0.5rem; }
.set-team-row {
    display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem;
    border: 1px solid #f1f5f9; border-radius: 0.75rem; transition: background 0.15s;
}
.set-team-row:hover { background: #fafafa; }
.set-team-row.is-inactive { opacity: 0.55; }
.set-team-avatar {
    width: 2.25rem; height: 2.25rem; border-radius: 50%; background: #fff7ed; color: #c2410c;
    display: flex; align-items: center; justify-content: center; font-weight: 800; flex-shrink: 0;
}
.set-team-avatar-lg { width: 3rem; height: 3rem; font-size: 1.25rem; }
.set-team-info { flex: 1; min-width: 0; }
.set-team-info strong { display: block; font-size: 0.85rem; }
.set-team-info span { display: block; font-size: 0.72rem; color: #94a3b8; }
.set-role-tag { display: inline-block; margin-top: 0.2rem; padding: 0.1rem 0.45rem; border-radius: 999px; font-size: 0.65rem; font-weight: 700; }
.set-team-actions { display: flex; gap: 0.35rem; flex-shrink: 0; }
.set-account-head { display: flex; align-items: center; gap: 1rem; }

@media (max-width: 900px) {
    .set-layout-2 { grid-template-columns: 1fr; }
    .set-stats { grid-template-columns: repeat(2, 1fr); }
    .set-form-grid { grid-template-columns: 1fr; }
    .set-span-2 { grid-column: span 1; }
}

/* ── Audit log ── */
.audit-page { display: flex; flex-direction: column; gap: 1rem; }
.audit-hero {
    display: flex; justify-content: space-between; align-items: center; gap: 1rem;
    padding: 1.25rem 1.5rem; background: linear-gradient(135deg, #1e1b4b, #312e81);
    border-radius: 1rem; color: #fff;
}
.audit-hero-title { font-size: 1.35rem; font-weight: 800; margin: 0 0 0.25rem; }
.audit-hero-desc { font-size: 0.82rem; color: #c7d2fe; margin: 0; }
.audit-hero-stat {
    padding: 0.5rem 1rem; border-radius: 999px; font-weight: 800; font-size: 0.85rem;
    background: rgba(255,255,255,0.12); border: 1px solid rgba(255,255,255,0.2);
}
.audit-stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0.65rem; }
.audit-stat { text-align: center; padding: 0.65rem; }
.audit-stat-warn .admin-stat-value { color: #dc2626; }
.audit-filters {
    display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center;
}
.audit-filter-q { min-width: 160px; flex: 1; }
.audit-table-panel { overflow: hidden; }
.audit-empty { padding: 3rem; text-align: center; color: #94a3b8; }
.audit-list { display: flex; flex-direction: column; }
.audit-row { border-bottom: 1px solid #f1f5f9; }
.audit-row-main {
    display: grid; grid-template-columns: 2rem 100px 120px 1fr 160px;
    gap: 0.75rem; align-items: center; padding: 0.75rem 1rem; cursor: pointer;
    list-style: none;
}
.audit-row-main::-webkit-details-marker { display: none; }
.audit-row:hover .audit-row-main { background: #fafafa; }
.audit-icon { font-size: 1.25rem; text-align: center; }
.audit-time { display: flex; flex-direction: column; font-size: 0.72rem; color: #64748b; }
.audit-time strong { color: #0f172a; font-size: 0.8rem; }
.audit-action-tag {
    font-size: 0.68rem; font-weight: 700; padding: 0.2rem 0.5rem; border-radius: 999px;
    background: #f1f5f9; color: #475569; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.audit-desc { font-size: 0.82rem; color: #334155; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.audit-actor { font-size: 0.72rem; color: #64748b; text-align: left; }
.audit-row-detail { padding: 0 1rem 1rem 3.5rem; background: #f8fafc; }
.audit-detail-grid { display: flex; flex-wrap: wrap; gap: 1rem; font-size: 0.78rem; color: #475569; margin-bottom: 0.5rem; }
.audit-dk { font-weight: 700; color: #94a3b8; margin-left: 0.35rem; }
.audit-meta {
    font-size: 0.7rem; background: #0f172a; color: #e2e8f0; padding: 0.75rem;
    border-radius: 0.5rem; overflow-x: auto; direction: ltr; text-align: left; margin: 0;
}
.audit-sev-warning .audit-action-tag { background: #fef3c7; color: #92400e; }
.audit-sev-critical .audit-action-tag { background: #fee2e2; color: #991b1b; }
.audit-sev-badge { padding: 0.1rem 0.4rem; border-radius: 4px; font-size: 0.68rem; font-weight: 700; }
.audit-sev-warning { background: #fef3c7; color: #92400e; }
.audit-sev-critical { background: #fee2e2; color: #991b1b; }
.audit-pagination {
    display: flex; justify-content: center; align-items: center; gap: 1rem;
    padding: 0.75rem; font-size: 0.85rem; color: #64748b;
}
@media (max-width: 900px) {
    .audit-stats { grid-template-columns: repeat(2, 1fr); }
    .audit-row-main { grid-template-columns: 2rem 1fr; grid-template-rows: auto auto; }
    .audit-action-tag, .audit-actor { display: none; }
}

/* ── Chat Support ── */
.chat-page { display: flex; flex-direction: column; gap: 1rem; }
.chat-toolbar {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem;
}
.chat-toolbar-stats { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chat-kpi {
    display: flex; flex-direction: column; align-items: center; min-width: 4.5rem;
    padding: 0.5rem 0.75rem; background: #fff; border: 1px solid #e2e8f0; border-radius: 0.75rem;
}
.chat-kpi span { font-size: 1.25rem; font-weight: 800; color: #0f172a; line-height: 1; }
.chat-kpi small { font-size: 0.65rem; color: #64748b; margin-top: 0.15rem; }
.chat-kpi-warn span { color: #dc2626; }
.chat-kpi-ai span { color: #2563eb; }
.chat-mode-badge {
    font-size: 0.75rem; font-weight: 700; padding: 0.4rem 0.85rem;
    background: linear-gradient(135deg, #fef3c7, #fde68a); color: #92400e; border-radius: 999px;
}
.chat-layout {
    display: grid; grid-template-columns: 280px 1fr 220px; gap: 1rem; min-height: calc(100vh - 220px);
}
.chat-sidebar, .chat-main, .chat-info { display: flex; flex-direction: column; overflow: hidden; }
.chat-sidebar-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 0.85rem 1rem; border-bottom: 1px solid #f1f5f9;
}
.chat-sidebar-head h3 { font-size: 0.9rem; font-weight: 700; margin: 0; }
.chat-filters {
    display: flex; flex-wrap: wrap; gap: 0.35rem; padding: 0.65rem 0.75rem; border-bottom: 1px solid #f1f5f9;
}
.chat-filter {
    font-size: 0.68rem; font-weight: 600; padding: 0.25rem 0.55rem; border-radius: 999px;
    background: #f1f5f9; color: #475569; text-decoration: none; transition: background 0.15s;
}
.chat-filter:hover { background: #e2e8f0; }
.chat-filter.active { background: #0f172a; color: #fff; }
.chat-session-list { flex: 1; overflow-y: auto; }
.chat-session-row {
    display: flex; align-items: stretch; border-bottom: 1px solid #f1f5f9;
    position: relative;
}
.chat-session-row:hover { background: #fafafa; }
.chat-session-row.is-active { background: #fffbeb; border-right: 3px solid #f59e0b; }
.chat-session-row.is-waiting { background: #fef2f2; }
.chat-session-item {
    flex: 1; display: flex; gap: 0.65rem; padding: 0.65rem 0.75rem;
    text-decoration: none; color: inherit; min-width: 0;
}
.chat-session-item:hover { background: transparent; }
.chat-session-delete {
    display: flex; align-items: center; padding: 0 0.5rem 0 0.35rem; margin: 0;
}
.chat-session-delete-btn {
    width: 1.75rem; height: 1.75rem; border: none; border-radius: 0.4rem;
    background: transparent; color: #94a3b8; cursor: pointer; font-size: 0.85rem;
    opacity: 0; transition: opacity 0.15s, background 0.15s, color 0.15s;
}
.chat-session-row:hover .chat-session-delete-btn { opacity: 1; }
.chat-session-delete-btn:hover { background: #fee2e2; color: #dc2626; }
.chat-toolbar-delete { margin-right: auto; }
.chat-btn-danger {
    background: #fef2f2 !important; color: #dc2626 !important; border: 1px solid #fecaca !important;
}
.chat-btn-danger:hover { background: #fee2e2 !important; border-color: #fca5a5 !important; }
.chat-info-delete { margin-top: 0.75rem; }
.chat-session-avatar {
    width: 2.25rem; height: 2.25rem; border-radius: 50%; background: #f1f5f9;
    display: flex; align-items: center; justify-content: center; font-size: 1rem; flex-shrink: 0;
}
.chat-session-body { flex: 1; min-width: 0; }
.chat-session-top { display: flex; align-items: center; gap: 0.35rem; font-size: 0.78rem; }
.chat-session-top strong { color: #0f172a; }
.chat-session-top span { color: #64748b; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-unread {
    margin-right: auto; background: #ef4444; color: #fff; font-size: 0.6rem; font-weight: 700;
    min-width: 1.1rem; height: 1.1rem; border-radius: 999px; display: flex; align-items: center; justify-content: center;
}
.chat-session-ip {
    font-size: 0.6rem; font-family: monospace; direction: ltr;
    background: #f1f5f9; color: #475569; padding: 0.1rem 0.35rem; border-radius: 4px;
}
.chat-session-time { font-size: 0.65rem; color: #94a3b8; }
.chat-empty-list { padding: 2rem 1rem; text-align: center; color: #94a3b8; font-size: 0.85rem; }
.chat-main-head {
    display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem;
    padding: 0.85rem 1rem; border-bottom: 1px solid #f1f5f9;
}
.chat-main-head h2 { font-size: 1rem; font-weight: 700; margin: 0 0 0.25rem; }
.chat-main-meta { display: flex; flex-wrap: wrap; gap: 0.75rem; font-size: 0.75rem; color: #64748b; }
.chat-main-meta a { color: #2563eb; text-decoration: none; }
.chat-main-actions { display: flex; align-items: center; gap: 0.5rem; }
.chat-messages {
    flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: 0.65rem;
    background: linear-gradient(180deg, #f8fafc 0%, #fff 100%); min-height: 320px; max-height: 55vh;
}
.chat-bubble-row { display: flex; }
.chat-bubble-user { justify-content: flex-start; }
.chat-bubble-ai, .chat-bubble-admin { justify-content: flex-end; }
.chat-bubble {
    max-width: 82%; padding: 0.65rem 0.85rem; border-radius: 1rem; font-size: 0.85rem; line-height: 1.5;
    box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.chat-bubble-user .chat-bubble { background: #fff; border: 1px solid #e2e8f0; border-bottom-right-radius: 0.25rem; }
.chat-bubble-ai .chat-bubble { background: #dbeafe; border-bottom-left-radius: 0.25rem; }
.chat-bubble-admin .chat-bubble { background: #fef3c7; border: 1px solid #fde68a; border-bottom-left-radius: 0.25rem; }
.chat-bubble-label { display: block; font-size: 0.65rem; font-weight: 700; margin-bottom: 0.25rem; opacity: 0.85; }
.chat-bubble-text { word-break: break-word; }
.chat-bubble time { display: block; font-size: 0.62rem; color: #94a3b8; margin-top: 0.35rem; }
.chat-compose { padding: 0.75rem 1rem; border-top: 1px solid #f1f5f9; background: #fff; }
.chat-canned { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-bottom: 0.5rem; }
.chat-canned-btn {
    font-size: 0.68rem; padding: 0.25rem 0.5rem; border-radius: 999px; border: 1px solid #e2e8f0;
    background: #f8fafc; color: #475569; cursor: pointer; max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.chat-canned-btn:hover { background: #f1f5f9; border-color: #cbd5e1; }
.chat-reply-form { display: flex; gap: 0.5rem; margin-bottom: 0.5rem; }
.chat-input {
    flex: 1; padding: 0.55rem 0.85rem; border: 1px solid #e2e8f0; border-radius: 0.65rem;
    font-size: 0.85rem; outline: none;
}
.chat-input:focus { border-color: #f59e0b; box-shadow: 0 0 0 3px rgba(245,158,11,0.15); }
.chat-compose-actions { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.chat-empty-main {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
    padding: 3rem; text-align: center; color: #64748b;
}
.chat-empty-icon { font-size: 3rem; margin-bottom: 0.75rem; opacity: 0.5; }
.chat-empty-main h3 { font-size: 1.1rem; color: #334155; margin: 0 0 0.35rem; }
.chat-info { padding: 1rem; }
.chat-info h3, .chat-info h4 { font-size: 0.85rem; font-weight: 700; margin: 0 0 0.75rem; }
.chat-info-list { font-size: 0.78rem; }
.chat-info-list dt { color: #94a3b8; font-weight: 600; margin-top: 0.5rem; }
.chat-info-list dd { margin: 0.15rem 0 0; color: #334155; }
.chat-info-divider { border: none; border-top: 1px solid #f1f5f9; margin: 1rem 0; }
.chat-wa-btn {
    display: block; text-align: center; padding: 0.5rem; margin-top: 0.75rem;
    background: #dcfce7; color: #166534; border-radius: 0.5rem; font-size: 0.78rem; font-weight: 700; text-decoration: none;
}
.chat-wa-btn:hover { background: #bbf7d0; }
.chat-mode-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.75rem; }
.chat-mode-card {
    display: flex; flex-direction: column; align-items: center; text-align: center; gap: 0.35rem;
    padding: 1rem; border: 2px solid #e2e8f0; border-radius: 0.85rem; cursor: pointer; transition: border-color 0.15s, background 0.15s;
}
.chat-mode-card input { position: absolute; opacity: 0; pointer-events: none; }
.chat-mode-card.is-selected, .chat-mode-card:has(input:checked) { border-color: #f59e0b; background: #fffbeb; }
.chat-mode-icon { font-size: 1.75rem; }
.chat-mode-card strong { font-size: 0.85rem; color: #0f172a; }
.chat-mode-card small { font-size: 0.68rem; color: #64748b; line-height: 1.4; }
@media (max-width: 1100px) {
    .chat-layout { grid-template-columns: 240px 1fr; }
    .chat-info { display: none; }
}
@media (max-width: 768px) {
    .chat-layout { grid-template-columns: 1fr; min-height: auto; }
    .chat-sidebar { max-height: 220px; }
    .chat-mode-cards { grid-template-columns: 1fr; }
}

/* ── Reviews ── */
.review-page { display: flex; flex-direction: column; gap: 1rem; }
.review-toolbar {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem;
}
.review-toolbar-desc { font-size: 0.85rem; color: #64748b; margin: 0; }
.review-stats {
    display: grid; grid-template-columns: repeat(5, 1fr); gap: 0.65rem;
}
.review-stat-warn .admin-stat-value { color: #d97706; }
.review-stat-ok .admin-stat-value { color: #059669; }
.review-stat-bad .admin-stat-value { color: #dc2626; }
.review-pending-banner { padding: 1rem; border-right: 4px solid #f59e0b; background: #fffbeb; }
.review-pending-head {
    display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.75rem;
}
.review-pending-head h3 { font-size: 0.9rem; font-weight: 700; margin: 0; color: #92400e; }
.review-pending-list { display: flex; flex-direction: column; gap: 0.65rem; }
.review-pending-item {
    display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 0.75rem;
    padding: 0.75rem; background: #fff; border-radius: 0.65rem; border: 1px solid #fde68a;
}
.review-pending-body { flex: 1; min-width: 200px; font-size: 0.85rem; }
.review-pending-body p { margin: 0.35rem 0 0; color: #64748b; font-size: 0.8rem; }
.review-product-tag {
    display: inline-block; font-size: 0.68rem; padding: 0.15rem 0.45rem; margin: 0 0.35rem;
    background: #f1f5f9; border-radius: 999px; color: #475569;
}
.review-filters { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.review-filter {
    display: inline-flex; align-items: center; gap: 0.35rem;
    padding: 0.4rem 0.75rem; border-radius: 999px; font-size: 0.78rem; font-weight: 600;
    background: #fff; border: 1px solid #e2e8f0; color: #475569; text-decoration: none;
}
.review-filter:hover { background: #f8fafc; }
.review-filter.active { background: #0f172a; color: #fff; border-color: #0f172a; }
.review-filter-count {
    font-size: 0.65rem; padding: 0.1rem 0.4rem; border-radius: 999px;
    background: rgba(0,0,0,0.08);
}
.review-filter.active .review-filter-count { background: rgba(255,255,255,0.2); }
.review-table-panel { overflow: hidden; }
.review-table-wrap { overflow-x: auto; }
.review-table { width: 100%; border-collapse: collapse; font-size: 0.82rem; }
.review-table th {
    text-align: right; padding: 0.75rem 1rem; background: #f8fafc;
    font-size: 0.72rem; font-weight: 700; color: #64748b; border-bottom: 1px solid #e2e8f0;
}
.review-table td { padding: 0.85rem 1rem; border-bottom: 1px solid #f1f5f9; vertical-align: middle; }
.review-row.is-pending { background: #fffbeb; }
.review-row.is-rejected { background: #fef2f2; opacity: 0.85; }
.review-row:hover { background: #fafafa; }
.review-row.is-pending:hover { background: #fef3c7; }
.review-user { display: flex; align-items: center; gap: 0.5rem; }
.review-avatar {
    width: 2rem; height: 2rem; border-radius: 50%; background: #e2e8f0;
    display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 0.85rem; color: #475569;
}
.review-product-link { color: #2563eb; text-decoration: none; font-weight: 600; }
.review-product-link:hover { text-decoration: underline; }
.review-comment { max-width: 220px; color: #475569; line-height: 1.4; }
.review-date { font-size: 0.72rem; color: #94a3b8; white-space: nowrap; }
.review-status {
    display: inline-block; font-size: 0.68rem; font-weight: 700; padding: 0.25rem 0.55rem; border-radius: 999px;
}
.review-status-ok { background: #dcfce7; color: #166534; }
.review-status-warn { background: #fef3c7; color: #92400e; }
.review-status-bad { background: #fee2e2; color: #991b1b; }
.review-actions { display: flex; flex-wrap: wrap; gap: 0.25rem; align-items: center; }
.review-actions form { display: inline; margin: 0; }
.review-btn {
    border: 1px solid #e2e8f0; background: #fff; border-radius: 0.45rem;
    padding: 0.3rem 0.55rem; font-size: 0.78rem; cursor: pointer; transition: background 0.12s, border-color 0.12s;
}
.review-btn-approve:hover { background: #dcfce7; border-color: #86efac; }
.review-btn-reject:hover { background: #fee2e2; border-color: #fca5a5; }
.review-btn-delete:hover { background: #f1f5f9; border-color: #cbd5e1; }
.review-empty { padding: 3rem; text-align: center; color: #94a3b8; }
.review-empty-icon { font-size: 2.5rem; margin-bottom: 0.5rem; opacity: 0.4; }
@media (max-width: 900px) {
    .review-stats { grid-template-columns: repeat(2, 1fr); }
    .review-comment { max-width: 140px; }
}
@media (max-width: 640px) {
    .review-stats { grid-template-columns: 1fr 1fr; }
    .review-table th:nth-child(5), .review-table td:nth-child(5) { display: none; }
}
