/* =============================================
   Flavor v3 - Dark Mode App-Like Design
   تصميم غامق احترافي يشبه التطبيقات
   ============================================= */

:root {
    /* Dark Theme Colors */
    --bg-primary: #0D0D0D;
    --bg-secondary: #1A1A1A;
    --bg-card: #1E1E1E;
    --bg-card-hover: #252525;
    --bg-input: #2A2A2A;
    
    /* Accent Colors */
    --accent: #8B5CF6;
    --accent-light: #A78BFA;
    --accent-glow: rgba(139, 92, 246, 0.3);
    
    --snap: #FFFC00;
    --whatsapp: #25D366;
    --tiktok: #FF0050;
    --instagram: #E4405F;
    --telegram: #0088CC;
    --twitter: #1DA1F2;
    --youtube: #FF0000;
    --discord: #5865F2;
    
    --success: #10B981;
    --warning: #F59E0B;
    --danger: #EF4444;
    
    --text-primary: #FFFFFF;
    --text-secondary: #A0A0A0;
    --text-muted: #666666;
    
    --border: #2D2D2D;
    --border-light: #3D3D3D;
    
    --male: #3B82F6;
    --female: #EC4899;
    
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 30px var(--accent-glow);
    
    --radius: 16px;
    --radius-sm: 10px;
    --radius-full: 50px;
    
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Tajawal', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    direction: rtl;
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

/* ==================== App Container ==================== */
.app {
    max-width: 100%;
    min-height: 100vh;
    padding-bottom: 70px;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 12px;
}

/* ==================== Header ==================== */
.header {
    background: var(--bg-secondary);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 54px;
    padding: 0 12px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--text-primary);
}

.logo-icon {
    width: 34px;
    height: 34px;
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.btn-add-header {
    background: var(--accent);
    color: #fff;
    padding: 8px 14px;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.8rem;
    transition: var(--transition);
}

.btn-add-header:hover {
    background: var(--accent-light);
}

/* ==================== Menu Toggle Button ==================== */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    padding: 8px;
    transition: var(--transition);
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition);
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ==================== Main Navigation ==================== */
.main-nav {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.main-nav::-webkit-scrollbar {
    height: 0;
    display: none;
}

.nav-list {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0;
}

.nav-list li {
    flex-shrink: 0;
}

.nav-list a {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    white-space: nowrap;
    transition: var(--transition);
    border-bottom: 2px solid transparent;
}

.nav-list a:hover,
.nav-list a.active {
    color: var(--accent);
    background: var(--bg-card-hover);
    border-bottom-color: var(--accent);
}

/* Desktop: Show all menu items */
@media (min-width: 769px) {
    .menu-toggle {
        display: none !important;
    }
    
    .main-nav {
        display: block !important;
    }
    
    .nav-list {
        justify-content: center;
    }
}

/* Mobile: Collapsible menu */
@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }
    
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        z-index: 99;
        max-height: 70vh;
        overflow-y: auto;
        box-shadow: var(--shadow);
    }
    
    .main-nav.active {
        display: block;
    }
    
    .nav-list {
        flex-direction: column;
    }
    
    .nav-list a {
        padding: 14px 20px;
        border-bottom: 1px solid var(--border);
    }
    
    .nav-list a:hover,
    .nav-list a.active {
        border-bottom-color: var(--border);
        border-right: 3px solid var(--accent);
    }
}

/* ==================== Bottom Navigation - Mobile First ==================== */
.nav-bottom {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(13, 13, 13, 0.98);
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    padding: 8px 4px calc(8px + env(safe-area-inset-bottom));
    z-index: 1000;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.nav-bottom a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.6rem;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 8px;
    transition: var(--transition);
    flex: 1;
    max-width: 70px;
}

.nav-bottom a svg {
    width: 22px;
    height: 22px;
    transition: var(--transition);
}

.nav-bottom a span {
    line-height: 1;
}

.nav-bottom a.active,
.nav-bottom a:hover {
    color: var(--accent);
}

/* زر الإضافة المميز */
.nav-bottom a.nav-add {
    position: relative;
}

.nav-bottom a.nav-add svg {
    width: 40px;
    height: 40px;
    padding: 8px;
    background: var(--accent);
    border-radius: 50%;
    color: #fff;
    margin-bottom: 2px;
}

