/* style.css */

/* CSS Variables for Theme - Adjusted for Windows 10 Fluent Design style (More High-End) */
:root {
    /* Dark Mode Colors - Deeper, richer grays */
    --bg-color-dark: #121212; /* Very dark gray, almost black */
    --text-color-dark: #E8E8E8; /* Softer white for text */
    --primary-color-dark: #0078D4; /* Standard Windows accent blue - remains */
    --accent-color-dark: #00A0E9; /* Slightly softer, more vibrant blue than pure cyan */
    --card-bg-dark: #1E1E1E; /* Slightly lighter than background for subtle layering */
    --card-border-dark: rgba(0, 120, 212, 0.1); /* Very subtle blue border */
    --header-bg-dark: rgba(18, 18, 18, 0.7); /* More translucent dark for acrylic */
    --hero-gradient-start-dark: rgba(0, 120, 212, 0.03); /* Extremely subtle blue glow */
    --hero-gradient-end-dark: rgba(0, 160, 233, 0.02); /* Even more subtle */
    --disclaimer-bg-dark: rgba(255, 204, 0, 0.06); /* Even less opaque */
    --disclaimer-text-dark: #FFCC00;

    /* New colors for specific buttons */
    --success-color: #28A745; /* Green for success/continue */
    --danger-color: #DC3545;  /* Red for danger/cancel */

    /* Light Mode Colors - Cleaner, softer whites */
    --bg-color-light: #F8F8F8; /* Soft off-white */
    --text-color-light: #333333;
    --primary-color-light: #0078D4;
    --accent-color-light: #0078D4; /* Accent is often same as primary in light mode */
    --card-bg-light: #FFFFFF; /* Pure white for cards */
    --card-border-light: rgba(0, 120, 212, 0.08); /* Very subtle border */
    --header-bg-light: rgba(248, 248, 248, 0.7); /* More translucent light for acrylic */
    --hero-gradient-start-light: rgba(0, 120, 212, 0.02);
    --hero-gradient-end-light: rgba(0, 120, 212, 0.01);
    --disclaimer-bg-light: rgba(255, 100, 0, 0.06);
    --disclaimer-text-light: #FF6400;

    /* General variables for smooth transitions */
    --bg-color: var(--bg-color-dark);
    --text-color: var(--text-color-dark);
    --primary-color: var(--primary-color-dark);
    --accent-color: var(--accent-color-dark);
    --card-bg: var(--card-bg-dark);
    --card-border: var(--card-border-dark);
    --header-bg: var(--header-bg-dark);
    --hero-gradient-start: var(--hero-gradient-start-dark);
    --hero-gradient-end: var(--hero-gradient-end-dark);
    --disclaimer-bg: var(--disclaimer-bg-dark);
    --disclaimer-text: var(--disclaimer-text-dark);
}

/* Light Mode Specific Styles */
body.light-mode {
    --bg-color: var(--bg-color-light);
    --text-color: var(--text-color-light);
    --primary-color: var(--primary-color-light);
    --accent-color: var(--accent-color-light);
    --card-bg: var(--card-bg-light);
    --card-border: var(--card-border-light);
    --header-bg: var(--header-bg-light);
    --hero-gradient-start: var(--hero-gradient-start-light);
    --hero-gradient-end: var(--hero-gradient-end-light);
    --disclaimer-bg: var(--disclaimer-bg-light);
    --disclaimer-text: var(--disclaimer-text-light);
    /* New colors for specific buttons in light mode */
    --success-color: #28A745;
    --danger-color: #DC3545;
}

/* Base Styles (Desktop/Tablet Fluent Design) */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans SC', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.7;
    transition: background-color 0.8s ease, color 0.8s ease;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--accent-color);
}

h1, h2, h3 {
    font-family: 'Montserrat', sans-serif;
    color: var(--text-color);
    margin-bottom: 1rem;
    font-weight: 700;
}

h1 { font-size: 3.8rem; letter-spacing: -1px;}
h2 { font-size: 2.8rem; }
h3 { font-size: 2rem; }

