:root {
    --primary-color: #E3FC02;
    /* primary color alpha steps for borders/overlays */
    --primary-color-100: rgba(227, 252, 2, 1);
    --primary-color-75: rgba(227, 252, 2, 0.75);
    --primary-color-50: rgba(227, 252, 2, 0.5);
    --primary-color-25: rgba(227, 252, 2, 0.25);
    --primary-color-10: rgba(227, 252, 2, 0.10);
    --secondary-color: #B8D002;
    --accent-color: #ff6b6b;
    --success-color: #4ecdc4;
    --warning-color: #ffa726;
    --error-color: #ef5350;

    --bg-primary: #0a0a0a;
    --bg-secondary: #121212;
    --bg-tertiary: #1a1a1a;

    --card-bg: rgba(255, 255, 255, 0.08);
    --card-border: rgba(255, 255, 255, 0.05);

    --text-primary: #ffffff;
    --text-secondary: #b8b8b8;
    --text-muted: #777777;
    --text-dark: #000000;

    --border-color: rgba(255, 255, 255, 0.05);
    --border-radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    /* Added design tokens for improved layout scale */
    --shadow-xl: 0 12px 48px rgba(0, 0, 0, 0.6);
    --border-radius-lg: 24px;
    --border-radius-sm: 8px;
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
}

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

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.feed-video-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

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

@media (max-width: 900px) {
    .feed-video-grid {
        grid-template-columns: 1fr;
    }

    .video-col {
        margin-top: 2rem;
    }
}

.material-symbols-outlined {
    font-variation-settings:
    'FILL' 0,
    'wght' 400,
    'GRAD' 0,
    'opsz' 24
}

/* Message Boxes */
.success-box, .error-box {
    padding: 15px 20px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: var(--shadow-sm);
}

.success-box {
    background: rgba(78, 205, 196, 0.1);
    border: 1px solid var(--success-color);
    color: var(--success-color);
}

.success-box::before {
    content: "✅";
    font-size: 1.1em;
}

.error-box {
    background: rgba(239, 83, 80, 0.1);
    border: 1px solid var(--error-color);
    color: var(--error-color);
}

.error-box::before {
    content: "❌";
    font-size: 1.1em;
}

/* Profile Header & Banner */
.profile-header {
    /* position: relative; */
    background: var(--bg-tertiary);
    overflow-x: hidden;
    box-shadow: var(--shadow-lg);
    /* linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%); */
    /* make header full-bleed across the viewport while staying inside flow */
    /*left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw; */
    width: 100%;
    /*border-top: 1px solid var(--primary-color-50);
    border-bottom: 1px solid var(--primary-color-50);*/
    padding: 1.5rem 2rem;
}

.profile-header-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.profile-banner {
    height: 200px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.profile-info {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: auto;
    flex-wrap: nowrap;
    position: relative;
    margin-bottom: 10px;
}

hr {
    color: var(--border-color);
    border-top: 1px solid var(--border-color);
    height: 0.5px;
    margin-top: 10px;
    margin-bottom: 10px;
}

.profile-info-left {
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.profile-identity {
    display: flex;
    flex-direction: column;
    min-width: 300px;
    max-width: 100%;
}

.profile-text-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1;
    min-width: 0;
}

.profile-actions a {
   text-decoration: none;
   background-color: var(--primary-color);
   color: var(--text-primary);
   padding: 10px 20px;
   border-radius: 5px;
   font-weight: bold;
   transition: background-color 0.3s;
}

.profile-actions a:hover {
   background-color: var(--secondary-color);
}

.username_text {
    color: var(--primary-color);
    align-items: center;
    font-size: 1.2em;
    font-weight: bold;
    line-height: 1.1;
}

.username_text::before {
    color: var(--primary-color);
    left: 0%;
    top: 0%;
    position: relative;
    content: '@';
    align-items: center;
}

.tiktok_text {
    color: var(--primary-color);
    align-items: center;
    font-size: 1.2em;
    font-weight: bold;
    line-height: 1.1;
}

.member_since {
    color: var(--primary-color);
}

/* Avatar Section */
.avatar-section {
    position: relative;
    flex-shrink: 0;
    margin-top: 0;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 3px solid var(--primary-color);
    box-shadow: var(--shadow-lg);
    object-fit: cover;
    background: var(--primary-color);
    transition: var(--transition);
}

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

.change-avatar-btn {
    position: absolute;
    bottom: 4px;
    right: 2px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-dark);
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    font-size: 16px; /* slightly smaller to fit common icons */
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: inline-flex; /* inline-flex keeps it flow-friendly while enabling centering */
    align-items: center;
    justify-content: center;
    padding: 0; /* ensure the icon sits exactly centered within the fixed width/height */
    line-height: 1; /* avoid font metrics shifting vertical alignment */
    font-weight: 700;
}

/* Ensure common icon types inside the button are block-level and sized to center properly */
.change-avatar-btn > img,
.change-avatar-btn > svg,
.change-avatar-btn > i,
.change-avatar-btn > .icon {
    display: block;
    width: 18px; /* tuned to match font-size; adjust if your icon is larger */
    height: 18px;
    margin: 0;
    line-height: 1;
}

.change-avatar-btn:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

/* Profile URL Section */
.profile-url-section {
    padding: 0.75rem 0;
    border-top: 1px solid var(--border-color);
    width: 100%;
    flex: 1;
}

.profile-url-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    white-space: nowrap;
    overflow: hidden;
    max-width: none;
}

.url-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    min-width: 30px;
    display: flex;
    align-items: center;
    justify-content: right;
}

.url-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
}

code.profile-url {
    pointer-events: none;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.profile-url {
    background: var(--bg-tertiary);
    color: var(--primary-color);
    padding: 0.4rem 0.6rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    border: 1px solid var(--border-color);
    flex: 1;
    word-break: break-all;
}

.copy-url-btn {
    background: var(--primary-color);
    color: var(--text-dark);
    border: none;
    padding: 0.4rem 0.6rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
}

.copy-url-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-1px);
}

.profile-handle-display {
    text-align: center;
    /* padding-top: 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1); */
}

.handle-text {
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    background: rgba(227, 252, 2, 0.1);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    display: inline-block;
}

/* #!SECTION: PROFILE PAGE
.profile-container {
   width: 90%;
   max-width: 1200px;
   margin: 2rem auto;
   padding: 2rem;
   background-color: var(--bg-secondary);
   border-radius: 8px;
} */

.profile-header h2 {
    margin: 0;
    color: var(--text-primary);
}

.profile-header p {
    margin: 0;
    color: var(--text-secondary);
}

/* Profile Details */


/* Header: left + right card layout */
.profile-header .profile-info {
    display: flex;
    gap: 18px;
    align-items: center;
    justify-content: space-between;
}

.profile-info-left {
    display: flex;
    gap: 12px;
    align-items: center;
    min-width: 0; /* allow text to truncate */
    flex: 1 1 auto;
}

