/* ============================================================
   ALPHAVAULT COMMUNITY HUB — community.css v2.0
   Drive-style layout | Dark/Light | Full Responsive
   ============================================================ */

/* ════════════════════════════════════════════════════════════
   1. CSS VARIABLES (Drive-compatible)
════════════════════════════════════════════════════════════ */
:root {
    /* Backgrounds */
    --avd-bg:             #0b1120;
    --avd-sidebar-bg:     #0f172a;
    --avd-header-bg:      rgba(11, 17, 32, 0.97);
    --avd-card:           rgba(30, 41, 59, 0.92);
    --avd-card-hover:     rgba(51, 65, 85, 0.9);
    --avd-input-bg:       rgba(255, 255, 255, 0.06);

    /* Card / Section aliases */
    --card-background:    rgba(30, 41, 59, 0.92);
    --glass-border:       rgba(255, 255, 255, 0.08);

    /* Borders */
    --avd-border:         rgba(255, 255, 255, 0.08);
    --avd-border-hover:   rgba(255, 255, 255, 0.15);

    /* Text */
    --avd-text:           #f0f4f8;
    --avd-text-muted:     #cbd5e1;
    --avd-text-dim:       #94a3b8;
    --text-primary:       #f0f4f8;
    --text-secondary:     #94a3b8;

    /* Brand */
    --avd-primary:        #667eea;
    --avd-primary-dark:   #764ba2;
    --avd-green:          #10b981;
    --avd-amber:          #f59e0b;
    --avd-red:            #ef4444;
    --avd-purple:         #8b5cf6;
    --primary-gradient:   linear-gradient(135deg, #667eea, #764ba2);

    /* Radii */
    --avd-radius:         10px;
    --avd-radius-lg:      16px;
    --avd-radius-xl:      24px;

    /* Shadows */
    --avd-shadow:         0 4px 24px rgba(0,0,0,0.35);
    --avd-shadow-lg:      0 10px 50px rgba(0,0,0,0.55);

    /* Layout */
    --avd-sidebar-w:      260px;
    --avd-header-h:       58px;

    --avd-transition:     all 0.2s ease;
}

/* ── Light mode overrides ─────────────────────────────────── */
body.light-mode {
    --avd-bg:             #f1f5f9;
    --avd-sidebar-bg:     #ffffff;
    --avd-header-bg:      rgba(255, 255, 255, 0.97);
    --avd-card:           #ffffff;
    --avd-card-hover:     #f8fafc;
    --avd-input-bg:       rgba(0, 0, 0, 0.04);
    --avd-border:         rgba(0, 0, 0, 0.08);
    --avd-border-hover:   rgba(0, 0, 0, 0.15);
    --avd-text:           #1e293b;
    --avd-text-muted:     #475569;
    --avd-text-dim:       #94a3b8;
    --card-background:    #ffffff;
    --glass-border:       rgba(0, 0, 0, 0.08);
    --text-primary:       #1e293b;
    --text-secondary:     #64748b;
}

/* ════════════════════════════════════════════════════════════
   2. RESET & BASE
════════════════════════════════════════════════════════════ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
    overflow: hidden;
}

body.avd-page {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--avd-bg);
    color: var(--avd-text);
    font-size: 13px;
    -webkit-font-smoothing: antialiased;
    line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; }

/* ════════════════════════════════════════════════════════════
   3. APP LAYOUT
════════════════════════════════════════════════════════════ */
#avDriveApp {
    display: flex;
    height: 100vh;
    overflow: hidden;
    position: relative;
}

/* ════════════════════════════════════════════════════════════
   4. SIDEBAR
════════════════════════════════════════════════════════════ */
#avdSidebar {
    width: var(--avd-sidebar-w);
    flex-shrink: 0;
    background: var(--avd-sidebar-bg);
    border-right: 1px solid var(--avd-border);
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: visible;
    position: relative;
    z-index: 200;
    transition: width 0.25s ease, transform 0.3s ease;
}

body.light-mode #avdSidebar {
    box-shadow: 2px 0 20px rgba(0,0,0,0.08);
}

/* Collapsed state */
#avdSidebar.collapsed { width: 64px; }

#avdSidebar.collapsed .avd-nav-item-text,
#avdSidebar.collapsed .avd-nav-badge,
#avdSidebar.collapsed .avd-nav-label,
#avdSidebar.collapsed .avd-platform-nav,
#avdSidebar.collapsed .avd-sidebar-user-trigger > div,
#avdSidebar.collapsed #avdUserPlan,
#avdSidebar.collapsed #avdUserChevron {
    display: none;
}

#avdSidebar.collapsed .avd-nav-item {
    justify-content: center;
    padding: 10px;
}
#avdSidebar.collapsed .avd-nav-item-icon { margin: 0; }

