* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background:
        linear-gradient(rgba(255, 250, 229, 0.48), rgba(217, 247, 240, 0.58)),
        url('assets/school-action-background-blinki-play.png') center / cover no-repeat fixed,
        linear-gradient(135deg, #d9f7f0 0%, #fff5d6 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.star-goal {
    display: flex;
    justify-content: center;
    gap: 8px;
    height: 136px;
    margin-bottom: -6px;
    pointer-events: none;
}

.star-goal-text {
    background: rgba(255, 247, 221, 0.92);
    border: 2px solid rgba(255, 212, 90, 0.85);
    border-radius: 999px;
    color: #73550d;
    font-size: 0.98rem;
    font-weight: 900;
    margin: 0 0 12px;
    padding: 8px 16px;
    text-align: center;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.75);
}

.goal-star {
    color: #b5c0c3;
    display: inline-block;
    font-size: 4.25rem;
    font-weight: 900;
    line-height: 1;
    text-shadow:
        0 2px 0 rgba(255, 255, 255, 0.8),
        0 0 12px rgba(31, 122, 140, 0.16);
    -webkit-text-stroke: 2px #74888d;
}

.goal-star:nth-child(1) {
    transform: translateY(58px) rotate(-18deg);
}

.goal-star:nth-child(2) {
    transform: translateY(24px) rotate(-9deg);
}

.goal-star:nth-child(3) {
    transform: translateY(6px);
}

.goal-star:nth-child(4) {
    transform: translateY(24px) rotate(9deg);
}

.goal-star:nth-child(5) {
    transform: translateY(58px) rotate(18deg);
}

.goal-star.earned {
    animation: none;
    color: #ffd45a;
    text-shadow:
        0 2px 0 #ff8a3d,
        0 0 18px rgba(255, 210, 72, 0.95),
        0 0 32px rgba(255, 138, 61, 0.45);
    -webkit-text-stroke: 2px #fff7dd;
}

.goal-star.chasing:not(.earned) {
    animation: none;
    color: #b5c0c3;
    text-shadow:
        0 2px 0 rgba(255, 255, 255, 0.9),
        0 0 18px rgba(255, 210, 72, 0.95),
        0 0 30px rgba(255, 138, 61, 0.42);
    -webkit-text-stroke: 2px #fff7dd;
}

.goal-star.just-earned {
    animation: starEarned 0.8s ease;
}

@keyframes starEarned {
    0% {
        filter: brightness(1);
    }

    45% {
        filter: brightness(1.45);
    }

    100% {
        filter: brightness(1);
    }
}

#app {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(31, 122, 140, 0.18);
    border-radius: 18px;
    padding: 32px;
    max-width: 540px;
    width: 100%;
    box-shadow: 0 18px 45px rgba(31, 122, 140, 0.24);
    backdrop-filter: blur(3px);
}

.site-credit {
    align-items: center;
    color: rgba(23, 63, 70, 0.72);
    display: flex;
    gap: 5px;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 700;
    margin-top: 12px;
    text-align: center;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.7);
}

.swiss-cross {
    background: #e53935;
    border-radius: 2px;
    display: inline-block;
    height: 14px;
    position: relative;
    width: 14px;
}

.swiss-cross::before,
.swiss-cross::after {
    background: #fff;
    content: "";
    left: 50%;
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
}

.swiss-cross::before {
    height: 8px;
    width: 3px;
}

.swiss-cross::after {
    height: 3px;
    width: 8px;
}

.screen {
    display: none;
    text-align: center;
}

.screen.active {
    display: block;
}

.top-bar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-bottom: 18px;
}

.top-bar label {
    color: #3b5960;
    font-size: 0.85rem;
    font-weight: 700;
}

.top-bar select {
    border: 2px solid #b8e2dc;
    border-radius: 999px;
    color: #173f46;
    cursor: pointer;
    font-weight: 700;
    padding: 8px 12px;
    background: #f7fffd;
}

h1 {
    font-size: 2.5rem;
    color: #173f46;
    margin-bottom: 8px;
}

.title-logo {
    display: block;
    height: auto;
    margin: 0 auto 14px;
    max-width: 280px;
    width: 62%;
}

#start-screen .title-logo {
    display: block !important;
    height: auto !important;
    margin: 0 auto 16px !important;
    max-width: min(340px, 82%) !important;
    width: min(340px, 82%) !important;
}

.subtitle {
    color: #4f6b72;
    font-size: 1.1rem;
    margin-bottom: 24px;
}