.profile-avatar { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; }
.profile-identity .username_text { font-size: 1.25rem; font-weight: 700; display:block; }
.profile-identity .tiktok_text { display:block; font-size: 20px; color: var(--text-muted, #666); }
/*.membership-badge { display: block; font-size: 0.8rem; color: var(--text-muted, #666); } */
.name-row { display: inline-flex; align-items: center; gap: 8px;
 margin-bottom: 5px; }
.profile-identity .full-name { display: inline-block; color: var(--text-muted, #666); font-size: 0.95rem; margin-top: 4px; }
.edit-name-btn { margin-left: 4px; border: none; background: transparent; color: var(--text-muted, #666); cursor: pointer; font-size: 0.9rem; padding: 4px; border-radius: 6px; opacity: 0; transform: translateY(-2px) scale(0.98); transition: opacity 160ms ease, transform 160ms ease; }
.name-row:hover .edit-name-btn,
.name-row:focus-within .edit-name-btn,
.edit-name-btn:focus-visible {
    opacity: 1; transform: translateY(0) scale(1);
}
.edit-name-btn:hover { background: rgba(11,105,255,0.06); color: var(--text-primary, --primary-color); }
.edit-name-btn:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(11,105,255,0.12); }

.profile-card {
    background: var(--card-bg, #fff);
    border-radius: 10px;
    padding: 12px;
    border: 1px solid rgba(0,0,0,0.06);
    box-shadow: 0 6px 18px rgba(10,10,10,0.04);
    transition: transform 160ms cubic-bezier(.2,.9,.2,1), box-shadow 160ms cubic-bezier(.2,.9,.2,1);
    align-items: center;
    justify-content: center;
}

.profile-social-card .social-stats .stat-item {
    text-align: center;
    min-width: 64px;
}

.profile-social-card .stat-count {
    font-size: 1.1rem;
    font-weight: 700;
    display: block;
    color: var(--text-primary, #222);
}
.profile-social-card .stat-label {
    font-size: 0.8rem;
    color: var(--text-muted, #666);
}

.profile-card .follow-profile-btn {
    display: inline-flex;
    gap: 6px;
    align-items: center;
    border-radius: 8px;
    padding: 8px 10px;
    border: 1px solid rgba(0,0,0,0.06);
    background: var(--button-bg, #f7f7f9);
    color: var(--button-text, #111);
    text-decoration: none;
    transition: transform 120ms cubic-bezier(.2,.9,.2,1), box-shadow 120ms cubic-bezier(.2,.9,.2,1), background 120ms;
}

.profile-card .follow-profile-btn:hover,
    .profile-card .follow-profile-btn:focus-visible {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}
    .profile-card .follow-profile-btn:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(11,105,255,0.12); }

.profile-social-card .friends-preview { margin-top: 10px; gap: 6px; }
.profile-social-card .friends-preview a { display: inline-block; }
.profile-social-card .friends-more { color: var(--primary-color); margin-left: 6px; font-size: 0.85rem; }

/* small friend preview inside card (optional) */
.profile-social-card .friends-preview {
    display: flex;
    gap: 8px;
    margin-top: 8px;
    align-items: center;
}

.profile-social-card .friends-preview img { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }

.profile-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
    margin-top: 10px;
}

/* responsive: stack header on smaller screens */
@media (max-width: 900px) {

    .profile-info-right {
        width: 100%;
        max-width: none;
    }
    .profile-social-card .profile-actions { justify-content: space-between; }
    /* Always show the edit button on small screens for discoverability */
    .edit-name-btn { opacity: 1; transform: none; }
}

.profile-details {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0;
    width: 100%;
}

.profile-details h2 {
    margin: 0;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    line-height: 1.2;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.membership-badge {
    display: block;
    background: linear-gradient(135deg, var(--accent-color), var(--error-color));
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow:
        0 2px 8px rgba(255, 107, 107, 0.4),
        0 1px 4px rgba(239, 83, 80, 0.3),
        inset 0 1px 2px rgba(255, 255, 255, 0.2);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    white-space: nowrap;
    text-align: center;
    margin: 12px auto 0;
    width: fit-content;
}

.completion-badge {
    padding: 0.4rem 1rem;
    border-radius: 24px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 2px 6px rgba(0, 0, 0, 0.2),
        0 1px 3px rgba(0, 0, 0, 0.1),
        inset 0 1px 2px rgba(255, 255, 255, 0.15);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    white-space: nowrap;
}

/* Dynamic gradient that matches progress bar progression */
.completion-badge.dynamic {
    background: linear-gradient(45deg,
        var(--badge-start-color, var(--accent-color)),
        var(--badge-end-color, var(--warning-color)));
    color: var(--badge-text-color, white);
    box-shadow:
        0 2px 8px rgba(255, 107, 107, 0.3),
        0 1px 4px rgba(255, 167, 38, 0.2),
        inset 0 1px 2px rgba(255, 255, 255, 0.2);
}

/* Fallback styles for different completion levels */
.completion-badge.low {
    background: linear-gradient(45deg, #666, #888);
    color: var(--text-secondary);
    border: 1px solid var(--card-border);
}

.completion-badge.medium {
    background: linear-gradient(45deg, var(--accent-color), var(--warning-color));
    color: white;
    box-shadow:
        0 2px 8px rgba(255, 107, 107, 0.3),
        0 1px 4px rgba(255, 167, 38, 0.2),
        inset 0 1px 2px rgba(255, 255, 255, 0.15);
}

.completion-badge.high {
    background: linear-gradient(45deg, var(--warning-color), var(--primary-color));
    color: var(--bg-primary);
    box-shadow:
        0 2px 10px rgba(255, 167, 38, 0.4),
        0 1px 5px rgba(227, 252, 2, 0.3),
        inset 0 1px 2px rgba(255, 255, 255, 0.2);
}

.completion-badge.complete {
    background: linear-gradient(45deg, var(--success-color), var(--primary-color));
    color: var(--bg-primary);
    box-shadow:
        0 3px 12px rgba(78, 205, 196, 0.4),
        0 2px 6px rgba(227, 252, 2, 0.3),
        inset 0 1px 3px rgba(255, 255, 255, 0.25);
}

.profile-details h2 {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 1rem;
}

.highlight-status {
    background: var(--primary-color);
    transition: background 0.5s;
}

.streak-notification {
    background: #181818;
    border-left: 4px solid #ff9800;
    border-radius: 10px;
    margin: 12px 0 18px 0;
    padding: 18px 20px 16px 16px;
    box-shadow: 0 2px 8px 0 rgba(0,0,0,0.10);
    color: #fff;
    display: flex;
    align-items: flex-start;
    animation: streak-notif-pop 0.5s;
}

.streak-notification .notif-icon-container {
    margin-right: 16px;
    font-size: 2rem;
    flex-shrink: 0;
}
.streak-notification .notif-text {
    font-size: 1.05rem;
    line-height: 1.5;
}

.streak-notification .streak-count {
    color: #ffb300;
    font-weight: bold;
    display: block;
    margin: 6px 0 10px 0;
}

.streak-notification .streak-activate-btn {
    background: linear-gradient(90deg, #ff9800 60%, #ffb300 100%);
    color: #181818;
    border: none;
    border-radius: 5px;
    padding: 7px 22px;
    margin-top: 6px;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 1px 4px 0 rgba(0,0,0,0.10);
    transition: background 0.2s, color 0.2s;
}

.streak-notification .streak-activate-btn:hover:not(:disabled) {
    background: #fb8c00;
    color: #fff;
}

.streak-notification .streak-success-msg {
    margin-left: 12px;
    color: #22c55e;
    font-weight: bold;
}

@keyframes streak-notif-pop {
    0% { opacity: 0; transform: translateY(-20px) scale(0.95); }
    100% { opacity: 1; transform: none; }
}

.streak-fire-animate {
    animation: streak-fire-pop 1.2s cubic-bezier(.4, 2, .6, 1) both;
}

@keyframes streak-fire-pop {
    0% { transform: scale(1) rotate(-5deg); filter: drop-shadow(0 0 2px #FF9800); }
    20% { transform: scale(1.4) rotate(8deg); filter: drop-shadow(0 0 16px #FFD740); }
    40% { transform: scale(1.1) rotate(-8deg); filter: drop-shadow(0 0 8px #FF9800); }
    60% { transform: scale(1.3) rotate(5deg); filter: drop-shadow(0 0 12px #FFD740); }
    100% { transform: scale(1) rotate(0deg); filter: drop-shadow(0 0 2px #FF9800); }
}

.streak-reminder {
    display: flex;
    align-items: center;
    background: #2D1A00;
    color: #FFB300;
    border-radius: 6px;
    padding: 7px 12px;
    margin: 10px 0 6px 0;
    font-size: 1rem;
    font-weight: 500;
    box-shadow: 0 1px 4px 0 rgba(0, 0, 0, 0.10);
    gap: 8px;
    animation: streak-reminder-pulse 1.2s infinite alternate;
}

.streak-reminder .fa-clock {
    color: #FFB300;
    font-size: 1.2em;
    margin-right: 6px;
}

@keyframes streak-reminder-pulse {
    0% { background: #2D1A00; }
    100% { background: #4A2C00; }
}

.status-wrapper {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    width: 100%;
    margin: 0;
}

.status-message {
    display: inline-block;
    font-style: italic;
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-secondary);
    padding-top: 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(227, 252, 2, 0.1);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    margin: 0;
    line-height: 1.5;
}

.status-edit-btn {
    background: rgba(227, 252, 2, 0.1);
    border: 1px solid rgba(227, 252, 2, 0.3);
    color: var(--primary-color);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.status-edit-btn:hover {
    background: rgba(227, 252, 2, 0.2);
    border-color: var(--primary-color);
    transform: scale(1.1);
}

.status-edit-btn:active {
    transform: scale(0.95);
}

.status-input {
    display: inline-block;
    font-style: italic;
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-secondary);
    background: rgba(227, 252, 2, 0.15);
    border: 2px solid rgba(227, 252, 2, 0.4);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    margin: 0;
    line-height: 1.5;
    outline: none;
    width: 100%;
    max-width: 400px;
    transition: all 0.2s ease;
}

.status-input:focus-visible {
    background: rgba(227, 252, 2, 0.2);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(227, 252, 2, 0.1);
}

.status-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
    font-style: italic;
}

/* Emotion Dropdown Styles */
.emotion-dropdown {
    position: absolute;
    background: #181818;
    border: 1px solid #333;
    z-index: 1001;
    width: 260px;
    max-height: 240px;
    overflow-y: auto;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
    border-radius: 8px;
}
.emotion-dropdown .emotion-item {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    cursor: pointer;
    color: #fff;
    background: none;
    border: none;
    font-size: 1rem;
    transition: background 0.15s;
}
.emotion-dropdown .emotion-item.selected,
.emotion-dropdown .emotion-item:hover {
    background: #232323;
    color: var(--primary-color);
}
.emotion-dropdown .emotion-emoji {
    font-size: 1.3em;
    margin-right: 10px;
}
/* Location Autocomplete Dropdown Styles */
.location-autocomplete-dropdown {
    position: absolute;
    background: #181818;
    border: 1px solid #333;
    z-index: 1000;
    width: 100%;
    max-height: 220px;
    overflow-y: auto;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
    border-radius: 8px;
    margin-top: 2px;
}
.location-autocomplete-item {
    padding: 10px 14px;
    cursor: pointer;
    color: #fff;
    background: none;
    border: none;
    font-size: 1rem;
    transition: background 0.15s;
}
.location-autocomplete-item.selected,
.location-autocomplete-item:hover {
    background: #232323;
    color: var(--primary-color);
}

.profile-meta {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
    font-size: 0.85rem;
    color: var(--text-muted);
    width: 100%;
}

.profile-meta span {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* Profile Completion Bar */
.progress-container {
    display: flex;
    margin: var(--spacing-sm) 0 0 0;
    background: transparent;
    padding: clamp(5px, 2vw, 10px);
    gap: clamp(8px, 2vw, 12px);
    align-items: center;
}

.progress-bar-wrapper {
    flex: 1;
    min-width: 0; /* Allow flexbox to shrink below min-content */
}

.progress-percentage.level {
    font-size: clamp(11px, 2.5vw, 14px);
    font-weight: 600;
    color: #FFFFFF;
    min-width: clamp(35px, 8vw, 45px);
    text-align: right;
    text-shadow: 0px 2px 4px rgba(0, 0, 0, 0.3);
    filter: drop-shadow(0px 1px 2px rgba(0, 0, 0, 0.2));
    flex-shrink: 0;
}

.progress-percentage {
    font-size: clamp(11px, 2.5vw, 14px);
    font-weight: 700;
    color: var(--primary-color);
    min-width: clamp(35px, 8vw, 50px);
    text-align: right;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-shrink: 0;
}

.profile-completion-bar {
    background: rgba(255, 255, 255, 0.1);
    border-radius: clamp(12px, 3vw, 20px);
    height: clamp(10px, 2.5vw, 15px);
    position: relative;
    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.15),
        0 1px 3px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    transition: height 0.3s ease;
}

.completion-progress {
    background: linear-gradient(90deg, #ef5350, #ffa726, #4ecdc4, #E3FC02);
    height: 100%;
    border-radius: clamp(12px, 3vw, 20px);
    transition: width 0.5s ease, border-radius 0.3s ease;
    box-shadow:
        0 2px 12px rgba(227, 252, 2, 0.3),
        0 1px 6px rgba(78, 205, 196, 0.2),
        inset 0 1px 2px rgba(255, 255, 255, 0.2);
    position: relative;
}

/* Dynamic progress bar colors based on completion */
.completion-progress[style*="width: 1"] /* 0-19% */ {
    background: linear-gradient(90deg, #ef5350, #ff6b6b);
}

.completion-progress[style*="width: 2"],
.completion-progress[style*="width: 3"] /* 20-39% */ {
    background: linear-gradient(90deg, #ff6b6b, #ffa726);
}

.completion-progress[style*="width: 4"],
.completion-progress[style*="width: 5"] /* 40-59% */ {
    background: linear-gradient(90deg, #ffa726, #ffca28);
}

.completion-progress[style*="width: 6"],
.completion-progress[style*="width: 7"] /* 60-79% */ {
    background: linear-gradient(90deg, #ffca28, #4ecdc4);
}

.completion-progress[style*="width: 8"],
.completion-progress[style*="width: 9"] /* 80-99% */ {
    background: linear-gradient(90deg, #4ecdc4, #B8D002);
}

.completion-progress[style*="width: 100"] /* 100% */ {
    background: linear-gradient(90deg, #B8D002, #E3FC02);
    box-shadow:
        0 2px 12px rgba(227, 252, 2, 0.5),
        0 1px 6px rgba(184, 208, 2, 0.4),
        inset 0 1px 2px rgba(255, 255, 255, 0.3);
}

.completion-progress::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.15), transparent 50%, rgba(0, 0, 0, 0.1));
    border-radius: 20px;
}

.completion-text {
    font-size: 12px;
    margin-left: 0px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Profile Actions */
.profile-actions {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    flex-shrink: 0;
    align-self: center;
    min-width: 140px;
    padding-top: var(--spacing-xs);
}

.profile-actions a, .profile-actions button {
    padding: 0.75rem 1.75rem;
    border-radius: 12px;
    text-decoration: none;
    text-align: center;
    font-weight: 600;
    transition: var(--transition);
    border: 2px solid transparent;
    cursor: pointer;
    font-size: 0.9rem;
    background: var(--bg-secondary);
    white-space: nowrap;
    min-width: 160px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.edit-profile-btn {
    background: var(--bg-secondary);
    border-color: var(--success-color);
    color: var(--success-color);
    font-weight: 600;
    box-shadow: 0 0 16px rgba(78, 205, 196, 0.3), inset 0 0 16px rgba(78, 205, 196, 0.05);
}

.upload-btn {
    background: var(--bg-secondary);
    border-color: #0080ff;
    color: #0080ff;
    font-weight: 600;
    box-shadow: 0 0 16px rgba(0, 128, 255, 0.3), inset 0 0 16px rgba(0, 128, 255, 0.05);
}

.chat-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-color: transparent;
    color: var(--text-dark);
    font-weight: 700;
    box-shadow: var(--shadow-md);
}

.profile-actions a:hover, .profile-actions button:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.2);
}

.edit-profile-btn:hover {
    box-shadow: 0 0 24px rgba(78, 205, 196, 0.5), inset 0 0 24px rgba(78, 205, 196, 0.1);
    background: rgba(78, 205, 196, 0.1);
}

.upload-btn:hover {
    box-shadow: 0 0 24px rgba(0, 128, 255, 0.5), inset 0 0 24px rgba(0, 128, 255, 0.1);
    background: rgba(0, 128, 255, 0.1);
}

.chat-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: var(--shadow-lg);
}

/* Edit Form */
.edit-form {
    background: var(--card-bg);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    margin-bottom: 30px;
    border: 1px solid var(--card-border);
}

.edit-form h3 {
    margin-top: 0;
    color: var(--text-primary);
}

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

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-group input, .form-group textarea, .form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    transition: var(--transition);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    resize: none;
}

.form-group input:focus-visible, .form-group textarea:focus-visible, .form-group select:focus-visible {
    outline: none;
    border-color: var(--primary-color);
    resize: none;
}

.form-group small {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    color: var(--text-muted);
    font-style: italic;
}

.form-actions {
    display: flex;
    gap: 10px;
}

.form-actions button {
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
}

.form-actions button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.form-actions button:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(227, 252, 2, 0.3);
    transform: translateY(-2px);
}

.form-actions button[type="submit"] {
    background: var(--success-color);
    color: var(--text-primary);
}

.form-actions button[type="button"] {
    background: var(--text-muted);
    color: var(--text-primary);
}

/* Stats Dashboard */
.stats-dashboard {
    margin-bottom: var(--spacing-xl);
    background: var(--card-bg);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
}

.stats-dashboard h3 {
    margin: 0 0 var(--spacing-md) 0;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: var(--spacing-md);
}

.stat-card {
    background: rgba(255, 255, 255, 0.02);
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-md);
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
}

.stat-card:hover {
    transform: translateY(-5px);
    border-color: rgba(227, 252, 2, 0.2);
}

.stat-icon {
    font-size: 40px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.stat-icon:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: var(--shadow-lg);
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -1px;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

/* Achievements Section */
.achievements-section {
    margin-bottom: var(--spacing-xl);
}

.achievements-card {
    background: var(--card-bg);
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
}

.achievements-card h3 {
    margin: 0 0 var(--spacing-md) 0;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.achievement-item {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(255, 107, 107, 0.1));
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    transition: var(--transition);
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.achievement-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(255, 215, 0, 0.2);
    border-color: rgba(255, 215, 0, 0.4);
}

.achievement-icon {
    font-size: 32px;
    width: 60px;
    height: 60px;
    border-radius: 12px;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
}

.achievement-info {
    flex: 1;
}

.achievement-name {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--text-primary);
    margin-bottom: 0.3rem;
}

.achievement-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
    line-height: 1.5;
}

.achievement-meta {
    display: flex;
    gap: var(--spacing-md);
    align-items: center;
}

.achievement-xp {
    font-size: 0.85rem;
    font-weight: 700;
    color: #FFD700;
    background: rgba(255, 215, 0, 0.1);
    padding: 4px 10px;
    border-radius: 12px;
    border: 1px solid rgba(255, 215, 0, 0.3);
}

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

/* Empty Achievements State */
.empty-achievements {
    text-align: center;
    padding: var(--spacing-xl) var(--spacing-lg);
    color: var(--text-secondary);
}

.empty-achievements .empty-icon {
    font-size: 64px;
    opacity: 0.3;
    margin-bottom: var(--spacing-md);
}

.empty-achievements p {
    font-size: 0.95rem;
    line-height: 1.6;
    max-width: 500px;
    margin: 0 auto;
}

/* Achievement Actions */
.achievement-actions {
    margin-top: var(--spacing-lg);
    text-align: center;
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--card-border);
}

.check-achievements-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--bg-primary);
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.check-achievements-btn:hover {
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.check-achievements-btn:active {
    transform: translateY(0);
}

.achievement-tabs {
    display: flex;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
    border-bottom: 1px solid var(--card-border);
    padding-bottom: var(--spacing-md);
}

.tab-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: var(--spacing-sm) var(--spacing-md);
    cursor: pointer;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
    border-bottom: 3px solid transparent;
    position: relative;
    top: 1px;
}

.tab-btn:hover {
    color: var(--text-primary);
}

.tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.achievement-tab {
    display: none;
    animation: fadeIn 0.3s ease-in;
}

.achievement-tab.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.potential-achievements-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.achievement-item.potential {
    background: linear-gradient(135deg, rgba(100, 100, 100, 0.15), rgba(80, 80, 80, 0.15));
    border-color: rgba(200, 200, 200, 0.1);
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1rem;
    gap: 0.5rem;
}

.achievement-item.potential .achievement-icon {
    background: linear-gradient(135deg, rgba(150, 150, 150, 0.5), rgba(120, 120, 120, 0.5));
    box-shadow: 0 4px 12px rgba(150, 150, 150, 0.15);
    width: 45px;
    height: 45px;
    font-size: 22px;
    flex-shrink: 0;
}

.achievement-item.potential .achievement-info {
    flex: 1;
    width: 100%;
    min-width: 0;
}

.achievement-item.potential .achievement-name {
    font-size: 0.9rem;
    margin-bottom: 0.15rem;
    line-height: 1.2;
}

.achievement-item.potential .achievement-desc {
    font-size: 0.75rem;
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.achievement-item.potential .progress-bar {
    margin: 0.2rem 0;
    height: 4px;
}

.achievement-item.potential .progress-text {
    font-size: 0.65rem;
    margin-top: 0.1rem;
}

.achievement-item.potential .achievement-meta {
    justify-content: center;
    margin-top: 0.2rem;
    flex-wrap: wrap;
    gap: 0.3rem;
}

.achievement-item.potential .achievement-xp {
    font-size: 0.75rem;
    padding: 2px 8px;
}

.achievement-item.potential:hover {
    box-shadow: 0 8px 20px rgba(150, 150, 150, 0.15);
    border-color: rgba(200, 200, 200, 0.2);
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    margin: 0.3rem 0;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 3px;
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: block;
    margin-top: 0.2rem;
}

/* Video Section Enhancements */
.video-section {
    padding: var(--spacing-sm);
    width: 100%;
    margin-bottom: var(--spacing-xl);
    background: var(--card-bg);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-lg);
    flex-wrap: wrap;
    gap: var(--spacing-md);
}

.section-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.video-controls {
    display: flex;
    gap: var(--spacing-sm);
}

.video-controls select {
    padding: 10px 16px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
}

.video-controls select:focus-visible {
    outline: none;
    border-color: var(--primary-color);
}

/* Video Gallery Grid */
.video-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--spacing-lg);
    margin-top: var(--spacing-lg);
    width: 100%;
    min-height: 100px;
}

/* Enhanced Video Cards */
.video-card.enhanced {
    position: relative;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
}

.video-card.enhanced:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-color);
}

.featured-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(45deg, var(--warning-color), var(--accent-color));
    color: var(--text-primary);
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    z-index: 2;
}

.video-container {
    position: relative;
    width: 100%;
    aspect-ratio: 9 / 16;
    overflow: hidden;
    background: var(--bg-tertiary);
}

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

.video-overlay {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-card:hover .video-overlay {
    opacity: 1;
}

.edit-video-btn, .delete-video-btn {
    background: rgba(0, 0, 0, 0.7);
    color: var(--text-primary);
    border: none;
    padding: 8px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    transition: var(--transition);
}

.edit-video-btn:hover {
    background: var(--secondary-color);
    color: var(--bg-primary);
}

.delete-video-btn:hover {
    background: var(--error-color);
}

.video-info {
    padding: var(--spacing-md);
}

.video-info h4 {
    margin: 0 0 8px 0;
    color: var(--text-primary);
    font-size: 1.05rem;
    font-weight: 700;
}

@supports (-webkit-line-clamp: 2) {
    .video-description {
        font-size: 14px;
        color: var(--text-secondary);
        margin-bottom: 15px;
        display: -webkit-box;
        line-clamp: 2;
        -webkit-line-clamp: 2; /* keep webkit for Safari */
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
}

@supports not (-webkit-line-clamp: 2) {
    .video-description {
        font-size: 14px;
        color: var(--text-secondary);
        margin-bottom: 15px;
        display: -webkit-box;
        line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
}

.video-description {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 15px;
    display: -webkit-box;
    /* Correct line clamp syntax with fallback */
    line-clamp: 2; /* Standard (currently experimental in some browsers) */
    -webkit-line-clamp: 2; /* WebKit specific */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-stats {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 10px;
    font-size: 12px;
    color: var(--text-muted);
}

.video-tags {
    margin-bottom: 15px;
}

.tag {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    margin-right: 5px;
    margin-bottom: 5px;
    display: inline-block;
    border: 1px solid var(--border-color);
}

.video-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.video-actions button {
    padding: 8px 15px;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: var(--transition);
}

.feature-btn {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.feature-btn.featured {
    background: linear-gradient(45deg, var(--warning-color), var(--accent-color));
    color: var(--text-primary);
}

.share-btn {
    background: var(--secondary-color);
    color: var(--bg-primary);
}

.video-actions button:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

/* No Videos Container */
.no-videos {
    grid-column: 1 / -1;
    width: 100%;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--card-border);
}

.empty-icon {
    font-size: 64px;
    margin-bottom: 20px;
    opacity: 0.5;
    color: var(--text-muted);
}

.empty-state h4 {
    color: var(--text-primary);
    margin-bottom: 10px;
}

.empty-state p {
    color: var(--text-secondary);
    margin-bottom: 25px;
}

.upload-first-btn {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--text-dark);
    padding: 18px 35px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    position: relative;
    overflow: hidden;
    border: 2px solid transparent;
    box-shadow:
        0 4px 15px rgba(227, 252, 2, 0.3),
        0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.upload-first-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.2) 20%,
        rgba(255, 255, 255, 0.5) 50%,
        rgba(255, 255, 255, 0.2) 80%,
        transparent 100%
    );
    transition: left 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

.upload-first-btn::after {
    content: '';
    position: absolute;
    inset: 2px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 46px;
    z-index: -1;
}

.upload-first-btn:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow:
        0 8px 25px rgba(227, 252, 2, 0.4),
        0 4px 15px rgba(0, 0, 0, 0.25),
        0 0 30px rgba(227, 252, 2, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.upload-first-btn:hover::before {
    left: 100%;
}

.upload-first-btn:active {
    transform: translateY(-2px) scale(0.98);
    transition: all 0.1s ease;
}

.upload-first-btn:focus-visible {
    outline: none;
    box-shadow:
        0 8px 25px rgba(227, 252, 2, 0.4),
        0 4px 15px rgba(0, 0, 0, 0.25),
        0 0 0 4px rgba(227, 252, 2, 0.2);
}

/* Pulse animation for extra attention */
.upload-first-btn {
    animation: uploadBtnPulse 3s ease-in-out infinite;
}

@keyframes uploadBtnPulse {
    0%, 100% {
        box-shadow:
            0 4px 15px rgba(227, 252, 2, 0.3),
            0 2px 8px rgba(0, 0, 0, 0.15);
    }
    50% {
        box-shadow:
            0 6px 20px rgba(227, 252, 2, 0.4),
            0 3px 12px rgba(0, 0, 0, 0.2),
            0 0 20px rgba(227, 252, 2, 0.15);
    }
}

.upload-first-btn:hover {
    animation: none; /* Stop pulse on hover */
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.share-link-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}
.share-link-container input[type="text"] {
    flex: 1 1 auto;
    padding: 0.6rem 1rem;
    border: 1.5px solid #d1d5db;
    border-radius: 6px;
    font-size: 1rem;
    background: #222222;
    color: #FFFFFF;
    outline: none;
    transition: border-color 0.2s;
    margin-right: 0.5rem;
    width: 100%;
}

.share-link-container input[type="text"]:focus-visible {
    border-color: var(--primary-color);
    background: #222222;
}

.copy-link-btn {
    padding: 0.6rem 1.1rem;
    background: #222222;
    color: var(--primary-color);
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.18s;
    display: flex;
    align-items: center;
    gap: 0.4em;
    box-shadow: 0 1px 4px rgba(79,140,255,0.08);
}

.copy-link-btn:hover, .copy-link-btn:focus-visible {
    background: #222222;
    color: #FFFFFF;
}

/* Share Modal Fixes */
.modal.share-modal {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.45);
    z-index: 9999 !important;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

.modal.share-modal .modal-content,
.modal.share-modal .share-modal-content {
    z-index: 10000 !important;
    position: relative;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25);
    max-width: 95vw;
    min-width: 320px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2rem 1.5rem;
    animation: modalSlideIn 0.2s cubic-bezier(.4,0,.2,1);
}

.modal.share-modal .close-btn {
    z-index: 10001 !important;
}

/*
.modal-content {
    background: var(--card-bg);
    margin: 5% auto;
    padding: 30px;
    border-radius: var(--border-radius);
    width: 90%;
    max-width: 600px;
    position: relative;
    animation: modalSlideIn 0.3s ease;
    border: 1px solid var(--card-border);
    box-shadow: var(--shadow-lg);
}
*/

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close {
    position: absolute;
    right: 15px;
    top: 15px;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-muted);
    transition: var(--transition);
}

.close:hover {
    color: var(--text-primary);
}

/* Level and Gamification Section */
.level-section {
    margin-bottom: var(--spacing-lg);
    background: var(--card-bg);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
}

.level-section h3 {
    margin: 0 0 var(--spacing-lg) 0;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.level-card {
    background: rgba(255, 255, 255, 0.02);
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    grid-template-columns: 1fr auto;
    gap: var(--spacing-xl);
    position: relative;
    overflow: hidden;
    flex-direction: column;
}

.level-card::before {
    content: '';
    position: absolute;
    top: -40px;
    right: -40px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(227, 252, 2, 0.07) 0%, transparent 70%);
    pointer-events: none;
}

.level-info {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.level-badge {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin: 0;
}

.level-number {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-dark);
    padding: 0.75rem 1.5rem;
    border-radius: 16px;
    font-weight: 800;
    font-size: 1.5rem;
    box-shadow: var(--shadow-md);
    letter-spacing: -0.5px;
}

.level-title {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.xp-info {
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.xp-container {
    display: flex;
    align-items: center;
    gap: clamp(8px, 2vw, var(--spacing-md));
    margin: 0;
    background: transparent;
}

.xp-bar {
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: clamp(16px, 3vw, 24px);
    height: clamp(12px, 2.5vw, 16px);
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4);
    flex: 1;
    transition: height 0.3s ease, border-radius 0.3s ease;
}

.xp-progress {
    background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
    height: 100%;
    border-radius: clamp(16px, 3vw, 24px);
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1), border-radius 0.3s ease;
    box-shadow: 0 0 16px rgba(227, 252, 2, 0.5);
    position: relative;
}

.xp-progress::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.2), transparent 50%, rgba(0, 0, 0, 0.1));
    border-radius: clamp(16px, 3vw, 20px);
}

.xp-text {
    font-size: clamp(12px, 2.5vw, 14px);
    color: var(--text-secondary);
    line-height: 1.4;
    font-weight: 500;
    flex-shrink: 0;
}

.rank-info {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    justify-content: center;
    min-width: 220px;
    padding: var(--spacing-lg);
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.rank-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
    margin: 0;
}

.rank-icon {
    font-size: 48px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.4));
}

.rank-text {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.contribution-score {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
    line-height: 1.4;
}

/* Social Features Section */
.social-section {
    margin-bottom: var(--spacing-xl);
    background: var(--card-bg);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
}

.social-section h3 {
    margin: 0 0 var(--spacing-md) 0;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.social-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: var(--spacing-md);
}

.social-card {
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.05);
    overflow: hidden;
    transition: var(--transition);
}
.social-card:hover {
    transform: translateY(-2px);
    border-color: rgba(227, 252, 2, 0.2);
}

.social-header {
    padding: 15px 20px;
    border-bottom: 1px solid var(--card-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.social-header h4 {
    margin: 0;
    color: var(--text-primary);
    font-size: 16px;
}

.manage-btn, .view-all-btn {
    background: var(--secondary-color);
    color: var(--bg-primary);
    padding: 12px 25px;
    border-radius: 15px;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    display: inline-block;
    text-align: center;
    line-height: 1;
    box-sizing: border-box;
    min-width: 60px;
}

.manage-btn:hover, .view-all-btn:hover {
    background: var(--primary-color);
    transform: translateY(-1px);
    text-decoration: none;
}

/* Friends List */
.friends-list {
    padding: 15px;
}

.friend-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--card-border);
}

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

.friend-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-color);
}

.friend-info {
    flex: 1;
}

.friend-name {
    font-weight: 500;
    color: var(--text-primary);
    font-size: 14px;
}

.friend-status {
    font-size: 12px;
    margin-top: 2px;
}

.friend-status.online {
    color: var(--success-color);
}

.friend-status.away {
    color: var(--warning-color);
}

.friend-status.busy {
    color: var(--accent-color);
}

.friend-status.invisible {
    color: var(--text-muted);
}

.empty-friends {
    text-align: center;
    color: var(--text-muted);
    padding: 20px;
    font-style: italic;
}

/* Recent Chats */
.chats-list {
    padding: 15px;
}

.chat-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--card-border);
    cursor: pointer;
    transition: var(--transition);
}

.chat-item:hover {
    background: var(--bg-tertiary);
    margin: 0 -15px;
    padding: 10px 15px;
}

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

.chat-item.unread {
    background: rgba(227, 252, 2, 0.05);
}

.chat-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--card-border);
}

.chat-info {
    flex: 1;
}

.chat-name {
    font-weight: 500;
    color: var(--text-primary);
    font-size: 14px;
    margin-bottom: 2px;
}

.chat-preview {
    color: var(--text-secondary);
    font-size: 12px;
    line-height: 1.3;
}

.chat-meta {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 5px;
}

.unread-badge {
    background: var(--accent-color);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
}

.chat-time {
    font-size: 11px;
    color: var(--text-muted);
}

.empty-chats {
    text-align: center;
    color: var(--text-muted);
    padding: 20px;
    font-style: italic;
}

/* Account Settings Section */
.settings-section {
    margin-bottom: var(--spacing-xl);
    background: var(--card-bg);
    padding: var(--spacing-xl);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
}

.settings-section h3 {
    margin: 0 0 var(--spacing-lg) 0;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: var(--spacing-lg);
}

.settings-card {
    background: rgba(255, 255, 255, 0.02);
    padding: var(--spacing-xl);
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.settings-card h4 {
    margin: 0 0 var(--spacing-lg) 0;
    color: var(--text-primary);
    font-size: 1.25rem;
    font-weight: 700;
}

/* Privacy Settings */
.setting-item {
    margin-bottom: 20px;
}

.setting-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    padding: 8px 0;
}

.setting-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    margin-right: 0;
    accent-color: var(--primary-color);
    flex-shrink: 0;
}

.setting-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.setting-label.dropdown-setting {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
}

.setting-content select {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    margin-top: 8px;
}

.setting-label select {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    margin-top: 5px;
}

.setting-name {
    font-weight: 500;
    color: var(--text-primary);
    font-size: 14px;
}

.setting-desc {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.save-settings-btn {
    background: var(--success-color);
    color: var(--text-primary);
    padding: 10px 20px;
    border: none;
    border-radius: 25px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
}

.save-settings-btn:hover {
    background: var(--primary-color);
    color: var(--bg-primary);
    transform: translateY(-2px);
}

/* Account Management */
.account-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.account-btn {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    padding: 12px 20px;
    border: 2px solid var(--card-border);
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    font-size: 14px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.account-btn:hover {
    background: var(--card-bg);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.account-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.account-btn.danger {
    border-color: var(--error-color);
    color: var(--error-color);
}

.account-btn.danger:hover {
    background: rgba(239, 83, 80, 0.1);
    border-color: var(--error-color);
}

/* Avatar Upload Section */
.avatar-upload-section {
    display: flex;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

.current-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 3px solid var(--primary-color);
    object-fit: cover;
    box-shadow: 0 4px 12px rgba(227, 252, 2, 0.2);
}

.avatar-upload-controls {
    flex: 1;
    min-width: 200px;
}

.upload-btn {
    padding: 12px 24px;
    background: rgba(227, 252, 2, 0.15);
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(227, 252, 2, 0.15);
}

.upload-btn:hover {
    background: rgba(227, 252, 2, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(227, 252, 2, 0.4);
    border-color: #E3FC02;
}

.upload-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(227, 252, 2, 0.2);
}

/* TikTok Status Info */
.tiktok-status-info {
    background: rgba(0, 242, 234, 0.05);
    border: 1px solid rgba(0, 242, 234, 0.2);
    border-radius: 8px;
    padding: 12px 16px;
    margin-top: 15px;
}

.tiktok-status-info p {
    margin: 0;
    font-size: 14px;
}

.tiktok-status-info strong {
    color: #00f2ea;
}

/* Connect Live Service Button */
.connect-live-service-btn {
    background: linear-gradient(135deg, #00f2ea 0%, #00d9d1 100%);
    color: #000;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 242, 234, 0.3);
}

.connect-live-service-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #00d9d1 0%, #00c0b9 100%);
    box-shadow: 0 4px 16px rgba(0, 242, 234, 0.4);
    transform: translateY(-1px);
}

.connect-live-service-btn:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 242, 234, 0.3);
}

.connect-live-service-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

#live-service-status {
    padding: 10px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.03);
}

