
/* MOBILE PROFILE TABS */
.mobile-profile-tabs {
    margin-bottom: 16px;
}

.profile-action-btn[href],
.mobile-menu-btn[href] {
    text-decoration: none;
}
.mobile-profile-tabs-nav {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    border: 1px solid #e2e8f0;
    border-radius: 5px;
    overflow: hidden;
    background: #f8fafc;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
}

.mobile-profile-tab-btn {
    appearance: none;
    border: none;
    border-right: 1px solid #e2e8f0;
    background: transparent;
    color: #475569;
    min-height: 46px;
    padding: 0 8px;
    font-size: .82rem;
    font-weight: 800;
    text-align: center;
    transition: all .2s ease;
}

.mobile-profile-tab-btn:last-child {
    border-right: none;
}

.mobile-profile-tab-btn.active {
    background: #ffffff;
    color: #4f46e5;
    box-shadow: inset 0 -2px 0 #4f46e5;
}

.mobile-profile-tab-panels {
    margin-top: 14px;
}

.mobile-profile-tab-panel {
    display: none;
}

.mobile-profile-tab-panel.active {
    display: block;
}

@media (max-width: 420px) {
    .mobile-profile-tab-btn {
        min-height: 44px;
        font-size: .74rem;
        padding: 0 4px;
    }
}

/* CREATOR STATS BAR */
.creator-stats-bar {
    position: relative;
    z-index: 35;
    margin: 0 auto;
    margin-top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-top: none;
    border-radius: 0 0 24px 24px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
    display: grid;
    grid-template-columns: 1fr 1px 1fr 1px 1fr 1px 1fr;
    overflow: hidden;
}

.creator-stat-item {
    min-height: 88px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 16px 10px;
    text-align: center;
    background: transparent;
}

.creator-stat-divider {
    width: 1px;
    background: linear-gradient(
        to bottom,
        transparent 10%,
        #e2e8f0 25%,
        #e2e8f0 75%,
        transparent 90%
    );
}

.creator-stat-value {
    font-size: 1.35rem;
    font-weight: 900;
    line-height: 1.1;
    color: #0f172a;
}

.creator-stat-label {
    margin-top: 6px;
    font-size: .76rem;
    font-weight: 800;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: .08em;
}

@media (max-width: 768px) {
    .creator-stats-bar {
        display: none;
    }

    .creator-stat-item {
        min-height: 72px;
        padding: 12px 8px;
    }

    .creator-stat-value {
        font-size: 1.02rem;
    }

    .creator-stat-label {
        font-size: .68rem;
    }

    .creator-stats-bar .creator-stat-item:nth-of-type(5),
    .creator-stats-bar .creator-stat-item:nth-of-type(7) {
        border-top: 1px solid #eef2f7;
    }
}

/* FEED SKELETON */
.feed-skeleton {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding-top: 6px;
}

.feed-skeleton.hidden {
    display: none;
}

.feed-skeleton-card {
    height: 160px;
    border-radius: 22px;
    background: linear-gradient(
        90deg,
        #f1f5f9 25%,
        #e2e8f0 37%,
        #f1f5f9 63%
    );
    background-size: 400% 100%;
    animation: profileSkeleton 1.25s ease infinite;
}

@keyframes profileSkeleton {
    0% { background-position: 100% 50%; }
    100% { background-position: 0 50%; }
}

/* PAGE */
.profile-page-wrapper {
    position: relative;
}

.profile-action-btn[href] {
    text-decoration: none;
}

.mobile-menu-btn[href] {
    text-decoration: none;
}

/* HERO */
.profile-hero {
    position: relative;
    min-height: 360px;
    background: #0f172a;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
    margin-bottom: 0;
    border-radius: 28px 28px 0 0;
}

.profile-cover {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transform: scale(1.02);
}

.profile-cover-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(15,23,42,0.10) 0%, rgba(15,23,42,0.35) 45%, rgba(15,23,42,0.88) 100%),
        linear-gradient(135deg, rgba(99,102,241,0.25) 0%, rgba(236,72,153,0.15) 100%);
}