/* Operation Buttons */
.operation-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 24px;
}

.random-mode-btn {
    grid-column: 1 / -1;
    border-style: dashed;
    background: linear-gradient(135deg, rgba(255, 245, 210, 0.95), rgba(230, 255, 235, 0.95));
}

.op-btn {
    padding: 16px;
    font-size: 1.1rem;
    border: 2px solid #c9e8e2;
    border-radius: 12px;
    background: #fbfffe;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
    color: #173f46;
}

.op-btn:hover {
    border-color: #1f7a8c;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(31, 122, 140, 0.18);
}

.op-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.op-btn:disabled:hover {
    border-color: #c9e8e2;
    box-shadow: none;
}

.op-btn.selected {
    border-color: #1f7a8c;
    background: #1f7a8c;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(31, 122, 140, 0.25);
}

.parent-panel {
    background: #f6fbf9;
    border: 2px solid rgba(31, 122, 140, 0.18);
    border-radius: 18px;
    padding: 28px 24px;
    text-align: left;
}

.parent-top-back-btn {
    background: #f6f9f8;
    border: 2px solid #c9e8e2;
    border-radius: 999px;
    color: #173f46;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 800;
    margin-bottom: 18px;
    padding: 9px 16px;
}

.parent-top-back-btn:hover {
    background: #e8f3f1;
    transform: translateY(-1px);
}

.parent-history {
    margin-top: 24px;
    width: 100%;
}

.parent-history h4 {
    margin-bottom: 12px;
    color: #173f46;
    font-size: 1rem;
    letter-spacing: 0.01em;
}

.parent-history table {
    table-layout: fixed;
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(31, 122, 140, 0.08);
}

.parent-history th,
.parent-history td {
    padding: 10px 6px;
    border-bottom: 1px solid rgba(31, 122, 140, 0.12);
    text-align: left;
    font-size: 0.92rem;
    overflow-wrap: normal;
    word-break: normal;
}

.parent-history th {
    background: rgba(31, 122, 140, 0.08);
    font-size: 0.86rem;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
}

.parent-history th:nth-child(1),
.parent-history td:nth-child(1) {
    width: 22%;
}

.parent-history th:nth-child(2),
.parent-history td:nth-child(2) {
    width: 34%;
}

.parent-history th:nth-child(3),
.parent-history td:nth-child(3),
.parent-history th:nth-child(4),
.parent-history td:nth-child(4) {
    width: 22%;
}

.parent-history th:nth-child(n+3),
.parent-history td:nth-child(n+3) {
    text-align: center;
}

.parent-history tbody tr:nth-child(even) {
    background: rgba(231, 252, 248, 0.8);
}

.parent-history-no-data {
    margin-top: 12px;
    color: #4f6b72;
    font-size: 0.95rem;
}

.parent-intro {
    color: #3b5960;
    line-height: 1.5;
    margin-bottom: 18px;
}

.parent-status {
    background: #e6f7ee;
    border: 1px solid #bbe2ce;
    border-radius: 12px;
    color: #175941;
    padding: 14px;
    margin-bottom: 16px;
}

.parent-form {
    display: grid;
    gap: 14px;
    margin-bottom: 22px;
}

.form-row {
    display: grid;
    gap: 8px;
}

.form-row label {
    color: #3b5960;
    font-size: 0.94rem;
    font-weight: 700;
}

.form-row input,
.form-row select {
    border: 2px solid #c9e8e2;
    border-radius: 12px;
    background: #f7fffd;
    color: #173f46;
    padding: 12px 14px;
    font-size: 1rem;
}

.password-field {
    position: relative;
}

.password-field input {
    padding-right: 64px;
    width: 100%;
}

.password-toggle {
    align-items: center;
    background: #e8f3f1;
    border: 1px solid #b8e2dc;
    border-radius: 999px;
    color: #173f46;
    cursor: pointer;
    display: flex;
    font-size: 0;
    height: 30px;
    justify-content: center;
    position: absolute;
    right: 9px;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
}

.password-toggle::before {
    content: "👁";
    font-size: 1rem;
    font-weight: 800;
    line-height: 1;
}

