/* === VARIABLES & RESET === */
:root {
    --bg: #0a0a0f;
    --bg2: #12121a;
    --bg3: #1a1a2e;
    --card: #16161f;
    --border: #2a2a3e;
    --text: #e4e4e7;
    --text2: #a1a1aa;
    --primary: #6366f1;
    --primary2: #818cf8;
    --accent: #e11d48;
    --green: #10b981;
    --gold: #f59e0b;
    --radius: 14px;
    --shadow: 0 4px 24px rgba(0,0,0,.4);
    --nav-h: 60px;
    --topbar-h: 56px;
}
.light-mode {
    --bg: #f8f9fc;
    --bg2: #ffffff;
    --bg3: #f0f0f5;
    --card: #ffffff;
    --border: #e4e4e7;
    --text: #18181b;
    --text2: #71717a;
    --shadow: 0 4px 24px rgba(0,0,0,.08);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body { font-family: 'Inter', -apple-system, sans-serif; background: var(--bg); color: var(--text); line-height: 1.6; overflow-x: hidden; -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; font-size: inherit; border: none; outline: none; background: none; color: inherit; }
img { max-width: 100%; display: block; }
.hidden { display: none !important; }

/* === SPLASH === */
.splash { position: fixed; inset: 0; z-index: 9999; background: var(--bg); display: flex; align-items: center; justify-content: center; transition: opacity .5s; }
.splash.fade-out { opacity: 0; pointer-events: none; }
.splash-content { text-align: center; }
.splash-icon { font-size: 3.5rem; color: var(--primary); margin-bottom: 16px; animation: pulse 1.5s infinite; }
.splash-content h1 { font-size: 1.8rem; font-weight: 800; }
.splash-content p { color: var(--text2); margin-top: 4px; }
.splash-loader { width: 40px; height: 4px; background: var(--bg3); border-radius: 4px; margin: 20px auto 0; overflow: hidden; }
.splash-loader::after { content: ''; display: block; width: 60%; height: 100%; background: var(--primary); border-radius: 4px; animation: load .8s infinite ease-in-out; }
@keyframes load { 0% { transform: translateX(-100%); } 100% { transform: translateX(200%); } }
@keyframes pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.1); } }