/* Logo collapsed vs expanded */
.avd-sidebar-logo-text {
    display: block;
    height: 42px !important;
    max-width: 180px !important;
    object-fit: contain;
}
.avd-sidebar-logo-icon {
    display: none;
    height: 40px !important;
    width:  40px !important;
    object-fit: contain;
}
#avdSidebar.collapsed .avd-sidebar-logo-text { display: none; }
#avdSidebar.collapsed .avd-sidebar-logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 0 10px;
    width: 100%;
}

/* Sidebar scroll area */
.avd-sidebar-scroll {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}
.avd-sidebar-scroll::-webkit-scrollbar { width: 3px; }
.avd-sidebar-scroll::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
}
body.light-mode .avd-sidebar-scroll::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.1);
}

/* Sidebar collapse toggle */
.avd-sidebar-toggle {
    position: absolute;
    right: -14px;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--avd-card);
    border: 1px solid var(--avd-border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--avd-text-muted);
    font-size: 10px;
    z-index: 300;
    transition: var(--avd-transition);
    box-shadow: 0 2px 10px rgba(0,0,0,0.4);
    flex-shrink: 0;
}
body.light-mode .avd-sidebar-toggle {
    background: #ffffff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
}
.avd-sidebar-toggle:hover {
    background: var(--avd-primary);
    color: #fff;
    border-color: var(--avd-primary);
    box-shadow: 0 4px 16px rgba(102,126,234,0.5);
}

/* Mobile close button */
.avd-mobile-close-btn {
    display: none;
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
    color: #94a3b8;
    font-size: 14px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: var(--avd-transition);
}
.avd-mobile-close-btn:hover {
    background: rgba(239,68,68,0.15);
    color: #ef4444;
    border-color: rgba(239,68,68,0.3);
}

/* ════════════════════════════════════════════════════════════
   5. MAIN AREA
════════════════════════════════════════════════════════════ */
#avdMain {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
    min-width: 0;
    transition: margin-left 0.25s ease;
}

/* ════════════════════════════════════════════════════════════
   6. HEADER
════════════════════════════════════════════════════════════ */
#avDriveHeader {
    height: var(--avd-header-h);
    background: var(--avd-header-bg);
    border-bottom: 1px solid var(--avd-border);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 18px;
    flex-shrink: 0;
    backdrop-filter: blur(20px);
    position: relative;
    z-index: 100;
}

/* Breadcrumb */
.avd-breadcrumb {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}
.avd-breadcrumb-item {
    font-size: 12px;
    font-weight: 700;
    color: var(--avd-text-dim);
    cursor: pointer;
    transition: color 0.15s;
    white-space: nowrap;
}
.avd-breadcrumb-item:hover { color: var(--avd-text); }
.avd-breadcrumb-item.active { color: var(--avd-text); }
.avd-breadcrumb-sep { font-size: 9px; color: var(--avd-text-dim); }

/* Header controls */
.avd-header-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
    flex-shrink: 0;
}

/* Theme toggle */
.avd-theme-toggle {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--avd-input-bg);
    border: 1px solid var(--avd-border);
    border-radius: 10px;
    cursor: pointer;
    color: var(--avd-text-muted);
    font-size: 14px;
    transition: var(--avd-transition);
    flex-shrink: 0;
}
.avd-theme-toggle:hover {
    background: rgba(245,158,11,0.12);
    color: var(--avd-amber);
    border-color: rgba(245,158,11,0.3);
}
body.light-mode .avd-theme-toggle:hover {
    background: rgba(102,126,234,0.1);
    color: var(--avd-primary);
    border-color: rgba(102,126,234,0.2);
}

/* Header button */
.avd-header-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    background: var(--avd-input-bg);
    border: 1px solid var(--avd-border);
    border-radius: 10px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    color: var(--avd-text-muted);
    cursor: pointer;
    transition: var(--avd-transition);
    white-space: nowrap;
}
.avd-header-btn:hover {
    background: rgba(255,255,255,0.08);
    color: var(--avd-text);
    border-color: var(--avd-border-hover);
}

/* Status dot */
.avd-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #475569;
    transition: var(--avd-transition);
    flex-shrink: 0;
}
.avd-status-dot.connected {
    background: var(--avd-green);
    box-shadow: 0 0 8px rgba(16,185,129,0.6);
}
.avd-status-dot.syncing {
    background: var(--avd-amber);
    animation: pulseDot 1s infinite;
}
.avd-status-dot.error {
    background: var(--avd-red);
    box-shadow: 0 0 8px rgba(239,68,68,0.6);
}
@keyframes pulseDot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* ════════════════════════════════════════════════════════════
   7. SIDEBAR NAV
════════════════════════════════════════════════════════════ */
.avd-nav { padding: 4px 8px; }
.avd-nav-section { margin-bottom: 6px; }
.avd-nav-label {
    padding: 10px 10px 5px;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.4px;
    color: var(--avd-text-dim);
}

