/* ================================================ */
/*  HOME PAGE - WHITE LABEL THEME AWARE             */
/*  Uses CSS variables from theme-system.css       */
/* ================================================ */


main {
    overflow: visible !important;
}
/* ===== TYPOGRAPHY - ITALICS FOR TITLES ===== */
h1, h2, h3, h4, h5, h6 {
    font-style: italic;
}

/* ===== HERO SECTION ===== */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
}

/* Enhanced gradient background with multiple glow effects */
.hero-gradient-enhanced {
    position: relative;
    background: var(--bg-primary);
    overflow: visible; /* Changed from hidden to visible */
}

/* Top-left glow - FIXED: Not cut off */
.hero-gradient-enhanced::before {
    content: "";
    position: absolute;
    top: -10%;
    left: -10%;
    width: 60%;
    height: 60%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-primary), 0.15) 0%,
        color-mix(in srgb, var(--accent-primary), 0.08) 30%,
        color-mix(in srgb, var(--accent-primary), 0.03) 50%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 1;
    animation: pulse-glow 8s ease-in-out infinite;
    filter: blur(40px);
}

/* Bottom-right glow - FIXED: Not cut off */
.hero-gradient-enhanced::after {
    content: "";
    position: absolute;
    bottom: -10%;
    right: -10%;
    width: 50%;
    height: 50%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-secondary), 0.12) 0%,
        color-mix(in srgb, var(--accent-secondary), 0.06) 30%,
        color-mix(in srgb, var(--accent-secondary), 0.03) 50%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 1;
    animation: pulse-glow 8s ease-in-out infinite 4s;
    filter: blur(40px);
}

@keyframes pulse-glow {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.1); }
}

/* ===== GLOW EFFECT VARIATIONS - FIXED: Radial glows from behind ===== */

/* Top-right glow effect - FIXED */
.glow-top-right {
    position: relative;
    overflow: visible;
}

.glow-top-right::before {
    content: "";
    position: absolute;
    top: -20%;
    right: -15%;
    width: 50%;
    height: 50%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-primary), 0.12) 0%,
        color-mix(in srgb, var(--accent-primary), 0.06) 30%,
        color-mix(in srgb, var(--accent-primary), 0.02) 50%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 0;
    filter: blur(60px);
}

/* Bottom-left glow effect - FIXED */
.glow-bottom-left {
    position: relative;
    overflow: visible;
}

.glow-bottom-left::before {
    content: "";
    position: absolute;
    bottom: -20%;
    left: -15%;
    width: 50%;
    height: 50%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-secondary), 0.12) 0%,
        color-mix(in srgb, var(--accent-secondary), 0.06) 30%,
        color-mix(in srgb, var(--accent-secondary), 0.02) 50%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 0;
    filter: blur(60px);
}

/* Center glow effect - FIXED */
.glow-center {
    position: relative;
    overflow: visible;
}

.glow-center::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70%;
    height: 70%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-primary), 0.08) 0%,
        color-mix(in srgb, var(--accent-secondary), 0.06) 30%,
        color-mix(in srgb, var(--accent-primary), 0.02) 50%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 0;
    filter: blur(80px);
}

/* Diagonal glow effect - FIXED */
.glow-diagonal {
    position: relative;
    overflow: visible;
}

.glow-diagonal::before {
    content: "";
    position: absolute;
    top: -15%;
    left: -15%;
    width: 80%;
    height: 80%;
    background: radial-gradient(
        ellipse at top left,
        color-mix(in srgb, var(--accent-primary), 0.1) 0%,
        color-mix(in srgb, var(--accent-secondary), 0.05) 40%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 0;
    filter: blur(60px);
}

/* Ensure content stays above glow effects */
.glow-top-right > *,
.glow-bottom-left > *,
.glow-center > *,
.glow-diagonal > * {
    position: relative;
    z-index: 1;
}

/* ===== COMPACT SPACING SYSTEM ===== */

/* Reduce section padding */
section {
    padding: 3rem 0;
}

@media (min-width: 640px) {
    section {
        padding: 4rem 0;
    }
}

/* Compact cards */
.card-compact {
    padding: 1.25rem;
}

@media (min-width: 640px) {
    .card-compact {
        padding: 1.5rem;
    }
}

/* Compact spacing utilities */
.mb-compact {
    margin-bottom: 2rem;
}

.mb-section-compact {
    margin-bottom: 3rem;
}

@media (min-width: 640px) {
    .mb-section-compact {
        margin-bottom: 4rem;
    }
}

/* ===== HERO IMAGE ENHANCEMENTS ===== */
.hero-image-container {
    position: relative;
    width: 100%;
}

/* FIXED: Floating cards with glow background */
.floating-card {
    position: absolute !important; /* Ensure absolute positioning */
    background: color-mix(in srgb, var(--bg-elevated) 95%, transparent);
    backdrop-filter: blur(20px);
    border: 1px solid color-mix(in srgb, var(--border-primary) 50%, transparent);
    box-shadow: var(--shadow-lg);
    overflow: visible;
    z-index: 30;
    border-radius: 0.75rem;
}

/* Add glow effect behind floating cards */
.floating-card::before {
    content: "";
    position: absolute;
    inset: -20px;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-primary), 0.15) 0%,
        color-mix(in srgb, var(--accent-primary), 0.08) 40%,
        transparent 70%
    );
    z-index: -1;
    opacity: 0.8;
    filter: blur(20px);
    pointer-events: none;
    border-radius: inherit;
}