.password-toggle.is-visible {
    background: #d9f7f0;
    border-color: #1f7a8c;
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.security-check-row {
    align-items: center;
    justify-items: center;
}

.security-check-row label {
    justify-self: start;
}

.form-toggle {
    display: flex;
    justify-content: center;
}

.form-link-row {
    display: flex;
    justify-content: center;
    margin: 0;
}

.text-link-btn {
    background: transparent;
    border: 0;
    color: #1f7a8c;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
    padding: 4px 6px;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.text-link-btn:hover {
    color: #14535f;
}

.parent-form-help {
    color: #3b5960;
    line-height: 1.45;
    margin: -2px 0 2px;
}

.parent-settings > .form-actions:last-child {
    display: grid;
    grid-template-columns: minmax(100px, 0.8fr) minmax(180px, 2.2fr);
    margin: 0 auto;
    max-width: 420px;
    width: 100%;
}

.parent-settings > .form-actions:last-child button {
    width: 100%;
}

.secondary-btn {
    border: 2px solid #c9e8e2;
    background: #f6f9f8;
    color: #173f46;
    border-radius: 12px;
    padding: 10px 18px;
    cursor: pointer;
    font-weight: 700;
}

.secondary-btn:hover {
    background: #e8f3f1;
    transform: translateY(-1px);
}

.parent-settings {
    display: grid;
    gap: 14px;
    margin-top: 18px;
}

.parent-settings h3,
.parent-history h4 {
    margin-bottom: 0;
}

.parent-settings-note {
    background: #fff8df;
    border: 1px solid #f0cf69;
    border-radius: 12px;
    color: #5a4510;
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0;
    padding: 10px 12px;
}

.parent-password-note {
    margin-bottom: 2px;
}

.parent-settings .form-row {
    gap: 8px;
}

.parent-settings .form-row label {
    line-height: 1.2;
}

.checkbox-group {
    display: grid;
    gap: 8px;
    margin-top: 8px;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #3b5960;
    font-weight: 600;
    cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* Settings */
.settings {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
    text-align: left;
}

.setting-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.settings label {
    font-size: 0.9rem;
    color: #3b5960;
    font-weight: 600;
}

.settings select {
    padding: 8px 12px;
    border-radius: 8px;
    border: 2px solid #c9e8e2;
    font-size: 1rem;
    cursor: pointer;
    color: #173f46;
    background: #fbfffe;
}

.setting-hint {
    font-size: 0.8rem;
    color: #6a7f84;
    text-align: center;
    font-style: italic;
}

/* Start Button */
.start-btn {
    padding: 16px 40px;
    font-size: 1.2rem;
    background: linear-gradient(135deg, #ff8a3d, #ffb23f);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.2s ease;
    width: 100%;
}

.start-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 138, 61, 0.32);
}

.start-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.reset-progress-btn {
    background: #f6f9f8;
    border: 2px solid #c9e8e2;
    border-radius: 12px;
    color: #3b5960;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 800;
    margin-top: 12px;
    padding: 12px 20px;
    transition: all 0.2s ease;
    width: 100%;
}

.reset-progress-btn:hover {
    background: #e8f3f1;
    transform: translateY(-1px);
}

.parent-login-cta {
    background:
        linear-gradient(#f7fffd, #f7fffd) padding-box,
        linear-gradient(135deg, #57c7b6, #ffd45a, #ff8a3d) border-box;
    border-color: transparent;
    box-shadow: 0 0 0 rgba(255, 212, 90, 0);
    overflow: hidden;
    padding-right: 92px;
    position: relative;
}

.parent-login-cta::before {
    background: linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.8) 45%, transparent 75%);
    content: "";
    height: 160%;
    left: -80%;
    position: absolute;
    top: -30%;
    transform: rotate(16deg);
    width: 45%;
    animation: freeSweep 2.7s ease-in-out infinite;
}

.parent-login-cta::after {
    background: linear-gradient(135deg, #ff8a3d, #ffd45a);
    border-radius: 999px;
    color: #173f46;
    content: "Gratis";
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.02em;
    padding: 5px 9px;
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    animation: freePulse 1.8s ease-in-out infinite;
}

html[lang="en"] .parent-login-cta::after {
    content: "Free";
}

.parent-login-cta:hover {
    box-shadow: 0 8px 22px rgba(255, 178, 63, 0.24);
}

.parent-login-cta.is-signed-in {
    background: #f6f9f8;
    border-color: #c9e8e2;
    box-shadow: none;
    padding-right: 20px;
}

.parent-login-cta.is-signed-in::before,
.parent-login-cta.is-signed-in::after {
    animation: none;
    content: none;
    display: none;
}

.parent-login-cta.is-signed-in:hover {
    background: #e8f3f1;
    box-shadow: none;
}

@keyframes freeSweep {
    0%, 42% {
        left: -80%;
    }

    68%, 100% {
        left: 125%;
    }
}

@keyframes freePulse {
    0%, 100% {
        transform: translateY(-50%) scale(1);
    }

    50% {
        transform: translateY(-50%) scale(1.06);
    }
}

/* Hard Questions Info */
.hard-info {
    background: #fff7dd;
    border: 2px solid #ffd45a;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}

.hard-info p {
    color: #73550d;
    font-weight: 600;
    margin-bottom: 10px;
}

.practice-hard-btn {
    padding: 10px 20px;
    font-size: 1rem;
    background: #ffd45a;
    color: #173f46;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s ease;
}

.practice-hard-btn:hover {
    background: #ffc83d;
    transform: translateY(-1px);
}

.hidden {
    display: none !important;
}

/* Progress Bar */
.progress-bar {
    width: 100%;
    height: 12px;
    background: #e0e0e0;
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #1f7a8c, #57c7b6);
    border-radius: 6px;
    transition: width 0.3s ease;
    width: 0%;
}

.progress-text {
    color: #4f6b72;
    font-size: 0.9rem;
}

.quiz-status {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 24px;
}

.quiz-actions {
    display: flex;
    gap: 8px;
}

.pause-btn,
.exit-quiz-btn {
    background: #fff7dd;
    border: 2px solid #ffd45a;
    border-radius: 999px;
    color: #73550d;
    cursor: pointer;
    font-weight: 800;
    padding: 9px 18px;
    transition: all 0.2s ease;
}

.exit-quiz-btn {
    background: #f6f9f8;
    border-color: #c9e8e2;
    color: #3b5960;
}

.pause-btn:hover:not(:disabled),
.exit-quiz-btn:hover:not(:disabled) {
    background: #ffeb9c;
    transform: translateY(-1px);
}

.exit-quiz-btn:hover:not(:disabled) {
    background: #e8f3f1;
}

.pause-btn:disabled,
.exit-quiz-btn:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

/* Question Card */
.question-card {
    background: #eefbf8;
    border: 2px solid #d6f1eb;
    border-radius: 12px;
    padding: 32px;
    margin-bottom: 16px;
    position: relative;
}

#quiz-screen {
    position: relative;
}

.timer-bar-container {
    width: 100%;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 12px;
}

.timer-bar {
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg, #dc3545 0%, #ffc107 50%, #28a745 100%);
    border-radius: 4px;
    transition: width 0.1s linear;
}

.timer-display {
    font-size: 1.1rem;
    font-weight: 700;
    color: #555;
    margin-bottom: 8px;
}

.timer-display.warning {
    color: #dc3545;
    animation: pulse 0.5s infinite;
}

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

.question-card h2 {
    font-size: 2rem;
    color: #173f46;
    margin-bottom: 20px;
}

#answer-input {
    width: 100%;
    padding: 16px;
    font-size: 1.5rem;
    text-align: center;
    border: 3px solid #c9e8e2;
    border-radius: 12px;
    outline: none;
    transition: border-color 0.2s;
    margin-bottom: 16px;
}

#answer-input:focus {
    border-color: #1f7a8c;
}

.submit-btn {
    padding: 14px 32px;
    font-size: 1.1rem;
    background: linear-gradient(135deg, #1f7a8c, #57c7b6);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.2s ease;
    width: 100%;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(31, 122, 140, 0.25);
}

.pause-overlay {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-radius: 12px;
    background:
        linear-gradient(rgba(23, 63, 70, 0.86), rgba(31, 122, 140, 0.9)),
        repeating-linear-gradient(45deg, transparent 0 12px, rgba(255, 255, 255, 0.08) 12px 24px);
    color: white;
    padding: 24px;
    text-align: center;
}

.pause-overlay strong {
    font-size: 2rem;
}

.pause-overlay span {
    font-size: 1rem;
    font-weight: 700;
}

/* Honeypot - hidden from humans */
.honeypot {
    position: absolute;
    left: -9999px;
    top: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

/* Lockout Overlay */
.lockout-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    z-index: 10;
    padding: 24px;
}

.lockout-overlay p {
    font-size: 1.2rem;
    font-weight: 700;
    color: #dc3545;
    margin-bottom: 8px;
    text-align: center;
}

/* Feedback */
.feedback {
    padding: 16px;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    animation: fadeIn 0.3s ease;
}

.feedback.correct {
    background: #dff8ed;
    color: #0f5c3d;
    border: 2px solid #35a66f;
}

.feedback.wrong {
    background: #f8d7da;
    color: #721c24;
    border: 2px solid #dc3545;
}

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

/* Result Screen */
.result-emoji {
    margin-bottom: 16px;
    animation: bounce 0.6s ease;
}

.blinki-result-icon {
    display: block;
    filter: drop-shadow(0 12px 18px rgba(31, 122, 140, 0.18));
    height: 132px;
    margin: 0 auto;
    object-fit: contain;
    width: 132px;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

#result-title {
    font-size: 1.8rem;
    color: #173f46;
    margin-bottom: 8px;
}

#result-summary {
    color: #4f6b72;
    font-size: 1.1rem;
    margin-bottom: 12px;
}

.pause-result {
    background: #e8f3f1;
    border: 2px solid #c9e8e2;
    border-radius: 999px;
    color: #173f46;
    display: inline-block;
    font-size: 0.95rem;
    font-weight: 800;
    margin-bottom: 24px;
    padding: 9px 16px;
}

/* Mistakes Section */
.mistakes-section {
    text-align: left;
    background: #fff7dd;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
}

.mistakes-section h3 {
    color: #73550d;
    margin-bottom: 12px;
}

.mistakes-section ul {
    list-style: none;
}

.mistakes-section li {
    padding: 8px 0;
    border-bottom: 1px solid #ffe69c;
    color: #555;
    font-size: 1rem;
}

.mistakes-section li:last-child {
    border-bottom: none;
}

.mistakes-section li .correct-answer {
    color: #1b7f56;
    font-weight: 700;
}

.mistakes-section li .wrong-answer {
    color: #dc3545;
    text-decoration: line-through;
}

.mistakes-section .result-practice-hard-btn {
    margin-top: 16px;
    width: 100%;
}

/* Result Actions */
.result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.retry-btn, .home-btn, .result-practice-hard-btn {
    flex: 1;
    min-width: 0;
    padding: 14px;
    font-size: 1rem;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.2s ease;
}

.retry-btn {
    background: linear-gradient(135deg, #1f7a8c, #57c7b6);
    color: white;
}

.result-practice-hard-btn {
    background: #fff7dd;
    color: #73550d;
    border: 2px solid #ffd45a;
}

.home-btn {
    background: #e8f3f1;
    color: #173f46;
}

#parent-back-home-btn.parent-start-ready {
    background: linear-gradient(135deg, #ff8a3d, #ffb23f);
    color: white;
    box-shadow: 0 6px 20px rgba(255, 138, 61, 0.24);
}

.retry-btn:hover, .home-btn:hover, .result-practice-hard-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(31, 122, 140, 0.18);
}

#parent-back-home-btn.parent-start-ready:hover {
    box-shadow: 0 6px 20px rgba(255, 138, 61, 0.32);
}

