/* ==========================================================================
   ReelsX Web App - Inspired Modern Design System
   Supports: Obsidian Dark Mode (Default) & Crisp Clean Light Mode
   ========================================================================== */

:root {
    /* Brand Colors */
    --primary: #FE2C55;
    --primary-hover: #e02047;
    --primary-light: rgba(254, 44, 85, 0.15);
    --primary-gradient: linear-gradient(135deg, #FE2C55 0%, #FF007A 100%);
    --cyan-accent: #25F4EE;
    --cyan-gradient: linear-gradient(135deg, #25F4EE 0%, #00C8FF 100%);
    --gold-gradient: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    --silver-gradient: linear-gradient(135deg, #E0E0E0 0%, #BDBDBD 100%);
    --bronze-gradient: linear-gradient(135deg, #D7A15C 0%, #A66E2E 100%);

    /* Dark Mode Defaults */
    --bg-main: #0f0f0f;
    --bg-surface: #181818;
    --bg-surface-elevated: #222222;
    --bg-input: #2a2a2a;
    --border-color: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.18);
    --text-main: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.75);
    --text-muted: rgba(255, 255, 255, 0.45);
    --sidebar-width: 240px;
    --header-height: 64px;
    --bottom-nav-height: 60px;
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-full: 9999px;
    --shadow-soft: 0 8px 30px rgba(0, 0, 0, 0.35);
    --shadow-glow: 0 0 20px rgba(254, 44, 85, 0.3);
}

/* Light Mode Overrides */
[data-theme="light"] {
    --bg-main: #f8f9fa;
    --bg-surface: #ffffff;
    --bg-surface-elevated: #f1f3f5;
    --bg-input: #f1f3f5;
    --border-color: rgba(0, 0, 0, 0.08);
    --border-hover: rgba(0, 0, 0, 0.16);
    --text-main: #111827;
    --text-secondary: #4b5563;
    --text-muted: #9ca3af;
    --shadow-soft: 0 8px 30px rgba(0, 0, 0, 0.06);
    --shadow-glow: 0 0 15px rgba(254, 44, 85, 0.2);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    overflow-x: hidden;
    min-height: 100vh;
}

body.theme-transitioning,
body.theme-transitioning * {
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease !important;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: var(--border-hover);
    border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* Hide Scrollbar Utility */
.hide-scrollbar {
    -ms-overflow-style: none !important;
    scrollbar-width: none !important;
}
.hide-scrollbar::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
}

/* App Master Layout */
.app-layout {
    display: flex;
    min-height: 100vh;
    min-width: 0;
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
}

/* Desktop Sidebar */
.app-sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    height: 100dvh;
    position: fixed;
    top: 0;
    left: 0;
    background: var(--bg-surface);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    padding: 16px 12px;
    z-index: 1000;
    transition: width 0.25s ease, transform 0.25s ease;
    overflow: hidden;
}

.sidebar-top-section {
    flex-shrink: 0;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px 20px;
    text-decoration: none;
    color: var(--text-main);
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.sidebar-brand img {
    height: 36px;
    border-radius: var(--radius-sm);
}

.sidebar-search-container {
    position: relative;
    width: 100%;
}

.sidebar-search-input {
    width: 100%;
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    padding: 8px 12px 8px 34px;
    color: var(--text-main);
    font-size: 13px;
    outline: none;
    transition: all 0.2s ease;
}

.sidebar-search-input:focus {
    border-color: var(--primary);
    background: var(--bg-surface);
    box-shadow: 0 0 0 2px var(--primary-light);
}

.sidebar-search-icon {
    position: absolute;
    left: 11px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 15px;
    pointer-events: none;
}

.sidebar-user-item:hover {
    background: var(--bg-surface-elevated);
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex-grow: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 4px;
    min-height: 0;
    margin: 6px 0;
    -webkit-overflow-scrolling: touch;
}

.sidebar-nav::-webkit-scrollbar {
    width: 4px;
}
.sidebar-nav::-webkit-scrollbar-track {
    background: transparent;
}
.sidebar-nav::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: var(--radius-full);
}
.sidebar-nav::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.sidebar-link i {
    font-size: 22px;
    transition: transform 0.2s ease;
}

.sidebar-link:hover {
    background: var(--bg-surface-elevated);
    color: var(--text-main);
    transform: translateX(3px);
}

.sidebar-link.active {
    background: var(--primary-light);
    color: var(--primary);
}

.sidebar-link.active i {
    color: var(--primary);
}

.sidebar-badge {
    margin-left: auto;
    background: var(--primary);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: var(--radius-full);
}

.sidebar-btn-create {
    background: var(--primary-gradient);
    color: #ffffff !important;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 15px;
    text-decoration: none;
    margin: 12px 0;
    box-shadow: var(--shadow-glow);
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.sidebar-btn-create:hover {
    transform: translateY(-2px);
    opacity: 0.95;
}

.sidebar-footer {
    border-top: 1px solid var(--border-color);
    padding-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
    margin-top: auto;
}

/* Top App Header */
.app-header {
    position: fixed;
    top: 0;
    right: 0;
    left: var(--sidebar-width);
    height: var(--header-height);
    background: rgba(15, 15, 15, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    z-index: 990;
    transition: left 0.25s ease, background 0.25s ease;
}

[data-theme="light"] .app-header {
    background: rgba(255, 255, 255, 0.88);
}

.search-container {
    position: relative;
    width: 100%;
    max-width: 380px;
}

.search-input {
    width: 100%;
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    padding: 10px 18px 10px 42px;
    color: var(--text-main);
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
}

.search-input:focus {
    border-color: var(--primary);
    background: var(--bg-surface);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 18px;
    pointer-events: none;
}

/* Header Action Controls */
.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.icon-btn {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
    font-size: 18px;
    position: relative;
    transition: all 0.2s ease;
}

.icon-btn:hover {
    background: var(--border-hover);
    color: var(--primary);
    transform: translateY(-1px);
}

.icon-btn .badge-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: 50%;
    border: 2px solid var(--bg-surface);
}

/* Main Content Area */
.app-main {
    margin-left: var(--sidebar-width);
    margin-top: var(--header-height);
    flex-grow: 1;
    min-width: 0;
    width: 100%;
    max-width: calc(100vw - var(--sidebar-width));
    min-height: calc(100vh - var(--header-height));
    padding: 24px;
    transition: margin-left 0.25s ease;
    overflow-x: hidden;
}

/* Horizontal Swipe Carousel Utilities */
.carousel-container {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
}

.carousel-strip {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
}

/* Compact Hashtag Pill Chips */
.rx-hashtag-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    margin-top: 5px;
    height: 38px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    text-decoration: none !important;
    color: var(--text-main);
    flex-shrink: 0;
    white-space: nowrap;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.rx-hashtag-pill:hover {
    background: var(--bg-surface-elevated);
    border-color: var(--primary);
    transform: translateY(-1px);
    color: var(--text-main);
}

.rx-hashtag-pill .pill-badge {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
    flex-shrink: 0;
}

.rx-hashtag-pill .pill-title {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.2;
}

.rx-hashtag-pill .pill-count {
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 500;
    margin-left: 2px;
}

.app-main.feed-view {
    padding: 0;
    margin-top: 0;
    height: 100vh;
    min-height: 0 !important;
    overflow: hidden;
}

/* Mobile Bottom Navigation */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--bottom-nav-height);
    background: var(--bg-surface);
    border-top: 1px solid var(--border-color);
    z-index: 1000;
    justify-content: space-around;
    align-items: center;
    padding: 0 8px;
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 10px;
    font-weight: 600;
    gap: 3px;
    flex: 1;
    height: 100%;
    transition: color 0.2s ease;
}

