/* CSS Variables for Theme Support */
:root {
    --primary-color: #9146ff;
    --primary-color-rgb: 145, 70, 255;
    --secondary-color: #772ce8;
    --accent-color: #9146ff;
    --success-color: #00ff88;
    --warning-color: #ffb800;
    --warning-color-rgb: 255, 184, 0;
    --error-color: #ff4757;
    
    /* Light Theme */
    --bg-primary: #989898;
    --bg-secondary: #ffffff;
    --bg-tertiary: #bbbdc2;
    --bg-hover: #c7c9ce;
    --text-primary: #1a1a1a;
    --text-secondary: #3a3a3a;
    --text-muted: #6a6a6a;
    --border-color: #a8aaaf;
    --shadow: rgba(0, 0, 0, 0.2);
    --shadow-hover: rgba(0, 0, 0, 0.3);
    
    /* Additional variables for modals and forms */
    --input-bg: #e8e9ed;
    --card-bg: #e8e9ed;
    --accent-color-rgb: 145, 70, 255;
    --accent-color-alpha: rgba(145, 70, 255, 0.1);
    --accent-hover: #772ce8;
}

[data-theme="dark"] {
    --bg-primary: #0e0e10;
    --bg-secondary: #18181b;
    --bg-tertiary: #1f1f23;
    --bg-hover: #2a2a2e;
    --text-primary: #efeff1;
    --text-secondary: #adadb8;
    --text-muted: #777;
    --border-color: #464649;
    --shadow: rgba(0, 0, 0, 0.3);
    --shadow-hover: rgba(0, 0, 0, 0.4);
    
    /* Additional variables for modals and forms */
    --input-bg: #1f1f23;
    --card-bg: #18181b;
    --accent-color-rgb: 145, 70, 255;
    --accent-color-alpha: rgb(145 70 255 / 20%);
    --accent-hover: #772ce8;
}

/* Reset and Base Styles */
* {
    /* flex: auto; */
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    /* Prevent address bar hiding on mobile */
    height: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    /* Prevent address bar hiding on mobile */
    min-height: 100%;
    position: relative;
}



.container {
    max-width: 97%;
    margin: 0 auto;
    padding: 0 20px;
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background-color: var(--bg-secondary);
}

/* Header Styles */
.header {
    background-color: var(--bg-secondary);
    /* border-bottom: 1px solid var(--border-color); */
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    height: 43px;
}

.nav-container {
    display: flex;
    align-items: center;
    /* max-width: 1200px; */
    margin: 0 auto;
    padding: 0 10px;
    transition: all 0.3s ease;
}

.nav-logo {
    flex: 0 0 auto;
    transition: all 0.3s ease;
}

.current-page-indicator {
    flex: 1;
    display: flex;
    justify-content: center;
    transition: all 0.3s ease;
}

.nav-actions {
    flex: 0 0 auto;
    margin-left: auto;
    transition: all 0.3s ease;
}

.nav-logo a {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.nav-logo a:hover {
    transform: scale(1.05);
}

.nav-logo i {
    font-size: 1.8rem;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Current Page Indicator */

.page-breadcrumb {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    padding: 8px 16px;
    background: linear-gradient(135deg, var(--bg-tertiary), var(--bg-secondary));
    border-radius: 20px;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    min-width: fit-content;
    white-space: nowrap;
}

.page-breadcrumb::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: left 0.5s ease;
}

.page-breadcrumb:hover::before {
    left: 100%;
}

/* Page-specific breadcrumb colors */
.page-breadcrumb.page-home {
    border-left: 4px solid var(--primary-color);
}

.page-breadcrumb.page-streams {
    border-left: 4px solid var(--accent-color);
    display: none;
}

.page-breadcrumb.page-api {
    border-left: 4px solid var(--success-color);
}

.page-breadcrumb.page-admin {
    border-left: 4px solid var(--warning-color);
}

.page-breadcrumb.page-profile {
    border-left: 4px solid var(--secondary-color);
}

.nav-menu {
    display: flex;
    gap: 1.5rem;
    list-style: none;
    margin: auto;
    padding: 0;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 2px 8px;
    border-radius: 8px;
    background: transparent;
}

.nav-link:hover {
    color: var(--primary-color);
    background: var(--bg-tertiary);
    transform: translateY(-2px);
}

.nav-link.active {
    color: var(--primary-color);
    background: linear-gradient(135deg, rgba(145, 70, 255, 0.1), rgba(0, 245, 255, 0.1));
    border: 1px solid rgba(145, 70, 255, 0.2);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 6px;
    background-color: var(--primary-color);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--primary-color);
}