section {
    padding: 100px 5%;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.section-slogan {
    font-size: 1.3rem;
    color: var(--text-color);
    opacity: 0.7;
    margin-bottom: 4rem;
    font-weight: 300;
}

/* Header - Enhanced Acrylic Effect */
header {
    background-color: var(--header-bg);
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    color: var(--text-color);
    padding: 1.2rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    transition: background-color 0.8s ease, box-shadow 0.8s ease;
}

.logo {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 2rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
}

.logo-icon {
    font-size: 2.2rem;
    margin-right: 12px;
    animation: pulse 4s infinite alternate ease-in-out;
    filter: drop-shadow(0 0 8px rgba(0, 120, 212, 0.6));
}

@keyframes pulse {
    from { transform: scale(1); opacity: 0.7; }
    to { transform: scale(1.02); opacity: 1; }
}

nav#main-nav ul { /* Targeting desktop nav */
    list-style: none;
    display: flex;
}

nav#main-nav ul li {
    margin-left: 3rem;
}

nav#main-nav ul li a {
    color: var(--text-color);
    font-size: 1.15rem;
    font-weight: 400;
    position: relative;
    padding-bottom: 8px;
}

nav#main-nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    left: 0;
    bottom: 0;
    transition: width 0.3s ease;
}

nav#main-nav ul li a:hover::after {
    width: 100%;
}

.theme-toggle {
    background: none;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    font-size: 1.6rem;
    padding: 10px 14px;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    background-color: var(--primary-color);
    color: var(--bg-color);
    box-shadow: 0 0 12px rgba(0, 120, 212, 0.5);
}

/* Mobile Menu Toggle (hidden by default on desktop) */
.mobile-menu-toggle {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 2rem;
    cursor: pointer;
    padding: 5px;
    display: none; /* Hidden on desktop */
}

/* Mobile Menu Overlay (hidden by default) */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8); /* Darker overlay */
    backdrop-filter: blur(15px) saturate(180%);
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    z-index: 1002;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-content {
    background-color: var(--card-bg);
    border-radius: 15px;
    padding: 30px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
    position: relative;
    transform: translateY(20px);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-menu-overlay.active .mobile-menu-content {
    transform: translateY(0);
    opacity: 1;
}

.mobile-menu-content .close-mobile-menu {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 2rem;
    cursor: pointer;
}

.mobile-menu-content ul {
    list-style: none;
    padding: 0;
    margin-top: 20px;
}

.mobile-menu-content ul li {
    margin-bottom: 20px;
}

.mobile-menu-content ul li a {
    color: var(--text-color);
    font-size: 1.5rem;
    font-weight: 500;
    display: block;
    padding: 10px 0;
    transition: color 0.2s ease;
}

.mobile-menu-content ul li a:hover {
    color: var(--primary-color);
}


/* Hero Section */
.hero-section {
    position: relative;
    height: 95vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    background: linear-gradient(45deg, var(--bg-color), color-mix(in srgb, var(--bg-color) 85%, var(--primary-color) 15%));
}

.hero-background-animation {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 80%, var(--hero-gradient-start), transparent 75%),
                radial-gradient(circle at 80% 20%, var(--hero-gradient-end), transparent 75%);
    background-size: 250% 250%;
    animation: backgroundPan 120s linear infinite alternate;
    opacity: 0.3;
}

@keyframes backgroundPan {
    0% { background-position: 0% 0%; }
    100% { background-position: 100% 100%; }
}

.hero-content {
    z-index: 1;
    text-align: center;
    max-width: 1000px;
    animation: fadeInScale 1.8s ease-out forwards;
}

@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.92); }
    to { opacity: 1; transform: scale(1); }
}

.hero-content h1 {
    font-size: 5rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: textGradientShift 25s ease-in-out infinite alternate;
    background-size: 200% 100%;
}

@keyframes textGradientShift {
    0% { background-position: 0% 50%; }
    100% { background-position: 100% 50%; }
}

.hero-content .slogan {
    font-size: 2rem;
    color: var(--text-color);
    margin-bottom: 3rem;
    opacity: 0;
    animation: fadeIn 1.2s ease-out 1s forwards;
}

.disclaimer-banner {
    background-color: var(--disclaimer-bg);
    border: 1px solid var(--disclaimer-text);
    padding: 18px 30px;
    margin: 2.5rem auto;
    border-radius: 10px;
    max-width: 750px;
    box-shadow: 0 0 20px rgba(255, 204, 0, 0.08);
    opacity: 0;
    animation: fadeIn 1.2s ease-out 1.5s forwards;
}

.disclaimer-banner p {
    font-size: 1.15rem;
    font-weight: 400;
}

.btn-explore {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    padding: 18px 35px;
    border-radius: 8px;
    font-size: 1.3rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-top: 3rem;
    box-shadow: 0 5px 15px rgba(0, 120, 212, 0.4);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    opacity: 0;
    animation: fadeIn 1.2s ease-out 2s forwards;
    border: none;
}