#live-service-status p {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Form Groups in Settings Cards */
.settings-card .form-group {
    margin-bottom: 20px;
}

.settings-card .form-group:last-child {
    margin-bottom: 0;
}

.settings-card .form-group label {
    display: block;
    color: var(--text-primary);
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.settings-card .form-group input[type="text"],
.settings-card .form-group input[type="email"],
.settings-card .form-group textarea {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg-tertiary);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: all 0.3s ease;
    resize: none;
}

.settings-card .form-group input:focus-visible,
.settings-card .form-group textarea:focus-visible {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(227, 252, 2, 0.1);
}

.settings-card .form-group input:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.settings-card .form-group textarea {
    min-height: 100px;
    resize: none;
    font-family: inherit;
}

.settings-card .form-group small {
    display: block;
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-top: 6px;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    flex-wrap: wrap;
}

.form-actions .save-settings-btn {
    flex: 1;
    min-width: 150px;
}

.form-actions .account-btn {
    flex: 1;
    min-width: 150px;
    text-align: center;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Settings Page Specific Styles */
.settings-page-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.settings-page-header {
    margin-bottom: 2rem;
    text-align: center;
}

.settings-page-header h1 {
    color: var(--text-primary);
    font-size: 2rem;
    margin: 1rem 0 0.5rem 0;
    font-weight: 700;
}

.settings-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
    margin: 0;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 1rem;
    transition: var(--transition);
}

