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

:root {
    --primary-color: #FF0050;
    --secondary-color: #00F2EA;
    --background-dark: #010101;
    --background-light: #111111;
    --text-primary: #FFFFFF;
    --text-secondary: #AAAAAA;
    --border-color: #333333;
    --success-color: #4CAF50;
    --error-color: #F44336;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--background-dark);
    color: var(--text-primary);
    overflow: hidden;
    height: 100vh;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, var(--background-light) 0%, var(--background-dark) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.loading-screen.fade-out {
    opacity: 0;
    transform: scale(1.1);
}

.loading-logo {
    width: 80px;
    height: 80px;
    margin-bottom: 24px;
    position: relative;
    animation: logoFloat 2s ease-in-out infinite;
}

.loading-logo::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    opacity: 0.2;
    animation: pulse 2s ease-in-out infinite;
    z-index: -1;
}

.loading-logo-icon {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    font-weight: bold;
    color: white;
    box-shadow: 0 8px 32px rgba(255, 0, 80, 0.3);
    animation: logoGlow 2s ease-in-out infinite alternate;
}

.loading-text {
    font-size: 24px;
    font-weight: 700;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
    animation: textShimmer 3s ease-in-out infinite;
}

.loading-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 32px;
    animation: fadeInOut 2s ease-in-out infinite;
}

