* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, "Malgun Gothic", sans-serif;
    color: #172033;
    background: #eef3f8;
    line-height: 1.6;
}

a {
    color: #0f6b8d;
    text-decoration: none;
}

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 28px;
    background: #ffffff;
    border-bottom: 1px solid #dce5ee;
    box-shadow: 0 8px 28px rgba(15, 35, 55, 0.06);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-size: 19px;
    font-weight: 700;
    color: #0d2f3f;
}

.brand-icon {
    width: 30px;
    height: 30px;
    object-fit: contain;
    flex: 0 0 auto;
}

.topbar nav {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.topbar nav a {
    padding: 8px 11px;
    border-radius: 999px;
    color: #334155;
    background: #f5f8fb;
    font-size: 14px;
}

.topbar nav a:hover {
    color: #ffffff;
    background: #0f6b8d;
}

.wrap {
    width: min(1180px, 100%);
    margin: 0 auto;
    padding: 28px 18px 48px;
}

.hero,
.panel,
.card,
.result,
.exam-card,
.course-strip {
    background: #ffffff;
    border: 1px solid #dce5ee;
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 18px;
    box-shadow: 0 12px 30px rgba(15, 35, 55, 0.06);
}

.hero {
    background: linear-gradient(135deg, #0f3d4d 0%, #146c7d 55%, #1c8a8a 100%);
    color: #ffffff;
    border: 0;
}

.exam-hero,
.admin-hero {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 20px;
}

.hero h1,
.panel h1,
.result h1 {
    margin: 0 0 8px;
}

.hero h1 {
    max-width: 720px;
    font-size: 32px;
    line-height: 1.25;
}

.hero p {
    margin: 6px 0;
}

.eyebrow {
    display: inline-block;
    margin: 0 0 10px;
    color: #bff4ff;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.hero-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 18px;
}

.hero-tags span,
.pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 5px 10px;
    background: #e8f7fa;
    color: #0f5c72;
    font-size: 12px;
    font-weight: 700;
}

.hero-tags span {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
}

.hero-summary {
    min-width: 210px;
    padding: 22px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-summary strong {
    display: block;
    font-size: 46px;
    line-height: 1;
}

.hero-summary span,
.hero-summary small {
    display: block;
}

.hero-actions {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

.exam-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 18px;
}

.course-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    padding: 18px;
}

.course-strip div {
    padding: 12px 14px;
    border-radius: 8px;
    background: #f7fafc;
}

.course-strip strong,
.course-strip span {
    display: block;
}

.course-strip strong {
    color: #64748b;
    font-size: 13px;
}

.course-strip span {
    color: #0f2633;
    font-weight: 700;
}

.card h2 {
    margin-top: 0;
}

.exam-card {
    position: relative;
    overflow: hidden;
}

.exam-card:before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background: #178c8c;
}

.exam-card.completed:before {
    background: #16a34a;
}

.exam-card h2 {
    margin: 12px 0 8px;
    font-size: 20px;
    line-height: 1.35;
}

.exam-card p {
    min-height: 48px;
}

