@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
    --bg-dark: #f8f9fa;
    --bg-card: #ffffff;
    --bg-card-hover: #ffffff;
    --primary-neon: #0b57d0; /* Google Material Blue */
    --primary-glow: rgba(11, 87, 208, 0.08);
    --secondary-neon: #006874; /* Google Material Teal */
    --secondary-glow: rgba(0, 104, 116, 0.08);
    --text-main: #1f1f1f; /* Charcoal */
    --text-muted: #5f6368; /* Slate gray */
    --text-dim: #8e918f;
    --border-glow: #e0e0e0;
    --accent-red: #b3261e; /* Material Red */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Roboto', sans-serif;
    --transition: all 0.2s cubic-bezier(0.2, 0, 0, 1);
    
    /* M3 Elevation Shadows */
    --shadow-1: 0 1px 2px rgba(0,0,0,0.05), 0 1px 3px rgba(0,0,0,0.08);
    --shadow-2: 0 3px 6px rgba(0,0,0,0.04), 0 3px 6px rgba(0,0,0,0.08);
    --shadow-3: 0 10px 20px rgba(0,0,0,0.05), 0 6px 6px rgba(0,0,0,0.08);
}

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

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-body);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center; /* Center main content vertically */
    align-items: center;
}

/* Cosmic elements removed in light theme */
.cosmic-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background-color: var(--bg-dark);
}

.glow-orb, .stars {
    display: none; /* Hide background particle effects */
}

/* Header & Logo */
header {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 1200px;
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.35rem;
    letter-spacing: -0.02em;
    color: var(--primary-neon);
}

.logo svg {
    width: 28px;
    height: 28px;
    stroke: var(--primary-neon);
}

.status-badge {
    background: rgba(11, 87, 208, 0.06);
    border: 1px solid rgba(11, 87, 208, 0.12);
    padding: 0.5rem 1rem;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--primary-neon);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.status-badge::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: var(--primary-neon);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.95); opacity: 0.6; }
    50% { transform: scale(1.15); opacity: 1; }
    100% { transform: scale(0.95); opacity: 0.6; }
}

/* Main Container Grid */
main {
    width: 100%;
    max-width: 1200px;
    padding: 1.5rem 2rem 4rem 2rem;
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 4rem;
    align-items: center;
    z-index: 1;
}

/* Hero Content Area */
.hero-content {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
    align-items: center;
    text-align: center;
}

.badge-new {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: rgba(11, 87, 208, 0.06);
    border: 1px solid rgba(11, 87, 208, 0.12);
    padding: 0.5rem 1rem;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary-neon);
    width: fit-content;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-dot {
    width: 6px;
    height: 6px;
    background-color: var(--primary-neon);
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 8px var(--primary-neon);
}

h1 {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.025em;
    background: linear-gradient(135deg, var(--text-main) 30%, var(--primary-neon) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.description {
    color: var(--text-muted);
    font-size: 1.125rem;
    line-height: 1.6;
}

/* Countdown Timer */
.countdown-container {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.countdown-box {
    background: rgba(255, 255, 255, 0.65);
    border: 1px solid rgba(11, 87, 208, 0.08);
    backdrop-filter: blur(12px);
    border-radius: 20px;
    padding: 1rem 1.25rem;
    min-width: 90px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02), 0 1px 3px rgba(0, 0, 0, 0.01);
    transition: var(--transition);
}

.countdown-box:hover {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(11, 87, 208, 0.2);
    box-shadow: 0 10px 25px rgba(11, 87, 208, 0.06);
    transform: translateY(-3px);
}

.countdown-num {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-neon) 0%, var(--secondary-neon) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
}

.countdown-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
    color: var(--text-muted);
    margin-top: 0.45rem;
}

/* Form Styles - M3 Pill Outlined Field */
.subscribe-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    width: 100%;
    max-width: 480px;
    margin-top: 0.5rem;
}

.form-group {
    display: flex;
    position: relative;
    background: #ffffff;
    border: 1px solid #74777f;
    border-radius: 100px; /* Fully Rounded Pill */
    padding: 4px;
    transition: var(--transition);
    overflow: hidden; /* Ensure rounded corners clip autofill/child background overflow */
}

.form-group:focus-within {
    border-color: var(--primary-neon);
    box-shadow: 0 0 0 1px var(--primary-neon);
}

.form-group input {
    flex-grow: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-main);
    padding: 0.75rem 1.5rem;
    font-family: var(--font-body);
    font-size: 0.95rem;
    width: 100%;
}

/* Fix browser autofill styling and prevent light blue overlap */
.form-group input:-webkit-autofill,
.form-group input:-webkit-autofill:hover, 
.form-group input:-webkit-autofill:focus, 
.form-group input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0px 1000px #ffffff inset !important;
    -webkit-text-fill-color: var(--text-main) !important;
}