.avd-nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 10px;
    cursor: pointer;
    transition: var(--avd-transition);
    color: var(--avd-text-muted);
    position: relative;
    margin-bottom: 2px;
}
.avd-nav-item:hover {
    background: rgba(255,255,255,0.05);
    color: var(--avd-text);
}
body.light-mode .avd-nav-item:hover {
    background: rgba(0,0,0,0.04);
    color: #1e293b;
}
.avd-nav-item.active {
    background: rgba(102,126,234,0.13);
    color: var(--avd-primary);
}
.avd-nav-item-icon {
    width: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}
.avd-nav-item-text {
    flex: 1;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.avd-nav-badge {
    font-size: 9px;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 20px;
    background: rgba(102,126,234,0.18);
    color: #a5b4fc;
    min-width: 22px;
    text-align: center;
    flex-shrink: 0;
}

/* ════════════════════════════════════════════════════════════
   8. PLATFORM NAV (sidebar)
════════════════════════════════════════════════════════════ */
.avd-platform-nav { padding: 0 0 8px; }
.avd-platform-section { margin-bottom: 1px; }

.avd-platform-folder {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px 10px;
    font-size: 12px;
    font-weight: 700;
    color: var(--avd-text-muted);
    cursor: pointer;
    border-radius: 10px;
    margin: 0 8px;
    transition: var(--avd-transition);
    position: relative;
    background: none;
    border: none;
    width: calc(100% - 16px);
    text-align: left;
}
.avd-platform-folder:hover {
    background: rgba(255,255,255,0.05);
    color: var(--avd-text);
}
body.light-mode .avd-platform-folder:hover {
    background: rgba(0,0,0,0.04);
    color: #1e293b;
}
.avd-platform-folder i:first-child {
    font-size: 13px;
    width: 16px;
    text-align: center;
}
.avd-platform-folder .arrow {
    margin-left: auto;
    font-size: 9px;
    transition: transform 0.2s;
}
.avd-platform-folder.open .arrow { transform: rotate(180deg); }

.avd-platform-submenu { display: none; padding: 2px 0; }
.avd-platform-submenu.open { display: block; }

.avd-platform-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px 6px 36px;
    font-size: 11px;
    font-weight: 500;
    color: var(--avd-text-dim);
    text-decoration: none;
    border-radius: 8px;
    margin: 0 8px;
    transition: var(--avd-transition);
}
.avd-platform-link:hover {
    background: rgba(255,255,255,0.04);
    color: var(--avd-text-muted);
}
body.light-mode .avd-platform-link:hover {
    background: rgba(0,0,0,0.04);
    color: #475569;
}
.avd-platform-link.active {
    color: var(--avd-primary);
    background: rgba(102,126,234,0.08);
}
.avd-platform-link i {
    font-size: 11px;
    width: 14px;
    text-align: center;
}
.avd-platform-divider {
    border: none;
    border-top: 1px solid var(--avd-border);
    margin: 8px 16px;
}

/* ════════════════════════════════════════════════════════════
   9. SIDEBAR FOOTER
════════════════════════════════════════════════════════════ */
.avd-sidebar-footer {
    border-top: 1px solid var(--avd-border);
    position: relative;
    flex-shrink: 0;
}
body.light-mode .avd-sidebar-footer { border-color: rgba(0,0,0,0.08); }

.avd-sidebar-user-trigger {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    cursor: pointer;
    transition: var(--avd-transition);
}
.avd-sidebar-user-trigger:hover { background: rgba(255,255,255,0.04); }
body.light-mode .avd-sidebar-user-trigger:hover { background: rgba(0,0,0,0.04); }

.avd-sidebar-user-dropdown {
    display: none;
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    background: #1e293b;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 14px;
    padding: 8px;
    margin: 0 8px 6px;
    box-shadow: 0 -10px 40px rgba(0,0,0,0.5);
    z-index: 1000;
}
body.light-mode .avd-sidebar-user-dropdown {
    background: #ffffff;
    border-color: rgba(0,0,0,0.1);
    box-shadow: 0 -8px 32px rgba(0,0,0,0.12);
}
.avd-sidebar-user-dropdown.open { display: block; }

.avd-sidebar-dropdown-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    margin-bottom: 6px;
}
body.light-mode .avd-sidebar-dropdown-header { border-color: rgba(0,0,0,0.07); }
.avd-sidebar-dropdown-header img {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
}

.avd-sidebar-dropdown-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    color: var(--avd-text-muted);
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    border-radius: 8px;
    transition: var(--avd-transition);
}
.avd-sidebar-dropdown-link:hover {
    background: rgba(255,255,255,0.05);
    color: var(--avd-text);
}
body.light-mode .avd-sidebar-dropdown-link:hover { background: rgba(0,0,0,0.04); }
.avd-sidebar-dropdown-link i { font-size: 13px; width: 16px; text-align: center; }