.mobile-nav-item i {
    font-size: 20px;
}

.mobile-nav-item.active {
    color: var(--primary);
}

.mobile-create-btn {
    width: 44px;
    height: 32px;
    background: var(--primary-gradient);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff !important;
    font-size: 18px;
    box-shadow: 0 2px 10px rgba(254, 44, 85, 0.4);
}

/* UI Card Styles */
.rx-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-soft);
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.rx-card:hover {
    border-color: var(--border-hover);
}

.reel-grid-card {
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.2s ease, border-color 0.2s ease;
}

.reel-grid-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    border-color: var(--primary) !important;
}

.reel-grid-card:hover .hgi-play {
    transform: scale(1.15);
}

.rx-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
    border: none;
    outline: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.rx-btn-primary {
    background: var(--primary-gradient);
    color: #ffffff;
    box-shadow: var(--shadow-glow);
}
.rx-btn-primary:hover {
    opacity: 0.92;
    transform: translateY(-1px);
    color: #fff;
}

.rx-btn-outline {
    background: transparent;
    border: 1px solid var(--border-hover);
    color: var(--text-main);
}
.rx-btn-outline:hover {
    background: var(--bg-surface-elevated);
    border-color: var(--text-secondary);
    color: var(--text-main);
}

.rx-btn-secondary {
    background: var(--bg-surface-elevated);
    color: var(--text-main);
}
.rx-btn-secondary:hover {
    background: var(--border-hover);
}

