:root {
    --bg-color: #000000;
    --gold: #d4af37;
    --gold-light: #f4d03f;
    --text-primary: #ffffff;
    --text-secondary: #999999;
    --glass: rgba(10, 10, 10, 0.7);
    --border: rgba(255, 255, 255, 0.1);
    --font-main: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --transition: all 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    overflow: hidden;
    position: relative;
}

/* More visible Code Background */
#code-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    opacity: 0.35; /* Increased visibility */
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, transparent 20%, var(--bg-color) 120%);
    z-index: -1;
    pointer-events: none;
}

#sound-toggle {
    position: fixed;
    top: 2rem;
    right: 2rem;
    background: var(--glass);
    border: 1px solid var(--border);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    z-index: 100;
}

#sound-toggle:hover {
    border-color: var(--gold);
    transform: scale(1.1);
}

#audio-icon {
    width: 20px;
    height: 20px;
    fill: var(--text-secondary);
}

#sound-toggle.active #audio-icon {
    fill: var(--gold);
}

main {
    width: 100%;
    max-width: 480px;
    animation: fadeIn 1.2s ease-out;
}

#game-container {
    background: var(--glass);
    backdrop-filter: blur(50px);
    -webkit-backdrop-filter: blur(50px);
    border: 1px solid var(--border);
    border-radius: 40px;
    padding: 2.5rem 2.5rem;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.9);
    text-align: center;
}

.brand-header {
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: 2.5rem;
}

.logo-block-container {
    width: 50px;
    height: 50px;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pixel-block {
    position: relative;
    width: 50px;
    height: 50px;
    animation: rotateBlock 8s infinite steps(4);
}

@keyframes rotateBlock {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.pixel {
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 4px;
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
}

.p-1 { top: 0; left: 0; }
.p-2 { top: 0; left: 30px; }
.p-3 { top: 30px; left: 0; }

.brand {
    font-size: 2.4rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    margin: 0;
    text-transform: uppercase;
}

.brand span {
    color: var(--gold);
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.dynamic-claim {
    margin-top: 1rem;
    line-height: 1.4;
    min-height: 60px;
}

.static-line {
    font-size: 0.9rem;
    font-weight: 300;
    letter-spacing: 0.4em;
    color: var(--text-secondary);
    margin-bottom: 0.3rem;
}

.dynamic-line {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    color: var(--gold);
    display: inline-block;
    position: relative;
}

.dynamic-line::after {
    content: '_';
    position: absolute;
    right: -15px;
    animation: blinkCursor 0.8s infinite;
}

@keyframes blinkCursor {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.game-info {
    margin-bottom: 2rem;
}

.game-info h2 {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.3em;
    color: var(--gold);
    margin-bottom: 0.5rem;
}

.stats {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 1rem;
    font-weight: 700;
    font-size: 0.8rem;
    color: var(--gold-light);
}

.board {
    display: grid;
    gap: 12px;
    margin: 0 auto 2.5rem;
    width: fit-content;
    padding: 15px;
    background: rgba(0,0,0,0.25);
    border-radius: 24px;
}

.cell {
    width: 60px;
    height: 60px;
    background: #0d0d0d;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid rgba(255,255,255,0.02);
}

.cell:hover {
    background: #151515;
    transform: scale(1.05);
}

.cell.active {
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
    box-shadow: 0 0 25px rgba(212, 175, 55, 0.4);
}

.btn-mini {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-secondary);
    padding: 0.7rem 1.8rem;
    border-radius: 100px;
    font-weight: 700;
    font-size: 0.7rem;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.btn-mini:hover {
    border-color: var(--gold);
    color: var(--gold);
    background: rgba(212, 175, 55, 0.05);
}

.game-message {
    height: 1.5rem;
    margin-top: 1rem;
    font-size: 0.8rem;
    color: var(--gold-light);
    font-weight: 500;
}

footer {
    margin-top: 3rem;
    font-size: 0.65rem;
    color: var(--text-secondary);
    opacity: 0.3;
    letter-spacing: 0.2em;
}

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

@media (max-width: 480px) {
    .cell { width: 50px; height: 50px; }
    #game-container { padding: 2.5rem 1.5rem; }
}