.nav-bottom a.nav-add.active svg,
.nav-bottom a.nav-add:hover svg {
    background: var(--accent-light);
}

/* ==================== Hero Section ==================== */
.hero {
    background: linear-gradient(180deg, var(--bg-secondary), var(--bg-primary));
    padding: 20px 16px;
    text-align: center;
}

.hero h1 {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 6px;
    background: linear-gradient(135deg, var(--text-primary), var(--accent-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 0.9rem;
}

/* ==================== Search Box ==================== */
.search-box {
    display: flex;
    gap: 10px;
    max-width: 500px;
    margin: 0 auto;
}

.search-box input {
    flex: 1;
    padding: 14px 20px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition);
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

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

.search-box button {
    padding: 14px 25px;
    background: var(--accent);
    border: none;
    border-radius: var(--radius-full);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

/* ==================== Categories Scroll ==================== */
.categories-scroll {
    display: flex;
    gap: 12px;
    padding: 20px 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.categories-scroll::-webkit-scrollbar {
    display: none;
}

.cat-chip {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
    white-space: nowrap;
}

.cat-chip:hover,
.cat-chip.active {
    background: var(--accent);
    border-color: var(--accent);
    box-shadow: var(--shadow-glow);
}

.cat-chip .icon {
    font-size: 1.2rem;
}

.cat-chip .count {
    background: rgba(255,255,255,0.2);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
}

/* ==================== Section ==================== */
.section {
    padding: 10px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    padding: 0 12px;
}

.section-header h2 {
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.section-header a {
    color: var(--accent);
    text-decoration: none;
    font-size: 0.8rem;
}

/* ==================== Accounts Grid ==================== */
.accounts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    padding: 0 8px;
}

@media (min-width: 768px) {
    .accounts-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }
}

@media (min-width: 1024px) {
    .accounts-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ==================== Account Card ==================== */
.account-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition);
    text-decoration: none;
    color: inherit;
}

.account-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.account-card.vip {
    border-color: var(--warning);
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.2);
}

.card-top {
    position: relative;
    padding: 15px 10px 12px;
    text-align: center;
    background: linear-gradient(180deg, var(--bg-card-hover), var(--bg-card));
}

.vip-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, #F59E0B, #FBBF24);
    color: #000;
    padding: 3px 6px;
    border-radius: 4px;
    font-size: 0.55rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    z-index: 5;
}

.card-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    margin: 0 auto 8px;
    border: 2px solid var(--border-light);
    overflow: hidden;
    background: var(--bg-input);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.card-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-name {
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #FFFFFF !important;
}

.card-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.card-meta .male { 
    color: var(--male); 
    font-weight: 700;
    font-size: 0.85rem;
}
.card-meta .female { 
    color: var(--female); 
    font-weight: 700;
    font-size: 0.85rem;
}

.card-body {
    padding: 10px;
    border-top: 1px solid var(--border);
}

.card-bio {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 28px;
}

.card-actions {
    display: flex;
    gap: 6px;
}

.btn-add {
    flex: 1;
    padding: 8px;
    background: var(--success);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.8rem;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    text-align: center;
    font-family: inherit;
}

.btn-add:hover {
    filter: brightness(1.1);
}