/* Global Modals & Drawers */
.rx-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    z-index: 1050;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.rx-modal-backdrop.show {
    display: flex;
}

.rx-modal-content {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 460px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.6), 0 0 30px rgba(254, 44, 85, 0.12);
    animation: modalIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

#tab-btn-login, #tab-btn-register {
    background: transparent;
    color: var(--text-secondary);
    border: none;
    box-shadow: none;
}

#tab-btn-login.active, #tab-btn-register.active {
    background: var(--primary-gradient) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(254, 44, 85, 0.35) !important;
    border: none !important;
}

@keyframes modalIn {
    from { opacity: 0; transform: scale(0.95) translateY(10px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

/* Form Controls */
.rx-form-group {
    margin-bottom: 18px;
}
.rx-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
}
.rx-input, .rx-select, .rx-textarea {
    width: 100%;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    color: var(--text-main);
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.rx-input:focus, .rx-select:focus, .rx-textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

/* Dropdown User Menu */
.user-menu-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    width: 220px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 8px;
    box-shadow: var(--shadow-soft);
    display: none;
    z-index: 1010;
}
.user-menu-dropdown.show {
    display: block;
    animation: dropdownIn 0.2s ease;
}
@keyframes dropdownIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

.dropdown-item-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.15s ease;
}
.dropdown-item-link:hover {
    background: var(--bg-surface-elevated);
    color: var(--text-main);
}
.dropdown-item-link.text-danger:hover {
    background: rgba(254, 44, 85, 0.12);
    color: var(--primary);
}

/* Nav Pills Styling */
.nav-pills .rx-btn {
    border: 1px solid var(--border-color);
}
.nav-pills .rx-btn.active,
.nav-pills .show > .rx-btn {
    background: var(--primary-gradient) !important;
    color: #ffffff !important;
    border-color: transparent !important;
    box-shadow: var(--shadow-glow);
}

/* Universal Premium Pagination */
.pagination,
.pagination-premium {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    list-style: none;
    padding: 20px 0;
    margin: 0;
    flex-wrap: wrap;
}

.pagination .page-item,
.pagination-premium .page-item {
    margin: 0;
    list-style: none;
}

.pagination .page-link,
.pagination-premium .page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 16px;
    border-radius: var(--radius-md) !important;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    user-select: none;
}

.pagination .page-link:hover,
.pagination-premium .page-link:hover {
    background: var(--bg-surface);
    color: var(--primary);
    border-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(254, 44, 85, 0.2);
}

.pagination .page-item.active .page-link,
.pagination-premium .page-item.active .page-link {
    background: var(--primary-gradient) !important;
    color: #ffffff !important;
    border: 1px solid transparent !important;
    font-weight: 700;
    transform: scale(1.05);
    box-shadow: 0 4px 16px rgba(254, 44, 85, 0.45) !important;
}

.pagination .page-item.disabled .page-link,
.pagination-premium .page-item.disabled .page-link {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
    background: var(--bg-surface);
    border-color: var(--border-color);
    color: var(--text-muted);
    box-shadow: none;
    transform: none;
}

[data-theme="light"] .pagination .page-link,
[data-theme="light"] .pagination-premium .page-link {
    background: #ffffff;
    color: #4b5563;
    border-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .pagination .page-link:hover,
[data-theme="light"] .pagination-premium .page-link:hover {
    background: #ffffff;
    color: var(--primary);
    border-color: var(--primary-light);
    box-shadow: 0 4px 14px rgba(254, 44, 85, 0.15);
}

[data-theme="light"] .pagination .page-item.active .page-link,
[data-theme="light"] .pagination-premium .page-item.active .page-link {
    background: var(--primary-gradient) !important;
    color: #ffffff !important;
    border-color: transparent !important;
    box-shadow: 0 4px 16px rgba(254, 44, 85, 0.35) !important;
}

[data-theme="light"] .pagination .page-item.disabled .page-link,
[data-theme="light"] .pagination-premium .page-item.disabled .page-link {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.05);
    color: #9ca3af;
}

