/* =====================
   RESET
   ===================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
    height: 100dvh;
    overflow: hidden;
}

body {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    transition: background 0.3s, color 0.3s;
}

/* =====================
   TYPOGRAPHY
   ===================== */
h1 {
    font-family: var(--font-title);
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text);
    line-height: 1;
}

h1 em {
    font-style: italic;
    color: var(--muted);
}

/* =====================
   ARABIC TEXT
   ===================== */
.arabic-text {
    font-family: var(--font-arabic);
    font-size: 1.2em;
    direction: rtl;
}

/* ── Dyslexia-friendly font (Atkinson Hyperlegible) ── */
body.dyslexia-font {
    font-family: 'Atkinson Hyperlegible', system-ui, -apple-system, sans-serif;
}

body.dyslexia-font .non-arabic,
body.dyslexia-font h1,
body.dyslexia-font .settings-row-title,
body.dyslexia-font .io-row-title,
body.dyslexia-font .continue-title {
    font-family: 'Atkinson Hyperlegible', system-ui, -apple-system, sans-serif;
}

/* ── Font scale ── */
html.font-small  { font-size: 14px; }
html.font-medium { font-size: 16px; }
html.font-large  { font-size: 22px; }

/* ── Desktop garden vignette background ── */
@media (min-width: 1024px) {
    body::before {
        content: '';
        position: fixed;
        inset: 0;
        background:
            radial-gradient(ellipse at 8% 40%, rgba(141,184,122,0.07) 0%, transparent 55%),
            radial-gradient(ellipse at 92% 60%, rgba(141,184,122,0.07) 0%, transparent 55%);
        pointer-events: none;
        z-index: 0;
    }
}

/* =====================
   BUTTON BASE
   ===================== */
button {
    cursor: pointer;
    border: none;
    font-family: var(--font-button);
    transition: .2s;
    background: none;
    color: inherit;
}

button:active  { opacity: 0.85; }
button:disabled { cursor: not-allowed; }