.back-link:hover {
    color: var(--secondary-color);
    transform: translateX(-4px);
}

.back-link i {
    font-size: 0.9rem;
}

/* Quick Actions Grid */
.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.quick-action-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius);
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
    text-align: center;
}

.quick-action-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--primary-color);
    transform: translateY(-4px);
}

.quick-action-card i {
    font-size: 2rem;
    color: var(--primary-color);
}

.quick-action-card span {
    font-weight: 500;
    font-size: 0.95rem;
}

.quick-action-card.logout-card:hover {
    border-color: var(--error-color);
}

.quick-action-card.logout-card i {
    color: var(--error-color);
}

.friends-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--card-border);
}

.tab-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 12px 20px;
    cursor: pointer;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    transition: var(--transition);
    font-weight: 500;
}

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

.tab-btn.active {
    color: var(--primary-color);
    background: var(--card-bg);
    border-bottom: 2px solid var(--primary-color);
}

#friends-content {
    min-height: 200px;
    color: var(--text-primary);
}

.loading {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

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

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

.form-group input {
    width: 100%;
    padding: 12px 16px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    color: var(--text-primary);
    font-size: 16px;
    transition: var(--transition);
}

.form-group input:focus-visible {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(227, 252, 2, 0.2);
}

.save-btn {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--text-dark);
    border: none;
    padding: 12px 24px;
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
    font-size: 16px;
}