.avd-sidebar-dropdown-logout {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    color: var(--avd-red);
    font-size: 12px;
    font-weight: 700;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--avd-transition);
    background: none;
    border: none;
    width: 100%;
    text-align: left;
    margin-top: 4px;
    border-top: 1px solid rgba(255,255,255,0.07);
}
body.light-mode .avd-sidebar-dropdown-logout { border-color: rgba(0,0,0,0.06); }
.avd-sidebar-dropdown-logout:hover { background: rgba(239,68,68,0.08); }

/* ════════════════════════════════════════════════════════════
   10. CONTENT AREA
════════════════════════════════════════════════════════════ */
#avDriveContent {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 22px 26px;
}
#avDriveContent::-webkit-scrollbar { width: 5px; }
#avDriveContent::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.1);
    border-radius: 4px;
}
body.light-mode #avDriveContent::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.12);
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
}

/* ════════════════════════════════════════════════════════════
   11. SECTION CARDS
════════════════════════════════════════════════════════════ */
.section {
    background: var(--avd-card);
    border: 1px solid var(--avd-border);
    border-radius: var(--avd-radius-xl);
    padding: 28px 32px;
    margin-bottom: 24px;
    transition: var(--avd-transition);
}
body.light-mode .section {
    box-shadow: 0 1px 6px rgba(0,0,0,0.06);
}

.section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--avd-text);
    margin-bottom: 6px;
}
.section-title i { color: var(--avd-primary); }

/* ════════════════════════════════════════════════════════════
   12. CHANNELS
════════════════════════════════════════════════════════════ */
.channels-scroll {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.channel-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 18px;
    background: var(--avd-input-bg);
    border: 2px solid var(--avd-border);
    border-radius: var(--avd-radius-lg);
    cursor: pointer;
    transition: var(--avd-transition);
    font-family: inherit;
    text-align: left;
    color: var(--avd-text);
    width: 100%;
    position: relative;
    overflow: hidden;
}
.channel-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(102,126,234,0), rgba(118,75,162,0));
    transition: var(--avd-transition);
}
.channel-card:hover {
    border-color: rgba(102,126,234,0.4);
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(102,126,234,0.15);
}
.channel-card:hover::before {
    background: linear-gradient(135deg, rgba(102,126,234,0.06), rgba(118,75,162,0.04));
}
.channel-card.active {
    border-color: var(--avd-primary);
    background: rgba(102,126,234,0.1);
    box-shadow: 0 0 0 3px rgba(102,126,234,0.12), 0 8px 24px rgba(102,126,234,0.2);
}
.channel-card.active::before {
    background: linear-gradient(135deg, rgba(102,126,234,0.1), rgba(118,75,162,0.06));
}

.channel-icon {
    font-size: 1.6rem;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}
.channel-info {
    flex: 1;
    min-width: 0;
    position: relative;
    z-index: 1;
}
.channel-name {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--avd-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
}
.channel-count {
    font-size: 0.75rem;
    color: var(--avd-text-dim);
    font-weight: 600;
}
.channel-card.active .channel-name { color: var(--avd-primary); }

/* ════════════════════════════════════════════════════════════
   13. ACTIONS BAR
════════════════════════════════════════════════════════════ */
.actions-bar {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* Search box */
.search-box {
    position: relative;
    flex: 1;
    min-width: 200px;
    max-width: 400px;
}
.search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--avd-text-dim);
    font-size: 13px;
    pointer-events: none;
    z-index: 1;
}
.search-input {
    width: 100%;
    background: var(--avd-input-bg);
    border: 1px solid var(--avd-border);
    border-radius: 10px;
    padding: 9px 14px 9px 36px;
    font-family: inherit;
    font-size: 13px;
    color: var(--avd-text);
    outline: none;
    transition: var(--avd-transition);
}
.search-input::placeholder { color: var(--avd-text-dim); }
.search-input:focus {
    border-color: var(--avd-primary);
    background: rgba(102,126,234,0.07);
    box-shadow: 0 0 0 3px rgba(102,126,234,0.15);
}

/* Filter buttons */
.filter-buttons {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.filter-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--avd-input-bg);
    border: 1px solid var(--avd-border);
    border-radius: 10px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
    color: var(--avd-text-muted);
    cursor: pointer;
    transition: var(--avd-transition);
    white-space: nowrap;
}
.filter-btn:hover {
    background: rgba(255,255,255,0.08);
    color: var(--avd-text);
    border-color: var(--avd-border-hover);
}
body.light-mode .filter-btn:hover { background: rgba(0,0,0,0.06); }
.filter-btn.active {
    background: linear-gradient(135deg, var(--avd-primary), var(--avd-primary-dark));
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 14px rgba(102,126,234,0.35);
}

/* Create post button */
.create-post-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: linear-gradient(135deg, var(--avd-primary), var(--avd-primary-dark));
    border: none;
    border-radius: 10px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 800;
    color: #fff;
    cursor: pointer;
    transition: var(--avd-transition);
    white-space: nowrap;
    box-shadow: 0 4px 16px rgba(102,126,234,0.35);
    flex-shrink: 0;
}
.create-post-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(102,126,234,0.5);
}

