:root {
    color-scheme: light;
}

body {
    min-height: 100vh;
    background: #f4f7fb;
    display: flex;
    flex-direction: column;
}

main { flex: 1 0 auto; }

.site-footer {
    flex: 0 0 auto;
    border-top: 1px solid rgba(93, 112, 128, .16);
    background: rgba(255, 255, 255, .68);
    color: #64717d;
    font-size: .82rem;
}

.site-footer-inner {
    min-height: 4rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: .6rem .85rem;
    padding-block: .85rem;
}

.site-footer a {
    color: inherit;
    text-decoration: none;
    transition: color 140ms ease;
}

.site-footer a:hover { color: #1f5d50; }

.site-footer-divider {
    width: 1px;
    height: 1rem;
    background: #c7d0d7;
}

.public-security-record {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
}

.public-security-record img {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

:focus-visible { outline: 3px solid #f0a35e; outline-offset: 2px; }
.admin-nav, .student-nav { display: flex; flex-wrap: wrap; gap: .75rem 1.25rem; }
.admin-nav-links, .student-nav-links { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem 1rem; }
.admin-nav-links .nav-link, .student-nav-links a, .student-nav-links button { min-height: 2.5rem; display: inline-flex; align-items: center; }

.hero-card {
    max-width: 760px;
    border: 1px solid #e3e9f2;
    background: #ffffff;
}

.page-narrow {
    max-width: 720px;
    margin-inline: auto;
}

.table th {
    white-space: nowrap;
}

.task-description {
    white-space: pre-wrap;
}

.public-page {
    max-width: 900px;
}

.task-card {
    transition: transform 150ms ease, box-shadow 150ms ease;
}

.task-card:hover {
    transform: translateY(-2px);
}

.requirement-box {
    display: flex;
    flex-direction: column;
    gap: .25rem;
    padding: 1rem;
    border-radius: .75rem;
    background: #f4f7fb;
}

.requirement-box span {
    color: #6c757d;
    font-size: .875rem;
}

.success-card {
    border-top: 4px solid #198754 !important;
}

.success-mark {
    display: grid;
    place-items: center;
    width: 4rem;
    height: 4rem;
    border-radius: 50%;
    color: #fff;
    background: #198754;
    font-size: 2rem;
    font-weight: 700;
}
.submission-attachment-cell { min-width: 12rem; }
.task-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .4rem; }
.student-shell { background: #f3f5ef; color: #18332d; min-height: 100vh; }
.student-navbar { background: rgba(243, 245, 239, .92); border-bottom: 1px solid #d4ddd5; backdrop-filter: blur(12px); }
.student-navbar a { color: #1f5d50; }
.auth-panel { max-width: 520px; background: #fffef9; border: 1px solid #dce3d8; border-radius: 1.5rem; padding: clamp(1.5rem, 5vw, 3rem); box-shadow: 0 24px 70px rgba(30, 68, 58, .11); }
.auth-kicker { color: #b05d34; font-size: .75rem; font-weight: 800; letter-spacing: .16em; margin-bottom: .75rem; }
.identity-strip { display: grid; gap: .2rem; padding: 1rem 1.15rem; border: 1px solid #cbdcd4; border-left: 4px solid #1f725f; border-radius: .8rem; background: #f5faf7; }
.student-hero { display: flex; align-items: end; justify-content: space-between; gap: 2rem; padding: clamp(1.5rem, 4vw, 3rem); border-radius: 1.6rem; background: linear-gradient(130deg, #fffdf6 0%, #e7f0e9 100%); border: 1px solid #d6dfd4; }
.student-task-card, .history-card { padding: 1.35rem; border-radius: 1.1rem; background: #fffef9; border: 1px solid #dce3d8; box-shadow: 0 12px 30px rgba(30, 68, 58, .06); }
.history-attachment { padding: .9rem 0; border-top: 1px solid #e5e8df; }
.student-empty { padding: 3rem 1.5rem; text-align: center; border: 1px dashed #acbcae; border-radius: 1.2rem; background: rgba(255, 254, 249, .7); }
@media (max-width: 767.98px) {
  .student-hero { align-items: start; flex-direction: column; }
  .admin-nav, .student-nav { align-items: flex-start; flex-direction: column; }
  .admin-nav-links, .student-nav-links { width: 100%; }
  .table-responsive { border-radius: .75rem; }
  .task-actions { justify-content: flex-start; min-width: 9rem; }
  .btn, .form-control, .form-select { min-height: 2.75rem; }
  .site-footer-inner { flex-direction: column; gap: .45rem; }
  .site-footer-divider { display: none; }
}
