
        /* ===== RESET & BASE ===== */
        *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
        html { font-size: 16px; scroll-behavior: smooth; }
        body {
            font-family: 'Inter', sans-serif;
            background: #f7f7f5;
            color: #1a1a1a;
            line-height: 1.6;
            min-height: 100vh;
        }
        a { color: inherit; text-decoration: none; }
        button, input, textarea, select {
            font-family: inherit;
            font-size: 1rem;
        }
        img { max-width: 100%; display: block; }

        /* ===== LAYOUT ===== */
        .container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
        .page { display: none; }
        .page.active { display: block; }

        /* ===== HEADER ===== */
        header {
            background: #fff;
            border-bottom: 1px solid #e8e8e4;
            position: sticky;
            top: 0;
            z-index: 100;
        }
        .header-inner {
            display: flex;
            align-items: center;
            justify-content: space-between;
            height: 64px;
            gap: 16px;
        }
        .logo {
            font-size: 1.25rem;
            font-weight: 700;
            color: #1a1a1a;
            letter-spacing: -0.5px;
            display: flex;
            align-items: center;
            gap: 8px;
            cursor: pointer;
        }
        .logo span { color: #e85d26; }
        .nav { display: flex; align-items: center; gap: 8px; }
        .nav-btn {
            padding: 8px 16px;
            border-radius: 8px;
            border: none;
            cursor: pointer;
            font-weight: 500;
            font-size: 0.875rem;
            transition: all 0.2s;
            background: transparent;
            color: #555;
        }
        .nav-btn:hover { background: #f0f0ec; color: #1a1a1a; }
        .nav-btn.primary {
            background: #1a1a1a;
            color: #fff;
        }
        .nav-btn.primary:hover { background: #333; }
        .nav-btn.active { color: #e85d26; }

        /* ===== SEARCH BAR ===== */
        .search-wrap {
            flex: 1;
            max-width: 400px;
            position: relative;
        }
        .search-wrap input {
            width: 100%;
            padding: 10px 16px 10px 40px;
            border: 1px solid #e8e8e4;
            border-radius: 10px;
            background: #f7f7f5;
            color: #1a1a1a;
            outline: none;
            transition: border-color 0.2s;
        }
        .search-wrap input:focus { border-color: #1a1a1a; background: #fff; }
        .search-wrap .search-icon {
            position: absolute;
            left: 12px;
            top: 50%;
            transform: translateY(-50%);
            color: #999;
            font-size: 0.875rem;
        }

        /* ===== HERO ===== */
        .hero {
            background: #1a1a1a;
            color: #fff;
            padding: 72px 0 64px;
            text-align: center;
        }
        .hero h1 {
            font-size: 2.75rem;
            font-weight: 700;
            letter-spacing: -1px;
            line-height: 1.2;
            margin-bottom: 16px;
        }
        .hero h1 span { color: #e85d26; }
        .hero p {
            font-size: 1.1rem;
            color: #aaa;
            max-width: 480px;
            margin: 0 auto 32px;
        }
        .hero-search {
            display: flex;
            max-width: 520px;
            margin: 0 auto;
            gap: 8px;
        }
        .hero-search input {
            flex: 1;
            padding: 14px 20px;
            border-radius: 10px;
            border: none;
            font-size: 1rem;
            outline: none;
            background: #fff;
            color: #1a1a1a;
        }
        .hero-search button {
            padding: 14px 24px;
            background: #e85d26;
            color: #fff;
            border: none;
            border-radius: 10px;
            cursor: pointer;
            font-weight: 600;
            transition: background 0.2s;
        }
        .hero-search button:hover { background: #d44e1a; }

        /* ===== CATEGORIES ===== */
        .section { padding: 48px 0; }
        .section-title {
            font-size: 1.375rem;
            font-weight: 700;
            margin-bottom: 24px;
            letter-spacing: -0.3px;
        }
        .categories-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
            gap: 12px;
        }
        .category-card {
            background: #fff;
            border: 1px solid #e8e8e4;
            border-radius: 12px;
            padding: 20px 16px;
            cursor: pointer;
            transition: all 0.2s;
            display: flex;
            align-items: center;
            gap: 12px;
        }
        .category-card:hover {
            border-color: #1a1a1a;
            transform: translateY(-1px);
        }
        .category-card .cat-icon {
            width: 40px;
            height: 40px;
            border-radius: 10px;
            background: #f7f7f5;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.1rem;
            color: #e85d26;
            flex-shrink: 0;
        }
        .category-card .cat-info { min-width: 0; }
        .category-card .cat-name {
            font-weight: 600;
            font-size: 0.9rem;
            color: #1a1a1a;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
        .category-card .cat-count {
            font-size: 0.75rem;
            color: #999;
        }

        /* ===== SITES GRID ===== */
        .sites-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
            gap: 20px;
        }
        .site-card {
            background: #fff;
            border: 1px solid #e8e8e4;
            border-radius: 14px;
            overflow: hidden;
            transition: all 0.2s;
            cursor: pointer;
        }
        .site-card:hover {
            border-color: #ccc;
            transform: translateY(-2px);
            box-shadow: 0 8px 24px rgba(0,0,0,0.06);
        }
        .site-screenshot {
            width: 100%;
            height: 180px;
            object-fit: cover;
            background: #f0f0ec;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #bbb;
            font-size: 2rem;
        }
        .site-screenshot img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }
        .site-info { padding: 16px; }
        .site-info h3 {
            font-size: 1rem;
            font-weight: 600;
            margin-bottom: 6px;
            color: #1a1a1a;
        }
        .site-info p {
            font-size: 0.85rem;
            color: #666;
            line-height: 1.5;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }
        .site-meta {
            display: flex;
            align-items: center;
            justify-content: space-between;
            margin-top: 12px;
        }
        .site-category-tag {
            font-size: 0.75rem;
            background: #f0f0ec;
            color: #555;
            padding: 4px 10px;
            border-radius: 20px;
            font-weight: 500;
        }
        .site-link {
            font-size: 0.8rem;
            color: #e85d26;
            font-weight: 500;
            display: flex;
            align-items: center;
            gap: 4px;
        }

        /* ===== MODAL ===== */
        .modal-overlay {
            display: none;
            position: fixed;
            inset: 0;
            background: rgba(0,0,0,0.4);
            z-index: 200;
            align-items: center;
            justify-content: center;
            padding: 20px;
        }
        .modal-overlay.open { display: flex; }
        .modal {
            background: #fff;
            border-radius: 16px;
            padding: 36px;
            width: 100%;
            max-width: 440px;
            position: relative;
            max-height: 90vh;
            overflow-y: auto;
        }
        .modal-close {
            position: absolute;
            top: 16px;
            right: 16px;
            background: none;
            border: none;
            font-size: 1.1rem;
            cursor: pointer;
            color: #999;
            width: 32px;
            height: 32px;
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s;
        }
        .modal-close:hover { background: #f0f0ec; color: #1a1a1a; }
        .modal h2 {
            font-size: 1.375rem;
            font-weight: 700;
            margin-bottom: 24px;
            letter-spacing: -0.3px;
        }
        .form-group { margin-bottom: 16px; }
        .form-group label {
            display: block;
            font-size: 0.85rem;
            font-weight: 500;
            color: #555;
            margin-bottom: 6px;
        }
        .form-group input,
        .form-group textarea,
        .form-group select {
            width: 100%;
            padding: 11px 14px;
            border: 1px solid #e8e8e4;
            border-radius: 10px;
            outline: none;
            transition: border-color 0.2s;
            background: #fff;
            color: #1a1a1a;
        }
        .form-group input:focus,
        .form-group textarea:focus,
        .form-group select:focus { border-color: #1a1a1a; }
        .form-group textarea { resize: vertical; min-height: 100px; }
        .btn-full {
            width: 100%;
            padding: 13px;
            background: #1a1a1a;
            color: #fff;
            border: none;
            border-radius: 10px;
            font-weight: 600;
            cursor: pointer;
            transition: background 0.2s;
            margin-top: 8px;
        }
        .btn-full:hover { background: #333; }
        .btn-full.orange { background: #e85d26; }
        .btn-full.orange:hover { background: #d44e1a; }
        .form-switch {
            text-align: center;
            margin-top: 16px;
            font-size: 0.875rem;
            color: #666;
        }
        .form-switch a {
            color: #e85d26;
            font-weight: 500;
            cursor: pointer;
        }
        .msg {
            padding: 10px 14px;
            border-radius: 8px;
            font-size: 0.875rem;
            margin-bottom: 16px;
            display: none;
        }
        .msg.error { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; display: block; }
        .msg.success { background: #f0fdf4; color: #16a34a; border: 1px solid #bbf7d0; display: block; }

        /* ===== DASHBOARD / CABINET ===== */
        .dashboard {
            display: grid;
            grid-template-columns: 240px 1fr;
            gap: 32px;
            padding: 40px 0;
            align-items: start;
        }
        .sidebar {
            background: #fff;
            border: 1px solid #e8e8e4;
            border-radius: 14px;
            overflow: hidden;
            position: sticky;
            top: 80px;
        }
        .sidebar-user {
            padding: 24px;
            border-bottom: 1px solid #e8e8e4;
            text-align: center;
        }
        .avatar {
            width: 72px;
            height: 72px;
            border-radius: 50%;
            background: #f0f0ec;
            margin: 0 auto 12px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.75rem;
            color: #bbb;
            overflow: hidden;
        }
        .avatar img { width: 100%; height: 100%; object-fit: cover; }
        .sidebar-user .user-name {
            font-weight: 600;
            font-size: 0.95rem;
            color: #1a1a1a;
        }
        .sidebar-user .user-role {
            font-size: 0.78rem;
            color: #999;
            margin-top: 2px;
        }
        .sidebar-nav { padding: 8px; }
        .sidebar-nav-item {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 10px 12px;
            border-radius: 8px;
            cursor: pointer;
            font-size: 0.875rem;
            color: #555;
            transition: all 0.2s;
            font-weight: 500;
        }
        .sidebar-nav-item:hover { background: #f7f7f5; color: #1a1a1a; }
        .sidebar-nav-item.active { background: #1a1a1a; color: #fff; }
        .sidebar-nav-item i { width: 16px; text-align: center; }

        .dash-content { min-width: 0; }
        .dash-panel { display: none; }
        .dash-panel.active { display: block; }
        .dash-panel h2 {
            font-size: 1.375rem;
            font-weight: 700;
            margin-bottom: 24px;
            letter-spacing: -0.3px;
        }

        /* ===== TABLES ===== */
        .table-wrap { overflow-x: auto; }
        table {
            width: 100%;
            border-collapse: collapse;
            font-size: 0.875rem;
        }
        th {
            text-align: left;
            padding: 10px 14px;
            background: #f7f7f5;
            color: #555;
            font-weight: 600;
            border-bottom: 1px solid #e8e8e4;
        }
        td {
            padding: 12px 14px;
            border-bottom: 1px solid #f0f0ec;
            color: #1a1a1a;
            vertical-align: middle;
        }
        tr:last-child td { border-bottom: none; }
        .badge {
            display: inline-block;
            padding: 3px 10px;
            border-radius: 20px;
            font-size: 0.75rem;
            font-weight: 600;
        }
        .badge.pending { background: #fef9c3; color: #854d0e; }
        .badge.approved { background: #dcfce7; color: #166534; }
        .badge.rejected { background: #fee2e2; color: #991b1b; }
        .badge.admin { background: #e0e7ff; color: #3730a3; }
        .badge.user { background: #f0f0ec; color: #555; }
        .action-btn {
            padding: 5px 12px;
            border-radius: 6px;
            border: none;
            cursor: pointer;
            font-size: 0.78rem;
            font-weight: 600;
            transition: all 0.2s;
        }
        .action-btn.approve { background: #dcfce7; color: #166534; }
        .action-btn.approve:hover { background: #bbf7d0; }
        .action-btn.reject { background: #fee2e2; color: #991b1b; }
        .action-btn.reject:hover { background: #fecaca; }
        .action-btn.delete { background: #f0f0ec; color: #555; }
        .action-btn.delete:hover { background: #e8e8e4; color: #1a1a1a; }
        .action-btn.edit { background: #e0e7ff; color: #3730a3; }
        .action-btn.edit:hover { background: #c7d2fe; }

        /* ===== STATS CARDS ===== */
        .stats-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
            gap: 16px;
            margin-bottom: 32px;
        }
        .stat-card {
            background: #fff;
            border: 1px solid #e8e8e4;
            border-radius: 12px;
            padding: 20px;
        }
        .stat-card .stat-num {
            font-size: 2rem;
            font-weight: 700;
            color: #1a1a1a;
            letter-spacing: -1px;
        }
        .stat-card .stat-label {
            font-size: 0.8rem;
            color: #999;
            margin-top: 4px;
        }

        /* ===== FILE UPLOAD ===== */
        .file-upload-area {
            border: 2px dashed #e8e8e4;
            border-radius: 10px;
            padding: 24px;
            text-align: center;
            cursor: pointer;
            transition: border-color 0.2s;
            position: relative;
        }
        .file-upload-area:hover { border-color: #1a1a1a; }
        .file-upload-area input[type="file"] {
            position: absolute;
            inset: 0;
            opacity: 0;
            cursor: pointer;
            width: 100%;
            height: 100%;
        }
        .file-upload-area .upload-icon { font-size: 1.5rem; color: #bbb; margin-bottom: 8px; }
        .file-upload-area p { font-size: 0.85rem; color: #999; }
        .file-preview {
            margin-top: 12px;
            display: none;
        }
        .file-preview img {
            max-height: 120px;
            border-radius: 8px;
            margin: 0 auto;
        }

        /* ===== TOAST ===== */
        #toast {
            position: fixed;
            bottom: 24px;
            right: 24px;
            background: #1a1a1a;
            color: #fff;
            padding: 14px 20px;
            border-radius: 10px;
            font-size: 0.875rem;
            font-weight: 500;
            z-index: 999;
            transform: translateY(80px);
            opacity: 0;
            transition: all 0.3s;
            max-width: 320px;
        }
        #toast.show { transform: translateY(0); opacity: 1; }

        /* ===== EMPTY STATE ===== */
        .empty-state {
            text-align: center;
            padding: 64px 24px;
            color: #999;
        }
        .empty-state i { font-size: 2.5rem; margin-bottom: 16px; display: block; }
        .empty-state p { font-size: 0.95rem; }

        /* ===== PROFILE AVATAR UPLOAD ===== */
        .avatar-upload {
            display: flex;
            align-items: center;
            gap: 20px;
            margin-bottom: 24px;
        }
        .avatar-upload .avatar { flex-shrink: 0; }
        .avatar-upload-btn {
            padding: 8px 16px;
            border: 1px solid #e8e8e4;
            border-radius: 8px;
            cursor: pointer;
            font-size: 0.85rem;
            font-weight: 500;
            color: #555;
            background: #fff;
            transition: all 0.2s;
            position: relative;
            overflow: hidden;
        }
        .avatar-upload-btn:hover { border-color: #1a1a1a; color: #1a1a1a; }
        .avatar-upload-btn input {
            position: absolute;
            inset: 0;
            opacity: 0;
            cursor: pointer;
        }

        /* ===== SEARCH RESULTS ===== */
        .search-results-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            margin-bottom: 24px;
        }
        .filter-bar {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
            margin-bottom: 24px;
        }
        .filter-chip {
            padding: 6px 14px;
            border-radius: 20px;
            border: 1px solid #e8e8e4;
            background: #fff;
            font-size: 0.8rem;
            font-weight: 500;
            cursor: pointer;
            color: #555;
            transition: all 0.2s;
        }
        .filter-chip:hover, .filter-chip.active {
            background: #1a1a1a;
            color: #fff;
            border-color: #1a1a1a;
        }

        /* ===== RESPONSIVE ===== */

        /* Hamburger button */
        .hamburger {
            display: none;
            background: none;
            border: none;
            cursor: pointer;
            padding: 8px;
            border-radius: 8px;
            color: #1a1a1a;
            font-size: 1.1rem;
            transition: background 0.2s;
        }
        .hamburger:hover { background: #f0f0ec; }

        /* Mobile nav drawer */
        .mobile-nav {
            display: none;
            flex-direction: column;
            gap: 4px;
            padding: 12px 16px 16px;
            border-top: 1px solid #e8e8e4;
            background: #fff;
        }
        .mobile-nav.open { display: flex; }
        .mobile-nav .nav-btn {
            text-align: left;
            padding: 12px 14px;
            border-radius: 10px;
            font-size: 0.95rem;
        }
        .mobile-search {
            display: none;
            padding: 0 16px 12px;
            background: #fff;
        }
        .mobile-search.open { display: block; }
        .mobile-search input {
            width: 100%;
            padding: 10px 16px 10px 40px;
            border: 1px solid #e8e8e4;
            border-radius: 10px;
            background: #f7f7f5;
            color: #1a1a1a;
            outline: none;
            font-family: inherit;
            font-size: 0.95rem;
        }
        .mobile-search .search-icon {
            position: absolute;
            left: 28px;
            top: 50%;
            transform: translateY(-50%);
            color: #999;
            font-size: 0.875rem;
        }
        .mobile-search-wrap { position: relative; }

        @media (max-width: 900px) {
            .sites-grid { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
        }

        @media (max-width: 768px) {
            .hero { padding: 48px 0 40px; }
            .hero h1 { font-size: 1.875rem; letter-spacing: -0.5px; }
            .hero p { font-size: 0.95rem; }
            .hero-search { flex-direction: column; gap: 10px; }
            .hero-search input, .hero-search button { width: 100%; }

            .section { padding: 32px 0; }
            .section-title { font-size: 1.15rem; }

            .categories-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
            .sites-grid { grid-template-columns: 1fr; }

            /* Header */
            .search-wrap { display: none; }
            .hamburger { display: flex; align-items: center; justify-content: center; }
            #mainNav { display: none; }

            /* Dashboard */
            .dashboard { grid-template-columns: 1fr; gap: 20px; padding: 24px 0; }
            .sidebar { position: static; }
            .sidebar-nav { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px; }
            .sidebar-nav-item { flex: 1 1 auto; justify-content: center; font-size: 0.8rem; padding: 8px 10px; }
            .sidebar-user { padding: 16px; }
            .avatar { width: 56px; height: 56px; font-size: 1.4rem; }

            /* Stats */
            .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
            .stat-card .stat-num { font-size: 1.6rem; }

            /* Tables — horizontal scroll with better UX */
            .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
            table { min-width: 520px; }
            th, td { padding: 10px 10px; font-size: 0.8rem; }

            /* Modal */
            .modal { padding: 24px 20px; border-radius: 14px; }
            .modal h2 { font-size: 1.15rem; margin-bottom: 18px; }

            /* Filter bar */
            .filter-bar { gap: 6px; }
            .filter-chip { font-size: 0.75rem; padding: 5px 11px; }

            /* Admin add category row */
            #apanel-categories > div:first-of-type { flex-direction: column; }
            #apanel-categories > div:first-of-type input,
            #apanel-categories > div:first-of-type select { min-width: unset; }

            /* Avatar upload */
            .avatar-upload { flex-direction: column; align-items: flex-start; gap: 12px; }

            /* Toast */
            #toast { left: 16px; right: 16px; bottom: 16px; max-width: unset; text-align: center; }

            /* Search results header */
            .search-results-header { flex-direction: column; align-items: flex-start; gap: 8px; }
        }

        @media (max-width: 480px) {
            .container { padding: 0 16px; }
            .hero h1 { font-size: 1.5rem; }
            .categories-grid { grid-template-columns: repeat(2, 1fr); }
            .stats-grid { grid-template-columns: repeat(2, 1fr); }
            .category-card { padding: 14px 12px; }
            .cat-icon { width: 34px; height: 34px; font-size: 0.95rem; }
            .dash-panel h2 { font-size: 1.1rem; margin-bottom: 16px; }
            .sidebar-nav-item { font-size: 0.75rem; padding: 7px 8px; }
            .sidebar-nav-item i { display: none; }
        }
    

/* ===== EXTRA RESPONSIVE FIXES ===== */
html, body { width: 100%; overflow-x: hidden; }
body { min-width: 0; }
.container { width: 100%; }
main, .dash-content, .card, .modal, .site-card, .category-card { min-width: 0; }
input, textarea, select, button { max-width: 100%; }
textarea { overflow-wrap: anywhere; }
.site-info h3, .site-info p, td, th, .notification, .small { overflow-wrap: anywhere; word-break: break-word; }
.modal { width: min(100%, 520px); }
.top-space { padding-top: clamp(24px, 5vw, 48px); padding-bottom: 48px; }
.table-wrap { width: 100%; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }

@media (max-width: 1024px) {
  .container { padding-left: 20px; padding-right: 20px; }
  .dashboard { grid-template-columns: 220px minmax(0,1fr); gap: 22px; }
  .search-wrap { max-width: 300px; }
}
@media (max-width: 820px) {
  .header-inner { height: 60px; }
  .search-wrap, .nav { display: none; }
  .hamburger { display: inline-flex; }
  .dashboard { grid-template-columns: 1fr; }
  .sidebar { position: static; width: 100%; }
  .sidebar-nav { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
  .sidebar-nav-item { justify-content: center; text-align: center; }
  .sites-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .categories-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 600px) {
  .container { padding-left: 14px; padding-right: 14px; }
  .hero { padding: 40px 0 34px; }
  .hero h1 { font-size: clamp(1.65rem, 8vw, 2.1rem); }
  .hero p { font-size: .95rem; margin-bottom: 22px; }
  .hero-search { flex-direction: column; }
  .hero-search input, .hero-search button { width: 100%; }
  .section { padding: 28px 0; }
  .sites-grid, .categories-grid { grid-template-columns: 1fr; gap: 14px; }
  .site-screenshot { height: auto; aspect-ratio: 16 / 9; }
  .site-meta { align-items: flex-start; gap: 10px; flex-wrap: wrap; }
  .modal { border-radius: 14px; padding: 22px 16px; }
  .top-space .modal { margin: 0 auto !important; }
  .stats-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .sidebar-nav { grid-template-columns: 1fr; }
  table { min-width: 620px; }
  .btn-full { min-height: 46px; }
}
@media (max-width: 360px) {
  .container { padding-left: 10px; padding-right: 10px; }
  .logo { font-size: 1.05rem; }
  .stats-grid { grid-template-columns: 1fr; }
}

/* ===== SIDE MOBILE MENU ===== */
.site-header .logo i { color:#e85d26; }
.mobile-menu-btn {
    display:none;
    position:relative;
    width:44px;
    height:44px;
    align-items:center;
    justify-content:center;
    border:1px solid #e8e8e4;
    border-radius:12px;
    background:#fff;
    color:#1a1a1a;
    cursor:pointer;
    font-size:1.15rem;
}
.menu-alert-dot {
    position:absolute;
    top:-5px;
    right:-5px;
    min-width:20px;
    height:20px;
    padding:0 5px;
    border-radius:10px;
    background:#e85d26;
    color:#fff;
    font-size:11px;
    line-height:20px;
    font-weight:700;
}
.drawer-overlay {
    position:fixed;
    inset:0;
    z-index:998;
    background:rgba(15,15,15,.48);
    opacity:0;
    visibility:hidden;
    transition:opacity .25s ease, visibility .25s ease;
    backdrop-filter:blur(2px);
}
.drawer-overlay.open { opacity:1; visibility:visible; }
.mobile-drawer {
    position:fixed;
    top:0;
    right:0;
    z-index:999;
    width:min(88vw,360px);
    height:100dvh;
    background:#fff;
    box-shadow:-20px 0 50px rgba(0,0,0,.16);
    transform:translateX(105%);
    transition:transform .28s ease;
    display:flex;
    flex-direction:column;
    overflow-y:auto;
    overscroll-behavior:contain;
    padding-bottom:max(18px,env(safe-area-inset-bottom));
}
.mobile-drawer.open { transform:translateX(0); }
body.drawer-open { overflow:hidden; touch-action:none; }
.drawer-head {
    min-height:68px;
    padding:12px 16px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    border-bottom:1px solid #ecece8;
}
.drawer-close {
    width:40px;
    height:40px;
    display:grid;
    place-items:center;
    border:0;
    border-radius:10px;
    background:#f5f5f2;
    color:#555;
    font-size:1.15rem;
    cursor:pointer;
}
.drawer-user,.drawer-guest {
    margin:16px;
    padding:16px;
    display:flex;
    align-items:center;
    gap:13px;
    background:#f7f7f5;
    border:1px solid #ecece8;
    border-radius:16px;
}
.drawer-avatar {
    width:50px;
    height:50px;
    flex:0 0 50px;
    display:grid;
    place-items:center;
    overflow:hidden;
    border-radius:50%;
    background:#fff;
    color:#e85d26;
    font-size:1.25rem;
    border:1px solid #e8e8e4;
}
.drawer-avatar img { width:100%; height:100%; object-fit:cover; }
.drawer-user-text,.drawer-guest>div:last-child { min-width:0; display:flex; flex-direction:column; }
.drawer-user strong,.drawer-guest strong { font-size:.95rem; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.drawer-user span,.drawer-guest span { color:#777; font-size:.75rem; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.drawer-user small { color:#e85d26; font-size:.72rem; font-weight:600; margin-top:2px; }
.drawer-search {
    position:relative;
    margin:0 16px 12px;
}
.drawer-search i {
    position:absolute;
    left:14px;
    top:50%;
    transform:translateY(-50%);
    color:#aaa;
}
.drawer-search input {
    width:100%;
    height:46px;
    padding:0 14px 0 42px;
    border:1px solid #e5e5e0;
    border-radius:12px;
    background:#fafaf8;
    outline:none;
}
.drawer-search input:focus { border-color:#e85d26; background:#fff; }
.drawer-nav { display:flex; flex-direction:column; padding:4px 12px 16px; }
.drawer-link {
    min-height:50px;
    display:flex;
    align-items:center;
    gap:13px;
    padding:10px 12px;
    border-radius:12px;
    color:#444;
    font-size:.92rem;
    font-weight:500;
}
.drawer-link i { width:22px; text-align:center; color:#888; font-size:1rem; }
.drawer-link:hover,.drawer-link.active { background:#fff3ed; color:#d94e18; }
.drawer-link:hover i,.drawer-link.active i { color:#e85d26; }
.drawer-link.admin-link { color:#4438a6; }
.drawer-link.admin-link i { color:#5b50c7; }
.drawer-link.register-link { margin-top:4px; background:#1a1a1a; color:#fff; }
.drawer-link.register-link i { color:#fff; }
.drawer-link.logout-link { color:#a33; }
.drawer-link.logout-link i { color:#c44; }
.drawer-count {
    margin-left:auto;
    min-width:24px;
    height:24px;
    padding:0 7px;
    display:grid;
    place-items:center;
    border-radius:12px;
    background:#e85d26;
    color:#fff;
    font-size:.72rem;
}
.drawer-separator { margin:10px 12px 6px; border-top:1px solid #ecece8; }
.drawer-separator span {
    position:relative;
    top:-10px;
    padding-right:8px;
    background:#fff;
    color:#aaa;
    font-size:.68rem;
    text-transform:uppercase;
    letter-spacing:.08em;
}
.notification-link { display:inline-flex; align-items:center; gap:5px; }

@media (max-width:820px) {
    .desktop-nav,.site-header .search-wrap { display:none !important; }
    .mobile-menu-btn { display:inline-flex; flex:0 0 auto; }
    .header-inner { min-height:64px; height:64px; }
    .site-header .logo { font-size:1.2rem; }
    .alerts { padding-left:14px; padding-right:14px; }
}
@media (min-width:821px) {
    .drawer-overlay,.mobile-drawer { display:none !important; }
}
@media (max-width:420px) {
    .mobile-drawer { width:92vw; }
    .drawer-head { padding-left:14px; padding-right:14px; }
    .drawer-user,.drawer-guest { margin-left:12px; margin-right:12px; }
    .drawer-search { margin-left:12px; margin-right:12px; }
}

/* Admin moderation screenshot preview */
.moderation-preview {
  display: block;
  width: min(100%, 320px);
  margin: 12px 0 16px;
  border: 1px solid #e8e8e4;
  border-radius: 12px;
  overflow: hidden;
  background: #f7f7f5;
}
.moderation-preview img {
  display: block;
  width: 100%;
  height: 180px;
  object-fit: cover;
}
@media (max-width: 600px) {
  .moderation-preview { width: 100%; max-width: 280px; }
  .moderation-preview img { height: 150px; }
}


/* Admin user and category actions */
.admin-actions { display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
.admin-actions form { margin:0; }
.admin-actions .action-btn { display:inline-flex; align-items:center; justify-content:center; text-decoration:none; }
.admin-user-form { max-width:680px; }
@media (max-width: 768px) {
  .admin-actions { align-items:stretch; }
  .admin-actions .action-btn { width:100%; min-height:42px; }
  .admin-actions form { width:100%; }
  .admin-actions form .action-btn { width:100%; }
}