.card-topline {
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.pill.primary {
    color: #075985;
    background: #e0f2fe;
}

.pill.done {
    color: #166534;
    background: #dcfce7;
}

.pill.danger {
    color: #991b1b;
    background: #fee2e2;
}

.exam-meta {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin: 18px 0;
}

.exam-meta span {
    padding: 10px;
    border-radius: 8px;
    background: #f3f7fb;
    color: #475569;
    text-align: center;
    font-size: 13px;
}

.exam-meta strong {
    display: block;
    color: #0f3d4d;
    font-size: 20px;
}

.muted {
    color: #6b7280;
    font-size: 14px;
}

.notice,
.warning {
    padding: 12px 14px;
    border-radius: 8px;
    margin-bottom: 16px;
}

.notice {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.warning {
    background: #fff7ed;
    color: #9a3412;
    border: 1px solid #fed7aa;
}

.button,
button {
    display: inline-block;
    border: 0;
    border-radius: 6px;
    padding: 10px 14px;
    background: #0f6b8d;
    color: #ffffff;
    font-size: 14px;
    cursor: pointer;
}

.button.ghost {
    color: #0f6b8d;
    background: #e8f7fa;
}

.button.danger-button,
.danger-button {
    background: #dc2626;
    color: #ffffff;
}

.button.danger-button:hover,
.danger-button:hover {
    background: #b91c1c;
}

.delete-warning {
    padding: 12px;
    border-radius: 6px;
}

label {
    display: block;
    margin: 12px 0;
    font-weight: 700;
}

input,
textarea,
select {
    width: 100%;
    margin-top: 6px;
    padding: 10px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font: inherit;
    background: #ffffff;
}

textarea {
    resize: vertical;
}

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

.form-row.two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-row.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.form-row.four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.filter-form {
    margin-top: 12px;
}

.check {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 32px;
}

.checks {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
    margin: 10px 0;
}

.checks .check {
    margin: 0;
}

.course-checks {
    margin: 16px 0;
    padding: 14px;
    border: 1px solid #dce5ee;
    border-radius: 8px;
    background: #f7fafc;
}

.course-checks legend {
    padding: 0 6px;
    font-weight: 800;
    color: #0f3d4d;
}

.course-checks .check {
    margin: 8px 0;
    padding: 9px 10px;
    border-radius: 8px;
    background: #ffffff;
}

.consent-box {
    background: #f8fafc;
}

.policy-summary {
    margin: 12px 0;
    padding: 14px;
    border: 1px solid #d6e3ef;
    border-radius: 8px;
    background: #ffffff;
}

.policy-summary h2 {
    margin: 0 0 8px;
    font-size: 17px;
}

.policy-summary ul {
    margin: 8px 0 0;
    padding-left: 20px;
}

.guardian-fields {
    margin-top: 12px;
    padding: 12px;
    border-radius: 8px;
    border: 1px dashed #cbd5e1;
    background: #ffffff;
}

.guardian-fields.is-required {
    border-color: #2563eb;
    background: #eff6ff;
}

.consent-admin-card {
    padding: 18px;
    border: 1px solid #dce5ee;
    border-radius: 8px;
    background: #f8fafc;
}

.guardian-verify-list {
    margin: 12px 0;
    padding: 12px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #ffffff;
}

.guardian-verify-list .check {
    align-items: flex-start;
    margin-top: 8px;
}

.guardian-verify-list.verified {
    border-color: #86efac;
    background: #f0fdf4;
}

.policy-page h2 {
    margin-top: 24px;
    font-size: 20px;
}

.consent-print {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    background: #ffffff;
}

.consent-table {
    margin: 20px 0;
    border: 1px solid #333333;
}

.consent-table th,
.consent-table td {
    height: 54px;
    border: 1px solid #333333;
}

.consent-table th {
    width: 18%;
    background: #f1f5f9;
}

.signature-box {
    margin-top: 24px;
    padding: 20px;
    border: 1px solid #333333;
    line-height: 2;
}

.inline-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.check input {
    width: auto;
    margin: 0;
}

.timer {
    position: sticky;
    top: 0;
    z-index: 1;
    margin: -8px -8px 18px;
    padding: 12px;
    background: #0f3d4d;
    color: #ffffff;
    border-radius: 6px;
    text-align: center;
}

.paper-cover,
.exam-paper,
.result-sheet {
    position: relative;
    overflow: hidden;
    margin-bottom: 18px;
    padding: 30px;
    border: 1px solid #d6cdb9;
    border-radius: 8px;
    background:
        linear-gradient(90deg, rgba(15, 61, 77, 0.035) 1px, transparent 1px),
        linear-gradient(#fffdf7, #fffaf0);
    background-size: 28px 28px, auto;
    box-shadow: 0 18px 38px rgba(61, 46, 20, 0.12);
}

.paper-cover {
    color: #172033;
    min-height: 250px;
}

.paper-cover .eyebrow {
    color: #0f6b8d;
}

.paper-cover h1 {
    max-width: 760px;
    margin: 0 0 10px;
    font-size: 32px;
    line-height: 1.25;
}

.paper-mark,
.result-stamp {
    position: absolute;
    right: 28px;
    top: 28px;
    width: 96px;
    height: 96px;
    border: 4px double rgba(180, 40, 40, 0.5);
    border-radius: 50%;
    color: rgba(180, 40, 40, 0.58);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    transform: rotate(-14deg);
}

.paper-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
    margin-top: 24px;
    padding-top: 18px;
    border-top: 2px solid #e4dac7;
}

.paper-info div {
    padding: 12px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid #eadfca;
}

.paper-info span,
.paper-info strong {
    display: block;
}

.paper-info span {
    color: #7c6f5c;
    font-size: 12px;
}

.paper-info strong {
    color: #172033;
    font-size: 15px;
}

.paper-timer {
    display: grid;
    grid-template-columns: auto auto 1fr;
    align-items: center;
    gap: 10px;
    margin: 0 0 22px;
    border-radius: 8px;
}

.paper-timer strong {
    font-size: 24px;
}

.paper-timer em {
    text-align: right;
    font-style: normal;
    color: #d9fbff;
    font-size: 13px;
}

.paper-question {
    position: relative;
    display: grid;
    grid-template-columns: 46px 1fr;
    gap: 14px;
    padding: 22px 0;
    border-top: 1px dashed #d9cdb8;
}

.question-number {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #0f6b8d;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
}

.paper-question h2 {
    margin-top: 5px;
    color: #162435;
}

.paper-question .choice {
    background: rgba(255, 255, 255, 0.78);
}

.paper-question .choice span {
    display: flex;
    gap: 10px;
}

.paper-question .choice b {
    min-width: 25px;
    height: 25px;
    border-radius: 50%;
    background: #edf7f9;
    color: #0f6b8d;
    text-align: center;
    line-height: 25px;
}

.submit-bar {
    position: sticky;
    bottom: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin: 20px -12px -12px;
    padding: 16px;
    border-radius: 8px;
    background: #fffaf0;
    border: 1px solid #eadfca;
}

.result-sheet {
    text-align: center;
}

.result-stamp {
    top: 26px;
    right: 30px;
    font-size: 18px;
}

.result-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    max-width: 560px;
    margin: 20px auto;
}

.result-metrics span {
    padding: 14px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid #eadfca;
}

.result-metrics strong {
    display: block;
    font-size: 24px;
    color: #0f6b8d;
}

.question {
    padding: 18px 0;
    border-top: 1px solid #e5e7eb;
}

.question h2 {
    font-size: 18px;
}

.choice {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 10px;
    border: 1px solid #dce5ee;
    border-radius: 6px;
    font-weight: 400;
}

.choice input {
    width: auto;
    margin-top: 5px;
}

.choice:hover {
    background: #f0fdfa;
    border-color: #99f6e4;
}

.result {
    text-align: center;
}

.result.pass {
    border-color: #86efac;
}

.result.fail {
    border-color: #fca5a5;
}

.review-item {
    padding: 14px 0;
    border-top: 1px solid #e5e7eb;
}

.review-item h2 {
    font-size: 17px;
    margin: 0 0 8px;
}

.review-item.ok {
    color: #065f46;
}

.review-item.no {
    color: #991b1b;
}

.badge {
    display: inline-block;
    margin: 0;
    padding: 6px 12px;
    border-radius: 999px;
    background: #eef2ff;
    color: #3730a3;
    font-weight: 700;
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 16px;
    margin-bottom: 18px;
}

.stat {
    display: block;
    padding: 24px;
    border: 1px solid #dce5ee;
    border-radius: 8px;
    background: #ffffff;
    color: #111827;
}

.stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px rgba(15, 35, 55, 0.08);
}