/* === TOPBAR === */
.topbar { position: fixed; top: 0; left: 0; right: 0; height: var(--topbar-h); background: var(--bg2); border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; padding: 0 16px; z-index: 100; backdrop-filter: blur(12px); }
.topbar-left { display: flex; align-items: center; gap: 12px; }
.topbar-center { display: none; }
.topbar-contact { display: flex; align-items: center; gap: 6px; font-size: .95rem; color: var(--primary); padding: 6px; border-radius: 50%; }
.topbar-right { display: flex; align-items: center; gap: 4px; }
.brand { font-size: 1.2rem; font-weight: 800; }
.brand span { color: var(--primary); }
.menu-btn, .icon-btn { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: background .2s; position: relative; }
.menu-btn:hover, .icon-btn:hover { background: var(--bg3); }
.icon-btn .badge { position: absolute; top: 6px; right: 6px; width: 16px; height: 16px; background: var(--accent); color: #fff; font-size: .6rem; border-radius: 50%; display: flex; align-items: center; justify-content: center; }

/* === SEARCH BAR === */
.search-bar { position: fixed; top: var(--topbar-h); left: 0; right: 0; padding: 8px 16px; background: var(--bg2); z-index: 99; border-bottom: 1px solid var(--border); animation: slideDown .2s; }
.search-inner { display: flex; align-items: center; background: var(--bg3); border-radius: 10px; padding: 0 12px; gap: 8px; }
.search-inner input { flex: 1; padding: 10px 0; background: none; }
.search-close { cursor: pointer; padding: 4px; }
@keyframes slideDown { from { transform: translateY(-10px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* === SIDE NAV === */
.sidenav { position: fixed; top: 0; left: -280px; width: 280px; height: 100%; background: var(--bg2); z-index: 200; transition: left .3s cubic-bezier(.4,0,.2,1); overflow-y: auto; }
.sidenav.open { left: 0; }
.sidenav-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.6); z-index: 199; opacity: 0; pointer-events: none; transition: opacity .3s; }
.sidenav-overlay.show { opacity: 1; pointer-events: all; }
.sidenav-header { padding: 40px 20px 20px; border-bottom: 1px solid var(--border); text-align: center; }
.sidenav-avatar { width: 64px; height: 64px; border-radius: 50%; background: var(--bg3); display: flex; align-items: center; justify-content: center; margin: 0 auto 12px; font-size: 1.5rem; color: var(--primary); }
.sidenav-header h3 { font-size: 1rem; }
.sidenav-header p { font-size: .8rem; color: var(--text2); }
.sidenav-menu { list-style: none; padding: 12px 0; }
.sidenav-menu li a { display: flex; align-items: center; gap: 14px; padding: 12px 24px; font-size: .9rem; transition: background .2s; }
.sidenav-menu li a:hover, .sidenav-menu li a.active { background: var(--bg3); color: var(--primary); }
.sidenav-menu li a i { width: 20px; text-align: center; }
.sidenav-menu .divider { height: 1px; background: var(--border); margin: 8px 20px; }

/* === BOTTOM NAV === */
.bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; height: var(--nav-h); background: var(--bg2); border-top: 1px solid var(--border); display: flex; align-items: center; justify-content: space-around; z-index: 100; backdrop-filter: blur(12px); }
.bnav-item { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: .65rem; color: var(--text2); padding: 8px 12px; border-radius: 12px; transition: all .2s; }
.bnav-item i { font-size: 1.2rem; }
.bnav-item.active { color: var(--primary); }
.bnav-item.active i { transform: scale(1.1); }

/* === MAIN CONTENT === */
.main-content { padding-top: var(--topbar-h); padding-bottom: calc(var(--nav-h) + 16px); min-height: 100vh; }
.page { display: none; padding: 16px; animation: fadeIn .3s; }
.page.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* === HERO === */
.hero { position: relative; border-radius: var(--radius); overflow: hidden; padding: 56px 20px; margin: -16px -16px 24px -16px; border-radius: 0; background: linear-gradient(135deg, var(--primary) 0%, #4f46e5 50%, #7c3aed 100%); }
.hero-bg { position: absolute; inset: 0; opacity: .1; background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.4'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E"); }
.hero-content { position: relative; z-index: 1; text-align: center; }
.hero h1 { font-size: 2rem; font-weight: 800; color: #fff; line-height: 1.2; }
.hero h1 span { color: #fbbf24; }
.hero p { color: rgba(255,255,255,.85); margin-top: 8px; font-size: .9rem; }
.hero-actions { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }

/* === BUTTONS === */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: 10px; font-weight: 600; font-size: .85rem; cursor: pointer; transition: all .2s; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary2); transform: translateY(-1px); }
.btn-outline { border: 1.5px solid rgba(255,255,255,.4); color: #fff; }
.btn-outline:hover { background: rgba(255,255,255,.1); }
.btn-block { width: 100%; justify-content: center; margin-top: 16px; }
.btn-sm { padding: 8px 14px; font-size: .78rem; }
.btn-success { background: var(--green); color: #fff; }
.btn-danger { background: var(--accent); color: #fff; }

/* === STATS === */
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: 24px; }
.stat-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; text-align: center; }
.stat-icon { font-size: 1.4rem; color: var(--primary); margin-bottom: 8px; }
.stat-card h3 { font-size: 1.3rem; font-weight: 700; }
.stat-card p { font-size: .75rem; color: var(--text2); }

/* === SECTIONS === */
.section { margin-bottom: 28px; }
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.section-header h2 { font-size: 1.1rem; font-weight: 700; }
.section-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 14px; }
.see-all { font-size: .8rem; color: var(--primary); font-weight: 600; }

/* === CARDS === */
.cards-scroll { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 8px; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; }
.cards-scroll::-webkit-scrollbar { display: none; }
.listing-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; min-width: 260px; scroll-snap-align: start; cursor: pointer; transition: transform .2s, box-shadow .2s; }
.listing-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.listing-card-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 10px; }
.listing-avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--bg3); display: flex; align-items: center; justify-content: center; color: var(--primary); font-size: 1.1rem; }
.listing-badge { font-size: .65rem; padding: 3px 8px; border-radius: 6px; font-weight: 600; }
.badge-approved { background: rgba(16,185,129,.15); color: var(--green); }
.badge-unapproved { background: rgba(245,158,11,.15); color: var(--gold); }
.badge-featured { background: rgba(99,102,241,.15); color: var(--primary); }
.badge-verified { color: var(--primary); margin-left: 4px; }
.listing-card h4 { font-size: .95rem; font-weight: 600; margin-bottom: 2px; }
.listing-card .listing-meta { font-size: .75rem; color: var(--text2); margin-bottom: 8px; }
.listing-card .listing-price { font-size: .85rem; font-weight: 700; color: var(--primary); }
.listing-card .listing-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.listing-tag { font-size: .65rem; padding: 3px 8px; background: var(--bg3); border-radius: 6px; color: var(--text2); }
.listing-actions { display: flex; gap: 8px; margin-top: 12px; }

