.card-front {
    min-height: 40vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem 1rem;
    gap: 0.5rem;
}

.card-definition {
    font-size: 1.4rem;
    font-weight: 500;
    line-height: 1.5;
}

.card-dan-zi {
    color: var(--fg-muted);
}

.card-example {
    font-size: 1rem;
    color: var(--fg-muted);
    font-style: italic;
    max-width: 480px;
    text-align: left;
}

.card-picture {
    max-width: min(320px, 80vw);
    border-radius: 8px;
}

/* flashcard.css */

.card-strokes {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
}

.card-strokes-svg {
    width: clamp(80px, 20vw, 130px);
    height: clamp(80px, 20vw, 130px);
    pointer-events: none; 
    overflow: hidden;
    display: block;
}

.card-hanzi {
    font-family: var(--font-cjk);
    font-size: 4rem;
    font-weight: 700;
    line-height: 1.1;
}

.card-question {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--fg-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.card-cloze {
    font-family: var(--font-cjk);
    font-size: 2rem;
    font-weight: 600;
    line-height: 1.4;
}

.card-cloze-placeholder {
    color: var(--link);
}

/* ── Progress bar ─────────────────────────────────────── */
#progress {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 0.45rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--fg-muted);
    text-align: center;
}

#status {
    padding: 1rem;
}

/* ── Card container ──────────────────────────────────── */
#card-container {
    padding-bottom: 6rem;      /* clear fixed response bar */
    min-height: calc(100vh - 3.5rem);
}

#card-front {
    padding: 0 0 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
}

/* callout inside card-front (e.g. Autres sens) should be left-aligned */
#card-front .callout {
    text-align: left;
    align-self: stretch;
}

#card-divider {
    display: none;
    margin: 0.75rem 0;
    border: none;
    border-top: 1px solid var(--border);
}

#card-back {
    display: none;
    padding: 0 0 1rem;
}

/* ── Response bar ────────────────────────────────────── */
#response-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 10;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    padding-bottom: calc(1.5rem + env(safe-area-inset-bottom));
    background: transparent;
}

.resp-btn {
    padding: 0.45rem 1.4rem;
    border: 1px solid #c8bfb4;
    border-radius: 999px;
    background: #faf7f2;
    font-family: var(--font-cjk), var(--font);
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.15);
    -webkit-tap-highlight-color: transparent;
    transition: background 0.15s, border-color 0.15s, filter 0.12s;
}
.resp-btn:active { filter: brightness(0.88); }
.resp-btn:hover  { background: #ede6da; border-color: #a09080; }

.resp-days {
    font-size: 1.5rem;
    font-family: var(--font-cjk), var(--font);
}

.resp-hard { color: #c0392b; }
.resp-good { color: #1a6fa8; }
.resp-easy { color: #1a7a44; }

/* ── Completion message ──────────────────────────────── */
.complete-msg {
    text-align: center;
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--fg-muted);
    padding: 3rem 1rem;
}