.loading-dots {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.loading-dot {
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    animation: dotBounce 1.4s ease-in-out infinite both;
}

.loading-dot:nth-child(1) { animation-delay: -0.32s; }
.loading-dot:nth-child(2) { animation-delay: -0.16s; }
.loading-dot:nth-child(3) { animation-delay: 0; }

.loader {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 0, 80, 0.1);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    box-shadow: 0 0 20px rgba(255, 0, 80, 0.3);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

@keyframes logoGlow {
    0% { box-shadow: 0 8px 32px rgba(255, 0, 80, 0.3); }
    100% { box-shadow: 0 12px 48px rgba(255, 0, 80, 0.5); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.2; }
    50% { transform: scale(1.1); opacity: 0.1; }
}

@keyframes textShimmer {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

@keyframes fadeInOut {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

@keyframes dotBounce {
    0%, 80%, 100% { 
        transform: scale(0.8);
        opacity: 0.5;
    }
    40% { 
        transform: scale(1.2);
        opacity: 1;
    }
}

/* App Container */
.app-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
    max-width: 480px;
    margin: 0 auto;
    background: var(--background-dark);
    position: relative;
}

/* Main Content */
.main-content {
    flex: 1;
    position: relative;
    overflow: hidden;
}

/* Pages */
.page {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transform: translateX(100%);
    transition: all 0.3s ease;
}

.page.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

/* Home Page - Video Feed */
.video-feed {
    height: 100%;
    scroll-snap-type: y mandatory;
    overflow-y: scroll;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.video-feed::-webkit-scrollbar {
    display: none;
}

.video-container {
    height: calc(100vh - 70px);
    scroll-snap-align: start;
    position: relative;
    background: var(--background-light);
}

.video-card {
    position: relative;
    height: calc(100vh - 70px);
    width: 100%;
}

.video-card video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: var(--background-dark);
}

/* Video Overlay */
.video-overlay {
    position: absolute;
    bottom: 20px;
    left: 15px;
    right: 80px;
    z-index: 10;
    color: white;
}

.video-info {
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.video-info .user-info {
    margin-bottom: 8px;
}

.video-info .user-info strong {
    color: white;
    font-weight: 700;
    font-size: 18px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.video-info .caption {
    margin: 8px 0;
    font-size: 15px;
    line-height: 1.4;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.video-music {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.video-music svg {
    width: 16px;
    height: 16px;
}

/* Video Actions */
.video-actions {
    position: absolute;
    bottom: 100px;
    right: 15px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

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

.profile-link {
    position: relative;
    display: block;
}

.profile-pic {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid white;
    background: var(--background-light);
}

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

.add-icon {
    position: absolute;
    bottom: -5px;
    right: -5px;
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--background-dark);
}

.add-icon svg {
    width: 12px;
    height: 12px;
    fill: white;
}

.like-btn, .comment-btn, .audio-btn {
    background: rgba(0, 0, 0, 0.3);
    border: none;
    cursor: pointer;
    padding: 12px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    transition: transform 0.2s ease, background 0.2s ease;
    min-width: 48px;
    min-height: 48px;
    backdrop-filter: blur(10px);
}

.like-btn:hover, .comment-btn:hover, .audio-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.like-btn.liked {
    background: rgba(255, 0, 80, 0.3);
    color: var(--primary-color);
}

.like-icon, .comment-icon, .audio-icon {
    font-size: 28px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

.like-count, .comment-count {
    font-size: 14px;
    font-weight: 600;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
    color: white;
}

/* Comments Section */
.comments-section {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.95), rgba(0,0,0,0.8));
    padding: 20px;
    border-radius: 20px 20px 0 0;
    max-height: 60vh;
    overflow-y: auto;
    backdrop-filter: blur(10px);
    z-index: 20;
}

.comments-list {
    margin-bottom: 15px;
    max-height: 200px;
    overflow-y: auto;
}

.comment {
    margin-bottom: 12px;
    padding: 8px 0;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.comment-header strong {
    color: white;
    font-size: 14px;
}

.comment-time {
    color: var(--text-secondary);
    font-size: 12px;
}

.comment-text {
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.3;
}

.no-comments {
    color: var(--text-secondary);
    font-size: 14px;
    text-align: center;
    padding: 20px;
}

.comment-input-container {
    display: flex;
    gap: 8px;
}

.comment-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 8px 15px;
    color: white;
    font-size: 14px;
}

.comment-input::placeholder {
    color: var(--text-secondary);
}

.comment-submit {
    background: var(--primary-color);
    border: none;
    border-radius: 20px;
    padding: 8px 15px;
    color: white;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
}

.comment-submit:hover {
    background: #ff1744;
}

.music-spin {
    width: 32px;
    height: 32px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: spin 3s linear infinite;
}

.music-icon {
    width: 20px;
    height: 20px;
    fill: white;
}

/* Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 480px;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 8px 0;
    z-index: 1000;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    color: var(--text-secondary);
    text-decoration: none;
    padding: 4px 12px;
    transition: color 0.2s ease;
    min-width: 44px;
}

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

.nav-icon {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.nav-item span {
    font-size: 10px;
    font-weight: 500;
}

.upload-btn {
    position: relative;
}

.upload-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(255, 0, 80, 0.3);
}

.upload-icon svg {
    width: 24px;
    height: 24px;
    fill: white;
}

/* Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--background-light);
    border-radius: 16px;
    width: 90%;
    max-width: 400px;
    max-height: 80vh;
    overflow: hidden;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal.active .modal-content {
    transform: scale(1);
}

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

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
}

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

.close-modal:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* Upload Form */
.upload-area {
    margin: 20px;
    border: 2px dashed var(--border-color);
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s ease;
}

.upload-area:hover {
    border-color: var(--primary-color);
}

.upload-preview {
    margin-top: 20px;
}

.upload-preview video {
    width: 100%;
    max-height: 300px;
    border-radius: 8px;
}

.form-group {
    margin: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: var(--background-dark);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 16px;
    transition: border-color 0.2s ease;
}

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

.upload-submit-btn,
.login-btn {
    width: calc(100% - 40px);
    margin: 20px;
    padding: 14px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.upload-submit-btn:hover,
.login-btn:hover {
    background: #E60047;
}

/* Enhanced Login/Register Modal */
.login-modal {
    text-align: center;
    max-height: 90vh;
    overflow-y: auto;
}

.login-header {
    padding: 40px 30px 20px;
}

.login-header h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 16px;
    margin-bottom: 8px;
}

.login-form-container {
    padding: 0 30px 20px;
}

.social-login {
    margin-bottom: 24px;
}

.social-login-title {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    position: relative;
}

.social-login-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 1px;
    background: var(--border-color);
    z-index: 1;
}

.social-login-title span {
    background: var(--background-light);
    padding: 0 16px;
    position: relative;
    z-index: 2;
}

.social-buttons {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
}

.social-btn {
    flex: 1;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--background-dark);
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
}

.social-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.social-btn-icon {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.divider {
    display: flex;
    align-items: center;
    margin: 24px 0;
    color: var(--text-secondary);
    font-size: 12px;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color);
}

.divider span {
    padding: 0 16px;
}

.form-group {
    margin-bottom: 16px;
    text-align: left;
}

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

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    background: var(--background-dark);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 16px;
    transition: all 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(255, 0, 80, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-secondary);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: 14px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-primary);
}

.remember-me input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary-color);
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.forgot-password:hover {
    opacity: 0.8;
}