/* ════════════════════════════════════════════════════════════
   14. COMMUNITY LAYOUT (Posts + Sidebar)
════════════════════════════════════════════════════════════ */
.community-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 24px;
    align-items: start;
}

/* Posts section */
.posts-section { min-width: 0; }

/* Posts grid */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

/* ════════════════════════════════════════════════════════════
   15. POST CARDS
════════════════════════════════════════════════════════════ */
.post-card {
    background: var(--avd-card);
    border: 2px solid var(--avd-border);
    border-radius: var(--avd-radius-xl);
    padding: 24px;
    cursor: pointer;
    transition: var(--avd-transition);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 0;
}
.post-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--avd-primary), var(--avd-primary-dark));
    opacity: 0;
    transition: opacity 0.3s ease;
}
.post-card:hover {
    border-color: rgba(102,126,234,0.35);
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(102,126,234,0.12), 0 4px 16px rgba(0,0,0,0.2);
}
.post-card:hover::before { opacity: 1; }
body.light-mode .post-card { box-shadow: 0 1px 6px rgba(0,0,0,0.06); }

/* Post author */
.post-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}
.post-author {
    display: flex;
    align-items: center;
    gap: 12px;
}
.post-author img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--avd-border);
    flex-shrink: 0;
}
.post-author-name {
    font-weight: 700;
    color: var(--avd-text);
    font-size: 0.95rem;
}
.post-author-meta {
    font-size: 0.85rem;
    color: var(--avd-text-dim);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Post title */
.post-card h2 {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--avd-text);
    margin-bottom: 10px;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Post excerpt */
.post-excerpt {
    color: var(--avd-text-muted);
    font-size: 0.9rem;
    line-height: 1.65;
    margin-bottom: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Post image preview */
.post-image-preview {
    position: relative;
    width: 100%;
    height: 190px;
    border-radius: 12px;
    overflow: hidden;
    margin: 12px 0;
}
.post-image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.post-card:hover .post-image-preview img { transform: scale(1.03); }

.image-count {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0,0,0,0.72);
    color: #fff;
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    backdrop-filter: blur(6px);
}

/* Post tags */
.post-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}
.post-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    background: rgba(102,126,234,0.1);
    border: 1px solid rgba(102,126,234,0.2);
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #a5b4fc;
    transition: var(--avd-transition);
    cursor: pointer;
    white-space: nowrap;
}
.post-tag:hover {
    background: rgba(102,126,234,0.2);
    border-color: rgba(102,126,234,0.4);
    color: #818cf8;
    transform: translateY(-1px);
}
body.light-mode .post-tag {
    background: rgba(102,126,234,0.08);
    border-color: rgba(102,126,234,0.18);
    color: #667eea;
}

/* Post footer */
.post-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    border-top: 1px solid var(--avd-border);
    margin-top: auto;
}
.post-stats {
    display: flex;
    gap: 14px;
    font-size: 0.85rem;
    color: var(--avd-text-dim);
}
.post-stats span {
    display: flex;
    align-items: center;
    gap: 5px;
    transition: color 0.2s;
}
.post-stats span:hover { color: var(--avd-primary); }
.post-stats i { font-size: 0.8rem; }

/* Read more button */
.btn-read-more {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: linear-gradient(135deg, var(--avd-primary), var(--avd-primary-dark));
    border: none;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
    transition: var(--avd-transition);
    box-shadow: 0 4px 12px rgba(102,126,234,0.3);
}
.btn-read-more:hover {
    transform: translateX(2px);
    box-shadow: 0 6px 18px rgba(102,126,234,0.45);
}
.btn-read-more i { font-size: 0.75rem; }

/* Page transition animation */
.posts-grid.page-transition {
    animation: fadeSlide 0.35s ease;
}
@keyframes fadeSlide {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ════════════════════════════════════════════════════════════
   16. PAGINATION
════════════════════════════════════════════════════════════ */
.pagination-container {
    margin-top: 32px;
    padding: 0 4px;
}

.pagination-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.pagination-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    background: var(--avd-input-bg);
    border: 1px solid var(--avd-border);
    border-radius: 10px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
    color: var(--avd-text-muted);
    cursor: pointer;
    transition: var(--avd-transition);
    white-space: nowrap;
}
.pagination-btn:hover:not(:disabled) {
    background: rgba(102,126,234,0.12);
    border-color: rgba(102,126,234,0.3);
    color: var(--avd-primary);
}
.pagination-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.pagination-numbers {
    display: flex;
    align-items: center;
    gap: 4px;
}