.nav-link i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.nav-link:hover i {
    transform: scale(1.1);
}

.nav-link span {
    font-size: 0.95rem;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.theme-toggle {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 10px;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.theme-toggle:hover {
    background-color: var(--bg-tertiary);
    color: var(--primary-color);
    transform: scale(1.1);
}

.theme-toggle::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, var(--primary-color), transparent);
    transition: all 0.3s ease;
    transform: translate(-50%, -50%);
    opacity: 0;
}

.theme-toggle:hover::before {
    width: 40px;
    height: 40px;
    opacity: 0.1;
}

.login-btn,
.admin-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(145, 70, 255, 0.3);
}

.login-btn:hover,
.admin-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(145, 70, 255, 0.4);
}

.login-btn::before,
.admin-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.login-btn:hover::before,
.admin-btn:hover::before {
    left: 100%;
}

.admin-btn {
    background: linear-gradient(135deg, var(--warning-color), #ff9500);
    box-shadow: 0 4px 15px rgba(255, 184, 0, 0.3);
}

.admin-btn:hover {
    box-shadow: 0 6px 20px rgba(255, 184, 0, 0.4);
}

/* Profile Dropdown Styles */
.profile-dropdown {
    position: relative;
    display: inline-block;
}

.profile-btn {
    background: none;
    border: none;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-primary);
}

.profile-btn:hover {
    background-color: var(--bg-tertiary);
}

.header .profile-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-color);
}

.profile-username {
    font-weight: 500;
    font-size: 14px;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-chevron {
    font-size: 12px;
    transition: transform 0.3s ease;
    color: var(--text-secondary);
}

.profile-dropdown.active .profile-chevron {
    transform: rotate(180deg);
}

.profile-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 4px 12px var(--shadow);
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    margin-top: 8px;
}

.profile-dropdown.active .profile-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.profile-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-primary);
    text-decoration: none;
    transition: background-color 0.3s ease;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font-size: 14px;
}

.profile-menu-item:hover {
    background-color: var(--bg-tertiary);
}

.profile-menu-item i {
    width: 16px;
    color: var(--text-secondary);
}

.profile-menu-divider {
    height: 1px;
    background-color: var(--border-color);
    margin: 4px 0;
}

.logout-btn {
    color: var(--error-color) !important;
}

.logout-btn:hover {
    background-color: rgba(255, 71, 87, 0.1) !important;
}

.logout-btn i {
    color: var(--error-color) !important;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--text-primary);
    transition: 0.3s;
    border-radius: 2px;
    transform-origin: center;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Main Content */
.main-content {
    min-height: calc(100dvh - 140px);
    min-height: calc(100% - 140px);
}

/* Latest Stream Section */

.latest-stream h1 {
    margin-bottom: 2rem;
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stream-player-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* gap: 8px; */
    margin-bottom: 1rem;
    /* width: 100%; */
    /* max-width: 2561px; */
    /* max-height: 1093px; */
    margin: 16px auto 16px auto;
    border-radius: 12px;
    /* padding: 16px; */
    background-color: var(--card-bg);
    /* border: 1px solid var(--border-color); */
}

.player-wrapper {
    max-width: auto;
    margin: 0 auto;
}

.video-section {
    position: relative;
    /* height: 75vh; */
    /* max-height: 1080px; */
    /* max-width: 1920px; */
    width: 70vw;
    /* aspect-ratio: 16 / 9; */
}

.video-player {
    position: relative;
    background-color: var(--bg-tertiary);
    border-radius: 10px;
    overflow: hidden;
    /* box-shadow: 0 8px 32px var(--shadow); */
}

.hls-player {
    /* width: 100%; */
    /* height: auto; */
    /* aspect-ratio: 16/9; */
    border-radius: 10px;
}

/* Stream Info */
.stream-info {
    background-color: var(--bg-secondary);
    /* border-radius: 12px; */
    /* padding: 2rem; */
    box-shadow: 0 4px 16px var(--shadow);
}