.btn-explore:hover {
    background: var(--accent-color);
    transform: translateY(-4px) scale(1.01);
    box-shadow: 0 8px 25px rgba(0, 160, 233, 0.5);
}

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


/* Applications Section & Epic Games Section (Cards Animation) */
.applications-section, .epic-games-section {
    background-color: var(--bg-color);
    padding-top: 120px;
    padding-bottom: 120px;
    border-top: 1px solid color-mix(in srgb, var(--bg-color) 80%, var(--primary-color) 10%);
    border-bottom: 1px solid color-mix(in srgb, var(--bg-color) 80%, var(--primary-color) 10%);
}

.applications-section h2, .epic-games-section h2 {
    font-size: 3.5rem;
    margin-bottom: 4rem;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.app-grid, .epic-games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
    justify-content: center;
    align-items: stretch;
}

/* Base state for cards before they animate into view */
.app-card, .epic-game-card {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 35px;
    text-align: center;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.5s ease; /* General transition for hover effects */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;

    /* Initial state for scroll-in animation */
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out, box-shadow 0.5s ease, border-color 0.5s ease, background-color 0.5s ease; /* Combined transition */
}

/* Class added by JS when element scrolls into view */
.app-card.fade-in-scroll, .epic-game-card.fade-in-scroll {
    opacity: 1;
    transform: translateY(0);
    /* transition-delay will be set by JS */
}

.app-card:hover {
    transform: translateY(-8px) scale(1.008);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25),
                0 0 20px rgba(0, 120, 212, 0.5);
    border-color: var(--primary-color);
    background-color: color-mix(in srgb, var(--card-bg) 92%, var(--primary-color) 8%);
}

.app-icon {
    font-size: 4.5rem;
    margin-bottom: 1.5rem;
    line-height: 1;
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 0 10px rgba(0, 120, 212, 0.4));
}

.app-card h3 {
    color: var(--text-color);
    margin-bottom: 0.8rem;
    position: relative;
    z-index: 1;
}

.app-slogan {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 1.2rem;
    font-weight: 500;
    position: relative;
    z-index: 1;
}

.app-description {
    font-size: 1rem;
    color: var(--text-color);
    flex-grow: 1;
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

.btn-access {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    padding: 12px 25px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    position: relative;
    z-index: 1;
}

.btn-access:hover {
    background: var(--accent-color);
    transform: scale(1.03);
    box-shadow: 0 0 12px rgba(0, 160, 233, 0.4);
}

/* About Section */
.about-section {
    padding: 120px 5%;
    text-align: left;
    background-color: var(--bg-color);
}

.about-section h2 {
    text-align: center;
    margin-bottom: 3rem;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.about-section p {
    max-width: 900px;
    margin: 0 auto 1.8rem auto;
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--text-color);
    font-weight: 300;
}


/* Footer */
footer {
    background-color: var(--card-bg);
    color: var(--text-color);
    padding: 50px 5%;
    text-align: center;
    border-top: 1px solid var(--card-border);
    box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.1);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

footer p {
    margin-bottom: 1rem;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.6);
}

footer a {
    color: var(--primary-color);
}

.footer-disclaimer {
    color: var(--disclaimer-text) !important;
    font-weight: 500;
    margin-top: 2rem;
    margin-bottom: 2rem;
}

/* --- Weather Module Styles --- */
.weather-module {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 18px 25px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 20px;
    z-index: 999;
    transition: all 0.4s ease;
    font-size: 1rem;
    color: var(--text-color);
}

.weather-module:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.25), 0 0 20px rgba(0, 120, 212, 0.3);
}

.weather-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.weather-city {
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--primary-color);
}

.weather-temp {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-color);
}

.weather-wind {
    font-size: 0.9rem;
    color: var(--text-color);
    opacity: 0.7;
}

.weather-warning-indicator {
    cursor: pointer;
    font-size: 2rem;
    animation: bounce 1.2s infinite alternate ease-in-out;
    filter: drop-shadow(0 0 8px rgba(255, 204, 0, 0.8));
}

.weather-warning-indicator:hover {
    transform: scale(1.15);
}

@keyframes bounce {
    from { transform: translateY(0); }
    to { transform: translateY(-7px); }
}

/* --- Modal Styles (Fluent Design) --- */
.modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.7);
    backdrop-filter: blur(15px) saturate(180%);
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeInModal 0.4s ease-out;
}