.login-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 16px;
    position: relative;
    overflow: hidden;
}

.login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(255, 0, 80, 0.3);
}

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

.login-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.login-footer {
    padding: 20px 30px;
    border-top: 1px solid var(--border-color);
    font-size: 14px;
    color: var(--text-secondary);
}

.login-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.2s ease;
}

.login-footer a:hover {
    opacity: 0.8;
}

.password-input-container {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    font-size: 18px;
}

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

.error-message {
    background: rgba(244, 67, 54, 0.1);
    border: 1px solid var(--error-color);
    color: var(--error-color);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
    display: none;
}

.success-message {
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid var(--success-color);
    color: var(--success-color);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
    display: none;
}

/* Enhanced Discover Page */
.discover-header {
    padding: 20px;
    background: var(--background-light);
    border-bottom: 1px solid var(--border-color);
}

.discover-header h2 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 16px;
}

.search-container {
    position: relative;
    margin-bottom: 20px;
}

.search-bar {
    position: relative;
    margin-bottom: 12px;
}

.search-bar input {
    width: 100%;
    padding: 14px 20px 14px 48px;
    background: var(--background-dark);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    color: var(--text-primary);
    font-size: 16px;
    transition: all 0.2s ease;
}

.search-bar input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(255, 0, 80, 0.1);
}

.search-bar svg {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    fill: var(--text-secondary);
}

.search-clear {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    font-size: 16px;
    transition: all 0.2s ease;
    display: none;
}

.search-clear:hover {
    background: rgba(255, 255, 255, 0.1);
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--background-light);
    border: 1px solid var(--border-color);
    border-top: none;
    border-radius: 0 0 16px 16px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 100;
    display: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.search-suggestions.active {
    display: block;
}

.search-suggestion-item {
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: background 0.2s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.search-suggestion-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

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

.suggestion-icon {
    width: 32px;
    height: 32px;
    background: rgba(255, 0, 80, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.suggestion-info {
    flex: 1;
}

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

.suggestion-subtitle {
    font-size: 12px;
    color: var(--text-secondary);
}

.search-filters {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
    margin-bottom: 16px;
}

.search-filters::-webkit-scrollbar {
    height: 4px;
}

.search-filters::-webkit-scrollbar-track {
    background: var(--background-dark);
}

.search-filters::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 2px;
}

.filter-chip {
    padding: 6px 16px;
    background: var(--background-dark);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    color: var(--text-secondary);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
}

.filter-chip:hover {
    border-color: var(--primary-color);
    color: var(--text-primary);
}

.filter-chip.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.filter-chip-remove {
    font-size: 12px;
    cursor: pointer;
}

.search-results {
    display: grid;
    gap: 16px;
}

.search-results-header {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    padding: 0 4px;
}

.search-section {
    margin-bottom: 32px;
}

.search-section-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.search-section-count {
    font-size: 12px;
    color: var(--text-secondary);
    background: var(--background-dark);
    padding: 2px 8px;
    border-radius: 10px;
}

.user-search-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.user-search-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--background-light);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.user-search-item:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-1px);
}

.user-search-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.user-search-info {
    flex: 1;
}