.stream-info h2 {
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-size: 1.8rem;
}

.stream-meta:not(.stream-info-meta) span {
    background-color: var(--bg-tertiary);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Override for stream-duration in stream-meta to prevent absolute positioning */
.stream-meta:not(.stream-info-meta) .stream-duration {
    position: static;
    background-color: var(--bg-tertiary);
    color: var(--text-secondary);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    bottom: auto;
    right: auto;
    box-shadow: none;
}

.stream-number {
    background-color: var(--primary-color) !important;
    color: white !important;
}

/* Legacy stream-description styles - kept for backward compatibility */
.stream-description:not(.stream-info-description) {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Recent Streams Grid */
.recent-streams {
    margin-top: 3rem;
}

.recent-streams h2 {
    margin-bottom: 2rem;
    font-size: 2rem;
    text-align: center;
}

.streams-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.stream-card {
    background-color: var(--bg-secondary);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px var(--shadow);
    transition: all 0.3s ease;
    cursor: pointer;
}

.stream-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px var(--shadow-hover);
}

.stream-thumbnail {
    position: relative;
    aspect-ratio: 16/9;
    background-color: var(--bg-tertiary);
    overflow: hidden;
}

.stream-thumbnail img {
    /* width: 100%; */
    /* height: 100%; */
    object-fit: cover;
}

.stream-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
}

.stream-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.stream-card-content {
    padding: 1.5rem;
    grid-column: o;
}

.stream-card h3 {
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    height: 50px;
    color: var(--text-primary);
}

.stream-card-meta {
    display: flex;
    color: var(--text-secondary);
    font-size: 0.9rem;
    flex-wrap: wrap;
    justify-content: space-between;
    align-content: flex-end;
}

/* Stream Info Component */
.stream-info {
    background-color: var(--card-bg);
    /* border-radius: 12px; */
    /* padding: 2rem; */
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 16px var(--shadow);
}

/* Legacy stream styles - kept for backward compatibility with other components */
.stream-header:not(.stream-info-header) {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    /* gap: 1rem; */
}

.stream-header:not(.stream-info-header) h1,
.stream-header:not(.stream-info-header) h2 {
    margin: 0;
    color: var(--text-primary);
    font-weight: 700;
    line-height: 1.2;
}

.stream-actions:not(.stream-info-actions) .btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.stream-actions:not(.stream-info-actions) .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px var(--shadow-hover);
}

.stream-actions:not(.stream-info-actions) .btn.active {
    background-color: var(--primary-color);
    color: white;
}

