:root {
    --bg-gradient: radial-gradient(circle at center, #101f32 0%, #050b14 100%);
    --card-bg: rgba(20, 29, 44, 0.75);
    --neon-blue: #66fcf1;
    --neon-green: #45f3ff;
    --neon-pink: #ff2a74;
    --neon-red: #ff4a4a;
    --neon-gold: #ffcf4b;
    --text-color: #c5c6c7;
    --border-glow: rgba(102, 252, 241, 0.25);
}

html {
    background-color: #050b14;
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: var(--bg-gradient);
    background-attachment: fixed;
    color: var(--text-color);
    margin: 0;
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100dvh;
    box-sizing: border-box;
}

.container {
    max-width: 520px; 
    width: 100%;
    text-align: center;
    position: relative;
    flex-grow: 1; 
    display: flex;
    flex-direction: column;
}

.hidden {
    display: none !important;
}

.text-white {
    color: #fff !important;
}

.welcome-title-spacing {
    margin: 20px 0 10px 0 !important;
}

.welcome-desc {
    font-size: 0.9rem;
    color: #8c9cb0;
    margin-bottom: 25px;
}

.setup-header-spacing {
    margin-bottom: 20px !important;
}

.main-game-inner {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
    min-height: 280px;
}

.about-section-spacing {
    margin-top: 20px !important;
}

.about-text-style {
    line-height: 1.6;
    color: #d1d5db;
}

.footer-divider {
    color: rgba(102, 252, 241, 0.1);
}

/* Klavye Odaklanma (Focus-Visible) Desteği */
button:focus-visible, input:focus-visible, select:focus-visible {
    outline: 2px solid var(--neon-blue);
    outline-offset: 2px;
}

.scoreboard {
    display: flex;
    justify-content: space-around;
    align-items: center;
    background: rgba(16, 31, 50, 0.95); 
    border: 1px solid rgba(102, 252, 241, 0.4);
    border-radius: 16px;
    padding: 10px 15px;
    margin-bottom: 15px;
    backdrop-filter: blur(16px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6), inset 0 0 10px rgba(102, 252, 241, 0.1);
    width: 100%;
    box-sizing: border-box;
    position: sticky;
    top: 5px; 
    z-index: 1000; 
}

.score-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 40%;
}

.score-name {
    font-size: 0.85rem;
    color: var(--text-color);
    font-weight: bold;
    margin-bottom: 2px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.score-points {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--neon-gold);
    text-shadow: 0 0 10px rgba(255, 207, 75, 0.5);
}

.score-divider {
    color: rgba(102, 252, 241, 0.3);
    font-size: 1.2rem;
    font-weight: bold;
}

.game-box {
    background-color: var(--card-bg);
    border-radius: 24px;
    padding: 25px 20px; 
    box-shadow: 0 20px 50px rgba(0,0,0,0.8), 
                inset 0 0 20px rgba(102, 252, 241, 0.05),
                0 0 30px rgba(102, 252, 241, 0.1);
    border: 1px solid var(--border-glow);
    backdrop-filter: blur(16px);
    min-height: 400px; 
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-sizing: border-box;
    position: relative;
}

.header-illustration {
    font-size: clamp(1.4rem, 6.2vw, 2.5rem); 
    font-weight: 900;
    color: transparent;
    background: linear-gradient(90deg, var(--neon-blue), var(--neon-green), var(--neon-pink));
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    letter-spacing: clamp(1px, 1.2vw, 6px); 
    text-transform: uppercase;
    font-style: italic;
    padding: 15px 0; 
    border-bottom: 1px dashed rgba(102, 252, 241, 0.2);
    text-shadow: 0 0 25px rgba(102, 252, 241, 0.4);
    user-select: none;
    white-space: nowrap;
    width: 100%;
    box-sizing: border-box;
    animation: shine 4s linear infinite;
}

@keyframes shine {
    to { background-position: 200% center; }
}