.pagination-number {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid var(--avd-border);
    background: var(--avd-input-bg);
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
    color: var(--avd-text-muted);
    cursor: pointer;
    transition: var(--avd-transition);
}
.pagination-number:hover:not(.active) {
    background: rgba(102,126,234,0.12);
    border-color: rgba(102,126,234,0.3);
    color: var(--avd-primary);
}
.pagination-number.active {
    background: linear-gradient(135deg, var(--avd-primary), var(--avd-primary-dark));
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 14px rgba(102,126,234,0.4);
    cursor: default;
}

.pagination-ellipsis {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 38px;
    color: var(--avd-text-dim);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
}

.pagination-info {
    text-align: center;
    margin-top: 12px;
    font-size: 12px;
    font-weight: 600;
    color: var(--avd-text-dim);
}

/* ════════════════════════════════════════════════════════════
   17. COMMUNITY SIDEBAR WIDGETS
════════════════════════════════════════════════════════════ */
.community-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
    position: sticky;
    top: 0;
}

.sidebar-widget {
    background: var(--avd-card);
    border: 1px solid var(--avd-border);
    border-radius: var(--avd-radius-xl);
    padding: 22px 20px;
    transition: var(--avd-transition);
}
body.light-mode .sidebar-widget {
    box-shadow: 0 1px 6px rgba(0,0,0,0.05);
}

.sidebar-widget .section-title {
    font-size: 0.95rem;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--avd-border);
}

/* Featured posts */
.featured-posts-list { display: flex; flex-direction: column; gap: 4px; }

.featured-post-item {
    padding: 14px;
    border-radius: 10px;
    cursor: pointer;
    transition: var(--avd-transition);
    border: 1px solid transparent;
}
.featured-post-item:hover {
    background: rgba(102,126,234,0.06);
    border-color: rgba(102,126,234,0.15);
    transform: translateX(4px);
}
.featured-post-item h4 {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--avd-text);
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.featured-post-stats {
    display: flex;
    gap: 12px;
    font-size: 0.8rem;
    color: var(--avd-text-dim);
}
.featured-post-stats span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.featured-posts-empty {
    text-align: center;
    padding: 24px 16px;
    color: var(--avd-text-dim);
}
.featured-posts-empty i {
    font-size: 2rem;
    display: block;
    margin-bottom: 10px;
    opacity: 0.3;
}

/* Leaderboard */
.leaderboard-list { display: flex; flex-direction: column; gap: 4px; }

.leaderboard-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--avd-transition);
    border: 2px solid var(--avd-border);
    background: var(--avd-input-bg);
}
.leaderboard-item:hover {
    border-color: rgba(102,126,234,0.3);
    transform: translateX(3px);
    box-shadow: 0 4px 16px rgba(102,126,234,0.08);
}
.leaderboard-item:first-child {
    background: linear-gradient(135deg, rgba(255,215,0,0.08), rgba(255,193,7,0.04));
    border-color: rgba(255,215,0,0.2);
}
.leaderboard-item:first-child:hover { border-color: rgba(255,215,0,0.4); }

.leaderboard-rank {
    font-size: 1.4rem;
    min-width: 32px;
    text-align: center;
    flex-shrink: 0;
}
.leaderboard-item img {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--avd-border);
    flex-shrink: 0;
}
.leaderboard-item:first-child img { border-color: #FFD700; }

.leaderboard-info { flex: 1; min-width: 0; }
.leaderboard-name {
    font-weight: 700;
    color: var(--avd-text);
    font-size: 0.88rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
}
.leaderboard-points {
    font-size: 0.78rem;
    color: var(--avd-text-dim);
    display: flex;
    align-items: center;
    gap: 4px;
}
.leaderboard-points i { color: var(--avd-amber); }
.leaderboard-count { font-size: 0.78rem; color: var(--avd-text-dim); flex-shrink: 0; }

.leaderboard-empty {
    text-align: center;
    padding: 24px;
    color: var(--avd-text-dim);
    font-size: 0.88rem;
}
.leaderboard-empty i {
    font-size: 2rem;
    opacity: 0.3;
    display: block;
    margin-bottom: 10px;
}

/* Trending tags */
.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* ════════════════════════════════════════════════════════════
   18. LOADING SPINNER
════════════════════════════════════════════════════════════ */
.loading-spinner {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 24px;
}

.loading-spinner-modern {
    position: relative;
    width: 52px;
    height: 52px;
}
.loading-spinner-modern::before,
.loading-spinner-modern::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 3px solid transparent;
}
.loading-spinner-modern::before {
    border-top-color: var(--avd-primary);
    animation: spin 0.8s linear infinite;
}
.loading-spinner-modern::after {
    border-bottom-color: var(--avd-primary-dark);
    animation: spin 1.2s linear infinite reverse;
}
.loading-spinner-modern-dot {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--avd-primary), var(--avd-primary-dark));
    animation: pulse 0.8s ease-in-out infinite alternate;
}
@keyframes spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}
@keyframes pulse {
    from { transform: translate(-50%, -50%) scale(0.8); opacity: 0.7; }
    to   { transform: translate(-50%, -50%) scale(1.2); opacity: 1; }
}