/* Tables in Modern UI */
.table {
    color: var(--text-main);
    border-color: var(--border-color);
}
.table > :not(caption) > * > * {
    background-color: transparent;
    color: var(--text-main);
    border-bottom-color: var(--border-color);
    padding: 14px 16px;
    vertical-align: middle;
}
.table-hover > tbody > tr:hover > * {
    background-color: var(--bg-surface-elevated);
    color: var(--text-main);
}

/* Responsive Media Queries */
.sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1040;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.sidebar-backdrop.show {
    opacity: 1;
    pointer-events: auto;
}

/* Desktop Web Layout: Feed view has 100vh full height and transparent floating header */
@media (min-width: 992px) {
    .app-header.feed-header-dynamic {
        background: transparent !important;
        border-bottom: none !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        pointer-events: none;
        padding: 24px 32px 0;
        height: auto;
    }
    .app-header.feed-header-dynamic .feed-top-tabs,
    .app-header.feed-header-dynamic .header-actions {
        pointer-events: auto;
    }
    .app-header.feed-header-dynamic .header-left {
        display: none !important;
    }
    .app-main.feed-view {
        margin-top: 0 !important;
        height: 100vh !important;
        margin-bottom: 0 !important;
    }
}

/* Mobile Layout: Header kept with sidebar toggle and centered filter tabs */
@media (max-width: 991px) {
    .app-sidebar {
        transform: translateX(-100%);
        z-index: 1050;
        box-shadow: var(--shadow-glow);
    }
    .app-sidebar.open {
        transform: translateX(0);
    }
    .app-header {
        left: 0;
        padding: 0 12px;
    }
    .app-header.feed-header-dynamic {
        background: var(--bg-surface) !important;
        border-bottom: 1px solid var(--border-color) !important;
        backdrop-filter: blur(16px) !important;
        -webkit-backdrop-filter: blur(16px) !important;
        left: 0 !important;
        height: var(--header-height) !important;
        padding: 0 10px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        z-index: 990 !important;
        pointer-events: auto !important;
    }
    .app-header.feed-header-dynamic .header-left {
        display: flex !important;
        align-items: center;
        gap: 6px;
    }
    .app-main {
        margin-left: 0;
        margin-bottom: var(--bottom-nav-height);
        padding: 16px;
        min-width: 0;
        width: 100%;
        max-width: 100vw;
        overflow-x: hidden;
    }
    .app-main.feed-view {
        padding: 0 !important;
        margin-left: 0 !important;
        margin-top: var(--header-height) !important;
        margin-bottom: var(--bottom-nav-height) !important;
        height: calc(100vh - var(--header-height) - var(--bottom-nav-height)) !important;
        height: calc(100dvh - var(--header-height) - var(--bottom-nav-height)) !important;
        max-height: calc(100dvh - var(--header-height) - var(--bottom-nav-height)) !important;
        min-height: 0 !important;
        flex-grow: 0 !important;
        flex-shrink: 0 !important;
        overflow: hidden !important;
    }
    .mobile-bottom-nav {
        display: flex;
    }
}

/* Chat & Messaging Responsive Layout */
.chat-container-card {
    height: calc(100vh - var(--header-height) - 48px);
    display: flex;
    overflow: hidden;
}

.chat-sidebar-col {
    width: 340px;
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    background: var(--bg-surface);
    flex-shrink: 0;
}

.chat-main-col {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    background: var(--bg-main);
    min-width: 0;
}

@media (max-width: 768px) {
    .app-header {
        padding: 0 10px;
        gap: 8px;
        max-width: 100vw;
        box-sizing: border-box;
    }
    .search-container {
        max-width: none;
        flex-grow: 1;
        min-width: 0;
    }
    .search-input {
        padding: 8px 12px 8px 34px;
        font-size: 13px;
    }
    .search-icon {
        left: 10px;
        font-size: 15px;
    }
    .header-actions {
        gap: 6px;
        flex-shrink: 0;
    }
    .icon-btn {
        width: 36px;
        height: 36px;
        font-size: 16px;
        flex-shrink: 0;
    }

    .app-main {
        padding: 12px 8px;
    }
}