.sr-only {
    border: 0;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
}

/* Responsive */
@media (max-width: 480px) {
    body {
        background-attachment: scroll;
        padding: 10px 6px;
    }

    #app {
        border-radius: 16px;
        padding: 14px;
        width: min(100%, 430px);
    }

    .top-bar {
        justify-content: center;
    }

    .setting-row,
    .quiz-status,
    .quiz-actions,
    .result-actions {
        align-items: stretch;
        flex-direction: column;
    }

    h1 {
        font-size: 2rem;
    }

    .title-logo {
        max-width: 280px;
        width: 84%;
    }

    .question-card h2 {
        font-size: 1.5rem;
    }

    .operation-buttons {
        grid-template-columns: 1fr;
    }

    .parent-panel {
        border-radius: 16px;
        padding: 18px 10px;
    }

    .parent-panel h2 {
        font-size: 1.45rem;
    }

    .parent-form h3,
    .parent-settings h3 {
        font-size: 1.25rem;
        line-height: 1.2;
    }

    .parent-form {
        gap: 12px;
    }

    .form-row input,
    .form-row select {
        font-size: 16px;
        padding: 11px 12px;
    }

    .security-check-row {
        justify-items: start;
        overflow: hidden;
    }

    .security-check-row .cf-turnstile {
        max-width: 100%;
    }

    .parent-history th,
    .parent-history td {
        font-size: 0.78rem;
        padding: 8px 5px;
    }

    .parent-settings > .form-actions:last-child {
        grid-template-columns: 1fr;
        max-width: none;
    }
}