/* ════════════════════════════════════════════════════════════
   19. COMMUNITY STATS
════════════════════════════════════════════════════════════ */
.community-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 8px;
}
.stat-card {
    background: var(--avd-input-bg);
    border: 1px solid var(--avd-border);
    border-radius: var(--avd-radius-lg);
    padding: 20px;
    text-align: center;
    transition: var(--avd-transition);
}
.stat-card:hover {
    border-color: rgba(102,126,234,0.3);
    transform: translateY(-2px);
}
.stat-number {
    font-size: 2rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--avd-primary), var(--avd-primary-dark));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: 4px;
}
.stat-label {
    font-size: 0.78rem;
    color: var(--avd-text-dim);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

/* ════════════════════════════════════════════════════════════
   20. NEWSLETTER ADMIN BUTTONS
════════════════════════════════════════════════════════════ */
.newsletter-btn-container { width: 100%; }

.newsletter-generate-btn-full {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 24px;
    background: linear-gradient(135deg, var(--avd-primary) 0%, var(--avd-primary-dark) 100%);
    border: none;
    border-radius: 16px;
    cursor: pointer;
    transition: var(--avd-transition);
    font-family: inherit;
    color: #fff;
    box-shadow: 0 6px 24px rgba(102,126,234,0.35);
    position: relative;
    overflow: hidden;
}
.newsletter-generate-btn-full::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.12) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.newsletter-generate-btn-full:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 36px rgba(102,126,234,0.5);
}
.newsletter-generate-btn-full:hover::before { opacity: 1; }

.btn-icon-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
    min-width: 0;
}
.btn-icon {
    width: 46px;
    height: 46px;
    background: rgba(255,255,255,0.18);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
    backdrop-filter: blur(6px);
}
.btn-content { min-width: 0; }
.btn-title {
    font-size: 0.95rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.btn-subtitle {
    font-size: 0.78rem;
    color: rgba(255,255,255,0.75);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn-action {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.btn-badge {
    font-size: 0.65rem;
    font-weight: 900;
    padding: 3px 8px;
    border-radius: 20px;
    background: rgba(255,255,255,0.2);
    color: #fff;
    letter-spacing: 1px;
    border: 1px solid rgba(255,255,255,0.3);
}
.btn-arrow {
    font-size: 1rem;
    color: rgba(255,255,255,0.85);
    transition: transform 0.2s ease;
}
.newsletter-generate-btn-full:hover .btn-arrow { transform: translateX(4px); }

/* ════════════════════════════════════════════════════════════
   21. PARTICLES BACKGROUND
════════════════════════════════════════════════════════════ */
.particles-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    pointer-events: none;
    opacity: 0.5;
    transition: opacity 0.5s ease;
}
body.dark-mode .particles-background { opacity: 0.35; }
body.light-mode .particles-background { opacity: 0.4; }

/* ════════════════════════════════════════════════════════════
   22. EMPTY STATE
════════════════════════════════════════════════════════════ */
.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 80px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}
.empty-state i {
    font-size: 3.5rem;
    opacity: 0.25;
    color: var(--avd-text-dim);
    margin-bottom: 20px;
}
.empty-state h3 {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--avd-text);
    margin-bottom: 10px;
}
.empty-state p {
    color: var(--avd-text-dim);
    font-size: 0.95rem;
    margin-bottom: 24px;
    line-height: 1.6;
}

/* ════════════════════════════════════════════════════════════
   23. SCROLLBARS (global)
════════════════════════════════════════════════════════════ */
* { scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.08) transparent; }
body.light-mode * { scrollbar-color: rgba(0,0,0,0.12) transparent; }
*::-webkit-scrollbar { width: 4px; height: 4px; }
*::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 4px; }
body.light-mode *::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.14); }

