.student-portal { min-height: 100vh; display: flex; flex-direction: column; }
.student-header { background: var(--surface); border-bottom: 1px solid var(--line); }
.student-header-inner { min-height: 92px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-block: 12px; }
.student-logo { width: 218px; max-height: 66px; object-fit: contain; }
.student-header-actions { display: flex; align-items: center; gap: 22px; }
.student-header-actions form { margin: 0; }
.student-site-link { color: var(--muted); font-size: 14px; font-weight: 700; }
.student-site-link:hover { color: var(--primary); }
.student-main { flex: 1; padding-block: 48px; }
.student-footer { padding: 20px 16px; border-top: 1px solid var(--line); text-align: center; color: var(--muted); font-size: 13px; }
.student-footer span { margin-inline: 10px; }
.student-login { max-width: 1020px; min-height: 65vh; margin: auto; display: grid; grid-template-columns: 1fr 430px; gap: 88px; align-items: center; }
.student-eyebrow { display: block; color: var(--accent); font-weight: 800; font-size: 13px; margin-bottom: 9px; }
.student-welcome h1 { font-size: clamp(38px, 5vw, 60px); line-height: 1.35; margin: 0 0 22px; letter-spacing: -.8px; }
.student-welcome > p { color: var(--muted); font-size: 19px; line-height: 1.9; max-width: 440px; }
.student-coming { display: flex; gap: 10px; align-items: center; color: var(--muted); font-size: 14px; margin-top: 28px; }
.student-coming-dot { width: 8px; height: 8px; flex-shrink: 0; background: var(--accent); border-radius: 50%; }
.student-login-card { padding: 32px; }
.student-login-card h2 { font-size: 28px; margin: 0 0 8px; }
.student-login-card > .muted { margin: 0 0 28px; line-height: 1.7; }
.student-login-card .field { margin-bottom: 22px; }
.student-login-card .field small { line-height: 1.8; font-size: 13px; }
.student-login-submit { width: 100%; font-size: 16px; }
.student-login-help { font-size: 13px; color: var(--muted); line-height: 1.8; text-align: center; margin: 20px 0 0; }
.student-page-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 28px; }
.student-page-heading h1 { font-size: clamp(25px, 3vw, 34px); margin: 0 0 9px; overflow-wrap: anywhere; }
.student-page-heading p { margin: 0; line-height: 1.8; }
.student-page-heading > .btn { flex-shrink: 0; }
.student-balance { background: var(--primary-deep); color: white; border-radius: 22px; padding: 32px 36px; display: flex; justify-content: space-between; gap: 24px; align-items: flex-end; }
.student-balance h2 { color: #dbeafa; font-size: 17px; font-weight: 500; margin: 0 0 14px; }
.student-balance-amount { font-size: clamp(38px, 6vw, 58px); font-weight: 800; line-height: 1.25; margin: 0 0 12px; overflow-wrap: anywhere; }
.student-balance-amount span { font-size: 19px; font-weight: 500; }
.student-balance-note, .student-balance-date { font-size: 14px; color: #dbeafa; line-height: 1.8; margin: 0; }
.student-balance-date { flex-shrink: 0; }
.student-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-block: 20px 32px; }
.student-metric { padding: 24px; box-shadow: none; }
.student-metric > span { color: var(--muted); font-size: 14px; display: block; margin-bottom: 12px; }
.student-metric strong { font-size: 27px; overflow-wrap: anywhere; }
.student-metric small { font-size: 14px; font-weight: 500; color: var(--muted); }
.student-notice { margin-block: 24px; padding: 20px 24px; border: 1px solid #e8d7a2; background: #fffbeb; color: #71541b; border-radius: 14px; }
.student-notice p { line-height: 1.8; margin: 8px 0 0; font-size: 14px; }
.student-section-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.student-section-heading h2 { font-size: 22px; margin: 0; }
.student-section-heading > span { font-size: 14px; }
.student-invoice-list { display: grid; gap: 18px; }
.student-invoice { padding: 26px; box-shadow: none; }
.student-invoice-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.student-invoice h3 { font-size: 21px; margin: 0 0 9px; overflow-wrap: anywhere; }
.student-invoice-heading p { font-size: 14px; margin: 0; line-height: 1.8; }
.student-status { display: inline-block; border-radius: 8px; padding: 7px 12px; flex-shrink: 0; background: var(--accent-soft); color: var(--primary); font-size: 13px; font-weight: 700; }
.student-status--paid, .student-status--free { color: #216146; background: #edf8f1; }
.student-status--overdue { color: #9a3412; background: #fff0e7; }
.student-invoice-values { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 24px 0 20px; padding-top: 22px; border-top: 1px solid var(--line); gap: 16px; }
.student-invoice-values dt { color: var(--muted); font-size: 13px; margin-bottom: 8px; }
.student-invoice-values dd { font-size: 23px; font-weight: 700; margin: 0; overflow-wrap: anywhere; }
.student-invoice-values small { font-size: 13px; font-weight: 400; }
.student-invoice-remaining dd { color: var(--primary); }
.student-invoice-meta { display: flex; flex-wrap: wrap; gap: 10px 24px; font-size: 13px; color: var(--muted); }
.student-coming-footer { justify-content: center; margin-top: 34px; }
.student-portal :focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
@media (max-width: 860px) {
    .student-login { grid-template-columns: 1fr 390px; gap: 32px; }
    .student-balance { align-items: flex-start; flex-direction: column; }
    .student-metric { padding: 20px; }
}
@media (max-width: 680px) {
    .student-header-inner { min-height: 78px; gap: 12px; }
    .student-logo { width: 156px; max-height: 55px; }
    .student-header-actions { gap: 10px; }
    .student-header-actions .btn { font-size: 12px; padding: 10px 12px; border-radius: 10px; }
    .student-header-actions:has(form) .student-site-link { display: none; }
    .student-main { padding-block: 28px; }
    .student-login { display: flex; flex-direction: column; min-height: 0; gap: 28px; align-items: stretch; }
    .student-welcome h1 { font-size: 36px; margin-bottom: 12px; }
    .student-welcome h1 br { display: none; }
    .student-welcome > p { font-size: 16px; margin: 0; }
    .student-welcome .student-coming { margin-top: 16px; }
    .student-login-card { padding: 24px; }
    .student-page-heading { align-items: flex-start; }
    .student-page-heading > .btn { padding: 10px 12px; font-size: 12px; }
    .student-balance { padding: 25px; border-radius: 16px; }
    .student-metrics { grid-template-columns: 1fr; gap: 10px; margin-bottom: 28px; }
    .student-metric { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px; }
    .student-metric > span { margin: 0; }
    .student-metric strong { font-size: 23px; }
    .student-section-heading > span { font-size: 12px; }
    .student-invoice { padding: 20px; }
    .student-invoice-heading { flex-direction: column; gap: 12px; }
    .student-invoice-values { gap: 10px; }
    .student-invoice-values dd { font-size: 18px; }
    .student-invoice-values dt { font-size: 12px; }
}