.stat strong {
    display: block;
    font-size: 34px;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
    gap: 18px;
}

.admin-actions {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.action-card {
    min-height: 138px;
    padding: 20px;
    border-radius: 8px;
    color: #172033;
    background: #ffffff;
    border: 1px solid #dce5ee;
    box-shadow: 0 12px 30px rgba(15, 35, 55, 0.06);
}

.action-card strong {
    display: block;
    margin-bottom: 8px;
    color: #0f3d4d;
    font-size: 18px;
}

.action-card span {
    color: #64748b;
    font-size: 14px;
}

.action-card:hover {
    background: #f0fdfa;
    border-color: #99f6e4;
    transform: translateY(-2px);
}

.mini-metrics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin: 16px 0;
}

.mini-metrics div {
    padding: 16px;
    border-radius: 8px;
    background: #f3f7fb;
}

.mini-metrics strong {
    display: block;
    color: #0f6b8d;
    font-size: 28px;
}

.mini-metrics span {
    color: #64748b;
    font-size: 13px;
}

.quick-links {
    display: grid;
    gap: 8px;
    margin-top: 18px;
}

.quick-links a {
    padding: 11px 12px;
    border-radius: 8px;
    background: #f7fafc;
    color: #0f3d4d;
    font-weight: 700;
}