.modal.hidden {
    display: none;
}

.modal-content {
    background-color: var(--card-bg);
    margin: auto;
    padding: 40px;
    border: 1px solid var(--card-border);
    border-radius: 15px;
    width: 85%;
    max-width: 700px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.4);
    position: relative;
    animation: slideInModal 0.5s ease-out;
    text-align: left;
}

.modal-content h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    text-align: center;
    font-size: 2.2rem;
}

.modal-content .close-button {
    color: var(--text-color);
    font-size: 32px;
    font-weight: bold;
    position: absolute;
    top: 15px;
    right: 20px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.modal-content .close-button:hover,
.modal-content .close-button:focus {
    color: var(--accent-color);
}

#warning-details p {
    margin-bottom: 12px;
    line-height: 1.6;
    font-size: 1rem;
    color: var(--text-color);
}

#warning-details strong {
    color: var(--primary-color);
}

.warning-item {
    padding: 12px;
    margin-bottom: 12px;
    border-radius: 8px;
    border-left: 6px solid;
    font-size: 1rem;
    background-color: rgba(0,0,0,0.08);
}

/* Warning colors based on API 'color' field, mapping to common warning colors */
.warning-item[data-color="蓝色"] { border-color: #0078D4; background-color: rgba(0, 120, 212, 0.12); }
.warning-item[data-color="黄色"] { border-color: #FFCC00; background-color: rgba(255, 204, 0, 0.12); }
.warning-item[data-color="橙色"] { border-color: #FF6600; background-color: rgba(255, 102, 0, 0.12); }
.warning-item[data-color="红色"] { border-color: #FF0000; background-color: rgba(255, 0, 0, 0.12); }

.modal-disclaimer {
    font-size: 0.85rem;
    color: var(--text-color);
    opacity: 0.6;
    margin-top: 25px;
    text-align: center;
}

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

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

/* --- User City Input Modal Styles --- */
#city-input-modal .modal-content {
    max-width: 500px;
    text-align: center;
}

#city-input-modal h3 {
    margin-bottom: 15px;
}

#city-input-modal p {
    margin-bottom: 25px;
    color: var(--text-color);
    opacity: 0.8;
    font-size: 1rem;
}

.fluent-input {
    width: calc(100% - 20px);
    padding: 12px 10px;
    margin-bottom: 20px;
    border: 1px solid var(--card-border);
    border-radius: 8px;
    background-color: color-mix(in srgb, var(--card-bg) 95%, var(--primary-color) 2%);
    color: var(--text-color);
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
}

.fluent-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 120, 212, 0.2), inset 0 1px 3px rgba(0,0,0,0.15);
    background-color: var(--card-bg);
}

/* This is the general .btn-primary, used for city input modal confirm button */
#city-input-modal .btn-primary {
    display: inline-block;
    background: var(--primary-color); /* Uses primary accent color */
    color: #fff;
    padding: 12px 25px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 120, 212, 0.3); /* Subtle shadow */
}

#city-input-modal .btn-primary:hover {
    background: var(--accent-color); /* Brighter accent on hover */
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 160, 233, 0.4);
}

/* --- External Link Confirmation Modal Styles --- */
#external-link-confirm-modal .modal-content {
    max-width: 550px;
    text-align: center;
}

#external-link-confirm-modal .modal-content p {
    margin-bottom: 15px;
    font-size: 1.1rem;
    color: var(--text-color);
    opacity: 0.9;
}

#external-link-confirm-modal .modal-content strong {
    display: block;
    margin: 10px 0;
    font-size: 1.2rem;
    color: var(--primary-color);
    word-break: break-all; /* Break long URLs */
}

.modal-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
}

/* Modified .btn-primary for "继续访问" (Continue Access) within the external link modal */
#external-link-confirm-modal #confirm-external-link { /* Target specifically by ID for higher specificity */
    background: var(--success-color); /* Green background */
    color: #fff; /* White text */
    border: none; /* Remove border for solid look */
    padding: 12px 25px;
    border-radius: 8px; /* Unified roundness */
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2); /* Subtle shadow */
}

#external-link-confirm-modal #confirm-external-link:hover {
    background: color-mix(in srgb, var(--success-color) 85%, black 15%); /* Slightly darker green on hover */
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