.form-group input::placeholder {
    color: var(--text-dim);
}

.form-group button {
    background-color: var(--primary-neon);
    color: #ffffff;
    border: none;
    outline: none;
    padding: 0.75rem 1.75rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    border-radius: 100px; /* Pill Button */
    cursor: pointer;
    box-shadow: var(--shadow-1);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-group button:hover {
    background-color: #0842a0; /* Darker Blue */
    box-shadow: var(--shadow-2);
}

.form-group button:active {
    background-color: #062e70;
}

.message-box {
    font-size: 0.875rem;
    padding: 0.65rem 1rem;
    border-radius: 100px;
    display: none;
    align-items: center;
    gap: 0.5rem;
    animation: slideUp 0.2s forwards ease-out;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

.message-box.success {
    display: flex;
    background: #e6f4ea;
    border: 1px solid #137333;
    color: #137333;
}

.message-box.error {
    display: flex;
    background: #fce8e6;
    border: 1px solid #c5221f;
    color: #c5221f;
}

/* Game Console Area - Material Flat Elevated Style */
.game-area {
    background: var(--bg-card);
    border: 1px solid var(--border-glow);
    border-radius: 28px; /* Large Rounded Corners */
    padding: 1.5rem;
    box-shadow: var(--shadow-2);
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    transition: var(--transition);
}

.game-area:hover {
    box-shadow: var(--shadow-3);
}

/* Top Console Bar */
.console-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.console-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-main);
}

.console-title span {
    font-size: 0.75rem;
    background: #f1f3f4;
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
    color: var(--text-muted);
    font-weight: 500;
}

.arcade-dots {
    display: flex;
    gap: 6px;
}

.dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}
.dot-red { background: #dadce0; }
.dot-yellow { background: #dadce0; }
.dot-green { background: #dadce0; }

/* Canvas Container styling */
.canvas-wrapper {
    position: relative;
    background: #f8f9fa; /* Light canvas screen background */
    border-radius: 16px;
    border: 1px solid #dadce0;
    overflow: hidden;
    width: 100%;
    aspect-ratio: 16 / 9;
}

/* Remove retro scanlines overlay for standard Material light theme */
.canvas-wrapper::after {
    display: none;
}

canvas {
    display: block;
    width: 100%;
    height: 100%;
}

/* Game overlays styling - Material Card style overlay */
.game-ui-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: rgba(255, 255, 255, 0.95);
    transition: var(--transition);
    padding: 1.5rem;
    text-align: center;
}

.game-ui-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.game-ui-title {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
    color: var(--primary-neon);
}

.game-ui-desc {
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-bottom: 1.25rem;
    max-width: 300px;
    line-height: 1.5;
}

.btn-game {
    background: var(--primary-neon);
    border: none;
    color: #ffffff;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    padding: 0.75rem 1.75rem;
    border-radius: 100px;
    cursor: pointer;
    box-shadow: var(--shadow-1);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-game:hover {
    background: #0842a0;
    box-shadow: var(--shadow-2);
    transform: translateY(-1px);
}

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

/* Audio toggle buttons */
.game-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.control-tips {
    display: flex;
    gap: 1rem;
}

.control-tip-key {
    background: #f1f3f4;
    border: 1px solid #e0e0e0;
    padding: 0.1rem 0.4rem;
    border-radius: 6px;
    color: var(--text-main);
    font-weight: 500;
}

.btn-icon-toggle {
    background: none;
    border: none;
    outline: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    transition: var(--transition);
}

.btn-icon-toggle:hover {
    color: var(--text-main);
    background: #f1f3f4;
}

/* Responsive Breakpoints */
@media (max-width: 992px) {
    main {
        grid-template-columns: 1fr;
        gap: 3rem;
        padding-bottom: 3rem;
    }

    h1 {
        font-size: 2.75rem;
    }

    .hero-content {
        align-items: center;
        text-align: center;
    }

    .subscribe-form {
        margin-left: auto;
        margin-right: auto;
        width: 100%;
    }

    .countdown-container {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    header {
        padding: 1.5rem 1.5rem 0.5rem 1.5rem;
    }

    main {
        padding: 1rem 1.5rem 2rem 1.5rem;
    }

    h1 {
        font-size: 2.25rem;
    }

    .countdown-container {
        gap: 0.75rem;
    }

    .countdown-box {
        padding: 0.75rem;
        min-width: 75px;
    }

    .countdown-num {
        font-size: 1.75rem;
    }

    .form-group {
        flex-direction: column;
        background: transparent;
        border: none;
        padding: 0;
        gap: 0.5rem;
    }

    .form-group input {
        background: #ffffff;
        border: 1px solid #74777f;
        border-radius: 100px;
        padding: 0.85rem 1.25rem;
    }

    .form-group button {
        width: 100%;
        justify-content: center;
        padding: 0.85rem;
        border-radius: 100px;
    }
}