.save-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.blocked-users-list {
    color: var(--text-primary);
    min-height: 150px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* NSFW Warning Modal Styles */
.nsfw-warning-modal .modal-content {
    max-width: 550px;
}

.nsfw-preview-container {
    position: relative;
    margin: 20px 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.nsfw-preview-container img {
    width: 100%;
    height: auto;
    display: block;
}

.warning-message {
    background: rgba(255, 167, 38, 0.1);
    padding: 15px;
    border-radius: 8px;
    border: 2px solid var(--warning-color);
    margin: 15px 0;
    animation: warningPulse 2s ease-in-out infinite;
}

.warning-message p {
    margin: 0;
}

.warning-message strong {
    color: var(--warning-color);
}

@keyframes warningPulse {
    0%, 100% {
        border-color: var(--warning-color);
        background: rgba(255, 167, 38, 0.1);
    }
    50% {
        border-color: rgba(255, 167, 38, 0.8);
        background: rgba(255, 167, 38, 0.15);
    }
}

.nsfw-warning-modal .secondary-btn {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.nsfw-warning-modal .secondary-btn:hover {
    background: var(--card-bg);
    border-color: var(--text-secondary);
    transform: translateY(-2px);
}

.nsfw-warning-modal .save-btn {
    padding: 12px 24px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.nsfw-warning-modal .save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 167, 38, 0.4);
}

/* Password Change Verification Styles */
.verification-info {
    background: rgba(227, 252, 2, 0.1);
    border: 1px solid rgba(227, 252, 2, 0.3);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    text-align: center;
}

.verification-info p {
    margin: 5px 0;
    color: var(--text-secondary);
}

.verification-info strong {
    color: var(--primary-color);
    font-family: monospace;
}

.form-actions {
    display: flex;
    gap: 10px;
    justify-content: space-between;
}

.secondary-btn {
    background: var(--bg-secondary);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    padding: 12px 20px;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 14px;
    transition: var(--transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.secondary-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.verification-note {
    text-align: center;
    margin-top: 15px;
    color: var(--text-muted);
    font-size: 0.9em;
}

/* Verification Code Input Styling */
input[name="verification_code"] {
    background: var(--bg-secondary) !important;
    border: 2px solid rgba(227, 252, 2, 0.3) !important;
    color: var(--primary-color) !important;
    font-weight: bold !important;
}

input[name="verification_code"]:focus-visible {
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 15px rgba(227, 252, 2, 0.3) !important;
}

/* Light mode theme variables (opt-in via data-theme="light" on <html> or a container) */
[data-theme="light"] {
    --bg-primary: #ffffff;
    --bg-secondary: #f7f7f7;
    --bg-tertiary: #f0f2f4;

    --text-primary: #111111;
    --text-secondary: #333333;
    --text-muted: #666666;
    --text-dark: #000000;

    --card-bg: rgba(0, 0, 0, 0.04);
    --card-border: rgba(0, 0, 0, 0.08);
    --border-color: rgba(0, 0, 0, 0.08);

    /* Subtle lighter shadows for light surfaces */
    --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 6px 14px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 10px 28px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 14px 44px rgba(0, 0, 0, 0.18);
}

@media (min-width: 300px) and (max-width: 740px) {
    .profile-info {
        display: flex;
        flex-direction: column;
        flex: 1;
        margin: 0 auto;
    }

    .profile-info-left {
        display: flex;
        flex-direction: column;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: center;
        vertical-align: middle;
        text-align: center;
        flex: 1;
        margin: 0 auto;
    }

    .profile-social-stats {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        vertical-align: middle;
        text-align: center;
        flex-wrap: wrap;
        min-width: 0;
        max-width: 100%;
        flex: 1;
        margin: 0 auto;
        margin-bottom: 0px;
    }

    .profile-info {
        flex-wrap: wrap;
        min-width: 0;
        max-width: 100%;
    }

    .profile-info-left,
    .profile-social-stats,
    .profile-identity {
        min-width: 0;
        max-width: 100%;
        box-sizing: border-box;
    }

    .profile-identity {
        align-items: center;
        text-align: center;
    }

    .avatar-section {
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0 auto;
    }

    .upload-first-btn {
        padding: 16px 28px;
        font-size: 1rem;
        border-radius: 40px;
    }

    .upload-first-btn::after {
        border-radius: 36px;
    }

    .upload-first-btn:hover {
        transform: translateY(-2px) scale(1.01);
    }

    .profile-text-wrapper {
        align-items: center;
        width: 100%;
    }

    .profile-details {
        align-items: center;
        text-align: center;
        width: 100%;
    }

    .profile-details h2 {
        justify-content: center;
        flex-wrap: wrap;
    }

    .mood-selector {
        gap: 0.25rem;
    }

    .mood-option {
        padding: 6px 12px;
        font-size: 0.85rem;
    }

    .stories-section {
        padding: 1rem;
    }

    .stories-container {
        display: flex;
        gap: 0.75rem;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        padding: 0.5rem 0;
        width: 100%;
    }

    .stories-container::-webkit-scrollbar {
        display: none;
    }

    .story-item,
    .add-story-card {
        min-width: 90px;
        width: 90px;
        height: 150px;
        flex-shrink: 0;
    }

    .add-story-btn {
        font-size: 0.85rem;
        padding: 8px 16px;
        white-space: nowrap;
    }

    .profile-url-display {
        flex-direction: row;
        gap: 0.75rem;
        align-items: stretch;
    }

    .url-container {
        flex-direction: row;
        gap: 0.5rem;
    }

    .profile-url {
        font-size: 0.8rem;
    }

    .video-gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
    }

    .social-stats {
        gap: 16px;
    }

    .stat-count {
        font-size: 18px;
    }

    .stat-label {
        font-size: 11px;
    }

    .profile-url-section {
        grid-column: 1 / -1;
        grid-row: 5;
        flex: 1;
        padding: 0.5rem 0;
    }

    .profile-url-display {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
        white-space: normal;
    }

    .profile-handle-display {
        order: -1;
        margin-bottom: 0.5rem;
    }

    .handle-text {
        font-size: 1rem;
        padding: 0.4rem 0.8rem;
    }

    .url-label {
        font-size: 0.85rem;
        justify-content: flex-start;
        min-width: auto;
    }

    .url-container {
        flex-direction: row;
        width: 100%;
    }

    .profile-url {
        font-size: 0.75rem;
        padding: 0.5rem;
        word-break: break-all;
        overflow-wrap: break-word;
        white-space: normal;
        min-width: 0;
    }

    .copy-url-btn {
        flex-shrink: 0;
        padding: 0.5rem 0.75rem;
        font-size: 0.85rem;
    }

    .settings-page-container {
        padding: 0 0.5rem;
    }

    .settings-page-header h1 {
        font-size: 1.5rem;
    }

    .settings-grid {
        grid-template-columns: 1fr;
    }

    .quick-actions-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: var(--spacing-md);
    }

    .section-header {
        flex-direction: column;
        align-items: stretch;
    }

    .video-controls {
        width: 100%;
    }

    .video-controls select {
        flex: 1;
    }

    .video-gallery {
        grid-template-columns: 1fr;
    }

    .level-card {
        grid-template-columns: 1fr;
        padding: var(--spacing-lg);
        text-align: center;
    }

    .rank-info {
        border-top: 1px solid var(--border-color);
        padding-top: var(--spacing-lg);
        min-width: 0;
    }

    .social-grid,
    .settings-grid {
        grid-template-columns: 1fr;
    }

    .level-card {
        flex-direction: column;
        padding: 20px;
        gap: 25px;
        align-items: stretch;
    }

    .level-info {
        width: 100%;
    }

    .level-badge {
        flex-direction: row;
        gap: 15px;
        justify-content: center;
        flex-wrap: wrap;
    }

    .level-number {
        font-size: 18px;
        padding: 8px 16px;
    }

    .level-title {
        font-size: 18px;
        text-align: center;
    }

    .xp-container {
        flex-direction: row;
        gap: clamp(10px, 2vw, 15px);
        align-items: center;
    }

    .xp-bar {
        flex: 1;
        height: clamp(10px, 2vw, 14px);
        border-radius: clamp(12px, 2.5vw, 18px);
    }

    .xp-progress {
        border-radius: clamp(12px, 2.5vw, 18px);
    }

    .xp-progress::after {
        border-radius: clamp(12px, 2.5vw, 18px);
    }

    .xp-text {
        font-size: clamp(11px, 2.2vw, 14px);
    }

    .rank-info {
        width: 100%;
        padding-top: 20px;
        border-top: 1px solid var(--card-border);
        min-width: auto;
    }

    .rank-badge {
        justify-content: center;
    }

    .social-grid {
        grid-template-columns: 1fr;
    }

    .level-card {
        flex-direction: column;
        text-align: center;
    }

    .social-grid {
        grid-template-columns: 1fr;
    }

    .settings-grid {
        grid-template-columns: 1fr;
    }

    .friend-item, .chat-item {
        padding: 12px 0;
    }

    .social-header {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }

    .form-actions {
        flex-direction: column;
    }

    .secondary-btn {
        text-align: center;
        justify-content: center;
    }
}

@media (min-width: 741px) and (max-width: 769px) {
        /* Removed conflicting column layout for .profile-info and .profile-social-stats */
        /* If you want to adjust button width for mobile, keep only the button rules below: */
        .follow-profile-btn,
        .follow-profile-btn.settings-btn {
                width: 100%;
                display: flex;
                align-items: center;
                text-align: center;
        }
}

@media (min-width: 741px) and (max-width: 899px) {
    .profile-info {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2rem;
    }

    .profile-identity {
        flex: 1 1 0;
        min-width: 0;
        display: flex;
        flex-direction: column;
        width: auto;
        max-width: 100%;
        flex-wrap: nowrap;
        justify-content: center;
        align-items: center;
    }

    .profile-info-left,
    .profile-info-right,
    .profile-social-stats {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        max-width: 100%;
        width: auto;
        flex-shrink: 0;
    }

    .stat-item {
        min-width: 0;
        max-width: 100%;
        box-sizing: border-box;
    }

    .social-stats {
        flex-wrap: wrap;
        width: 100%;
        gap: 16px;
    }
}

/* Responsive profile header layout */
@media (min-width: 900px) and (max-width: 1024px) {
    .profile-info {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
    }

    .stat-item {
        text-align: center;
        min-width: 0;
        max-width: 100%;
        box-sizing: border-box;
    }

    .social-stats {
        flex-wrap: wrap;
        width: 100%;
        gap: 10px;
        text-align: center;
    }

    .profile-info-left,
    .profile-social-stats {
        min-width: 0;
        max-width: 100%;
    }

    .profile-info-right {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: center;
        gap: 1.5rem;
        flex-wrap: wrap;
    }

    .profile-social-stats {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: center;
    }

    .social-stats {
        display: flex;
        flex-direction: row;
        gap: 20px;
    }

    .profile-actions {
        display: flex;
        justify-content: center;
    }

    .membership-badge {
        white-space: nowrap;
    }

    .profile-details {
        align-items: center;
        text-align: center;
        padding-right: 0;
    }

    .profile-details h2 {
        justify-content: center;
    }

    .stories-section {
        flex: 1 1 auto;
        width: 100%;
    }
}


/* Small mobile devices */
@media (max-width: 480px) {
    .video-gallery {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .achievements-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-sm);
    }

    .achievement-item {
        padding: var(--spacing-sm);
    }

    .achievement-icon {
        width: 50px;
        height: 50px;
        font-size: 24px;
    }

    .achievement-name {
        font-size: 0.95rem;
    }

    .achievement-desc {
        font-size: 0.85rem;
    }

    .achievements-card {
        padding: var(--spacing-md);
    }

    .share-popover {
        min-width: 240px;
        left: 50%;
        right: auto;
        transform: translateX(-50%) translateY(-10px);
    }

    .share-popover.active {
        transform: translateX(-50%) translateY(-5px);
    }

    .share-platforms {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }

    .share-platform-btn {
        padding: 10px 6px;
    }

    .share-platform-name {
        font-size: 11px;
    }

    /* XP bar responsive for small screens */
    .xp-container {
        gap: clamp(6px, 1.5vw, 10px);
    }

    .xp-bar {
        height: clamp(8px, 1.8vw, 10px);
        border-radius: clamp(10px, 2vw, 14px);
    }

    .xp-progress {
        border-radius: clamp(10px, 2vw, 14px);
    }

    .xp-progress::after {
        border-radius: clamp(10px, 2vw, 14px);
    }

    .xp-text {
        font-size: clamp(10px, 2vw, 12px);
    }
}

/* Extra small screens */
@media (max-width: 360px) {
    /* XP bar extra small screens */
    .xp-container {
        gap: 6px;
    }

    .xp-bar {
        height: 8px;
        border-radius: 10px;
        border-width: 1px;
    }

    .xp-progress {
        border-radius: 10px;
    }

    .xp-progress::after {
        border-radius: 10px;
    }

    .xp-text {
        font-size: 10px;
    }
}

/* Medium screen adjustments */
@media (max-width: 1024px) and (min-width: 769px) {
    .video-gallery {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: var(--spacing-lg);
    }
}

/* Accessibility: Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001s !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001s !important;
        scroll-behavior: auto !important;
    }

    /* Disable non-essential transforms on hover */
    .profile-avatar:hover,
    .stat-card:hover,
    .achievement-card:hover,
    .video-card.enhanced:hover,
    .social-card:hover,
    .profile-actions a:hover,
    .profile-actions button:hover,
    .edit-profile-btn:hover,
    .upload-btn:hover,
    .chat-btn:hover,
    .manage-btn:hover,
    .view-all-btn:hover,
    .check-achievements-btn:hover,
    .upload-first-btn:hover {
        transform: none !important;
        box-shadow: none !important;
    }

    /* Disable decorative pulses and slide/fade */
    .upload-first-btn,
    .modal-content,
    .modal-overlay {
        animation: none !important;
    }
}