/* Modified .btn-secondary for "取消" (Cancel) within the external link modal */
#external-link-confirm-modal #cancel-external-link { /* Target specifically by ID for higher specificity */
    background: var(--danger-color); /* Red background */
    color: #fff; /* White text */
    border: none; /* Remove border for solid look */
    padding: 12px 25px;
    border-radius: 8px; /* Unified roundness */
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2); /* Subtle shadow */
}

#external-link-confirm-modal #cancel-external-link:hover {
    background-color: color-mix(in srgb, var(--danger-color) 85%, black 15%); /* Slightly darker red on hover */
    color: #fff;
    border-color: transparent; /* No border on hover */
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}


/* --- Epic Games Module Styles --- */
.epic-games-section {
    /* Background and padding inherited from general section styles */
}

.epic-games-section h2 {
    /* Styles inherited from general h2 styles */
}

.epic-games-grid {
    /* Styles inherited from general grid styles */
}

.epic-game-card {
    /* Base state for cards before they animate into view */
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.5s ease; /* General transition for hover effects */
    text-align: left;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
    cursor: pointer; /* Indicate clickable */

    /* Initial state for scroll-in animation */
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out, box-shadow 0.5s ease, border-color 0.5s ease, background-color 0.5s ease; /* Combined transition */
}

/* Class added by JS when element scrolls into view */
.epic-game-card.fade-in-scroll {
    opacity: 1;
    transform: translateY(0);
    /* transition-delay will be set by JS */
}

.epic-game-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25), 0 0 20px rgba(0, 120, 212, 0.3);
    border-color: var(--primary-color);
}

.epic-game-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-bottom: 1px solid var(--card-border);
    transition: transform 0.4s ease;
}

.epic-game-card:hover img {
    transform: scale(1.06);
}

.epic-game-card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.epic-game-card h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: var(--text-color);
}

.epic-game-card p {
    font-size: 0.95rem;
    color: var(--text-color);
    opacity: 0.75;
    margin-bottom: 12px;
    flex-grow: 1;
}

.epic-game-card .game-info {
    font-size: 0.9rem;
    color: var(--text-color);
    opacity: 0.65;
    margin-top: 15px;
}

.epic-game-card .game-status {
    font-weight: 600;
    margin-top: 12px;
    padding: 6px 12px;
    border-radius: 6px;
    display: inline-block;
    font-size: 0.85rem;
}

.game-status.free-now {
    background-color: rgba(0, 120, 212, 0.25);
    color: var(--primary-color);
}

.game-status.coming-soon {
    background-color: rgba(255, 204, 0, 0.25);
    color: var(--disclaimer-text);
}

/* Removed .btn-view-game as per request */
/* .epic-game-card .btn-view-game { ... } */

.loading-message {
    font-size: 1.3rem;
    color: var(--text-color);
    opacity: 0.6;
    margin-top: 60px;
    grid-column: 1 / -1;
}

/* --- Notification Container Styles (Subtle Toast) --- */
#notification-container {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    pointer-events: none;
}

.notification {
    background-color: var(--card-bg);
    color: var(--text-color);
    padding: 12px 20px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
    transform: translateY(-20px);
    font-size: 0.95rem;
    min-width: 250px;
    text-align: center;
    pointer-events: auto;
}

.notification-info {
    border: 1px solid var(--primary-color);
}

.notification-warning {
    border: 1px solid var(--disclaimer-text);
    background-color: color-mix(in srgb, var(--card-bg) 90%, var(--disclaimer-text) 10%);
}