.meta-item:not(.stream-info-meta-item) {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.meta-item:not(.stream-info-meta-item) i {
    color: var(--primary-color);
    font-size: 1rem;
    width: 16px;
    text-align: center;
}

.stream-tags:not(.stream-info-tags) {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.stream-tag:not(.stream-info-tag) {
    background-color: var(--bg-tertiary);
    color: var(--text-secondary);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.stream-tag:not(.stream-info-tag):hover {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.stream-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    /* gap: 1rem; */
}

.stream-header h1,
.stream-header h2 {
    margin: 0;
    color: var(--text-primary);
    font-weight: 700;
    line-height: 1.2;
}

.stream-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.stream-actions .btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.stream-actions .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px var(--shadow-hover);
}

.stream-actions .btn.active {
    background-color: var(--primary-color);
    color: white;
}

.stream-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    /* margin-bottom: 1.5rem; */
    /* padding: 1rem 0; */
    /* border-top: 1px solid var(--border-color); */
    /* border-bottom: 1px solid var(--border-color); */
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.meta-item i {
    color: var(--primary-color);
    font-size: 1rem;
    width: 16px;
    text-align: center;
}

.stream-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.stream-tag {
    background-color: var(--bg-tertiary);
    color: var(--text-secondary);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.stream-tag:hover {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Mobile responsive styles for legacy stream components */
@media (max-width: 768px) {
    .stream-header:not(.stream-info-header) {
        flex-direction: column;
        align-items: stretch;
    }
}

.stream-description h3 {
    margin: 0 0 0.75rem 0;
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
}

.stream-description p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Footer */
.footer {
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    margin-top: 3rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 2rem;
}

.footer-section {
    flex: 1;
    min-width: 200px;
}

.footer-section h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-weight: 600;
}

.footer-section p {
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.footer-section li {
    list-style: none;
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: var(--accent-color);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.social-links a {
    color: var(--text-secondary);
    font-size: 1.4rem;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.2s ease;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
}

.social-links a:hover {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

.footer-actions {
    margin-top: 1rem;
}

.footer-btn {
    font-size: 0.9rem;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
}

.footer-btn:hover {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
    transform: translateY(-1px);
}

.footer-bottom {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.footer-bottom p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 0;
}

.footer-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.footer-links a,
.footer-links button {
    color: var(--text-secondary);
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.3s ease;
}

.footer-links a:hover,
.footer-links button:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    color: var(--text-secondary);
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.social-link:hover {
    color: var(--primary-color);
}

/* Cookie Consent - Alternative naming to avoid ad blockers */
.cookie-consent:not(.hidden),
.privacy-notice:not(.hidden),
.user-preference-banner:not(.hidden) {
    position: fixed !important;
    bottom: 20px !important;
    left: 20px !important;
    right: 20px !important;
    background-color: var(--bg-secondary) !important;
    border: 1px solid var(--border-color) !important;
    border-radius: 12px !important;
    padding: 1.5rem !important;
    box-shadow: 0 8px 32px var(--shadow) !important;
    z-index: 9999 !important;
    max-width: 500px !important;
    margin: 0 auto !important;
    display: block !important;
    visibility: visible !important;
}

/* Ensure hidden class works for cookie consent */
.cookie-consent.hidden,
.privacy-notice.hidden,
.user-preference-banner.hidden {
    display: none !important;
    visibility: hidden !important;
}

/* Additional fallback styles */
#cookieConsent {
    font-family: inherit !important;
    color: var(--text-primary) !important;
    background: var(--bg-secondary) !important;
}

.cookie-content p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

.cookie-buttons {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

/* Responsive Design */
/* Mobile Menu Styles */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100dvh;
    max-height: 100%;
    background: var(--bg-primary);
    border-left: 1px solid var(--border-color);
    z-index: 1000;
    transition: right 0.3s ease;
    padding: 2rem 0;
    overflow-y: auto;
}

.mobile-menu.active {
    right: 0;
}

.mobile-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-nav-list li {
    margin: 0;
}

.mobile-nav-link {
    display: block;
    padding: 1rem 2rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-bottom: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    background: var(--bg-secondary);
    color: var(--accent-color);
}

.mobile-actions {
    padding: 2rem;
    border-top: 1px solid var(--border-color);
    margin-top: 1rem;
}

.mobile-action-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1rem;
    margin-bottom: 0.5rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
}

.mobile-action-btn:hover {
    background: var(--accent-color);
    color: white;
}

/* Mobile Bottom Navigation */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 8px 0 calc(8px + env(safe-area-inset-bottom));
    z-index: 1100;
    backdrop-filter: blur(10px);
    display: none;
}

.mobile-bottom-nav-list {
    display: flex;
    justify-content: space-around;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
    max-width: 500px;
    margin: 0 auto;
}

.mobile-bottom-nav-item {
    flex: 1;
    text-align: center;
}

.mobile-bottom-nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 4px;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.2s ease;
    border-radius: 8px;
    position: relative;
}

.mobile-bottom-nav-link i {
    font-size: 1.2rem;
    transition: all 0.2s ease;
}

.mobile-bottom-nav-link span {
    font-size: 0.7rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.mobile-bottom-nav-link:hover,
.mobile-bottom-nav-link.active {
    color: var(--primary-color);
    transform: translateY(-2px);
}

.mobile-bottom-nav-link.active i {
    transform: scale(1.1);
}

.mobile-bottom-nav-link.active::before {
    content: '';
    position: absolute;
    top: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

@media (max-width: 1075px) {
    .nav-menu {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: none; /* Hide hamburger menu in favor of bottom nav */
    }
    
    .mobile-bottom-nav {
        display: block;
    }
    
    
    .footer {
        position: relative;
        margin-bottom: 80px; /* Space above bottom nav */
        background: var(--bg-primary);
        border-top: 1px solid var(--border-color);
    }
    
    .current-page-indicator {
        display: none; /* Hide breadcrumb on mobile */
    }
    
    .page-breadcrumb {
        display: none; /* Hide breadcrumb on mobile */
    }
    
    .nav-logo a {
        font-size: 1.3rem;
    }
    
    .nav-logo i {
        font-size: 1.5rem;
    }
    
    .login-btn span,
    .theme-toggle {
        display: none;
    }
    
    .login-btn {
        padding: 8px;
        min-width: 40px;
        justify-content: center;
    }
        
    .chat-section {
        order: 2;
        width: 100%;
    }
        
    .latest-stream h1 {
        font-size: 2rem;
    }
    
    .streams-grid {
        grid-template-columns: 1fr;
    }
    
    .footer {
        padding: 2rem 1rem; /* Better padding with horizontal spacing */
        margin-top: 2rem;
        background: var(--bg-secondary);
        border-top: 1px solid var(--border-color);
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 2rem; /* Increased spacing between sections */
        max-width: 100%;
        align-items: center; /* Center all content */
    }
    
    .footer-section {
        margin-bottom: 0;
        padding: 0;
        width: 100%;
        max-width: 320px; /* Consistent max width for better centering */
    }
    
    .footer-section:first-child {
        order: 1; /* Main description first */
    }
    
    .footer-section:nth-child(3) {
        order: 2; /* Social media second */
    }
    
    .footer-section:nth-child(4) {
        order: 3; /* Actions third */
    }
    
    .footer-section:nth-child(2) {
        order: 4; /* Legal links last */
    }
    
    .footer-section h3 {
        font-size: 1.2rem;
        margin-bottom: 1rem;
        color: var(--text-primary);
        font-weight: 600;
    }
    
    .footer-section p {
        font-size: 0.95rem;
        line-height: 1.6;
        margin-bottom: 0;
        color: var(--text-secondary);
        max-width: 280px;
        margin: 0 auto;
    }
    
    .footer-section li {
        list-style: none;
        margin-bottom: 0.75rem;
        display: block; /* Stack vertically for better mobile layout */
        text-align: center;
    }
    
    .footer-section a {
        color: var(--text-secondary);
        text-decoration: none;
        font-size: 0.9rem;
        transition: color 0.3s ease;
    }
    
    .footer-section a:hover {
        color: var(--accent-color);
    }
    
    .social-links {
        gap: 1.5rem;
        justify-content: center;
        margin-top: 1rem;
        flex-wrap: wrap;
    }
    
    .social-links a {
        font-size: 1.4rem;
        padding: 0.875rem;
        border-radius: 14px;
        transition: all 0.3s ease;
        background: var(--bg-tertiary);
        border: 1px solid var(--border-color);
        color: var(--text-secondary);
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 52px;
        height: 52px;
    }
    
    .social-links a:hover {
        background: var(--accent-color);
        color: white;
        border-color: var(--accent-color);
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }
    
    .footer-actions {
        margin-top: 1rem;
        display: flex;
        justify-content: center;
    }
    
    .footer-btn {
        font-size: 0.95rem;
        padding: 0.875rem 2rem;
        border-radius: 10px;
        background: var(--bg-tertiary);
        border: 1px solid var(--border-color);
        color: var(--text-primary);
        transition: all 0.3s ease;
        font-weight: 500;
        min-width: 160px;
        cursor: pointer;
    }
    
    .footer-btn:hover {
        background: var(--accent-color);
        color: white;
        border-color: var(--accent-color);
        transform: translateY(-1px);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    }
    
    .footer-bottom {
        margin-top: 1.5rem;
        padding-top: 1.5rem;
        border-top: 1px solid var(--border-color);
    }
    
    .footer-bottom p {
        font-size: 0.85rem;
        color: var(--text-muted);
        margin: 0;
        opacity: 0.8;
    }
    
    .cookie-consent {
        left: 10px;
        right: 10px;
    }
    
    .cookie-buttons {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0px 15px 50px 15px;
        max-width: 100%;
        width: 100%;
    }
        
    .stream-info {
        padding: 1.5rem;
    }
    
    .stream-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .stream-actions {
        width: 100%;
        justify-content: flex-start;
    }
        
    .stream-tags {
        gap: 0.25rem;
    }
    
    .footer-links {
        flex-direction: row;
        gap: 1.5rem;
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .footer-links a {
        font-size: 0.85rem;
        padding: 0.25rem 0;
    }
}