.user-search-username {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.user-search-name {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.user-search-stats {
    font-size: 11px;
    color: var(--text-secondary);
}

.user-search-follow {
    font-size: 12px;
    color: var(--primary-color);
    cursor: pointer;
    padding: 4px 12px;
    border: 1px solid var(--primary-color);
    border-radius: 12px;
    transition: all 0.2s ease;
}

.user-search-follow:hover {
    background: var(--primary-color);
    color: white;
}

.hashtag-search-results {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hashtag-item {
    padding: 8px 16px;
    background: rgba(255, 0, 80, 0.1);
    border: 1px solid var(--primary-color);
    border-radius: 16px;
    color: var(--primary-color);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.hashtag-item:hover {
    background: var(--primary-color);
    color: white;
}

.video-search-results {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.video-search-item {
    position: relative;
    aspect-ratio: 9/16;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.video-search-item:hover {
    transform: scale(1.02);
}

.video-search-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-search-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, transparent 100%);
    padding: 8px;
    color: white;
}

.video-search-title {
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 4px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
}

.video-search-meta {
    font-size: 10px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
}

.search-no-results {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.search-no-results-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.search-no-results-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.search-no-results-text {
    font-size: 14px;
    margin-bottom: 20px;
}

/* Enhanced Notifications System */
.inbox-header {
    padding: 20px;
    background: var(--background-light);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.inbox-header h2 {
    font-size: 20px;
    font-weight: 600;
}

.inbox-actions {
    display: flex;
    gap: 8px;
}

.inbox-btn {
    padding: 6px 12px;
    background: var(--background-dark);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    color: var(--text-secondary);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

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

.inbox-content {
    height: calc(100vh - 140px);
    overflow-y: auto;
    background: var(--background-dark);
}

.notifications-list {
    padding: 0;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
    transition: background 0.2s ease;
    position: relative;
}

.notification-item:hover {
    background: rgba(255, 255, 255, 0.02);
}

.notification-item.unread {
    background: rgba(255, 0, 80, 0.05);
}

.notification-item.unread::before {
    content: '';
    position: absolute;
    left: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    background: var(--primary-color);
    border-radius: 50%;
}

.notification-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.notification-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
    background: rgba(255, 0, 80, 0.1);
}

.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-text {
    font-size: 14px;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 4px;
}

.notification-user {
    font-weight: 600;
    color: var(--primary-color);
}

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

.notification-action {
    padding: 4px 12px;
    background: rgba(255, 0, 80, 0.1);
    border: 1px solid var(--primary-color);
    border-radius: 12px;
    color: var(--primary-color);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.notification-action:hover {
    background: var(--primary-color);
    color: white;
}

.notifications-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.notifications-empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.notifications-empty-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.notifications-empty-text {
    font-size: 14px;
    margin-bottom: 20px;
}

.notifications-empty-btn {
    padding: 10px 20px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.notifications-empty-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(255, 0, 80, 0.3);
}

/* Notification Badge */
.notification-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--error-color);
    color: white;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 16px;
    text-align: center;
    animation: notificationPulse 2s infinite;
}

@keyframes notificationPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(244, 67, 54, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(244, 67, 54, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(244, 67, 54, 0);
    }
}

/* Real-time notification toast */
.realtime-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--background-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-width: 300px;
    max-width: 400px;
    z-index: 10000;
    animation: slideInRight 0.3s ease, slideOutRight 0.3s ease 2.7s forwards;
}

.realtime-notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
    background: rgba(255, 0, 80, 0.1);
    color: var(--primary-color);
}

.realtime-notification-content {
    flex: 1;
}

.realtime-notification-text {
    font-size: 14px;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.realtime-notification-time {
    font-size: 12px;
    color: var(--text-secondary);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

.trending-section {
    padding: 20px;
}

.trending-section h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
}

.trending-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.trending-item {
    position: relative;
    aspect-ratio: 9/16;
    border-radius: 8px;
    overflow: hidden;
    background: var(--background-light);
}

.trending-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.trending-info {
    position: absolute;
    bottom: 8px;
    left: 8px;
    right: 8px;
    color: white;
    font-size: 12px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
}

/* Enhanced Profile Page */
.profile-header {
    background: linear-gradient(135deg, var(--background-light) 0%, var(--background-dark) 100%);
    position: relative;
    overflow: hidden;
}

.profile-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255, 0, 80, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

.profile-cover {
    height: 120px;
    background: linear-gradient(135deg, rgba(255, 0, 80, 0.2) 0%, rgba(0, 242, 234, 0.2) 100%);
    position: relative;
    overflow: hidden;
}

.profile-cover::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
}

.profile-info {
    padding: 20px;
    position: relative;
    z-index: 1;
}

.profile-main-info {
    display: flex;
    align-items: flex-end;
    gap: 16px;
    margin-bottom: 20px;
    position: relative;
}

.profile-avatar-container {
    position: relative;
}

.profile-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--background-light);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    background: var(--background-dark);
}

.profile-status {
    position: absolute;
    bottom: 5px;
    right: 5px;
    width: 24px;
    height: 24px;
    background: var(--success-color);
    border: 3px solid var(--background-light);
    border-radius: 50%;
}

.profile-status.away {
    background: #FFA726;
}

.profile-status.offline {
    background: var(--text-secondary);
}

.profile-details {
    flex: 1;
    padding-bottom: 8px;
}

.profile-username {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.verified-badge {
    width: 20px;
    height: 20px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: white;
    font-weight: bold;
}

.profile-fullname {
    color: var(--text-secondary);
    font-size: 16px;
    margin-bottom: 8px;
}

.profile-bio {
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 12px;
}

.profile-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.profile-link {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.profile-link:hover {
    text-decoration: underline;
}

.profile-actions {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.profile-btn {
    flex: 1;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    text-align: center;
}

.profile-btn-primary {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.profile-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(255, 0, 80, 0.3);
}

.profile-btn-secondary {
    background: var(--background-dark);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

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

.profile-more-btn {
    width: 40px;
    height: 40px;
    background: var(--background-dark);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.profile-more-btn:hover {
    background: var(--border-color);
}

.profile-stats {
    display: flex;
    justify-content: space-around;
    padding: 20px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    background: var(--background-light);
}

.stat-item {
    text-align: center;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.stat-item:hover {
    transform: scale(1.05);
}

.stat-number {
    display: block;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 4px;
    color: var(--text-primary);
}

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

.profile-tabs {
    display: flex;
    background: var(--background-light);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 10;
}

.tab-btn {
    flex: 1;
    padding: 16px;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: all 0.2s ease;
    position: relative;
}

.tab-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.02);
}

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

.tab-btn .tab-icon {
    margin-right: 6px;
    font-size: 16px;
}

.profile-content {
    padding: 0;
    min-height: 400px;
}

.videos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
    background: var(--background-dark);
}

.videos-grid.hidden {
    display: none;
}

.video-item {
    position: relative;
    aspect-ratio: 9/16;
    background: var(--background-light);
    cursor: pointer;
    overflow: hidden;
    transition: transform 0.2s ease;
}

.video-item:hover {
    transform: scale(1.02);
    z-index: 1;
}

.video-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-item-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, transparent 100%);
    padding: 8px;
    color: white;
    opacity: 0;
    transition: opacity 0.2s ease;
}

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

.video-item-plays {
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
}

.video-item-likes {
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

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

.empty-state-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.empty-state-text {
    font-size: 14px;
    margin-bottom: 20px;
}

.empty-state-btn {
    padding: 10px 20px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.empty-state-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(255, 0, 80, 0.3);
}

/* Comments Modal */
.comments-modal {
    width: 100%;
    max-width: 100%;
    height: 60vh;
    max-height: 60vh;
    margin: 20vh auto;
}

.comments-container {
    display: flex;
    flex-direction: column;
    height: calc(100% - 60px);
}

.comments-list {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.comment-item {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}

.comment-content {
    flex: 1;
}

.comment-username {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
}

.comment-text {
    font-size: 14px;
    line-height: 1.4;
    margin-bottom: 4px;
}

.comment-time {
    font-size: 12px;
    color: var(--text-secondary);
}

.comment-form {
    padding: 16px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 12px;
}

.comment-form input {
    flex: 1;
    padding: 8px 12px;
    background: var(--background-dark);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    color: var(--text-primary);
    font-size: 14px;
}

.comment-form button {
    padding: 8px 16px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

/* Enhanced Responsive Design */

/* Tablet Styles (768px - 1023px) */
@media (min-width: 768px) {
    body {
        overflow: auto;
    }
    
    .app-container {
        max-width: 768px;
        height: 100vh;
        margin: 0 auto;
        box-shadow: 0 0 40px rgba(0, 0, 0, 0.3);
    }
    
    .bottom-nav {
        max-width: 768px;
    }
    
    /* Video feed adjustments */
    .video-container {
        height: calc(100vh - 80px);
    }
    
    /* Profile adjustments */
    .videos-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    /* Modal adjustments */
    .modal-content {
        max-width: 500px;
    }
    
    /* Welcome screen */
    .welcome-container {
        max-width: 500px;
    }
}

/* Desktop Styles (1024px and up) */
@media (min-width: 1024px) {
    .app-container {
        max-width: 1200px;
        height: 100vh;
        display: grid;
        grid-template-columns: 280px 1fr 280px;
        grid-template-rows: 1fr 60px;
        grid-template-areas: 
            "sidebar main extra"
            "sidebar nav extra";
        background: var(--background-dark);
    }
    
    /* Sidebar */
    .app-sidebar {
        grid-area: sidebar;
        background: var(--background-light);
        border-right: 1px solid var(--border-color);
        padding: 20px;
        overflow-y: auto;
        display: flex;
        flex-direction: column;
    }
    
    .sidebar-logo {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-bottom: 32px;
        padding: 0 12px;
    }
    
    .sidebar-logo-icon {
        width: 40px;
        height: 40px;
        background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
        border-radius: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
        font-weight: bold;
        color: white;
    }
    
    .sidebar-logo-text {
        font-size: 20px;
        font-weight: 700;
        background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }
    
    .sidebar-nav {
        flex: 1;
    }
    
    .sidebar-nav-item {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px 16px;
        margin-bottom: 4px;
        border-radius: 8px;
        color: var(--text-secondary);
        text-decoration: none;
        transition: all 0.2s ease;
        cursor: pointer;
    }
    
    .sidebar-nav-item:hover {
        background: rgba(255, 255, 255, 0.05);
        color: var(--text-primary);
    }
    
    .sidebar-nav-item.active {
        background: rgba(255, 0, 80, 0.1);
        color: var(--primary-color);
    }
    
    .sidebar-nav-icon {
        width: 24px;
        height: 24px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }
    
    .sidebar-user {
        margin-top: auto;
        padding-top: 20px;
        border-top: 1px solid var(--border-color);
    }
    
    .sidebar-user-info {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px;
        border-radius: 8px;
        cursor: pointer;
        transition: background 0.2s ease;
    }
    
    .sidebar-user-info:hover {
        background: rgba(255, 255, 255, 0.05);
    }
    
    .sidebar-user-avatar {
        width: 36px;
        height: 36px;
        border-radius: 50%;
        object-fit: cover;
    }
    
    .sidebar-user-details {
        flex: 1;
    }
    
    .sidebar-user-username {
        font-size: 14px;
        font-weight: 600;
        color: var(--text-primary);
    }
    
    .sidebar-user-status {
        font-size: 12px;
        color: var(--text-secondary);
    }
    
    /* Main Content */
    .main-content {
        grid-area: main;
        position: relative;
        overflow: hidden;
        height: calc(100vh - 60px);
    }
    
    /* Extra Sidebar */
    .app-extra {
        grid-area: extra;
        background: var(--background-light);
        border-left: 1px solid var(--border-color);
        padding: 20px;
        overflow-y: auto;
    }
    
    .suggestions-section {
        margin-bottom: 32px;
    }
    
    .section-title {
        font-size: 16px;
        font-weight: 600;
        margin-bottom: 16px;
        color: var(--text-primary);
    }
    
    .suggestion-item {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 8px 0;
        cursor: pointer;
        transition: opacity 0.2s ease;
    }
    
    .suggestion-item:hover {
        opacity: 0.8;
    }
    
    .suggestion-avatar {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        object-fit: cover;
    }
    
    .suggestion-info {
        flex: 1;
    }
    
    .suggestion-username {
        font-size: 14px;
        font-weight: 600;
        color: var(--text-primary);
    }
    
    .suggestion-name {
        font-size: 12px;
        color: var(--text-secondary);
    }
    
    .suggestion-follow {
        font-size: 12px;
        color: var(--primary-color);
        cursor: pointer;
    }
    
    /* Bottom Nav becomes Top Navigation on Desktop */
    .bottom-nav {
        grid-area: nav;
        position: static;
        transform: none;
        width: 100%;
        max-width: none;
        background: var(--background-light);
        border-top: none;
        border-bottom: 1px solid var(--border-color);
        padding: 0 20px;
        justify-content: center;
    }
    
    .nav-item {
        margin: 0 16px;
    }
    
    .nav-item span {
        display: block;
    }
    
    /* Video feed adjustments */
    .video-feed {
        height: 100%;
    }
    
    .video-container {
        height: 100%;
        max-height: calc(100vh - 60px);
    }
    
    /* Profile adjustments */
    .videos-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    /* Modal adjustments */
    .modal-content {
        max-width: 600px;
    }
    
    /* Welcome screen */
    .welcome-container {
        max-width: 600px;
    }
    
    /* Upload modal */
    .upload-modal .modal-content {
        max-width: 800px;
    }
}

/* Large Desktop Styles (1440px and up) */
@media (min-width: 1440px) {
    .app-container {
        max-width: 1600px;
    }
    
    .videos-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* Small Mobile Styles (up to 374px) */
@media (max-width: 374px) {
    .videos-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .profile-avatar {
        width: 70px;
        height: 70px;
    }
    
    .profile-username {
        font-size: 20px;
    }
}

/* Ultra Small Mobile (up to 320px) */
@media (max-width: 320px) {
    .nav-item span {
        display: none;
    }
    
    .nav-item {
        padding: 4px 8px;
        margin: 0 4px;
    }
    
    .profile-main-info {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .profile-actions {
        flex-direction: column;
    }
}

/* Landscape Mobile (max height, min width) */
@media (max-height: 600px) and (orientation: landscape) {
    .video-container {
        height: calc(100vh - 60px);
    }
    
    .video-overlay {
        bottom: 10px;
        left: 10px;
        right: 60px;
    }
    
    .video-actions {
        bottom: 60px;
        right: 10px;
    }
}

/* Print Styles */
@media print {
    .loading-screen,
    .welcome-screen,
    .modal,
    .bottom-nav {
        display: none !important;
    }
    
    .app-container {
        max-width: 100%;
        box-shadow: none;
    }
    
    body {
        background: white;
        color: black;
    }
}

/* Welcome Screen */
.welcome-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--background-dark) 0%, var(--background-light) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s ease;
    padding: 20px;
}

.welcome-screen.active {
    opacity: 1;
    visibility: visible;
}

.welcome-screen.fade-out {
    opacity: 0;
    transform: scale(1.05);
}

.welcome-container {
    max-width: 400px;
    width: 100%;
    text-align: center;
}

.welcome-logo {
    width: 120px;
    height: 120px;
    margin: 0 auto 24px;
    position: relative;
    animation: welcomeLogoFloat 3s ease-in-out infinite;
}

.welcome-logo::before {
    content: '';
    position: absolute;
    top: -20px;
    left: -20px;
    right: -20px;
    bottom: -20px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    opacity: 0.1;
    animation: welcomePulse 3s ease-in-out infinite;
    z-index: -1;
}

.welcome-logo-icon {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: bold;
    color: white;
    box-shadow: 0 12px 48px rgba(255, 0, 80, 0.4);
    animation: welcomeLogoGlow 3s ease-in-out infinite alternate;
}

.welcome-title {
    font-size: 32px;
    font-weight: 700;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 12px;
}

.welcome-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.4;
}

.welcome-features {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 40px;
}

.welcome-feature {
    display: flex;
    align-items: center;
    gap: 16px;
    text-align: left;
    animation: welcomeFeatureSlide 0.5s ease forwards;
    opacity: 0;
}

.welcome-feature:nth-child(1) { animation-delay: 0.2s; }
.welcome-feature:nth-child(2) { animation-delay: 0.4s; }
.welcome-feature:nth-child(3) { animation-delay: 0.6s; }

.welcome-feature-icon {
    width: 48px;
    height: 48px;
    background: rgba(255, 0, 80, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.welcome-feature-text {
    flex: 1;
}

.welcome-feature-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.welcome-feature-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.3;
}

.welcome-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.welcome-btn {
    padding: 16px 32px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    text-decoration: none;
    display: block;
    text-align: center;
}

.welcome-btn-primary {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: 0 8px 24px rgba(255, 0, 80, 0.3);
}

.welcome-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(255, 0, 80, 0.4);
}

.welcome-btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.welcome-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

.welcome-skip {
    color: var(--text-secondary);
    font-size: 14px;
    margin-top: 24px;
    cursor: pointer;
    transition: color 0.2s ease;
}

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

@keyframes welcomeLogoFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(5deg); }
}

@keyframes welcomeLogoGlow {
    0% { box-shadow: 0 12px 48px rgba(255, 0, 80, 0.4); }
    100% { box-shadow: 0 16px 64px rgba(255, 0, 80, 0.6); }
}

@keyframes welcomePulse {
    0%, 100% { transform: scale(1); opacity: 0.1; }
    50% { transform: scale(1.1); opacity: 0.05; }
}

@keyframes welcomeFeatureSlide {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Utility Classes */
.hidden {
    display: none !important;
}

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

.mb-20 {
    margin-bottom: 20px;
}

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

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