@media (max-width: 576px) {
    .app-header {
        padding: 0 8px;
        gap: 6px;
    }
    .app-header .header-left a span {
        display: none !important;
    }
    .app-header .header-left {
        gap: 4px;
        flex-shrink: 0;
    }
    .app-header .header-actions {
        gap: 4px;
        flex-shrink: 0;
    }
    .app-header .header-actions .rx-btn {
        padding: 6px 10px !important;
        font-size: 12px !important;
        white-space: nowrap;
    }
    .app-header .header-actions .rx-btn span {
        display: none;
    }
    .search-input {
        padding: 6px 10px 6px 30px;
        font-size: 12px;
        height: 36px;
    }
    .search-icon {
        left: 8px;
        font-size: 14px;
    }
}

/* Mobile Chat Split */
@media (max-width: 768px) {
    .chat-container-card {
        height: calc(100vh - var(--header-height) - var(--bottom-nav-height) - 16px);
        border-radius: var(--radius-md) !important;
    }
    .chat-sidebar-col {
        width: 100%;
        border-right: none;
    }
    .chat-sidebar-col.d-mobile-none {
        display: none !important;
    }
    .chat-main-col.d-mobile-none {
        display: none !important;
    }
    .chat-main-col {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .app-header {
        padding: 0 8px;
        gap: 6px;
    }
    .search-input {
        padding: 7px 10px 7px 28px;
        font-size: 12px;
    }
    .search-icon {
        left: 8px;
        font-size: 14px;
    }
    .rx-card {
        padding: 16px;
    }
}

/* ==========================================================================
   ReelsX Custom Premium HTML5 Video Player
   ========================================================================== */
.rx-player-container {
    position: relative;
    width: 100%;
    background: #000000;
    border-radius: var(--radius-lg);
    overflow: hidden;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rx-player-container video {
    width: 100%;
    max-height: 580px;
    object-fit: contain;
    background: #000000;
    display: block;
    cursor: pointer;
}

.rx-player-overlay-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 32px;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 15;
}

.rx-player-container.paused .rx-player-overlay-center {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

.rx-player-overlay-center:hover {
    background: var(--primary);
    transform: translate(-50%, -50%) scale(1.1) !important;
}

.rx-player-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px 16px 12px;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.4) 60%, transparent 100%);
    display: flex;
    flex-direction: column;
    gap: 8px;
    opacity: 1;
    transition: opacity 0.3s ease;
    z-index: 20;
}

.rx-player-container.playing.hide-controls .rx-player-controls {
    opacity: 0;
    pointer-events: none;
}

/* Scrub Progress Bar */
.rx-player-progress-wrap {
    position: relative;
    width: 100%;
    height: 14px;
    display: flex;
    align-items: center;
    cursor: pointer;
}

.rx-player-progress-bar {
    position: relative;
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: var(--radius-full);
    transition: height 0.15s ease;
}

.rx-player-progress-wrap:hover .rx-player-progress-bar {
    height: 6px;
}

.rx-player-buffered-bar {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: rgba(255, 255, 255, 0.4);
    border-radius: var(--radius-full);
    width: 0%;
}

.rx-player-played-bar {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: var(--primary-gradient);
    border-radius: var(--radius-full);
    width: 0%;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.rx-player-scrub-thumb {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 0 6px rgba(0, 0, 0, 0.6);
    transform: scale(0);
    transition: transform 0.15s ease;
}

.rx-player-progress-wrap:hover .rx-player-scrub-thumb {
    transform: scale(1);
}

/* Bottom Controls Row */
.rx-player-actions-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.rx-player-btn {
    background: none;
    border: none;
    color: #ffffff;
    font-size: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    transition: all 0.15s ease;
    line-height: 1;
}

.rx-player-btn:hover {
    color: var(--primary);
    background: rgba(255, 255, 255, 0.1);
}

.rx-player-time {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    white-space: nowrap;
}

.rx-player-volume-group {
    display: flex;
    align-items: center;
    gap: 6px;
}

.rx-player-volume-slider {
    width: 0;
    opacity: 0;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    accent-color: var(--primary);
    cursor: pointer;
    transition: width 0.2s ease, opacity 0.2s ease;
}

.rx-player-volume-group:hover .rx-player-volume-slider {
    width: 60px;
    opacity: 1;
}

/* ==========================================================================
   Creator Studio — Mobile Web Style & Music Picker
   ========================================================================== */

/* Creator Studio Layout Container */
.creator-studio-wrap {
    max-width: 980px;
    margin: 0 auto;
    padding: 16px 12px 40px;
}

@media (min-width: 768px) {
    .creator-studio-wrap {
        padding: 24px 20px 60px;
    }
}

.creator-studio-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
}