/* Notification Toast Styles */
.notification-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transform: translateX(400px);
    transition: transform 0.3s ease;
    max-width: 400px;
    font-weight: 500;
    animation: slideIn 0.3s ease forwards;
}

@keyframes slideIn {
    to {
        transform: translateX(0);
    }
}

.notification-toast.success {
    background: var(--success-color);
    color: white;
}

.notification-toast.error {
    background: var(--error-color);
    color: white;
}

.notification-toast.warning {
    background: var(--warning-color);
    color: white;
}

.notification-toast.info {
    background: var(--primary-color);
    color: var(--text-dark);
}

.notification-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.notification-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

.notification-message {
    flex: 1;
}

.notification-close {
    background: none;
    border: none;
    color: inherit;
    font-size: 20px;
    cursor: pointer;
    opacity: 0.7;
    margin-left: auto;
    padding: 0 5px;
    transition: opacity 0.2s ease;
    flex-shrink: 0;
}

/* Share Popover Styles */
.share-popover {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    background: var(--bg-secondary);
    border: 1px solid var(--primary-color);
    border-radius: var(--border-radius);
    padding: 15px;
    min-width: 280px;
    box-shadow: var(--shadow-xl);
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    backdrop-filter: blur(10px);
}

.share-popover.active {
    opacity: 1;
    pointer-events: all;
    transform: translateX(-50%) translateY(-5px);
}

.share-popover::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 8px solid transparent;
    border-top-color: var(--primary-color);
}

.share-popover-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

.share-popover-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.share-popover-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.share-popover-close:hover {
    color: var(--text-primary);
}

.share-link-container {
    display: flex;
    gap: 8px;
    margin-bottom: 15px;
    padding: 10px;
    background: var(--bg-tertiary);
    border-radius: var(--border-radius-sm);
}

.share-link-input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 13px;
    outline: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.copy-share-link-btn {
    background: var(--primary-color);
    color: var(--bg-primary);
    border: none;
    padding: 6px 12px;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: var(--transition);
    white-space: nowrap;
}

.copy-share-link-btn:hover {
    background: var(--secondary-color);
    transform: scale(1.05);
}

.copy-share-link-btn.copied {
    background: var(--success-color);
}

.share-platforms {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.share-platform-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 12px 8px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    color: var(--text-primary);
}