.compact-table th,
.compact-table td {
    font-size: 13px;
}

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

table {
    width: 100%;
    border-collapse: collapse;
    table-layout: auto;
    background: #ffffff;
    border-radius: 8px;
    overflow: hidden;
}

th,
td {
    padding: 10px;
    border-bottom: 1px solid #e7edf3;
    text-align: left;
    vertical-align: top;
    overflow-wrap: anywhere;
}

th {
    background: #f3f7fb;
    color: #334155;
}

.actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.actions form {
    display: inline;
}

.actions button {
    padding: 4px 8px;
    background: #dc2626;
}

.inline-reset {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) auto;
    gap: 6px;
    min-width: 220px;
}

.inline-reset input {
    margin-top: 0;
    padding: 7px;
}

.inline-reset button {
    margin-top: 0;
    padding: 7px 9px;
}

.member-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.member-actions form {
    margin: 0;
}

.member-actions .button,
.member-actions button {
    margin: 0;
    padding: 7px 10px;
    white-space: nowrap;
}

.login {
    max-width: 420px;
    margin: 40px auto;
}

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

.auth-page {
    background: #f4f4f4;
}

.auth-page .topbar,
.auth-page .footer {
    display: none;
}

.auth-page .wrap {
    width: 100%;
    min-height: 100vh;
    padding: 0;
}

.auth-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: linear-gradient(#ffffff 0, #ffffff 72%, #f4f4f4 72%, #f4f4f4 100%);
}

.auth-card {
    width: min(100%, 393px);
    margin: 0 auto;
    padding: 54px 48px 40px;
    background: #ffffff;
}

.auth-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 48px;
    color: #000000;
    white-space: nowrap;
}

.kdec-mark {
    width: 50px;
    height: 50px;
    display: block;
    object-fit: contain;
    flex: 0 0 auto;
}

.kdec-word {
    display: flex;
    flex-direction: column;
    line-height: 1;
}

.kdec-word strong {
    display: block;
    font-size: 30px;
    font-weight: 900;
    letter-spacing: 7px;
}

.kdec-word small {
    display: block;
    margin-top: 4px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.auth-card input {
    width: 100%;
    height: 40px;
    margin: 0 0 11px;
    padding: 0 8px;
    border: 1px solid #c8d1df;
    border-radius: 3px;
    background: #e8f0ff;
    color: #000000;
    font-size: 14px;
}

.auth-card input:focus {
    border-color: #4f83ee;
    outline: 2px solid rgba(79, 131, 238, 0.18);
}

.auth-submit {
    width: 100%;
    height: 46px;
    margin-top: 0;
    border-radius: 4px;
    background: #4f83ee;
    color: #ffffff;
    font-size: 15px;
    font-weight: 700;
}

.auth-submit:hover {
    background: #356fdf;
}

.auth-links {
    margin-top: 18px;
    text-align: center;
    color: #8b8f99;
    font-size: 13px;
}

.auth-links a {
    color: #8b8f99;
}

.auth-caption {
    margin: -24px 0 24px;
    text-align: center;
    color: #315f9f;
    font-weight: 700;
}

.auth-note {
    margin: 18px 0 0;
    text-align: center;
    color: #7a8290;
    font-size: 13px;
}

.auth-bottom {
    min-height: 88px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-top: 1px solid #dddddd;
    background: #f4f4f4;
}

.auth-back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 190px;
    height: 36px;
    border-radius: 999px;
    background: #333333;
    color: #ffffff;
    font-size: 13px;
}

.auth-back:hover {
    color: #ffffff;
    background: #111111;
}

.admin-auth-card .auth-logo {
    margin-bottom: 34px;
}

.user-score-stats {
    margin-bottom: 18px;
}

.panel form + form {
    margin-top: 14px;
}

.footer {
    padding: 24px;
    text-align: center;
    color: #6b7280;
    font-size: 13px;
}