.btn-report {
    padding: 8px 10px;
    background: var(--bg-input);
    color: var(--text-muted);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-report:hover {
    color: var(--danger);
}

/* ==================== Filters ==================== */
.filters {
    display: flex;
    gap: 6px;
    padding: 10px 12px;
    overflow-x: auto;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    -webkit-overflow-scrolling: touch;
}

.filters::-webkit-scrollbar {
    display: none;
}

.filter-chip {
    flex-shrink: 0;
    padding: 8px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: var(--text-secondary);
    font-size: 0.8rem;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    font-family: inherit;
    white-space: nowrap;
}

.filter-chip:hover,
.filter-chip.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.filter-chip.male.active { background: var(--male); border-color: var(--male); }
.filter-chip.female.active { background: var(--female); border-color: var(--female); }

/* ==================== Add Form - Wizard Style ==================== */
.add-page {
    padding: 20px 16px 100px;
}

.wizard-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.wizard-header {
    padding: 20px;
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    text-align: center;
}

.wizard-header h1 {
    font-size: 1.4rem;
    margin-bottom: 5px;
}

.wizard-header p {
    opacity: 0.9;
    font-size: 0.9rem;
}

/* Progress Steps */
.wizard-steps {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 20px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
}

.step {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.step-num {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--bg-input);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.step.active {
    color: var(--accent);
}

.step.active .step-num {
    background: var(--accent);
    color: #fff;
}

.step.completed .step-num {
    background: var(--success);
    color: #fff;
}

.step-line {
    width: 30px;
    height: 2px;
    background: var(--border);
}

/* Form Content */
.wizard-content {
    padding: 25px 20px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group label .required {
    color: var(--danger);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 16px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

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

.form-group small {
    display: block;
    margin-top: 6px;
    color: var(--text-muted);
    font-size: 0.8rem;
}

/* Gender Selector */
.gender-options {
    display: flex;
    gap: 12px;
}

.gender-option {
    flex: 1;
    padding: 20px;
    background: var(--bg-input);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}

.gender-option .icon {
    font-size: 2.5rem;
    margin-bottom: 8px;
}

.gender-option input {
    display: none;
}

.gender-option.male.selected {
    border-color: var(--male);
    background: rgba(59, 130, 246, 0.1);
}

.gender-option.female.selected {
    border-color: var(--female);
    background: rgba(236, 72, 153, 0.1);
}

/* Avatar Upload */
.avatar-upload {
    text-align: center;
}

.avatar-preview {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--bg-input);
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--text-muted);
    border: 3px dashed var(--border);
    overflow: hidden;
    transition: var(--transition);
}

.avatar-preview:hover {
    border-color: var(--accent);
}

.avatar-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.upload-btn {
    display: inline-block;
    padding: 12px 24px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
}

.upload-btn:hover {
    border-color: var(--accent);
}

/* Submit Button */
.btn-submit {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    border: none;
    border-radius: var(--radius);
    color: #fff;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
    box-shadow: var(--shadow-glow);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px var(--accent-glow);
}

/* ==================== Single Account Page ==================== */
.account-single {
    padding: 16px;
    padding-bottom: 100px;
}

.profile-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.profile-header {
    padding: 40px 20px;
    text-align: center;
    background: linear-gradient(180deg, var(--accent-glow), transparent);
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin: 0 auto 16px;
    border: 4px solid var(--accent);
    overflow: hidden;
    background: var(--bg-input);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-name {
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: 5px;
}

.profile-username {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.profile-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    padding: 20px;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.stat-item {
    text-align: center;
}

.stat-num {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent);
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.profile-body {
    padding: 20px;
}

.profile-info {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px;
    background: var(--bg-input);
    border-radius: var(--radius-sm);
}

.info-item .icon {
    font-size: 1.3rem;
}

.info-item .text {
    font-size: 0.9rem;
}

.profile-bio {
    padding: 16px;
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    line-height: 1.8;
}

.btn-add-large {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 18px;
    background: var(--success);
    color: #fff;
    border: none;
    border-radius: var(--radius);
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition);
    font-family: inherit;
}

.btn-add-large:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
}

/* ==================== Ad Slots ==================== */
.ad-slot {
    padding: 16px;
    margin: 16px 0;
    background: var(--bg-secondary);
    border: 1px dashed var(--border);
    border-radius: var(--radius);
    text-align: center;
    min-height: 100px;
}

.ad-slot.sidebar {
    margin-bottom: 20px;
}

/* ==================== Alerts ==================== */
.alert {
    padding: 16px;
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
}

.alert-success { background: rgba(16, 185, 129, 0.1); border: 1px solid var(--success); color: var(--success); }
.alert-error { background: rgba(239, 68, 68, 0.1); border: 1px solid var(--danger); color: var(--danger); }
.alert-warning { background: rgba(245, 158, 11, 0.1); border: 1px solid var(--warning); color: var(--warning); }

/* ==================== Empty State ==================== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
}

.empty-state .icon {
    font-size: 4rem;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state h3 {
    margin-bottom: 8px;
}

.empty-state p {
    color: var(--text-muted);
}

/* ==================== Pagination ==================== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 20px;
    flex-wrap: wrap;
}

.pagination a,
.pagination span {
    padding: 12px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
}

.pagination a:hover,
.pagination .active {
    background: var(--accent);
    border-color: var(--accent);
}

/* ==================== Footer ==================== */
.footer {
    background: var(--bg-secondary);
    padding: 40px 16px 100px;
    text-align: center;
    border-top: 1px solid var(--border);
}

.footer h3 {
    margin-bottom: 10px;
}

.footer p {
    color: var(--text-muted);
    margin-bottom: 20px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--accent);
}

.footer-copyright {
    font-size: 0.8rem;
    color: var(--text-muted);
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

/* ==================== Modal ==================== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.8);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 25px;
    width: 100%;
    max-width: 400px;
}

.modal-content h3 {
    margin-bottom: 20px;
}

/* ==================== Responsive ==================== */
@media (min-width: 768px) {
    .accounts-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }
    
    .profile-info {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
}

@media (min-width: 1024px) {
    .nav-bottom {
        display: none;
    }
    
    .app {
        padding-bottom: 0;
    }
    
    .footer {
        padding-bottom: 40px;
    }
    
    .accounts-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ==================== Animations ==================== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.3s ease;
}

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

.pulse {
    animation: pulse 2s infinite;
}

/* ==================== Loading ==================== */
.loading {
    display: flex;
    justify-content: center;
    padding: 40px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ==================== Breadcrumb ==================== */
.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    padding: 10px 12px;
    background: var(--bg-secondary);
    font-size: 0.8rem;
    border-bottom: 1px solid var(--border);
}

.breadcrumb a {
    color: var(--accent);
    text-decoration: none;
    transition: var(--transition);
}

.breadcrumb a:hover {
    color: var(--accent-light);
}

.breadcrumb .separator {
    color: var(--text-muted);
    font-size: 0.7rem;
}

.breadcrumb .current {
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 150px;
}

/* ==================== Subcategories Scroll ==================== */
.subcategories-scroll {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.subcategories-scroll::-webkit-scrollbar {
    display: none;
}

.subcat-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.85rem;
    white-space: nowrap;
    transition: var(--transition);
}

.subcat-chip:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
    border-color: var(--accent);
}

.subcat-chip.active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

/* ==================== Contact List View - Mobile First ==================== */
.contacts-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    background: var(--bg-primary);
    border-radius: 0;
    overflow: hidden;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-card);
    text-decoration: none;
    transition: var(--transition);
    border-bottom: 1px solid var(--border);
}