.profile-badge-platinum {
    position: absolute;
    top: 18px;
    left: 18px;
    z-index: 30;
    display: inline-flex;
    align-items: center;
    padding: 10px 16px;
    border-radius: 999px;
    background: rgba(99, 102, 241, 0.88);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 30px rgba(79, 70, 229, .35);
}

/* HERO CONTENT */
.profile-hero-content {
    position: relative;
    min-height: 360px;
    display: flex;
    align-items: flex-end;
    gap: 24px;
    padding: 28px;
}

.profile-avatar-wrap {
    flex-shrink: 0;
    position: relative;
}

.profile-avatar-img {
    width: 140px;
    height: 140px;
    object-fit: cover;
    border-radius: 999px;
    border: 5px solid rgba(255,255,255,0.95);
    box-shadow: 0 18px 40px rgba(0,0,0,0.28);
    background: #fff;
    transition: transform .25s ease, box-shadow .25s ease;
}

.profile-avatar-img:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 22px 50px rgba(0,0,0,0.34);
}

.profile-main-info {
    width: 100%;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
}

.profile-identity {
    min-width: 0;
}

.profile-name {
    display: block;
    font-size: clamp(1.8rem, 3vw, 2.6rem);
    font-weight: 800;
    line-height: 1.05;
    color: #fff;
    text-decoration: none;
    text-shadow: 0 4px 20px rgba(0,0,0,.25);
    word-break: break-word;
}

.profile-handle {
    display: inline-block;
    margin-top: 6px;
    color: rgba(255,255,255,.82);
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
}

.profile-status-line {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 14px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255,255,255,0.14);
    border: 1px solid rgba(255,255,255,0.16);
    backdrop-filter: blur(10px);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    display: inline-block;
    box-shadow: 0 0 0 4px rgba(255,255,255,.08);
}

