/**
 * NHL Predators Light Theme
 * Clean, modern design with Predators gold/navy accents
 * Light backgrounds for better readability
 */

:root {
    /* Predators Brand Colors */
    --predators-gold: #FFB81C;
    --predators-navy: #041E42;

    /* Light Theme Backgrounds */
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-tertiary: #f1f3f5;
    --bg-card: #ffffff;

    /* Text Colors */
    --text-primary: #1a1a1a;
    --text-secondary: #4a4a4a;
    --text-muted: #6b7280;

    /* Borders */
    --border-light: #e5e7eb;
    --border-medium: #d1d5db;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

/* Global Styles */
body {
    background: linear-gradient(135deg, #e8eaed 0%, #d5d8dc 50%, #e1e4e8 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    min-height: 100vh;
    /* iOS safe area support for notched devices (iPhone X+) */
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
    padding-bottom: env(safe-area-inset-bottom);
    /* Better touch feedback on mobile */
    -webkit-tap-highlight-color: rgba(255, 184, 28, 0.3); /* Predators gold with transparency */
}

/* ========================================
   NAVIGATION HEADER - Enhanced Design
   ======================================== */

.site-header {
    background: linear-gradient(180deg, var(--predators-navy) 0%, #05274d 100%);
    border-bottom: 4px solid var(--predators-gold);
    box-shadow: 0 4px 16px rgba(4, 30, 66, 0.4);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header-top {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
    padding: 0 2rem;
    position: relative; /* Allow absolute positioning of mobile menu */
}

/* Logo/Brand */
.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.nav-brand:hover {
    transform: translateY(-1px);
}

.nav-brand a {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.nav-logo {
    width: 52px;
    height: 52px;
    transition: transform 0.2s ease;
}

.nav-brand:hover .nav-logo {
    transform: scale(1.05);
}

.nav-brand span {
    font-size: 28px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.5px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Main Navigation */
.main-nav {
    display: flex;
    align-items: center;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0;
    list-style: none;
    margin: 0;
    padding: 0;
    height: 70px;
}

.nav-links li {
    height: 100%;
}

.site-header .nav-link {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 1.25rem;
    color: rgba(255, 255, 255, 0.9) !important;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    letter-spacing: 0.2px;
    position: relative;
    transition: all 0.2s ease;
    border-bottom: 3px solid transparent;
}

.nav-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 80%;
    height: 3px;
    background-color: var(--predators-gold);
    transition: transform 0.3s ease;
}

.site-header .nav-link:hover {
    color: #ffffff !important;
    background-color: rgba(255, 184, 28, 0.15);
}

.nav-link:hover::before {
    transform: translateX(-50%) scaleX(1);
}

.site-header .nav-link.active {
    color: var(--predators-gold) !important;
    font-weight: 700;
}

.nav-link.active::before {
    transform: translateX(-50%) scaleX(1);
}

/* Mobile Menu Toggle */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 12px;
    min-width: 48px;
    min-height: 48px;
    transition: all 0.2s ease;
}

.nav-toggle:hover {
    background-color: var(--bg-tertiary);
    border-radius: 6px;
}

.hamburger-icon {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 24px;
}

.hamburger-icon span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #ffffff;
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* Hamburger Animation - Transform to X when active */
.nav-toggle.active .hamburger-icon span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active .hamburger-icon span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active .hamburger-icon span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Menu Backdrop */
.mobile-menu-backdrop {
    display: none;
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-menu-backdrop.active {
    display: block;
    opacity: 1;
}

/* Responsive Navbar */
@media (max-width: 1024px) {
    .nav-toggle {
        display: flex;
    }

    .main-nav {
        position: fixed;
        top: 70px;
        right: -280px;
        width: 280px;
        height: calc(100vh - 70px);
        background-color: var(--bg-primary);
        border-left: 1px solid var(--border-light);
        box-shadow: -4px 0 12px rgba(0, 0, 0, 0.1);
        overflow-y: auto;
        transition: right 0.3s ease;
        z-index: 999;
        padding: 0;
        padding-bottom: env(safe-area-inset-bottom);
        margin: 0;
    }

    .main-nav.active {
        right: env(safe-area-inset-right);
    }

    .nav-links {
        flex-direction: column !important;
        height: auto !important;
        width: 100%;
        padding: 0 !important;
        margin: 0 !important;
        list-style: none;
        gap: 0 !important;
        display: flex;
    }

    .nav-links li {
        width: 100%;
        height: auto !important;
        margin: 0 !important;
        padding: 0;
    }

    .site-header .nav-link {
        display: block !important;
        width: 100%;
        height: auto !important;
        padding: 0.875rem 2rem !important;
        margin: 0 !important;
        border-bottom: 1px solid var(--border-light) !important;
        border-left: 3px solid transparent !important;
        color: var(--predators-navy) !important;
        background-color: transparent !important;
        text-decoration: none;
        font-size: 15px !important;
    }

    .site-header .nav-link:first-child {
        margin-top: 0 !important;
        padding-top: 0.875rem !important;
    }

    .site-header .nav-link:hover {
        background-color: rgba(255, 184, 28, 0.1) !important;
        color: var(--predators-navy) !important;
    }

    .nav-link::before {
        display: none !important;
    }

    .site-header .nav-link.active {
        border-left-color: var(--predators-gold) !important;
        border-left-width: 4px !important;
        background-color: rgba(255, 184, 28, 0.15) !important;
        color: var(--predators-navy) !important;
        font-weight: 600 !important;
    }
}

/* Hero/Featured Section */
.hero-section {
    background-color: var(--bg-primary);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.hero-overlay {
    background: linear-gradient(
        to top,
        rgba(4, 30, 66, 0.9) 0%,
        rgba(4, 30, 66, 0.6) 50%,
        transparent 100%
    );
}

.hero-category {
    background-color: var(--predators-gold);
    color: var(--predators-navy);
}

/* Cards */
.card {
    background: linear-gradient(145deg, #ffffff 0%, #fafbfc 100%);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07), 0 1px 3px rgba(0, 0, 0, 0.06);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    position: relative;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--predators-gold) 0%, var(--predators-navy) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12), 0 4px 8px rgba(255, 184, 28, 0.15);
    border-color: var(--predators-gold);
}

.card:hover::before {
    opacity: 1;
}

.card-badge {
    background: linear-gradient(135deg, var(--predators-gold) 0%, #f0a800 100%);
    color: var(--predators-navy);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.35rem 0.75rem;
    border-radius: 6px;
    font-size: 0.75rem;
    box-shadow: 0 2px 4px rgba(255, 184, 28, 0.3);
}

.card-title {
    color: var(--text-primary);
}

.card-title a {
    color: var(--text-primary);
}

.card-title a:hover {
    color: var(--predators-gold);
}

.card-meta {
    color: var(--text-muted);
}

/* Schedule Bar */
.schedule-bar {
    background: #ffffff;
    padding: 0;
    margin: 0;
    border-bottom: 3px solid var(--predators-gold);
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.schedule-game-card {
    background: linear-gradient(145deg, #ffffff 0%, #fafbfc 100%);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.schedule-game-card:hover {
    border-color: var(--predators-gold);
    box-shadow: 0 6px 16px rgba(255, 184, 28, 0.2);
    transform: translateY(-2px);
}

.schedule-game-time {
    color: var(--text-muted);
}

.schedule-team-name {
    color: var(--text-primary);
}

.schedule-score {
    color: var(--predators-gold);
}

.schedule-vs {
    color: var(--text-muted);
}

/* Sidebar */
.sidebar-item {
    background: linear-gradient(145deg, #ffffff 0%, #fafbfc 100%);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.sidebar-item:hover {
    background: linear-gradient(145deg, #fafbfc 0%, #f8f9fa 100%);
    border-color: var(--predators-gold);
    border-left-color: var(--predators-gold);
    box-shadow: 0 4px 12px rgba(255, 184, 28, 0.15);
    transform: translateX(4px);
}

.sidebar-item h4 {
    color: var(--text-primary);
}

.sidebar-item a {
    color: var(--text-primary);
}

.sidebar-item a:hover {
    color: var(--predators-gold);
}

.sidebar-item small {
    color: var(--text-muted);
}

/* Stats Bar */
.stats-bar {
    background-color: var(--bg-primary);
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
}

.stat-label {
    color: var(--text-muted);
}

.stat-value {
    color: var(--predators-gold);
}

/* Section Headers */
.section-title {
    color: var(--text-primary);
}

.section-link {
    color: var(--predators-gold);
}

.section-link:hover {
    color: var(--predators-navy);
}

/* Buttons */
.btn-primary {
    background-color: var(--predators-gold);
    color: var(--predators-navy);
    font-weight: 700;
}

.btn-primary:hover {
    background-color: #e6a519;
}

/* Loading Spinner */
.spinner {
    border-color: rgba(255, 184, 28, 0.2);
    border-top-color: var(--predators-gold);
}

.loading-spinner p {
    color: var(--text-muted);
}

/* Top Stories Section */
.top-stories-section {
    padding: 2rem 1.5rem;
    background-color: var(--bg-secondary);
}

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    padding: 2rem 1.5rem;
    background-color: var(--bg-secondary);
}

/* Quick Stats Bar - Below hero grid */
.quick-stats-bar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    padding: 0.8rem;
    margin-top: 16px;
    border-radius: 8px;
    border: 2px solid var(--predators-gold);
    box-shadow: 0 2px 8px rgba(255, 184, 28, 0.15);
    display: flex !important;
    justify-content: space-around;
    gap: 0.5rem;
}

.quick-stat {
    text-align: center;
    flex: 1;
    padding: 0.4rem 0.5rem;
    background: transparent;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.quick-stat:hover {
    background: rgba(255, 184, 28, 0.1);
}

.quick-stat .label {
    display: block;
    color: var(--text-muted);
    text-transform: uppercase;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    margin-bottom: 0.2rem;
}

.quick-stat .value {
    display: block;
    color: var(--predators-navy);
    font-size: 1.5rem;
    font-weight: 900;
    line-height: 1;
}

/* Content Wrapper */
.content-wrapper {
    background-color: var(--bg-secondary);
    padding: 2rem 0;
}

.main-content {
    background-color: transparent;
}

aside.sidebar {
    background-color: transparent;
}

/* Responsive */
@media (max-width: 768px) {
    /* Reduce header height on mobile for more content visibility */
    .site-header {
        height: 56px !important;
    }

    .header-content {
        height: 56px;
        padding: 0 1rem;
    }

    .nav-brand span {
        font-size: 20px;
    }

    .nav-logo {
        width: 40px;
        height: 40px;
    }

    .nav-links {
        top: 56px;
        height: calc(100vh - 56px);
    }

    .hero-section {
        height: 400px;
    }

    .news-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 1rem;
    }
}