.floating-card.orange-accent::before {
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-secondary), 0.2) 0%,
        color-mix(in srgb, var(--accent-secondary), 0.1) 40%,
        transparent 70%
    );
}

/* Ensure floating card content is above the glow */
.floating-card > * {
    position: relative;
    z-index: 2;
}

.card img {
    display: block;
}

/* ===== WIDGETS SECTION ===== */
.widgets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .widgets-grid {
        gap: 2rem;
    }
}

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

.weather-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.temperature {
    font-size: 1.75rem;
    font-weight: bold;
    color: var(--accent-lime);
    margin-bottom: 0.5rem;
}

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

.current-time {
    font-size: 1.75rem;
    font-weight: bold;
    color: var(--accent-lime);
    margin-bottom: 0.5rem;
}

/* ===== MATCH CARDS ===== */
.match-card {
    background: rgba(31, 31, 31, 0.8);
    border: 1px solid color-mix(in srgb, var(--accent-primary), 0.2);
    border-radius: 0.75rem;
    padding: 1rem;
    margin-bottom: 0.75rem;
}

.match-teams {
    font-weight: bold;
    color: white;
    margin-bottom: 0.5rem;
}

.match-info {
    font-size: 0.875rem;
    color: #9ca3af;
}

.match-info i {
    color: var(--accent-lime);
    margin-right: 0.25rem;
}

.no-matches {
    text-align: center;
    color: #9ca3af;
    font-style: italic;
    padding: 2rem;
}

/* ===== SPONSOR IMAGES ===== */
.sponsor-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.sponsor-img:hover {
    transform: scale(1.05);
    opacity: 0.8;
}

.main-sponsor-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.main-sponsor-logo:hover {
    transform: scale(1.02);
}

/* ===== CATEGORY CARDS ===== */
.category-card {
    background: var(--bg-tertiary);
    border: 1px solid color-mix(in srgb, var(--accent-primary), 0.2);
    border-radius: 0.75rem;
    padding: 1rem;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-primary), 0.05) 0%,
        transparent 50%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.category-card:hover {
    border-color: var(--accent-lime);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px color-mix(in srgb, var(--accent-primary), 0.2);
}

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

/* ===== ENHANCED CARD VARIANTS WITH GLOWS ===== */

/* Tournament section with glow */
.tournament-section {
    position: relative;
    overflow: visible;
}

.tournament-section::before {
    content: "";
    position: absolute;
    top: 10%;
    right: -10%;
    width: 40%;
    height: 50%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-primary), 0.08) 0%,
        color-mix(in srgb, var(--accent-primary), 0.04) 40%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 0;
    filter: blur(60px);
}

/* Rules section with diagonal glow */
.rules-section {
    position: relative;
    overflow: visible;
}

.rules-section::before {
    content: "";
    position: absolute;
    top: -20%;
    left: -20%;
    width: 70%;
    height: 70%;
    background: radial-gradient(
        ellipse at top left,
        color-mix(in srgb, var(--accent-secondary), 0.1) 0%,
        color-mix(in srgb, var(--accent-secondary), 0.05) 40%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 0;
    filter: blur(60px);
}

/* Prizes section with center glow */
.prizes-section {
    position: relative;
    overflow: visible;
}

.prizes-section::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60%;
    height: 60%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-primary), 0.06) 0%,
        color-mix(in srgb, var(--accent-secondary), 0.04) 30%,
        transparent 60%
    );
    pointer-events: none;
    z-index: 0;
    filter: blur(80px);
}

/* Location section with bottom glow */
.location-section {
    position: relative;
    overflow: visible;
}