.status-dot.online { background: #22c55e; }
.status-dot.offline { background: #94a3b8; }

.status-text {
    font-size: .92rem;
    color: #fff;
    font-weight: 600;
}

.status-text.offline {
    color: rgba(255,255,255,.88);
}

/* DESKTOP ACTIONS */
.profile-desktop-actions {
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.profile-cover-actions {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 35;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    max-width: calc(100% - 40px);
}

.profile-cover-actions .profile-action-btn,
.profile-cover-actions .action-btn.follow {
    min-height: 44px;
    padding: 0 16px !important;
    border-radius: 999px !important;
    backdrop-filter: blur(10px);
}

.profile-action-btn,
.action-btn.follow {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    min-height: 46px;
    padding: 0 18px !important;
    border-radius: 999px !important;
    font-size: .92rem !important;
    font-weight: 700 !important;
    transition: all .22s ease !important;
    text-decoration: none !important;
    cursor: pointer !important;
    white-space: nowrap;
}

.action-btn.follow {
    background: #2563eb !important;
    border: 1px solid #2563eb !important;
    color: #fff !important;
    box-shadow: 0 12px 28px rgba(37,99,235,.25);
}

.action-btn.follow:hover {
    transform: translateY(-1px);
    background: #1d4ed8 !important;
    border-color: #1d4ed8 !important;
}

.profile-action-btn {
    border: 1px solid rgba(255,255,255,.22);
    background: rgba(255,255,255,.14);
    color: #fff;
    backdrop-filter: blur(10px);
}

.profile-action-btn:hover {
    transform: translateY(-1px);
    background: rgba(255,255,255,.2);
    border-color: rgba(255,255,255,.32);
}

.profile-action-btn.subscribe {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 12px 28px rgba(249,115,22,.28);
}

.profile-action-btn.subscribe:hover {
    filter: brightness(1.04);
}

.profile-action-btn.danger {
    background: rgba(239,68,68,.18);
    border-color: rgba(248,113,113,.25);
}

.profile-action-btn.notification-toggle-btn {
    min-width: 168px;
}

/* MOBILE ACTIONS */
.mobile-actions {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 40;
}

.mobile-actions-toggle {
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 999px;
    background: rgba(255,255,255,.18);
    color: #fff;
    font-size: 1.05rem;
    backdrop-filter: blur(12px);
    box-shadow: 0 10px 26px rgba(0,0,0,.18);
}

.mobile-actions-menu {
    position: absolute;
    top: 58px;
    right: 0;
    width: 290px;
    max-width: calc(100vw - 24px);
    border-radius: 20px;
    background: rgba(255,255,255,.96);
    border: 1px solid rgba(226,232,240,.9);
    box-shadow: 0 25px 60px rgba(15,23,42,.18);
    overflow: hidden;
    transform-origin: top right;
    transform: scale(.96);
    opacity: 0;
    transition: all .18s ease;
}

.mobile-actions-menu.show {
    transform: scale(1);
    opacity: 1;
}

.mobile-menu-inner {
    padding: 10px;
}

.mobile-menu-item,
.mobile-menu-btn {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 48px;
    padding: 12px 14px;
    border: none;
    border-radius: 14px;
    background: transparent;
    color: #0f172a;
    font-weight: 600;
    text-align: left;
}

.mobile-menu-btn:hover,
.mobile-menu-item:hover {
    background: #f8fafc;
}

.mobile-menu-btn.danger {
    color: #dc2626;
}

/* LAYOUT */
.profile-layout {
    display: grid;
    grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.profile-sidebar-col,
.profile-feed-col {
    min-width: 0;
}

/* CONTENT CARDS */
.content-card {
    background: linear-gradient(180deg, #ffffff 0%, #fcfcff 100%);
    border: 1px solid #e8ecf7;
    border-radius: 24px;
    box-shadow: 0 12px 35px rgba(15, 23, 42, 0.06);
    overflow: hidden;
}

.section-heading-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px;
    border-bottom: 1px solid #edf1f7;
    background: linear-gradient(180deg, #ffffff 0%, #fafbff 100%);
}

.section-title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -.01em;
}

.section-body {
    padding: 18px;
}

/* PINNED */
.pinned-post-shell {
    position: relative;
    border-radius: 24px;
    padding: 18px 16px 16px;
    background: linear-gradient(135deg, #fff7cc 0%, #fffef7 100%);
    border: 1px solid #fde68a;
    box-shadow: 0 12px 30px rgba(234,179,8,.12);
}

.pinned-post-label {
    position: absolute;
    top: -12px;
    left: 18px;
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, #f59e0b, #facc15);
    color: #fff;
    font-size: .82rem;
    font-weight: 800;
    box-shadow: 0 8px 22px rgba(245,158,11,.22);
}

.pinned-post-inner {
    margin-top: 8px;
}

/* FEED */
.postsList {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.feed-loader {
    text-align: center;
    color: #64748b;
    font-weight: 600;
    margin-top: 16px;
    min-height: 24px;
}

/* RESPONSIVE */
@media (max-width: 1280px) {
    .profile-cover-actions {
        top: 16px;
        right: 16px;
        gap: 8px;
    }

    .profile-cover-actions .profile-action-btn,
    .profile-cover-actions .action-btn.follow {
        min-height: 40px;
        font-size: .85rem !important;
        padding: 0 14px !important;
    }
}

@media (max-width: 1024px) {
    .profile-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .profile-hero {
        min-height: 340px;
        border-radius: 24px 24px 0 0;
    }

    .profile-hero-content {
        min-height: 340px;
        flex-direction: column;
        align-items: center;
        justify-content: flex-end;
        text-align: center;
        gap: 14px;
        padding: 22px 16px 20px;
    }

    .profile-main-info {
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }

    .profile-avatar-img {
        width: 112px;
        height: 112px;
        border-width: 4px;
    }

    .profile-name {
        font-size: 1.8rem;
    }

    .profile-handle {
        font-size: .96rem;
    }

    .profile-status-line {
        justify-content: center;
    }

    .section-heading-row,
    .section-body {
        padding-left: 14px;
        padding-right: 14px;
    }
}

/* SMALL FIXES */
.membership-popup-btn:hover {
    filter: brightness(1.03);
}