/* === LISTINGS GRID === */
.listings-grid { display: grid; grid-template-columns: 1fr; gap: 14px; margin-bottom: 16px; }

/* === CATEGORIES === */
.categories-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.categories-full-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.category-card { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 14px; text-align: center; cursor: pointer; transition: all .2s; }
.category-card:hover { border-color: var(--primary); transform: translateY(-2px); }
.category-card i { font-size: 1.3rem; color: var(--primary); margin-bottom: 6px; }
.category-card p { font-size: .75rem; font-weight: 500; }

/* === STEPS === */
.steps-grid { display: grid; gap: 14px; }
.step-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; }
.step-num { width: 32px; height: 32px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .85rem; margin-bottom: 10px; }
.step-card h4 { margin-bottom: 4px; }
.step-card p { font-size: .8rem; color: var(--text2); }

/* === FORMS === */
.form-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; margin-bottom: 16px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: .8rem; font-weight: 600; margin-bottom: 6px; color: var(--text2); }
.form-group input, .form-group select, .form-group textarea { width: 100%; padding: 12px 14px; background: var(--bg3); border: 1px solid var(--border); border-radius: 10px; color: var(--text); transition: border-color .2s; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: var(--primary); }
.form-group textarea { min-height: 100px; resize: vertical; }
.form-section-title { font-size: .95rem; font-weight: 700; margin: 20px 0 12px; display: flex; align-items: center; gap: 8px; }
.private-badge { font-size: .65rem; background: rgba(225,29,72,.1); color: var(--accent); padding: 3px 8px; border-radius: 6px; font-weight: 600; }
.form-hint { font-size: .75rem; color: var(--text2); margin-bottom: 12px; }
.form-hint.center { text-align: center; margin-top: 12px; }

/* === FILTERS === */
.filters-bar { display: flex; gap: 8px; margin-bottom: 16px; overflow-x: auto; padding-bottom: 4px; }
.filter-select { padding: 8px 12px; background: var(--card); border: 1px solid var(--border); border-radius: 8px; font-size: .78rem; white-space: nowrap; min-width: fit-content; }
.page-header { margin-bottom: 20px; }
.page-header h2 { font-size: 1.3rem; font-weight: 700; display: flex; align-items: center; gap: 10px; }
.page-header p { color: var(--text2); font-size: .85rem; margin-top: 4px; }