.share-platform-btn:hover {
    transform: translateY(-3px);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.share-platform-icon {
    font-size: 24px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.share-platform-btn[data-platform="facebook"] .share-platform-icon {
    background: #1877F2;
    color: white;
}

.share-platform-btn[data-platform="twitter"] .share-platform-icon {
    background: #000000;
    color: white;
}

.share-platform-btn[data-platform="discord"] .share-platform-icon {
    background: #5865F2;
    color: white;
}

.share-platform-btn[data-platform="reddit"] .share-platform-icon {
    background: #FF4500;
    color: white;
}

.share-platform-btn[data-platform="linkedin"] .share-platform-icon {
    background: #0A66C2;
    color: white;
}

.share-platform-btn[data-platform="whatsapp"] .share-platform-icon {
    background: #25D366;
    color: white;
}

.share-platform-name {
    font-size: 12px;
    font-weight: 500;
}

.video-actions {
    position: relative;
}

.notification-close:hover {
    opacity: 1;
}

/* Login Prompt Section for Non-Logged-In Users */
.login-prompt-section {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: var(--spacing-lg);
    margin: var(--spacing-md) 0;
    text-align: center;
}

.login-prompt-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    flex-wrap: wrap;
}

.login-prompt-content i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.login-prompt-content p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
}

.login-prompt-content a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.login-prompt-content a:hover {
    text-decoration: underline;
    color: var(--secondary-color);
}

/* Settings Page Header */
.settings-page-header {
    text-align: center;
    padding: var(--spacing-xl) var(--spacing-md);
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    margin-bottom: var(--spacing-lg);
}

.settings-page-header h1 {
    font-size: 2rem;
    color: var(--text-primary);
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
}

.settings-page-header h1 i {
    color: var(--primary-color);
}

.settings-page-header p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
}

/* Active nav link styling */
.nav-links a.active {
    color: var(--primary-color);
    font-weight: 600;
}

/* ============================================
   PROFILE SOCIAL STATS AND FOLLOW BUTTON
   ============================================ */

.profile-social-stats {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 20px;
    padding: 12px 20px;
    background: var(--card-bg, rgba(255, 255, 255, 0.05));
    border-radius: 12px;
    border: 1px solid var(--border-color, #333);
    backdrop-filter: blur(10px);
    width: fit-content;
}

.social-stats {
    display: flex;
    gap: 32px;
    align-items: center;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.stat-count {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary, #fff);
}

.stat-label {
    font-size: 13px;
    color: var(--text-secondary, #888);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.follow-profile-btn {
    padding: 10px 28px;
    background: var(--primary-color, #444444);
    color: #FFFFFF;
    border: none;
    border-radius: 24px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    white-space: nowrap;
    text-align: center;
}

.follow-profile-btn:hover {
    background: var(--secondary-color, #ff1744);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(7, 7, 7, 7, 0.2);
}

.follow-profile-btn.following {
    background: transparent;
    color: var(--text-primary, #fff);
    border: 2px solid var(--border-color, #444);
}

.follow-profile-btn.following:hover {
    background: rgba(7, 7, 7, 0.1);
    border-color: var(--primary-color, #444444);
}

.follow-profile-btn i {
    font-size: 16px;
}

.follow-profile-btn.settings-btn {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.follow-profile-btn.settings-btn:hover {
    background: var(--card-bg);
    border-color: var(--primary-color);
}

/* ============================================
   ENHANCED STATUS SECTION
   ============================================ */

.enhanced-status-section {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    margin: 1.5rem 0;
    position: relative;
}

.status-composer {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.status-input-wrapper {
    position: relative;
}

.status-textarea {
    width: 100%;
    min-height: 100px;
    padding: 15px;
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
    resize: none;
    transition: var(--transition);
}

.status-textarea:focus-visible {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(227, 252, 2, 0.1);
}

.status-textarea::placeholder {
    color: var(--text-secondary);
}

.mood-selector {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    padding: 1rem 0;
}

.mood-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 8px 16px;
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: 20px;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.95rem;
}

.mood-option:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.mood-option.selected {
    background: var(--primary-color);
    color: var(--bg-primary);
    border-color: var(--primary-color);
}

.mood-icon {
    font-size: 1.2rem;
}

.status-extras {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem 0;
}

.feeling-selector,
.location-input {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.feeling-selector label,
.location-input label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.feeling-selector select,
.location-input input {
    padding: 10px 15px;
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: var(--transition);
}

.feeling-selector select:focus-visible,
.location-input input:focus-visible {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(227, 252, 2, 0.1);
}

.feeling-selector select option {
    padding: 8px;
}

/* Enhanced Status Composer Layout */
.status-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1em;
}

.status-tools {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.status-tool-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 6px;
    transition: var(--transition);
    font-size: 1.2rem;
}

.status-tool-btn:hover {
    background: var(--bg-primary);
    color: var(--primary-color);
}

#status-image-preview-wrapper img {
    display: block;
    margin-top: 0.5em;
    max-width: 100%;
    max-height: 200px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
}

/* Share Modal Always on Top */
.modal.share-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.45);
    z-index: 9999;
}

.modal.share-modal .modal-content {
    z-index: 10000;
    position: relative;
    background: rgba(0,0,0,0.45);
    border-radius: 10px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25);
    padding: 2em 1.5em;
    min-width: 320px;
    max-width: 95vw;
}

.post-status-btn {
    padding: 10px 24px;
    background: var(--primary-color);
    color: var(--bg-primary);
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    margin-left: auto;
}

.post-status-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.post-status-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ============================================
   STORIES/REELS SECTION
   ============================================ */

.stories-section {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    min-width: 280px;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}

.stories-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.stories-header h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
}

.add-story-btn {
    padding: 8px 16px;
    background: var(--primary-color);
    color: var(--bg-primary);
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.add-story-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.stories-container {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding: 1rem 0;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) var(--bg-tertiary);
}

.stories-container::-webkit-scrollbar {
    height: 8px;
}

.stories-container::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
    border-radius: 4px;
}

.stories-container::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

.story-item {
    min-width: 120px;
    height: 200px;
    position: relative;
    border-radius: 12px;
    cursor: pointer;
    border: 1px dashed var(--primary-color);
    transition: var(--transition);
}

.story-item:hover {
    transform: scale(1.05);
    border-color: var(--primary-color);
}

.story-item.viewed {
    opacity: 0.7;
    border: 1px dashed var(--text-secondary);
}

.story-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.story-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.7) 0%, transparent 40%, rgba(0,0,0,0.8) 100%);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1rem 0.75rem;
}

.story-user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.story-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid var(--primary-color);
}

.story-username {
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
}

.story-time {
    color: rgba(255,255,255,0.8);
    font-size: 0.75rem;
}

.add-story-card {
    min-width: 120px;
    height: 200px;
    background: var(--bg-tertiary);
    border: 2px dashed var(--border-color);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.add-story-card:hover {
    border-color: var(--primary-color);
    border: 1px dashed var(--primary-color);
    background: var(--bg-primary);
    transform: scale(1);
}

.add-story-icon {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.add-story-text {
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 600;
}

/* ============================================
   NOTIFICATION BELL FLOAT
   ============================================ */

.notification-bell-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
}

.notification-bell-btn {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    color: var(--bg-primary);
    border: none;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(227, 252, 2, 0.4);
    transition: var(--transition);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notification-bell-btn:hover {
    transform: scale(1.1) rotate(15deg);
    box-shadow: 0 6px 30px rgba(227, 252, 2, 0.6);
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff0050;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    border: 2px solid var(--bg-primary);
    animation: bounce 2s infinite;
}

.notification-panel {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 400px;
    max-height: 600px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    box-shadow: 0 10px 50px rgba(0,0,0,0.4);
    backdrop-filter: blur(10px);
    display: none;
    flex-direction: column;
    overflow: hidden;
    z-index: 1001;
}

.notification-panel.active {
    display: flex;
    animation: slideUpNotification 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.notification-tabs {
    display: flex;
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
}

.notification-tab {
    flex: 1;
    padding: 1rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    position: relative;
    transition: all 0.2s ease;
}

.notification-tab:hover {
    color: var(--text-primary);
    background: rgba(227, 252, 2, 0.05);
}

.notification-tab.active {
    color: var(--primary-color);
    background: rgba(227, 252, 2, 0.1);
}

.notification-tab.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-color);
}

.tab-badge {
    background: var(--accent-color);
    color: white;
    padding: 0.15rem 0.4rem;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 700;
    min-width: 18px;
    text-align: center;
}

.tab-content {
    display: none;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
}

.tab-content.active {
    display: flex;
}

@keyframes slideUpNotification {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notification-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-primary);
}

.notification-header h4 {
    color: var(--text-primary);
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0;
}

.mark-all-read-btn {
    background: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.4rem 0.9rem;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.mark-all-read-btn:hover {
    background: var(--primary-color);
    color: var(--bg-primary);
    transform: scale(1.05);
}

.notification-list {
    overflow-y: auto;
    max-height: 500px;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) var(--bg-tertiary);
}

.notification-list::-webkit-scrollbar {
    width: 6px;
}

.notification-list::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
}

.notification-list::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 3px;
}

.notification-list::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

.notification-item {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    gap: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

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

.notification-item:hover {
    background: var(--bg-primary);
    transform: translateX(-2px);
}

.notification-item.unread {
    background: rgba(227, 252, 2, 0.08);
}

.notification-item.unread::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--primary-color);
    box-shadow: 0 0 8px var(--primary-color);
}

.notification-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.3rem;
}

.notification-icon.friend-request {
    background: rgba(78, 205, 196, 0.15);
    color: #4ECDC4;
}

.notification-icon.message {
    background: rgba(227, 252, 2, 0.15);
    color: var(--primary-color);
}

.notification-icon.comment {
    background: rgba(255, 167, 38, 0.15);
    color: #FFA726;
}

.notification-icon.like {
    background: rgba(255, 107, 107, 0.15);
    color: #FF6B6B;
}

.notification-content {
    flex: 1;
    flex-shrink: 0;
}