.creator-studio-header {
    padding: 20px 24px 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.creator-studio-title {
    font-size: 20px;
    font-weight: 800;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.creator-studio-subtitle {
    font-size: 13px;
    color: var(--text-muted);
    margin: 4px 0 0;
}

.creator-studio-body {
    padding: 20px 16px;
}

@media (min-width: 768px) {
    .creator-studio-body {
        padding: 24px;
    }
}

/* Video Upload / Dropzone Component */
.creator-dropzone {
    border: 2px dashed var(--border-hover);
    border-radius: var(--radius-lg);
    background: var(--bg-surface-elevated);
    min-height: 420px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 28px 16px;
    text-align: center;
    cursor: pointer;
    position: relative;
    transition: all 0.25s ease;
    overflow: hidden;
}

.creator-dropzone:hover,
.creator-dropzone.dragover {
    border-color: var(--primary);
    background: rgba(254, 44, 85, 0.04);
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.creator-dropzone-icon {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    margin-bottom: 16px;
    transition: transform 0.25s ease;
}

.creator-dropzone:hover .creator-dropzone-icon {
    transform: scale(1.08);
}

/* Mobile Video Preview Box */
.creator-video-preview {
    position: relative;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
    border-radius: 18px;
    overflow: hidden;
    background: #000;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    aspect-ratio: 9/16;
    display: flex;
    align-items: center;
    justify-content: center;
}

.creator-video-preview video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.creator-video-overlay-info {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    pointer-events: none;
    z-index: 5;
}

.creator-video-badge {
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(8px);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.creator-video-change-btn {
    position: absolute;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 6;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(10px);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.creator-video-change-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* Hashtag Quick Select Pills */
.hashtag-pills-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.hashtag-pill {
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.15s ease;
    user-select: none;
}

.hashtag-pill:hover {
    color: var(--primary);
    border-color: var(--primary);
    background: var(--primary-light);
    transform: translateY(-1px);
}

/* Thumbnail Picker Box */
.thumbnail-preview-tile {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 10px 14px;
}

.thumbnail-preview-thumb {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    border: 1px solid var(--border-color);
    flex-shrink: 0;
}

/* Music Picker Component & Trigger Chip */
.fb-music-trigger-card {
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.fb-music-trigger-card:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 16px rgba(254, 44, 85, 0.08);
}

.fb-music-trigger-left {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex: 1;
}

.fb-music-trigger-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--primary-gradient);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(254, 44, 85, 0.25);
}

.fb-music-trigger-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fb-music-trigger-desc {
    font-size: 12px;
    color: var(--text-muted);
    margin: 2px 0 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Selected Music Chip on Uploader */
.fb-selected-music-card {
    background: linear-gradient(135deg, rgba(254, 44, 85, 0.08) 0%, rgba(37, 244, 238, 0.04) 100%);
    border: 1.5px solid rgba(254, 44, 85, 0.35);
    border-radius: var(--radius-md);
    padding: 10px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.fb-selected-music-cover {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.15);
    flex-shrink: 0;
}

.fb-music-mini-preview-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    cursor: pointer;
    flex-shrink: 0;
    transition: transform 0.15s ease;
}

.fb-music-mini-preview-btn:hover {
    transform: scale(1.1);
}

/* Music Modal / Sheet */
.fb-music-sheet-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(10px);
    z-index: 1060;
    display: none;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.fb-music-sheet-backdrop.active {
    display: flex;
    opacity: 1;
    align-items: flex-end;
    justify-content: center;
}

@media (min-width: 768px) {
    .fb-music-sheet-backdrop.active {
        align-items: center;
    }
}

.fb-music-sheet-dialog {
    background: var(--bg-surface);
    width: 100%;
    max-width: 580px;
    max-height: 88vh;
    max-height: 88dvh;
    display: flex;
    flex-direction: column;
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border-color);
    animation: fbSheetSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

@media (min-width: 768px) {
    .fb-music-sheet-dialog {
        border-radius: 24px;
        max-height: 82vh;
        box-shadow: var(--shadow-soft);
        animation: fbModalZoom 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    }
}

@keyframes fbSheetSlideUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

@keyframes fbModalZoom {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.fb-music-sheet-header {
    padding: 16px 20px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
    position: relative;
}

.fb-music-sheet-handle {
    width: 36px;
    height: 4px;
    border-radius: 2px;
    background: var(--border-hover);
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
}

@media (min-width: 768px) {
    .fb-music-sheet-handle {
        display: none;
    }
}

.fb-music-search-bar {
    padding: 12px 20px;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-surface);
}

.fb-music-search-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.fb-music-search-input-wrap i.search-icon {
    position: absolute;
    left: 14px;
    color: var(--text-muted);
    font-size: 18px;
    pointer-events: none;
}

.fb-music-search-input {
    width: 100%;
    padding: 10px 40px 10px 42px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    color: var(--text-main);
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
}

.fb-music-search-input:focus {
    border-color: var(--primary);
    background: var(--bg-surface-elevated);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.fb-music-search-clear {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 16px;
    cursor: pointer;
    display: none;
}

/* Category Filter Pills (Horizontal Scroll) */
.fb-music-cats-scroll {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    overflow-x: auto;
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
    scrollbar-width: none;
}

.fb-music-cats-scroll::-webkit-scrollbar {
    display: none;
}

.fb-music-cat-pill {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    cursor: pointer;
    transition: all 0.15s ease;
}

.fb-music-cat-pill.active,
.fb-music-cat-pill:hover {
    background: var(--primary-light);
    color: var(--primary);
    border-color: var(--primary);
}

/* Sound List Content Area */
.fb-music-list-scroll {
    flex: 1;
    overflow-y: auto;
    padding: 8px 12px 20px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-height: 280px;
}

/* Single Sound Item Row */
.fb-sound-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    background: transparent;
    transition: all 0.15s ease;
    cursor: pointer;
}

.fb-sound-row:hover {
    background: var(--bg-surface-elevated);
}

.fb-sound-row.is-selected {
    background: var(--primary-light);
    border: 1px solid var(--primary);
}

.fb-sound-left {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex: 1;
}

.fb-sound-cover-wrap {
    position: relative;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    overflow: hidden;
    background: var(--bg-surface-elevated);
    flex-shrink: 0;
    border: 1px solid var(--border-color);
}

.fb-sound-cover-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.fb-sound-cover-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 20px;
}

/* Equalizer Bars for Playing State */
.fb-sound-equalizer {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(2px);
    display: none;
    align-items: center;
    justify-content: center;
    gap: 3px;
}

.fb-sound-row.is-playing .fb-sound-equalizer {
    display: flex;
}

.fb-eq-bar {
    width: 3px;
    background: #fff;
    border-radius: 2px;
    animation: fbEqAnim 0.8s ease-in-out infinite alternate;
}

.fb-eq-bar:nth-child(1) { height: 10px; animation-delay: 0.1s; }
.fb-eq-bar:nth-child(2) { height: 18px; animation-delay: 0.3s; }
.fb-eq-bar:nth-child(3) { height: 12px; animation-delay: 0.2s; }
.fb-eq-bar:nth-child(4) { height: 16px; animation-delay: 0.4s; }

@keyframes fbEqAnim {
    0% { height: 4px; }
    100% { height: 22px; }
}

.fb-sound-info {
    min-width: 0;
    flex: 1;
}

.fb-sound-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fb-sound-meta {
    font-size: 12px;
    color: var(--text-muted);
    margin: 2px 0 0;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fb-sound-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.fb-sound-preview-toggle-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.fb-sound-preview-toggle-btn:hover {
    background: var(--primary-light);
    color: var(--primary);
    border-color: var(--primary);
    transform: scale(1.05);
}

.fb-sound-row.is-playing .fb-sound-preview-toggle-btn {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.fb-sound-use-action-btn {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    background: var(--primary-gradient);
    color: #fff;
    border: none;
    cursor: pointer;
    transition: all 0.15s ease;
}

.fb-sound-use-action-btn:hover {
    transform: scale(1.04);
    box-shadow: 0 4px 12px rgba(254, 44, 85, 0.35);
}

/* ==========================================================================
   ReelsX Premium Creator Profile Design System
   ========================================================================== */
.rx-profile-hero {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    position: relative;
    margin-bottom: 24px;
}

.rx-profile-cover {
    height: 180px;
    background: linear-gradient(135deg, #1f1225 0%, #111d2e 50%, #0d1b2a 100%);
    position: relative;
    overflow: hidden;
}

[data-theme="light"] .rx-profile-cover {
    background: linear-gradient(135deg, #ffe5ec 0%, #e0f4ff 50%, #f0f7ff 100%);
}

.rx-profile-cover::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 140%;
    height: 200%;
    background: radial-gradient(circle at 30% 30%, rgba(254, 44, 85, 0.25), transparent 45%),
                radial-gradient(circle at 80% 40%, rgba(37, 244, 238, 0.2), transparent 40%);
    pointer-events: none;
}

.rx-profile-cover-actions {
    position: absolute;
    top: 16px;
    right: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 5;
}

.rx-profile-body {
    padding: 0 28px 28px;
    position: relative;
}

.rx-profile-avatar-wrap {
    margin-top: -64px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 20px;
}

.rx-profile-avatar-box {
    position: relative;
    display: inline-block;
}

.rx-profile-avatar-img {
    width: 116px;
    height: 116px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--bg-surface);
    background: var(--bg-surface-elevated);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    display: block;
    transition: transform 0.25s ease;
}

.rx-profile-avatar-box:hover .rx-profile-avatar-img {
    transform: scale(1.03);
}

.rx-profile-verified-badge {
    position: absolute;
    bottom: 6px;
    right: 6px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--primary-gradient);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    border: 3px solid var(--bg-surface);
    box-shadow: 0 4px 10px rgba(254, 44, 85, 0.4);
}

.rx-profile-name {
    font-size: 26px;
    font-weight: 900;
    color: var(--text-main);
    letter-spacing: -0.5px;
    margin: 0;
    line-height: 1.2;
}

.rx-profile-handle-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.rx-profile-handle-chip:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-light);
}

.rx-profile-bio-box {
    background: var(--bg-surface-elevated);
    border-left: 3px solid var(--primary);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    padding: 12px 16px;
    margin: 16px 0;
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    max-width: 720px;
}

.rx-profile-stats-bar {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 32px;
    padding: 16px 0 0;
    border-top: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.rx-profile-stat-item {
    display: flex;
    align-items: baseline;
    gap: 6px;
    text-decoration: none;
    cursor: default;
}

.rx-profile-stat-value {
    font-size: 20px;
    font-weight: 800;
    color: var(--text-main);
    letter-spacing: -0.3px;
}

.rx-profile-stat-label {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
}

.rx-profile-tabs {
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 12px;
    margin-bottom: 20px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.rx-profile-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: var(--radius-full);
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    text-decoration: none;
}

.rx-profile-tab-btn:hover {
    color: var(--text-main);
    background: var(--bg-surface-elevated);
}

.rx-profile-tab-btn.active {
    background: var(--primary-gradient);
    color: #ffffff !important;
    box-shadow: var(--shadow-glow);
}

.rx-profile-tab-btn .tab-count {
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-size: 11px;
    background: rgba(255, 255, 255, 0.2);
}

.rx-profile-tab-btn:not(.active) .tab-count {
    background: var(--bg-surface-elevated);
    color: var(--text-muted);
    border: 1px solid var(--border-color);
}

@media (max-width: 768px) {
    .rx-profile-cover {
        height: 120px;
    }
    .rx-profile-body {
        padding: 0 16px 20px;
    }
    .rx-profile-avatar-wrap {
        margin-top: -44px;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 12px;
    }
    .rx-profile-avatar-img {
        width: 88px;
        height: 88px;
    }
    .rx-profile-name {
        font-size: 20px;
    }
    .rx-profile-stats-bar {
        justify-content: space-around;
        gap: 12px;
    }
    .rx-profile-stat-item {
        flex-direction: column;
        align-items: center;
        gap: 2px;
    }
    .rx-profile-stat-value {
        font-size: 16px;
    }
    .rx-profile-stat-label {
        font-size: 11px;
    }
    .rx-profile-tab-btn {
        padding: 8px 14px;
        font-size: 12px;
    }
}