/* === CONTACT === */
.contact-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; text-align: center; margin-bottom: 24px; }
.contact-person { margin-bottom: 16px; }
.contact-avatar { width: 72px; height: 72px; border-radius: 50%; background: var(--bg3); display: flex; align-items: center; justify-content: center; margin: 0 auto 12px; font-size: 1.8rem; color: var(--primary); }
.contact-details { display: flex; flex-direction: column; gap: 10px; }
.contact-item { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 10px; background: var(--bg3); border-radius: 10px; font-weight: 500; transition: background .2s; }
.contact-item:hover { background: var(--primary); color: #fff; }

/* === REVIEWS === */
.reviews-list { display: grid; gap: 12px; margin-bottom: 24px; }
.review-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; }
.review-card-header { display: flex; justify-content: space-between; margin-bottom: 8px; }
.review-card h4 { font-size: .9rem; }
.review-stars { color: var(--gold); font-size: .8rem; }
.review-card p { font-size: .8rem; color: var(--text2); }
.review-card .review-date { font-size: .7rem; color: var(--text2); margin-top: 8px; }
.star-rating { display: flex; gap: 6px; font-size: 1.4rem; color: var(--border); cursor: pointer; }
.star-rating .fas.active { color: var(--gold); }

/* === PROFILE === */
.profile-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; text-align: center; margin-bottom: 24px; }
.profile-avatar { width: 80px; height: 80px; border-radius: 50%; background: var(--bg3); display: flex; align-items: center; justify-content: center; margin: 0 auto 12px; font-size: 2rem; color: var(--primary); }
.profile-section { margin-bottom: 24px; }
.profile-section h4 { font-size: .95rem; margin-bottom: 12px; font-weight: 600; }
.empty-state { font-size: .8rem; color: var(--text2); text-align: center; padding: 20px; }

/* === ADMIN === */
.admin-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 20px; }
.admin-stat { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 14px; text-align: center; }
.admin-stat h3 { font-size: 1.4rem; font-weight: 700; color: var(--primary); }
.admin-stat p { font-size: .7rem; color: var(--text2); }
.admin-tabs { display: flex; gap: 4px; overflow-x: auto; margin-bottom: 16px; background: var(--card); border-radius: 10px; padding: 4px; }
.admin-tab { padding: 8px 16px; border-radius: 8px; font-size: .8rem; font-weight: 600; cursor: pointer; white-space: nowrap; transition: all .2s; }
.admin-tab.active { background: var(--primary); color: #fff; }
.admin-content { min-height: 200px; }
.admin-listing-item { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 14px; margin-bottom: 10px; }
.admin-listing-item h4 { font-size: .85rem; margin-bottom: 4px; }
.admin-listing-item .admin-meta { font-size: .7rem; color: var(--text2); margin-bottom: 8px; }
.admin-listing-item .admin-private { font-size: .7rem; background: var(--bg3); padding: 8px; border-radius: 8px; margin-bottom: 8px; }
.admin-listing-item .admin-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* === MODAL === */
.modal { position: fixed; inset: 0; z-index: 300; background: rgba(0,0,0,.7); display: flex; align-items: flex-end; justify-content: center; animation: fadeIn .2s; }
.modal-content { background: var(--bg2); border-radius: 20px 20px 0 0; width: 100%; max-width: 500px; max-height: 85vh; overflow-y: auto; padding: 24px; animation: slideUp .3s; }
.modal-close { position: absolute; top: 16px; right: 16px; width: 32px; height: 32px; border-radius: 50%; background: var(--bg3); display: flex; align-items: center; justify-content: center; cursor: pointer; }
@keyframes slideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }

/* === TOAST === */
.toast { position: fixed; bottom: 80px; left: 50%; transform: translateX(-50%); background: var(--green); color: #fff; padding: 12px 20px; border-radius: 10px; display: flex; align-items: center; gap: 8px; font-size: .85rem; font-weight: 500; z-index: 400; animation: toastIn .3s; }
@keyframes toastIn { from { transform: translateX(-50%) translateY(20px); opacity: 0; } to { transform: translateX(-50%) translateY(0); opacity: 1; } }

/* === RESPONSIVE === */
/* === HOME OPTIONS === */
.followers-selector { display: flex; gap: 8px; }
.followers-selector input, .followers-selector select { padding: 12px 14px; background: var(--bg3); border: 1px solid var(--border); border-radius: 10px; color: var(--text); }

/* === FILTER TABS === */
.filter-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.filter-tab { padding: 8px 16px; border-radius: 20px; font-size: .8rem; font-weight: 600; cursor: pointer; background: var(--card); border: 1px solid var(--border); white-space: nowrap; transition: all .2s; }
.filter-tab.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* === RANKED LISTINGS === */
.ranked-listings { display: flex; flex-direction: column; gap: 16px; }
.ranked-wrapper { max-width: 500px; margin: 0 auto; width: 100%; }
.ranked-item-large { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; text-align: center; position: relative; transition: border-color .2s; }
.ranked-item-large.active-border { border: 2px solid var(--text); }
.ranked-outside { display: flex; justify-content: center; margin-top: 10px; }
.btn-need-details { display: flex; align-items: center; gap: 6px; padding: 10px 20px; background: rgba(99,102,241,.1); border: 1px solid var(--primary); border-radius: 10px; color: var(--primary); cursor: pointer; font-size: .8rem; font-weight: 600; transition: background .2s; }
.btn-need-details:hover { background: rgba(99,102,241,.2); }
.btn-need-details i { font-size: 1rem; }
.need-details-panel { margin-top: 10px; padding: 14px; background: var(--bg3); border-radius: 10px; animation: fadeIn .2s; }
.need-details-panel .need-input { width: 100%; padding: 12px 14px; font-size: .85rem; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; color: var(--text); margin-bottom: 10px; }
.need-details-panel .btn { width: 100%; justify-content: center; }
.need-details-label { font-size: .75rem; color: var(--text2); margin-bottom: 8px; }
.ranked-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.ranked-center { margin-bottom: 14px; }
.ranked-avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--bg3); display: flex; align-items: center; justify-content: center; margin: 0 auto 10px; font-size: 1.4rem; color: var(--primary); }
.ranked-center h3 { font-size: 1.1rem; font-weight: 700; }
.ranked-followers { font-size: .8rem; color: var(--text2); margin-top: 2px; }
.ranked-details { text-align: left; margin-bottom: 12px; }
.ranked-detail-row { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid var(--border); font-size: .8rem; }
.ranked-detail-row span { color: var(--text2); }
.ranked-detail-row strong { color: var(--primary); }
.ranked-desc { font-size: .78rem; color: var(--text2); line-height: 1.4; }
/* === HOME OPTIONS === */
.home-options { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 24px; }
.home-option-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 16px; text-align: center; cursor: pointer; transition: all .25s; }
.home-option-card:hover { border-color: var(--primary); transform: translateY(-3px); box-shadow: var(--shadow); }
.home-option-icon { width: 52px; height: 52px; border-radius: 50%; background: rgba(99,102,241,.12); display: flex; align-items: center; justify-content: center; margin: 0 auto 12px; font-size: 1.3rem; color: var(--primary); }
.home-option-card h3 { font-size: .82rem; font-weight: 700; margin-bottom: 4px; line-height: 1.3; }
.home-option-card p { font-size: .7rem; color: var(--text2); line-height: 1.4; }

/* === RESPONSIVE === */
@media (min-width: 768px) {
    .listings-grid { grid-template-columns: repeat(2, 1fr); }
    .categories-grid, .categories-full-grid { grid-template-columns: repeat(3, 1fr); }
    .stats-grid { grid-template-columns: repeat(4, 1fr); }
    .admin-stats { grid-template-columns: repeat(4, 1fr); }
    .steps-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1024px) {
    .main-content { max-width: 800px; margin: 0 auto; }
    .listings-grid { grid-template-columns: repeat(2, 1fr); }
    .categories-full-grid { grid-template-columns: repeat(4, 1fr); }
}