.contact-item:last-child {
    border-bottom: none;
}

.contact-item:hover {
    background: var(--bg-card-hover);
}

.contact-item:active {
    background: var(--bg-input);
}

.contact-item.vip {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.12), rgba(139, 92, 246, 0.05));
    border-right: 3px solid var(--accent);
}

.contact-avatar {
    position: relative;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--bg-input);
    flex-shrink: 0;
}

.contact-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.contact-avatar .avatar-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    opacity: 0.7;
}

.contact-vip {
    position: absolute;
    bottom: -2px;
    right: -2px;
    font-size: 12px;
    background: var(--bg-card);
    border-radius: 50%;
    padding: 1px;
}

.contact-info {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.contact-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 3px;
    line-height: 1.2;
}

.contact-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.contact-gender {
    display: inline-flex;
    align-items: center;
}

.contact-city {
    max-width: 70px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text-muted);
}

.contact-category {
    font-size: 0.9rem;
}

.contact-action {
    flex-shrink: 0;
}

.btn-add-small {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 14px;
    background: var(--accent);
    color: #fff;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    white-space: nowrap;
}

.btn-add-small:hover {
    background: var(--accent-light);
    transform: scale(1.05);
}

/* ==================== Filters Row ==================== */
.filters-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    gap: 8px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
}

.filters-row .filters {
    padding: 0;
    flex: 1;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.filters-row .filters::-webkit-scrollbar {
    display: none;
}

/* ==================== View Toggle Buttons ==================== */
.view-toggle {
    display: flex;
    gap: 4px;
    padding: 0;
    flex-shrink: 0;
}

.view-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-muted);
    text-decoration: none;
    transition: var(--transition);
}

.view-btn:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.view-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

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