.illustration-badge {
    width: 80px;
    height: 80px;
    margin: 15px auto 5px auto;
    background: radial-gradient(circle, rgba(102,252,241,0.15) 0%, rgba(0,0,0,0) 70%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.8rem;
    border: 1px solid rgba(102, 252, 241, 0.3);
    box-shadow: 0 0 20px rgba(102, 252, 241, 0.2);
    animation: pulseGlow 3s infinite alternate;
}

@keyframes pulseGlow {
    0% { transform: scale(0.98); box-shadow: 0 0 15px rgba(102, 252, 241, 0.2); }
    100% { transform: scale(1.05); box-shadow: 0 0 30px rgba(102, 252, 241, 0.5); }
}

.status-bar {
    font-weight: bold;
    color: var(--neon-green);
    margin-bottom: 10px;
    font-size: 1.1rem; 
    line-height: 1.4;
    text-shadow: 0 0 10px rgba(69, 243, 255, 0.3);
}

.situation-text {
    font-size: 1.15rem; 
    line-height: 1.5;
    margin: 10px 0 15px 0; 
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
    min-height: 75px;
    display: flex;
    flex-direction: column; 
    align-items: center;
    justify-content: center;
    gap: 12px;
    animation: fadeIn 0.4s ease-in-out;
}

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

.input-group {
    margin-bottom: 18px;
    text-align: left;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--neon-blue);
    font-weight: bold;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.name-input {
    width: 100%;
    padding: 14px; 
    background: rgba(5, 11, 20, 0.6);
    border: 1px solid rgba(102, 252, 241, 0.3);
    border-radius: 12px;
    color: #fff;
    font-size: 1rem;
    box-sizing: border-box;
    transition: all 0.3s;
}

.name-input:focus {
    outline: none;
    border-color: var(--neon-blue);
    box-shadow: 0 0 15px rgba(102, 252, 241, 0.4);
    background: rgba(5, 11, 20, 0.8);
}

.btn {
    background: linear-gradient(135deg, rgba(102, 252, 241, 0.1), rgba(69, 243, 255, 0.2));
    border: 2px solid var(--neon-blue);
    color: var(--neon-blue);
    padding: 14px 20px; 
    font-size: 1.05rem;
    border-radius: 30px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.25s ease;
    box-shadow: 0 0 15px rgba(102, 252, 241, 0.2);
    margin-top: 12px;
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: block;
    box-sizing: border-box;
    text-decoration: none;
}

.btn-secondary {
    border-color: #8c9cb0;
    color: #8c9cb0;
    background: rgba(255, 255, 255, 0.03);
    box-shadow: none;
}

.btn-secondary:hover {
    background: #8c9cb0;
    color: #050b14;
    box-shadow: 0 0 15px #8c9cb0;
}

.btn:hover {
    background: var(--neon-blue);
    color: #050b14;
    box-shadow: 0 0 25px var(--neon-blue);
    transform: translateY(-2px);
}

.btn:active {
    transform: translateY(1px);
}

.slider-container {
    margin: 15px auto;
    padding: 0;
    width: 92%; 
    display: flex;
    flex-direction: column;
    align-items: center;
}

.range-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 10px;
    border-radius: 6px;
    background: linear-gradient(90deg, #101f32, #1f2833);
    border: 1px solid rgba(102, 252, 241, 0.3);
    outline: none;
    transition: all 0.3s;
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--neon-blue);
    cursor: pointer;
    box-shadow: 0 0 15px var(--neon-blue), inset 0 0 5px #fff;
    transition: transform 0.15s ease;
}

.range-slider::-webkit-slider-thumb:active {
    transform: scale(1.25);
    box-shadow: 0 0 25px var(--neon-blue);
}

.range-slider::-moz-range-thumb {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--neon-blue);
    cursor: pointer;
    border: none;
    box-shadow: 0 0 15px var(--neon-blue), inset 0 0 5px #fff;
}

.slider-value {
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--neon-blue);
    text-shadow: 0 0 15px var(--neon-blue);
    margin-top: 8px;
    width: 100%;
    text-align: center; 
    display: inline-block;
}

.ceza-box {
    font-weight: bold;
    border: 1px dashed var(--neon-red);
    padding: 15px;
    margin-bottom: 15px; 
    border-radius: 14px;
    background: rgba(255, 74, 74, 0.08);
    color: #ff8888;
    font-size: 0.95rem;
    line-height: 1.4;
    box-shadow: 0 0 15px rgba(255, 74, 74, 0.15);
    animation: fadeIn 0.3s;
}

.how-to-play-section {
    margin-top: 40px;
    background: rgba(16, 31, 50, 0.6);
    border: 1px solid rgba(102, 252, 241, 0.15);
    border-radius: 20px;
    padding: 25px 20px;
    text-align: left;
    backdrop-filter: blur(10px);
}

.how-to-play-title {
    color: var(--neon-blue);
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px dashed rgba(102, 252, 241, 0.2);
    padding-bottom: 10px;
}

.step-item {
    margin-bottom: 12px;
    font-size: 0.95rem;
    line-height: 1.5;
    color: #d1d5db;
}

.step-item span {
    color: var(--neon-green);
    font-weight: bold;
}

.footer {
    margin-top: auto;
    padding: 20px 0 10px 0;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.footer-link-btn {
    background: none;
    border: none;
    color: #8c9cb0;
    font-size: 0.8rem;
    text-decoration: none;
    transition: color 0.3s;
    cursor: pointer;
    opacity: 0.7;
    padding: 0;
    font-family: inherit;
}

.footer-link-btn:hover {
    color: var(--neon-pink);
    opacity: 1;
}

.lang-select-footer {
    background: rgba(16, 31, 50, 0.5);
    color: #8c9cb0;
    border: 1px solid rgba(102, 252, 241, 0.1);
    border-radius: 8px;
    padding: 4px 8px;
    font-size: 0.75rem;
    cursor: pointer;
    outline: none;
    transition: all 0.3s;
    font-family: inherit;
}

.lang-select-footer:hover {
    border-color: var(--neon-blue);
    color: var(--neon-blue);
    background: rgba(16, 31, 50, 0.8);
}

.lang-select-footer option {
    background: #050b14;
    color: #fff;
}

.modal {
    display: none; 
    position: fixed; 
    z-index: 1000; 
    left: 0; 
    top: 0; 
    width: 100%; 
    height: 100%; 
    background-color: rgba(5, 11, 20, 0.9); 
    backdrop-filter: blur(6px);
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: var(--card-bg);
    border: 1px solid rgba(102, 252, 241, 0.3);
    border-radius: 16px;
    padding: 25px;
    width: 90%;
    max-width: 450px;
    color: #fff;
    text-align: left;
    position: relative;
    box-shadow: 0 0 30px rgba(102, 252, 241, 0.2);
    animation: fadeIn 0.3s;
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    color: #8c9cb0;
    font-size: 1.8rem;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.close-btn:hover {
    color: var(--neon-red);
}

.modal-title {
    color: var(--neon-blue);
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 15px;
    border-bottom: 1px dashed rgba(102, 252, 241, 0.2);
    padding-bottom: 10px;
}

.modal-text {
    font-size: 0.9rem;
    line-height: 1.5;
    color: #d1d5db;
}

.modal-text b {
    color: var(--neon-green);
}