.location-section::before {
    content: "";
    position: absolute;
    bottom: -15%;
    left: 20%;
    width: 50%;
    height: 50%;
    background: radial-gradient(
        circle at center,
        color-mix(in srgb, var(--accent-secondary), 0.1) 0%,
        color-mix(in srgb, var(--accent-secondary), 0.05) 40%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 0;
    filter: blur(60px);
}

/* ===== IMAGE ENHANCEMENTS ===== */
.image-with-rotated-bg {
    position: relative;
    overflow: visible !important; /* CRITICAL: Allow floating cards to show */
}

.image-with-rotated-bg::before {
    content: "";
    position: absolute;
    inset: -5%;
    background: linear-gradient(
        135deg,
        color-mix(in srgb, var(--accent-primary), 0.15) 0%,
        transparent 40%,
        color-mix(in srgb, var(--accent-secondary), 0.15) 100%
    );
    transform: rotate(3deg);
    border-radius: 1.5rem;
    z-index: 0;
    pointer-events: none;
}

.image-with-rotated-bg > * {
    position: relative;
    z-index: 1;
}

/* Ensure inner card maintains overflow hidden but doesn't affect floating cards */
.image-with-rotated-bg > .card {
    overflow: hidden;
    position: relative;
    z-index: 1;
}

/* Make sure floating cards are above everything */
.image-with-rotated-bg > .floating-card {
    z-index: 40 !important;
}

/* ===== FLOATING ANIMATION ===== */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* ===== COMPACT BOTTOM INFO GRID - EXTRA SMALL ===== */
.bottom-info-grid-compact {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.875rem;
}

@media (min-width: 768px) {
    .bottom-info-grid-compact {
        gap: 1rem;
    }
}

/* Make contact cards extra compact */
.contact-card-compact {
    padding: 0.875rem;
}

@media (min-width: 640px) {
    .contact-card-compact {
        padding: 1rem;
    }
}

.contact-card-compact .icon-header {
    width: 2.5rem;
    height: 2.5rem;
    margin-bottom: 0.75rem;
}

@media (min-width: 640px) {
    .contact-card-compact .icon-header {
        width: 3rem;
        height: 3rem;
        margin-bottom: 0.875rem;
    }
}

.contact-card-compact h4 {
    font-size: 0.938rem;
    margin-bottom: 0.375rem;
}

@media (min-width: 640px) {
    .contact-card-compact h4 {
        font-size: 1rem;
        margin-bottom: 0.5rem;
    }
}

.contact-card-compact p {
    font-size: 0.75rem;
    margin-bottom: 0.75rem;
}

@media (min-width: 640px) {
    .contact-card-compact p {
        font-size: 0.813rem;
        margin-bottom: 0.875rem;
    }
}

.contact-item-compact {
    padding: 0.5rem;
}

@media (min-width: 640px) {
    .contact-item-compact {
        padding: 0.625rem;
    }
}

.contact-icon-compact {
    width: 1.75rem;
    height: 1.75rem;
}

@media (min-width: 640px) {
    .contact-icon-compact {
        width: 2rem;
        height: 2rem;
    }
}

/* Logo sizes for organizers card - smaller */
.logo-compact {
    width: 3.5rem;
    height: 3.5rem;
}

@media (min-width: 640px) {
    .logo-compact {
        width: 4rem;
        height: 4rem;
    }
}

/* ===== RESPONSIVE MOBILE OPTIMIZATIONS ===== */
@media (max-width: 768px) {
    .hero-section {
        padding-top: 4rem;
    }
    
    .widgets-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .weather-icon {
        font-size: 2rem;
    }
    
    .temperature,
    .current-time {
        font-size: 1.5rem;
    }
    
    section {
        padding: 2.5rem 0;
    }
    
    /* Reduce glow intensity on mobile */
    .hero-gradient-enhanced::before,
    .hero-gradient-enhanced::after,
    .glow-top-right::before,
    .glow-bottom-left::before,
    .glow-center::before,
    .glow-diagonal::before {
        opacity: 0.5;
    }
}

/* ===== WIDGET DEBUG PANEL ===== */
#widget-debug-panel {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    z-index: 50;
    background: var(--bg-secondary);
    border: 1px solid var(--accent-lime);
    border-radius: 0.5rem;
    padding: 1rem;
    font-size: 0.75rem;
    max-width: 28rem;
}

/* ===== PULSE ANIMATION FOR BADGES ===== */
.pulse-sport {
    animation: pulse-badge 2s ease-in-out infinite;
}

@keyframes pulse-badge {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* ===== TEXT SHADOW FOR BETTER READABILITY ===== */
.text-shadow {
    text-shadow: 0 2px 20px color-mix(in srgb, #000000 0.5);
}

/* ===== GLASS EFFECTS ===== */
.glass-effect-brand {
    background: color-mix(in srgb, var(--accent-primary), 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid color-mix(in srgb, var(--accent-primary), 0.1);
}

.glass-effect {
    background: color-mix(in srgb, var(--text-primary) 3%, transparent);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
}

/* ===== PAGE TRANSITIONS ===== */
.page-transition {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.page-transition.loaded {
    opacity: 1;
    transform: translateY(0);
}

/* ===== COMPACT SECTION HEADINGS ===== */
section h2 {
    margin-bottom: 1rem;
}

section h3 {
    margin-bottom: 0.75rem;
}

@media (min-width: 640px) {
    section h2 {
        margin-bottom: 1.5rem;
    }
    
    section h3 {
        margin-bottom: 1rem;
    }
}

/* ===== ENHANCED CARD HOVER EFFECTS WITH GLOW ===== */
.card:hover,
.card-gradient:hover {
    box-shadow: 0 20px 60px color-mix(in srgb, #000000 0.5),
                0 0 40px color-mix(in srgb, var(--accent-primary), 0.1);
}

.card-gradient-orange:hover {
    box-shadow: 0 20px 60px color-mix(in srgb, #000000 0.5),
                0 0 40px color-mix(in srgb, var(--accent-secondary), 0.1);
}