.notification-error {
    border: 1px solid #FF0000;
    background-color: color-mix(in srgb, var(--card-bg) 90%, #FF0000 10%);
}


/* --- Responsive Design (Mobile-Specific Overrides) --- */
@media (max-width: 768px) {
    body.is-mobile {
        /* Mobile specific base adjustments */
        font-size: 90%;
    }

    /* Header for mobile */
    body.is-mobile header {
        padding: 0.8rem 4%;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
        justify-content: space-between;
    }

    body.is-mobile nav#main-nav {
        display: none;
    }

    body.is-mobile .mobile-menu-toggle {
        display: block;
        margin-left: auto;
    }

    body.is-mobile .logo {
        font-size: 1.6rem;
    }

    body.is-mobile .logo-icon {
        font-size: 1.8rem;
        margin-right: 8px;
    }

    body.is-mobile .theme-toggle {
        font-size: 1.2rem;
        padding: 6px 10px;
        margin-right: 10px;
    }

    /* Hero Section for mobile */
    body.is-mobile .hero-section {
        height: 70vh;
        padding: 60px 3%;
    }

    body.is-mobile .hero-content h1 {
        font-size: 2.8rem;
        letter-spacing: 0px;
        margin-bottom: 1rem;
        animation: none;
        -webkit-text-fill-color: var(--text-color);
        background: none;
    }

    body.is-mobile .hero-content .slogan {
        font-size: 1.2rem;
        margin-bottom: 2rem;
    }

    body.is-mobile .disclaimer-banner {
        padding: 12px 20px;
        margin: 1.5rem auto;
        font-size: 0.9rem;
    }

    body.is-mobile .btn-explore {
        padding: 12px 25px;
        font-size: 1rem;
        margin-top: 2rem;
        box-shadow: 0 3px 10px rgba(0, 120, 212, 0.3);
    }

    /* Sections for mobile */
    body.is-mobile section {
        padding: 60px 4%;
    }

    body.is-mobile h2 {
        font-size: 2.2rem;
        margin-bottom: 2.5rem;
        animation: none;
        -webkit-text-fill-color: var(--text-color);
        background: none;
    }

    body.is-mobile .section-slogan {
        font-size: 1rem;
        margin-bottom: 2rem;
    }

    /* App Grid and Cards for mobile */
    body.is-mobile .app-grid,
    body.is-mobile .epic-games-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    body.is-mobile .app-card,
    body.is-mobile .epic-game-card {
        padding: 20px;
        border-radius: 10px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        transform: translateY(0) !important; /* Disable initial translateY */
        opacity: 1 !important; /* Ensure visible */
        transition: all 0.5s ease; /* Keep general transition for hover */
        animation: none !important; /* Disable initial animations */
    }

    body.is-mobile .app-card:hover,
    body.is-mobile .epic-game-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2), 0 0 10px rgba(0, 120, 212, 0.2);
    }

    body.is-mobile .app-icon {
        font-size: 3.5rem;
        margin-bottom: 1rem;
    }

    body.is-mobile .app-card h3,
    body.is-mobile .epic-game-card h3 {
        font-size: 1.3rem;
    }

    body.is-mobile .app-slogan {
        font-size: 1.1rem;
        margin-bottom: 1rem;
    }

    body.is-mobile .app-description,
    body.is-mobile .epic-game-card p {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }

    body.is-mobile .btn-access,
    body.is-mobile .epic-game-card .btn-view-game {
        padding: 10px 20px;
        font-size: 0.9rem;
        border-radius: 6px;
    }

    body.is-mobile .epic-game-card img {
        height: 180px;
    }

    /* Weather Module for mobile */
    body.is-mobile .weather-module {
        bottom: 15px;
        right: 15px;
        padding: 10px 15px;
        font-size: 0.85rem;
        gap: 10px;
        border-radius: 10px;
        box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
    }

    body.is-mobile .weather-module:hover {
        transform: translateY(-2px);
        box-shadow: 0 5px 12px rgba(0, 0, 0, 0.2), 0 0 8px rgba(0, 120, 212, 0.15);
    }

    body.is-mobile .weather-temp {
        font-size: 1.4rem;
    }

    body.is-mobile .weather-warning-indicator {
        font-size: 1.5rem;
        animation: bounce 1s infinite alternate;
    }

    /* Modal for mobile */
    body.is-mobile .modal-content {
        width: 95%;
        padding: 25px;
        border-radius: 12px;
        box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    }

    body.is-mobile .modal-content h3 {
        font-size: 1.6rem;
    }

    body.is-mobile .modal-content .close-button {
        font-size: 28px;
    }

    body.is-mobile .modal-disclaimer {
        font-size: 0.75rem;
    }

    /* Notification for mobile */
    #notification-container {
        top: 10px;
        gap: 5px;
    }
    .notification {
        padding: 10px 15px;
        font-size: 0.85rem;
        min-width: unset;
        width: 90%;
    }
    body.is-mobile #city-input-modal .modal-content {
        padding: 25px;
        border-radius: 10px;
    }

    body.is-mobile .fluent-input {
        padding: 10px;
        font-size: 0.95rem;
    }

    body.is-mobile #city-input-modal .btn-primary {
        padding: 10px 20px;
        font-size: 0.95rem;
    }

    /* External link confirm modal buttons for mobile */
    body.is-mobile #external-link-confirm-modal #confirm-external-link,
    body.is-mobile #external-link-confirm-modal #cancel-external-link {
        padding: 10px 20px;
        font-size: 0.95rem;
        border-radius: 6px;
    }
}