@media (max-width: 720px) {
    body {
        background: #f5f8fb;
    }

    .topbar,
    .split,
    .exam-hero,
    .admin-hero {
        align-items: flex-start;
        flex-direction: column;
    }

    .topbar {
        padding: 13px 14px;
    }

    .topbar nav {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
    }

    .topbar nav a {
        text-align: center;
        padding: 9px 8px;
        font-size: 13px;
    }

    .wrap {
        padding: 16px 10px 34px;
    }

    .course-strip,
    .dashboard-grid,
    .admin-actions,
    .paper-info,
    .result-metrics {
        grid-template-columns: 1fr;
    }

    .exam-grid,
    .stats,
    .grid {
        grid-template-columns: 1fr;
    }

    .paper-timer,
    .paper-question,
    .submit-bar {
        display: block;
    }

    .hero,
    .panel,
    .card,
    .exam-card,
    .paper-cover,
    .exam-paper,
    .result,
    .course-strip {
        padding: 18px;
        margin-bottom: 12px;
    }

    .paper-mark,
    .result-stamp {
        position: static;
        margin-bottom: 12px;
        width: 72px;
        height: 72px;
        font-size: 14px;
    }

    .hero h1 {
        font-size: 25px;
    }

    .exam-meta {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
    }

    .exam-meta span {
        padding: 8px 4px;
        font-size: 12px;
    }

    .exam-meta strong {
        font-size: 17px;
    }

    .choice {
        padding: 13px 10px;
    }

    .paper-question .choice span {
        display: grid;
        grid-template-columns: 28px 1fr;
        gap: 8px;
    }

    .submit-bar {
        position: static;
        margin: 18px 0 0;
    }

    .submit-bar .button,
    .button,
    button {
        width: 100%;
        text-align: center;
        margin-top: 6px;
    }

    .actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .actions form,
    .actions button {
        width: 100%;
    }

     .form-row.two {
         grid-template-columns: 1fr;
     }
 
     .form-row.three {
         grid-template-columns: 1fr;
     }
 
     .form-row.four {
         grid-template-columns: 1fr;
     }

    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

@media (min-width: 721px) and (max-width: 1020px) {
    .admin-actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .paper-info {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .form-row.four {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1280px) {
    .wrap {
        width: min(1240px, 100%);
    }

    .exam-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .hero h1 {
        font-size: 36px;
    }
}

@media (min-width: 1021px) and (max-width: 1279px) {
    .exam-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-actions {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .brand {
        font-size: 17px;
    }

    .auth-card {
        padding-left: 32px;
        padding-right: 32px;
    }

    .auth-logo {
        gap: 6px;
        transform: scale(0.88);
        transform-origin: center;
    }

    .kdec-word strong {
        font-size: 27px;
        letter-spacing: 5px;
    }

    .topbar nav {
        grid-template-columns: 1fr;
    }

    .hero h1,
    .paper-cover h1 {
        font-size: 22px;
    }

    .hero-summary {
        min-width: 0;
        width: 100%;
    }

    .hero-summary strong {
        font-size: 38px;
    }

    .exam-meta {
        grid-template-columns: 1fr;
    }

    .paper-cover,
    .exam-paper,
    .result-sheet {
        padding: 14px;
    }

    .question-number {
        margin-bottom: 10px;
    }

    input,
    textarea,
    select {
        font-size: 16px;
    }
}

@media (max-width: 360px) {
    .wrap {
        padding-left: 8px;
        padding-right: 8px;
    }

    .hero,
    .panel,
    .card,
    .exam-card,
    .paper-cover,
    .exam-paper,
    .result,
    .course-strip {
        padding: 12px;
    }

    .topbar nav a {
        font-size: 12px;
    }

    .paper-question .choice span {
        grid-template-columns: 24px 1fr;
    }
}

@media print {
    body {
        background: #ffffff;
    }

    .topbar,
    .footer,
    .button,
    button,
    .submit-bar,
    .timer {
        display: none !important;
    }

    .wrap {
        width: 100%;
        padding: 0;
    }

    .paper-cover,
    .exam-paper,
    .result-sheet,
    .panel {
        box-shadow: none;
        border-color: #999999;
        page-break-inside: avoid;
    }
}