/* ════════════════════════════════════════════════════════════
   24. LIGHT MODE ADJUSTMENTS
════════════════════════════════════════════════════════════ */
body.light-mode .channel-card {
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}
body.light-mode .post-card {
    box-shadow: 0 1px 6px rgba(0,0,0,0.06);
}
body.light-mode .post-tag {
    background: rgba(102,126,234,0.08);
    border-color: rgba(102,126,234,0.18);
    color: #667eea;
}
body.light-mode .leaderboard-item {
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
body.light-mode .filter-btn { color: #475569; }
body.light-mode .pagination-btn { color: #475569; }
body.light-mode .pagination-number { color: #475569; }
body.light-mode .avd-nav-label { color: #94a3b8; }

/* ════════════════════════════════════════════════════════════
   25. RESPONSIVE — TABLET (≤ 1200px)
════════════════════════════════════════════════════════════ */
@media (max-width: 1200px) {
    :root { --avd-sidebar-w: 240px; }

    .community-layout {
        grid-template-columns: 1fr 280px;
    }
    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
    .channels-scroll {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }
}

@media (max-width: 1024px) {
    .community-layout {
        grid-template-columns: 1fr;
    }
    .community-sidebar {
        position: static;
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
    .section { padding: 22px 24px; }
}

/* ════════════════════════════════════════════════════════════
   26. RESPONSIVE — MOBILE (≤ 768px)
════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
    html, body { overflow: hidden; }
    #avDriveApp { flex-direction: row; }

    /* Sidebar overlay */
    #avdSidebar {
        position: fixed;
        left: 0; top: 0; bottom: 0;
        z-index: 1000;
        transform: translateX(-100%);
        overflow-y: auto;
        overflow-x: hidden;
    }
    #avdSidebar.mobile-open {
        transform: translateX(0);
        box-shadow: 4px 0 40px rgba(0,0,0,0.55);
    }
    #avdSidebar.mobile-open::before {
        content: '';
        position: fixed;
        inset: 0;
        left: var(--avd-sidebar-w);
        background: rgba(0,0,0,0.5);
        z-index: -1;
    }

    .avd-sidebar-toggle { display: none !important; }
    .avd-mobile-close-btn { display: flex; }
    #avdMain { flex: 1; }
    #avdMobileMenuBtn { display: flex !important; }

    .avd-breadcrumb { display: none; }
    #avDriveContent { padding: 14px 14px; }

    /* Actions bar */
    .actions-bar {
        flex-direction: column;
        align-items: stretch;
    }
    .search-box { max-width: 100%; }
    .filter-buttons { justify-content: center; }
    .create-post-btn { justify-content: center; }

    /* Channels */
    .channels-scroll {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 10px;
    }
    .channel-card { padding: 12px 14px; }
    .channel-icon { font-size: 1.4rem; }
    .channel-name { font-size: 0.78rem; }

    /* Posts grid */
    .posts-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    /* Community sidebar */
    .community-sidebar {
        grid-template-columns: 1fr;
    }

    /* Pagination */
    .pagination-wrapper { gap: 5px; }
    .pagination-btn span { display: none; }
    .pagination-btn { padding: 10px 12px; }
    .pagination-number { width: 34px; height: 34px; font-size: 11px; }

    /* Newsletter */
    .btn-subtitle { display: none; }
    .newsletter-generate-btn-full { padding: 16px 18px; }

    /* Section */
    .section { padding: 18px 16px; border-radius: var(--avd-radius-lg); }
}

/* ════════════════════════════════════════════════════════════
   27. RESPONSIVE — SMALL MOBILE (≤ 480px)
════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
    :root { --avd-header-h: 52px; }

    #avDriveHeader { padding: 0 10px; gap: 6px; }
    #avDriveContent { padding: 10px 10px; }

    .channels-scroll {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    .channel-card { padding: 10px 12px; gap: 8px; }
    .channel-icon { font-size: 1.2rem; }

    .section { padding: 16px 14px; }
    .section-title { font-size: 1rem; }

    .posts-grid { gap: 10px; }
    .post-card { padding: 16px; }
    .post-card h2 { font-size: 1rem; }

    .filter-buttons { gap: 4px; }
    .filter-btn { padding: 7px 10px; font-size: 11px; }

    .pagination-numbers { gap: 3px; }
    .pagination-number { width: 30px; height: 30px; font-size: 10px; }
    .pagination-ellipsis { width: 22px; }

    .community-stats { grid-template-columns: 1fr; gap: 10px; }
    .stat-number { font-size: 1.6rem; }

    .leaderboard-item { padding: 10px; gap: 8px; }
    .leaderboard-rank { font-size: 1.2rem; min-width: 26px; }

    .sidebar-widget { padding: 16px 14px; }
    .newsletter-generate-btn-full { padding: 14px 16px; }
    .btn-icon { width: 38px; height: 38px; font-size: 1.1rem; }
    .btn-title { font-size: 0.85rem; }
}

/* ════════════════════════════════════════════════════════════
   28. ANIMATIONS & MICRO-INTERACTIONS
════════════════════════════════════════════════════════════ */
@keyframes avdFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}
.section { animation: avdFadeIn 0.25s ease both; }
.post-card { animation: avdFadeIn 0.25s ease both; }
.channel-card { animation: avdFadeIn 0.2s ease both; }

/* Skeleton loading */
.avd-skeleton {
    background: linear-gradient(
        90deg,
        rgba(255,255,255,0.04) 25%,
        rgba(255,255,255,0.09) 50%,
        rgba(255,255,255,0.04) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--avd-radius-lg);
}
body.light-mode .avd-skeleton {
    background: linear-gradient(
        90deg,
        rgba(0,0,0,0.04) 25%,
        rgba(0,0,0,0.08) 50%,
        rgba(0,0,0,0.04) 75%
    );
    background-size: 200% 100%;
}
@keyframes shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}