* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

:root {
    --transition: all 0.3s ease;
}

html, body {
    width: 100%;
    height: 100%;
    font-family: 'Segoe UI', system-ui, sans-serif;
}

/* ================= BASE ================= */
body {
    min-height: 100vh;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    transition: background 1.5s ease-in-out;
}

/* ================= THEME TOGGLE ================= */
.theme-toggle {
    position: fixed;
    top: 18px;
    right: 18px;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.4);
    background: rgba(255,255,255,0.15);
    color: white;
    font-size: 1.25rem;
    backdrop-filter: blur(10px);
    cursor: pointer;
    transition: var(--transition);
    z-index: 999;
}

.theme-toggle:hover {
    transform: rotate(20deg) scale(1.05);
}

.theme-toggle:active {
    transform: scale(0.9);
}

/* ================= CONTAINER LAYOUT ================= */
.exam-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
    text-align: center;
}

h1 {
    font-size: 2.8rem;
    letter-spacing: 2px;
    text-shadow: 0 0 12px rgba(255,255,255,0.35);
}

.special-btn {
    padding: 15px 30px;
    background: linear-gradient(135deg, #00c6ff, #0072ff);
    color: white;
    font-size: 1.1rem;
    font-weight: bold;
    border-radius: 50px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
    text-align: center;
    user-select: none;
    pointer-events: none;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.button-stack {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.button-stack a {
    min-width: 260px;
    padding: 18px 40px;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    color: white;
    border-radius: 10px;
    border: 2px solid rgba(255,255,255,0.35);
    background: rgba(255,255,255,0.12);
    backdrop-filter: blur(12px);
    transition: var(--transition);
    box-shadow: 0 0 20px rgba(0,0,0,0.25);
}

/* Desktop hover behavior */
@media (hover: hover) {
    .button-stack a:hover {
        transform: scale(1.05);
        background: rgba(255,255,255,0.25);
        box-shadow: 0 10px 30px rgba(0,0,0,0.35);
    }
}

/* ================= MOBILE MODE ================= */
@media (max-width: 768px), (pointer: coarse) {

    body {
        padding: env(safe-area-inset-top)
                 env(safe-area-inset-right)
                 env(safe-area-inset-bottom)
                 env(safe-area-inset-left);
    }

    .exam-container {
        width: 100%;
        max-width: 420px;
        gap: 30px;
        padding: 20px;
    }

    h1 {
        font-size: 1.8rem;
        letter-spacing: 0.15em;
    }

    .special-btn {
        padding: 12px 20px;
        font-size: 0.95rem;
    }

    .button-stack {
        width: 100%;
        gap: 18px;
    }

    .button-stack a {
        width: 100%;
        padding: 20px;
        font-size: 1.05rem;
        border-radius: 16px;
        box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    }

    /* Mobile tap feedback instead of hover */
    .button-stack a:active {
        transform: scale(0.96);
        background: rgba(255,255,255,0.28);
    }
}