.notification-text {
    color: var(--text-primary);
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.notification-time {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.notification-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.notification-action-btn {
    padding: 4px 12px;
    border: none;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.accept-btn {
    background: var(--primary-color);
    color: var(--bg-primary);
}

.accept-btn:hover {
    background: var(--secondary-color);
}

.decline-btn {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}

.decline-btn:hover {
    background: var(--error-color);
    color: white;
}

.empty-notifications {
    padding: 4rem 2rem;
    text-align: center;
    color: var(--text-secondary);
}

.empty-notifications i {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    color: var(--text-muted);
    opacity: 0.5;
}

.empty-notifications p {
    font-size: 0.95rem;
    margin: 0;
    line-height: 1.5;
}

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

.story-upload-modal.active {
    display: flex;
}

.story-upload-content {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.story-upload-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.story-upload-header h3 {
    color: var(--text-primary);
    margin: 0;
}

.close-modal-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
}

.close-modal-btn:hover {
    color: var(--error-color);
}

.story-preview {
    width: 100%;
    max-height: 400px;
    border-radius: 8px;
    margin-bottom: 1rem;
    object-fit: cover;
}

.story-form-fields {
    margin-bottom: 1rem;
}

.story-input-group {
    margin-bottom: 1rem;
}

.story-input-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.story-input-group label i {
    color: var(--primary-color);
}

.story-input {
    width: 100%;
    padding: 0.75rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: var(--transition);
}

.story-input:focus-visible {
    outline: none;
    border-color: var(--primary-color);
    background: var(--bg-primary);
}

.story-textarea {
    width: 100%;
    padding: 0.75rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.95rem;
    resize: none;
    min-height: 80px;
    font-family: inherit;
    transition: var(--transition);
}

.story-textarea:focus-visible {
    outline: none;
    border-color: var(--primary-color);
    background: var(--bg-primary);
}

.story-duration-info {
    background: var(--bg-tertiary);
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.story-upload-btn {
    width: 100%;
    padding: 12px;
    background: var(--primary-color);
    color: var(--bg-primary);
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.story-upload-btn:hover {
    background: var(--secondary-color);
}

/* ============================================
   TikTok Live Section Styles
   ============================================ */

.tiktok-live-section {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.tiktok-live-section.tiktok-live {
    background: linear-gradient(135deg, #ff0050 0%, #00f2ea 100%);
    border: none;
    box-shadow: 0 8px 32px rgba(255, 0, 80, 0.3);
}

.tiktok-live-section.tiktok-connected {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
}

.tiktok-live-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tiktok-live-section.tiktok-live::before {
    opacity: 1;
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.tiktok-live-content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.tiktok-status-indicator {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 8px 16px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 24px;
    backdrop-filter: blur(10px);
}

.tiktok-offline .tiktok-status-indicator {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    position: relative;
}

/* Live Indicator - Pulsing Red Dot */
.status-dot.live {
    background: #ff0000;
    box-shadow: 0 0 0 0 rgba(255, 0, 0, 0.7);
    animation: livePulse 2s infinite;
}

@keyframes livePulse {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 0, 0, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(255, 0, 0, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 0, 0, 0);
    }
}

/* Offline Indicator - Static Gray Dot */
.status-dot.offline {
    background: #6b7280;
}

/* Connected but offline - Blue dot */
.status-dot.connected {
    background: #00f2ea;
}

#tiktok-status-text {
    font-weight: 700;
    font-size: 0.9rem;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tiktok-offline #tiktok-status-text {
    color: var(--text-secondary);
}

.tiktok-live-info {
    flex: 1;
}

.live-title {
    color: white;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.live-title i {
    font-size: 1.5rem;
}

.tiktok-offline .live-title {
    color: var(--text-primary);
}

.live-meta {
    color: rgba(255, 255, 255, 0.95);
    font-size: 0.95rem;
    line-height: 1.5;
}

#tiktok-live-meta {
    margin-top: 0.5rem;
}

.tiktok-offline .live-meta {
    color: var(--text-secondary);
}

/* Live status text styles */
.tiktok-live-section.tiktok-live .live-title::before {
    content: '🔴 ';
    animation: blink 1.5s infinite;
}

.tiktok-live-section.tiktok-connected .live-title::before {
    content: '🔵 ';
}

.tiktok-live-section.tiktok-offline .live-title::before {
    content: '⚪ ';
}

/* Stream info display when live */
.stream-info {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-top: 1rem;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.stream-duration,
.stream-viewers {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: white;
}

.stream-duration i,
.stream-viewers i {
    font-size: 1.1rem;
    opacity: 0.9;
}

.stream-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.connect-tiktok-btn,
#tiktok-action-btn {
    padding: 12px 24px;
    background: white;
    color: #ff0050;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.tiktok-live .connect-tiktok-btn,
.tiktok-live #tiktok-action-btn {
    background: white;
    color: #ff0050;
}

.tiktok-connected .connect-tiktok-btn,
.tiktok-connected #tiktok-action-btn {
    background: white;
    color: #667eea;
}

.tiktok-offline .connect-tiktok-btn,
.tiktok-offline #tiktok-action-btn {
    background: var(--primary-color);
    color: var(--bg-primary);
}

.connect-tiktok-btn:hover,
#tiktok-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.tiktok-offline .connect-tiktok-btn:hover,
.tiktok-offline #tiktok-action-btn:hover {
    background: var(--secondary-color);
}

.connect-tiktok-btn i,
#tiktok-action-btn i {
    font-size: 1.1rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .tiktok-live-content {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }

    .tiktok-status-indicator {
        justify-content: center;
    }

    .stream-info {
        flex-direction: column;
        gap: 0.75rem;
        align-items: flex-start;
    }

    .connect-tiktok-btn,
    #tiktok-action-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Profile-specific styling for forum post list in social card */
#forum-profile-posts-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px;
    max-height: 420px;
    overflow-y: auto;
    box-sizing: border-box;
}

#forum-profile-posts-list .post-card {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 10px;
    border-radius: 8px;
    background: rgba(255,255,255,0.01);
    border: 1px solid rgba(255,255,255,0.03);
    transition: background 120ms ease, transform 120ms ease, border-color 120ms ease;
    margin: 0; /* override forum default margin in this compact layout */
    cursor: default;
}

#forum-profile-posts-list .post-card:hover {
    transform: translateY(-2px);
    background: rgba(255,255,255,0.02);
    border-color: rgba(227,252,2,0.12);
}

#forum-profile-posts-list .post-meta {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    min-width: 44px;
    gap: 10px;
}

#forum-profile-posts-list .post-meta .avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--card-bg, #222);
    border: 1px solid rgba(255,255,255,0.04);
}

#forum-profile-posts-list .thread-content {
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 100%;
}

#forum-profile-posts-list .thread-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--link-color);
    text-decoration: none;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#forum-profile-posts-list .thread-snippet {
    color: var(--text-secondary);
    font-size: 0.88rem;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

#forum-profile-posts-list .post-meta-extra {
    display: flex;
    gap: 8px;
    align-items: center;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

#forum-profile-posts-list .post-last-comment-preview {
    color: var(--text-secondary);
    font-size: 0.82rem;
    opacity: 0.95;
}

#forum-profile-posts-list .post-comments-count {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-weight: 600;
}

#forum-profile-posts-list time.post-time {
    color: var(--text-secondary);
    font-size: 0.78rem;
}

.forum-load-more-wrapper { /* make consistent across profile social cards */
    display: flex;
    justify-content: center;
    padding: 8px 0 0 0;
}

.loading {
    width: 25px;
    height: 25px;
    border: 5px solid var(--primary-color);
    border-radius: 50%;
    border-top-color: transparent;
    cursor: pointer;
    animation: load-spinner 1s linear infinite, load-glow 1.5s ease-in-out infinite alternate;
}

@keyframes load-spinner {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes load-glow {
    0% {
        box-shadow: 0 0 10px var(--primary-color), 0 0 20px var(--primary-color), 0 0 30px var(--primary-color), 0 0 40px var(--primary-color);
    }

    100% {
        box-shadow: 0 0 20px #444, 0 0 40px #444, 0 0 60px #444, 0 0 80px #444;
    }
}

/* Responsive: reduce avatar size and spacing on narrow screens */
@media (max-width: 520px) {
    #forum-profile-posts-list {
        padding: 8px;
        gap: 8px;
        max-height: 360px;
    }
    #forum-profile-posts-list .post-meta .avatar {
        width: 34px;
        height: 34px;
    }
    #forum-profile-posts-list .thread-title {
        font-size: 0.92rem;
    }
    #forum-profile-posts-list .thread-snippet {
        -webkit-line-clamp: 1;
        line-clamp: 1;
    }
}

/* Keyboard focus accessibility */
#forum-profile-posts-list .post-card:focus-within {
    outline: none;
    box-shadow: 0 0 0 3px rgba(227,252,2,0.08);
}

.profile-card:hover,
.profile-card:focus-within {
    transform: translateY(-6px);
    box-shadow: 0 12px 32px rgba(10,10,10,0.12);
}

/* Modal overlay for profile edits */
.modal-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.45);
    z-index: 5000;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease-out, visibility 0.3s ease-out;
}
.modal-overlay.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
/* Modal Styling for Enhanced Features */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    border: 1px solid var(--card-border);
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    animation: slideIn 0.3s ease-out;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--card-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--card-bg);
}

.modal-header h3 {
    color: var(--text-primary);
    margin: 0;
    font-size: 1.4em;
}

.close-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 24px;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: var(--transition);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.modal-body {
    padding: 20px;
    max-height: calc(80vh - 100px);
    overflow-y: auto;
}

.modal-overlay.open .modal-content {
    transform: scale(1) translateY(0);
    opacity: 1;
}
.modal-close{
    position: absolute;
    top: 10px;
    right: 10px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 8px;
    border-radius: 6px;
}

.modal-close:hover {
    color: var(--text-primary);
    background: rgba(227, 252, 2, 0.1);
}

.modal-close:focus-visible {
    outline: none;
    color: var(--text-primary);
    box-shadow: 0 0 0 2px var(--primary-color);
}
.modal-body h3 { margin-top: 0; }

.profile-bio {
    margin-top: 8px;
    padding-top: 8px;
    color: var(--text-muted, #666);
    font-size: 0.95rem;
    line-height: 1.35;
    display: -webkit-box;
    line-clamp: 3;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.profile-bio[aria-expanded="true"] {
    line-clamp: unset;
    -webkit-line-clamp: unset;
    max-height: none;
}

/* Ripple effect */
.profile-card .follow-profile-btn, .profile-card a.follow-profile-btn {
    position: relative;
    overflow: hidden;
}
.profile-card .follow-profile-btn .ripple,
.profile-card a.follow-profile-btn .ripple {
    position: absolute;
    border-radius: 50%;
    transform: scale(0);
    background: rgba(255,255,255,0.5);
    animation: ripple 600ms ease-out;
    pointer-events: none;
}
@keyframes ripple {
    to { transform: scale(4); opacity: 0; }
}

/* subtle hover background color */
.profile-card .follow-profile-btn:hover { background: rgba(10,120,70,0.06); border-color: rgba(88, 255, 11, 0.16); }
.profile-card .follow-profile-btn.following { background: rgba(10,120,70,0.06); border-color: rgba(88, 255, 11, 0.16); }

@media (max-width: 1024px) {
    .potential-achievements-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .achievement-tabs {
        gap: var(--spacing-sm);
        padding-bottom: var(--spacing-sm);
    }

    .tab-btn {
        padding: var(--spacing-xs) var(--spacing-sm);
        font-size: 0.9rem;
    }

    .potential-achievements-grid {
        grid-template-columns: 1fr;
    }

    .achievements-grid {
        grid-template-columns: 1fr;
    }

    .achievement-item {
        flex-direction: row;
        align-items: flex-start;
        gap: var(--spacing-sm);
    }

    .achievement-item.potential {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .achievement-icon {
        width: 50px;
        height: 50px;
        font-size: 24px;
    }

    .achievement-meta {
        flex-wrap: wrap;
        gap: var(--spacing-sm);
        justify-content: center;
    }
}