:root {
  font-family: 'DM Sans', 'Trebuchet MS', sans-serif;
  color: #203634;
  background: #edf3f0;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --ink: #203634;
  --muted: #788783;
  --line: #e3eae6;
  --paper: #ffffff;
  --canvas: #edf3f0;
  --green: #285b54;
  --green-deep: #183b37;
  --mint: #e7f1ec;
  --coral: #c85e47;
  --coral-soft: #faece7;
  --gold: #c79639;
  --gold-soft: #f8f0dd;
  --blue: #557d91;
  --blue-soft: #e9f1f5;
  --shadow: 0 18px 60px rgba(30, 57, 50, .12);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 1024px; min-height: 100vh; }
button, input, select, textarea { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 3px solid rgba(85, 125, 145, .38); outline-offset: 2px; }
[hidden] { display: none !important; }

.login-screen { min-height: 100vh; display: grid; grid-template-columns: minmax(360px, .92fr) 1.08fr; background: #fff; }
.login-aside { min-height: 100vh; position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; padding: 42px clamp(32px, 6vw, 94px) 34px; color: #f5f7f3; background: var(--green-deep); }
.login-aside::before { content: ''; position: absolute; width: 540px; height: 540px; right: -260px; top: 18%; border: 1px solid rgba(225, 236, 226, .11); border-radius: 50%; box-shadow: 0 0 0 48px rgba(225, 236, 226, .025), 0 0 0 104px rgba(225, 236, 226, .025); }
.login-aside::after { content: ''; position: absolute; width: 7px; height: 116px; right: 17%; bottom: 13%; background: linear-gradient(var(--coral) 0 28%, transparent 28% 35%, #d4b767 35% 66%, transparent 66% 72%, #78a49a 72%); border-radius: 8px; opacity: .85; }
.login-brand, .sidebar-brand { display: block; color: inherit; text-decoration: none; position: relative; z-index: 1; }
.login-brand { width: min(280px, 100%); height: 142px; overflow: hidden; border: 1px solid rgba(255, 255, 255, .48); border-radius: 8px; background: #fff; box-shadow: 0 12px 30px rgba(9, 29, 26, .2); }
.sidebar-brand { width: 100%; flex: none; overflow: hidden; border-radius: 3px; background: #fff; line-height: 0; }
.brand-mark-image { width: 100%; height: auto; display: block; object-fit: contain; }
.login-brand .brand-mark-image { width: 100%; height: 100%; object-fit: contain; transform: none; }
.login-message { max-width: 510px; padding: 50px 0 86px; position: relative; z-index: 1; animation: rise-in .5s ease both; }
.eyebrow { margin: 0 0 14px; color: #71948b; font-size: 10px; font-weight: 700; letter-spacing: 1.5px; }
.login-aside .eyebrow { color: #a7c2b8; }
.login-message h1 { margin: 0; font: 500 clamp(42px, 5vw, 66px)/1.08 'Playfair Display', Georgia, serif; letter-spacing: 0; }
.login-message > p:last-child { max-width: 340px; margin: 24px 0 0; color: #c0d0c9; font-size: 15px; line-height: 1.7; }
.login-main { display: grid; place-items: center; padding: 50px 28px; }
.login-form { width: min(100%, 386px); animation: rise-in .55s .06s ease both; }
.login-form h2 { margin: 0 0 8px; color: var(--ink); font: 600 35px/1.2 'Playfair Display', Georgia, serif; }
.muted { margin: 0 0 32px; color: var(--muted); font-size: 14px; }
.login-form label, .field label { display: block; margin: 0 0 8px; color: #354c47; font-size: 12px; font-weight: 700; }
.login-form input, .field input, .field select, .field textarea { width: 100%; min-height: 46px; padding: 12px 13px; border: 1px solid #dbe4df; border-radius: 5px; color: var(--ink); background: #fff; font-size: 13px; transition: border-color .15s, box-shadow .15s; }
.field select { accent-color: var(--green); color-scheme: light; }
.field select option { color: var(--ink); background-color: #fff; }
.field select option:checked { color: #fff; background-color: var(--green); }
.login-form input { margin-bottom: 21px; }
.login-form .password-control { margin-bottom: 21px; }
.login-form .password-control input { margin-bottom: 0; }
.login-form input::placeholder, .field input::placeholder, .field textarea::placeholder { color: #a0ada8; }
.login-form input:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: #6a9a8c; outline: none; box-shadow: 0 0 0 3px rgba(77, 132, 114, .12); }
.password-control { position: relative; display: flex; align-items: center; }
.password-control input { padding-right: 48px; }
.password-toggle { width: 34px; height: 34px; position: absolute; top: 50%; right: 7px; display: grid; place-items: center; padding: 0; transform: translateY(-50%); border: 0; border-radius: 4px; color: #74857e; background: transparent; cursor: pointer; }
.password-toggle:hover { color: var(--green-deep); background: var(--mint); }
.password-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.password-warning { margin: 5px 0 0; color: #a53d2d; font-size: 11px; font-weight: 600; line-height: 1.4; }
.role-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; margin: 0 0 23px; padding: 4px; border-radius: 5px; background: var(--mint); }
.role-option { min-height: 37px; border: 0; border-radius: 3px; color: #667872; background: transparent; cursor: pointer; font-size: 12px; font-weight: 700; }
.role-option[aria-pressed="true"] { color: var(--green-deep); background: #fff; box-shadow: 0 1px 4px rgba(30, 57, 50, .12); }
.captcha-fields { display: grid; gap: 8px; margin: 0 0 19px; }
.captcha-fields label { margin-bottom: 0; }
.login-form .captcha-fields input { min-height: 43px; margin-bottom: 0; padding-right: 13px; }
.captcha-challenge { min-height: 58px; display: flex; align-items: center; gap: 9px; }
.captcha-challenge img { width: 180px; height: 58px; display: block; border: 1px solid #d5e4dc; border-radius: 5px; background: #eff6f2; object-fit: contain; }
.captcha-refresh { width: 37px; height: 37px; display: grid; place-items: center; border: 1px solid #d5e4dc; border-radius: 5px; color: var(--green); background: #fff; cursor: pointer; font-size: 23px; line-height: 1; }
.captcha-refresh:hover { border-color: var(--green); color: #fff; background: var(--green); }
.captcha-refresh:disabled { opacity: .55; cursor: wait; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 39px; padding: 0 15px; border: 1px solid transparent; border-radius: 4px; cursor: pointer; font-size: 12px; font-weight: 700; transition: background .15s, border-color .15s, transform .15s; }
.button:hover { transform: translateY(-1px); }
.button-primary { color: #fff; background: var(--green); }
.button-primary:hover { background: #214d47; }
.login-submit { width: 100%; min-height: 49px; margin-top: 2px; }
.login-submit span { margin-left: auto; font-size: 17px; font-weight: 400; }
.auth-switch { margin: 17px 0 0; color: var(--muted); text-align: center; font-size: 12px; }
.auth-switch button { padding: 3px 2px; border: 0; color: var(--green); background: transparent; cursor: pointer; font-size: inherit; font-weight: 700; }
.auth-switch button:hover { color: var(--green-deep); text-decoration: underline; }
.auth-dialog { width: min(500px, calc(100% - 28px)); }
.auth-dialog form { padding: 24px; }
.signup-fields { display: grid; gap: 13px; }
.signup-fields .field input { margin-bottom: 0; }
.signup-note, .signup-admin-notice { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.otp-input { letter-spacing: .5em; text-align: center; font-size: 20px; font-weight: 700; }
.otp-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.otp-actions #otp-timer { color: var(--muted); }
.otp-actions #otp-back { margin-left: auto; }
.otp-link { padding: 0; border: 0; background: none; color: var(--green); font: inherit; font-weight: 700; cursor: pointer; }
.otp-link:disabled { color: var(--muted); cursor: not-allowed; font-weight: 400; }
.signup-admin-notice { padding: 14px; border-left: 3px solid var(--gold); color: #645331; background: var(--gold-soft); }
.signup-field { margin-bottom: 21px; }
.signup-field input { margin-bottom: 0; }
.student-portal { min-height: 100vh; background: var(--canvas); }
.student-portal-header { min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 12px clamp(20px, 5vw, 72px); border-bottom: 1px solid var(--line); background: #fff; }
.student-header-actions { display: flex; align-items: center; gap: 8px; }
.student-portal-logo { width: min(220px, 55vw); max-height: 58px; object-fit: contain; }
.student-portal-main { width: min(100% - 40px, 1100px); margin: 0 auto; padding: 52px 0 64px; }
.student-portal-main h1 { margin: 0 0 12px; color: var(--ink); font: 600 40px/1.15 'Playfair Display', Georgia, serif; }
.student-portal-intro { margin: 0 0 30px; color: var(--muted); font-size: 14px; }
.student-emergency { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 22px; padding: 20px 22px; border: 1px solid #efc8bc; border-left: 5px solid var(--coral); border-radius: 5px; background: #fff4f0; }
.student-emergency-mark { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--coral); font-weight: 800; }
.student-emergency .eyebrow { margin-bottom: 6px; color: #a64c38; }
.student-emergency h2 { margin: 0 0 6px; color: #6d3025; font-size: 17px; }
.student-emergency p:last-child { margin: 0; color: #714d45; font-size: 12px; line-height: 1.6; }
.student-dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .85fr); gap: 18px; align-items: start; }
.student-dashboard-panel { max-width: none; min-width: 0; }
.student-dashboard-side { display: grid; gap: 18px; }
.appointment-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 20px 0 24px; }
.appointment-form .field select { width: 100%; }
.appointment-form .field:nth-child(3), .appointment-form > button { grid-column: 1 / -1; }
.student-list-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 0 10px; border-bottom: 1px solid var(--line); }
.student-list-heading h3 { margin: 0; color: #314b44; font-size: 13px; }
.student-list-heading span { min-width: 24px; padding: 3px 7px; border-radius: 12px; color: var(--green-deep); background: var(--mint); text-align: center; font-size: 10px; font-weight: 700; }
.student-appointment-row, .student-history-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 0; border-bottom: 1px solid #eef2ef; }
.student-appointment-row:last-child, .student-history-row:last-child { border-bottom: 0; }
.student-appointment-date b, .student-history-row b { display: block; color: var(--ink); font-size: 12px; }
.student-appointment-date small, .student-history-row small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.student-notification { display: flex; align-items: flex-start; gap: 10px; padding: 13px 0; border-bottom: 1px solid #eef2ef; }
.student-update-button { width: 100%; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.student-notification.student-update-button { align-items: center; }
.student-update-button:hover { background: #f7faf8; }
.student-update-button:focus-visible { outline: 2px solid #6a9a8c; outline-offset: 2px; }
.student-update-hint { flex: none; margin-left: auto; color: #56796e; font-size: 10px; white-space: nowrap; }
.student-history-row.student-update-button { background: transparent; border: 0; border-bottom: 1px solid #eef2ef; }
.appointment-details-dialog { width: min(560px, calc(100% - 28px)); max-height: min(86vh, 680px); padding: 0; border: 1px solid #dfe7e2; border-radius: 7px; color: var(--ink); background: #fff; box-shadow: var(--shadow); }
.appointment-details-dialog::backdrop { background: rgba(20, 43, 39, .42); backdrop-filter: blur(2px); }
.appointment-details-list { display: grid; gap: 0; margin: 0; padding: 8px 24px 24px; }
.appointment-detail-item { padding: 13px 0; border-bottom: 1px solid #eef2ef; }
.appointment-detail-item:last-child { border-bottom: 0; }
.appointment-detail-item dt { margin-bottom: 5px; color: var(--muted); font-size: 11px; }
.appointment-detail-item dd { margin: 0; color: var(--ink); font-size: 13px; line-height: 1.55; overflow-wrap: anywhere; }
.student-row-actions { white-space: nowrap; }
.student-row-actions .table-action { margin-right: 8px; }
.student-row-actions .danger-action { color: #a64c38; }
.student-notification:last-child { border-bottom: 0; }
.student-notification b { display: block; color: var(--ink); font-size: 12px; }
.student-notification small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.notification-dot { width: 8px; height: 8px; flex: none; margin-top: 4px; border-radius: 50%; background: var(--green); }
.notification-dot.pending { background: var(--gold); }
.student-empty-state { padding: 18px 4px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.student-portal-notice { max-width: 620px; padding: 23px 24px; border: 1px solid #d8e4df; border-left: 4px solid var(--green); border-radius: 4px; background: #fff; }
.student-portal-notice h2 { margin: 0 0 9px; color: var(--ink); font-size: 16px; }
.student-portal-notice p { margin: 0; color: #667872; font-size: 13px; line-height: 1.65; }
.student-profile-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.student-profile-heading h2 { margin: 0 0 4px; }
.student-profile-heading p { overflow-wrap: anywhere; }
.student-profile-details { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 20px; margin: 25px 0 0; }
.student-profile-details div { min-width: 0; }
.student-profile-details dt { margin-bottom: 5px; color: var(--muted); font-size: 11px; }
.student-profile-details dd { margin: 0; color: var(--ink); font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
.feedback-card { max-width: 760px; margin-top: 24px; }
.feedback-form { display: grid; gap: 16px; margin-top: 20px; }
.feedback-form .field textarea { width: 100%; min-height: 120px; padding: 12px 13px; border: 1px solid #dbe4df; border-radius: 5px; color: var(--ink); background: #fff; font: inherit; font-size: 13px; line-height: 1.5; resize: vertical; }
.feedback-form .field textarea:focus { border-color: #6a9a8c; outline: none; box-shadow: 0 0 0 3px rgba(77, 132, 114, .12); }
.feedback-form-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.feedback-form-footer small { color: var(--muted); font-size: 11px; line-height: 1.5; }
.feedback-comments { min-width: 260px; max-width: 480px; white-space: pre-wrap; overflow-wrap: anywhere; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 238px minmax(0, 1fr); }
.sidebar { height: 100vh; position: sticky; top: 0; display: flex; flex-direction: column; padding: 25px 16px 14px; color: #d9e5df; background: var(--green-deep); }
.sidebar-brand { margin: 0 0 32px; }
.campus-switch { display: flex; align-items: center; gap: 10px; padding: 10px 8px; border: 1px solid rgba(224, 239, 229, .13); border-radius: 5px; background: rgba(255, 255, 255, .045); }
.campus-icon { width: 29px; height: 29px; display: grid; place-items: center; border-radius: 4px; color: #f2dfaa; background: rgba(214, 185, 106, .18); font: 600 14px 'Playfair Display', Georgia, serif; }
.campus-switch b, .campus-switch small, .profile-button b, .profile-button small { display: block; }
.campus-switch b { font-size: 11px; }
.campus-switch small, .profile-button small { margin-top: 3px; color: #91aaa0; font-size: 10px; }
.chevron { margin-left: auto; color: #8eaaa0; }
.nav-label { margin: 31px 0 10px 10px; color: #77948a; font-size: 9px; font-weight: 700; letter-spacing: 1.3px; }
.primary-nav { display: grid; gap: 4px; }
.nav-item { width: 100%; min-height: 41px; display: flex; align-items: center; gap: 11px; padding: 0 10px; border: 0; border-radius: 4px; color: #b8cbc2; background: transparent; text-align: left; cursor: pointer; font-size: 12px; transition: color .15s, background .15s; }
.nav-document-link { color: #b8cbc2; font-family: inherit; text-decoration: none; }
.nav-item:hover { color: #fff; background: rgba(255, 255, 255, .07); }
.nav-item.active { color: #fff; background: #2a554d; box-shadow: inset 2px 0 #e4bd68; }
.nav-icon { width: 17px; color: #9ab5aa; text-align: center; font-size: 16px; }
.nav-count { min-width: 20px; height: 20px; display: grid; place-items: center; margin-left: auto; border-radius: 10px; color: #bed0c8; background: rgba(255, 255, 255, .09); font-size: 10px; }
.nav-count-warm { color: #f0d8a2; background: rgba(201, 150, 57, .18); }
.sidebar-bottom { margin-top: auto; }
.profile-button b { color: #dce6e1; font-size: 10px; }
.profile-area { position: relative; padding-top: 10px; border-top: 1px solid rgba(224, 239, 229, .12); }
.profile-button { width: 100%; display: flex; align-items: center; gap: 9px; padding: 14px 35px 4px 5px; border: 0; color: inherit; background: transparent; text-align: left; cursor: pointer; font: inherit; }
.profile-button:hover { background: rgba(255, 255, 255, .06); }
.avatar { width: 31px; height: 31px; flex: none; display: inline-grid; place-items: center; border: 0; border-radius: 50%; color: #793c2c; background: #f0c3ae; font-size: 10px; font-weight: 700; }
.profile-menu-trigger { position: absolute; top: 10px; right: 0; width: 30px; height: 30px; display: grid; place-items: center; border: 0; border-radius: 4px; color: #b6c8c0; background: transparent; cursor: pointer; font-size: 19px; }
.profile-menu-trigger:hover, .profile-menu-trigger[aria-expanded="true"] { color: #fff; background: rgba(255, 255, 255, .08); }
.profile-options { position: absolute; z-index: 8; right: 0; bottom: calc(100% - 3px); width: 176px; padding: 5px; border: 1px solid #dfe7e2; border-radius: 4px; background: #fff; box-shadow: 0 10px 28px rgba(12, 31, 27, .2); }
.profile-options button { width: 100%; min-height: 36px; padding: 0 10px; border: 0; border-radius: 3px; color: var(--ink); background: transparent; text-align: left; cursor: pointer; font-size: 11px; }
.profile-options button:hover { background: var(--mint); }

.main-area { min-width: 0; display: flex; flex-direction: column; }
.topbar { height: 65px; flex: none; display: flex; align-items: center; justify-content: space-between; padding: 0 clamp(20px, 3vw, 46px); border-bottom: 1px solid #e0e8e4; background: rgba(255, 255, 255, .74); }
.breadcrumb { display: flex; align-items: center; gap: 10px; color: #899791; font-size: 11px; }
.breadcrumb b { color: var(--ink); font-weight: 600; }
.breadcrumb-slash { color: #c0cac5; }
.topbar-actions { display: flex; align-items: center; gap: 12px; }
.global-search { width: min(290px, 31vw); height: 34px; display: flex; align-items: center; gap: 7px; padding: 0 9px; border: 1px solid #e1e8e4; border-radius: 4px; background: #fff; color: #80918a; }
.global-search > span { font-size: 18px; }
.global-search input { width: 100%; min-width: 0; border: 0; outline: none; color: var(--ink); font-size: 11px; }
.global-search input::placeholder { color: #9aa7a1; }
kbd { flex: none; padding: 2px 4px; border: 1px solid #e6ece8; border-radius: 3px; color: #a3aea9; font: 9px 'DM Sans', sans-serif; }
.icon-button { width: 34px; height: 34px; position: relative; display: inline-grid; place-items: center; border: 1px solid #e1e8e4; border-radius: 4px; color: #55716a; background: #fff; cursor: pointer; font-size: 17px; }
.icon-button:hover { background: #f3f7f4; }
.notification-button i { width: 6px; height: 6px; position: absolute; top: 6px; right: 6px; border: 1px solid #fff; border-radius: 50%; background: var(--coral); }
.topbar-avatar { width: 29px; height: 29px; cursor: pointer; }
.content { width: 100%; max-width: 1440px; flex: 1; margin: 0 auto; padding: 34px clamp(20px, 3vw, 46px) 28px; animation: rise-in .22s ease both; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.page-heading h1 { margin: 0; color: var(--ink); font: 600 29px/1.2 'Playfair Display', Georgia, serif; letter-spacing: 0; }
.page-heading p { margin: 7px 0 0; color: var(--muted); font-size: 12px; }
.heading-actions { display: flex; gap: 8px; }
.button-quiet { border-color: #dfe8e3; color: #46635a; background: #fff; }
.button-quiet:hover { background: #f7faf8; }
.button-small { min-height: 32px; padding: 0 10px; font-size: 10px; }
.section-label { color: #74857e; font-size: 10px; font-weight: 700; letter-spacing: 1px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 12px; }
.section-heading h2 { margin: 0; color: #314b44; font-size: 13px; font-weight: 700; }
.text-link { padding: 4px 0; border: 0; color: #3a7568; background: transparent; cursor: pointer; font-size: 10px; font-weight: 700; }
.text-link:hover { color: #23544a; text-decoration: underline; }
.overview-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(250px, .85fr); gap: 18px; align-items: start; }
.metric-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 11px; margin-bottom: 24px; }
.metric-card { min-height: 112px; padding: 15px 16px; border: 1px solid #e3eae6; border-radius: 5px; background: var(--paper); }
.metric-top { display: flex; align-items: center; justify-content: space-between; color: #75877f; font-size: 10px; }
.metric-symbol { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 4px; font-size: 14px; }
.metric-symbol.green { color: #437469; background: var(--mint); }
.metric-symbol.gold { color: #a67a26; background: var(--gold-soft); }
.metric-symbol.coral { color: #b75c47; background: var(--coral-soft); }
.metric-value { margin: 8px 0 0; color: #233a35; font: 600 28px/1 'Playfair Display', Georgia, serif; }
.metric-foot { margin: 7px 0 0; color: #8c9a94; font-size: 9px; }
.metric-foot strong { color: #507c6c; font-weight: 700; }
.panel { border: 1px solid #e3eae6; border-radius: 5px; background: var(--paper); }
.panel-pad { padding: 16px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { padding: 10px 12px; border-bottom: 1px solid #e9eeeb; color: #87948e; font-size: 9px; font-weight: 700; letter-spacing: .45px; text-transform: uppercase; white-space: nowrap; }
td { padding: 11px 12px; border-bottom: 1px solid #eef2ef; color: #485b55; font-size: 10px; white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
.person-cell { display: flex; align-items: center; gap: 8px; }
.person-cell b { display: block; color: #2f4941; font-size: 10px; }
.person-cell small { display: block; margin-top: 3px; color: #8b9992; font-size: 9px; }
.mini-avatar { width: 27px; height: 27px; flex: none; display: inline-grid; place-items: center; border-radius: 50%; color: #416d62; background: #e3eee8; font-size: 9px; font-weight: 700; }
.mini-avatar.coral { color: #9e5943; background: #f8e7df; }
.mini-avatar.blue { color: #466b7c; background: #e5eff4; }
.mini-avatar.gold { color: #8e702d; background: #f7efd9; }
.status-pill { min-height: 21px; display: inline-flex; align-items: center; gap: 5px; padding: 0 8px; border-radius: 11px; color: #517366; background: #e9f2ed; font-size: 9px; font-weight: 700; }
.status-pill::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.status-pill.urgent, .status-pill.high { color: #ae5541; background: #faece7; }
.status-pill.medium { color: #9a742d; background: #f8f0dd; }
.status-pill.low, .status-pill.scheduled { color: #4a7585; background: #eaf2f5; }
.status-pill.closed { color: #7b8781; background: #eff2f0; }
.status-pill.sent { color: #547a62; background: #eaf3e9; }
.table-action { padding: 5px 7px; border: 0; border-radius: 3px; color: #397164; background: transparent; cursor: pointer; font-size: 10px; font-weight: 700; }
.table-action:hover { background: #edf5f0; }
.right-column { display: grid; gap: 17px; }
.agenda-list { display: grid; }
.agenda-item { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid #eef2ef; }
.agenda-item:last-child { border-bottom: 0; }
.date-tile { width: 43px; height: 46px; display: grid; align-content: center; justify-items: center; border-radius: 4px; color: #45695f; background: #edf4ef; }
.date-tile b { font: 600 17px/1 'Playfair Display', Georgia, serif; }
.date-tile small { margin-top: 4px; color: #779086; font-size: 8px; text-transform: uppercase; }
.agenda-copy b { display: block; overflow: hidden; color: #334b44; font-size: 10px; text-overflow: ellipsis; }
.agenda-copy small { display: block; margin-top: 4px; color: #87958f; font-size: 9px; }
.agenda-time { color: #6d7e77; font-size: 9px; }
.attention-card { padding: 15px; border: 1px solid #f0dfd1; border-radius: 5px; background: #fffaf5; }
.attention-top { display: flex; align-items: center; gap: 8px; color: #a1543c; font-size: 11px; font-weight: 700; }
.attention-mark { width: 23px; height: 23px; display: grid; place-items: center; border-radius: 50%; color: #a1543c; background: #f9e8dd; }
.attention-card p { margin: 10px 0 13px; color: #8c7266; font-size: 10px; line-height: 1.55; }
.attention-footer { display: flex; align-items: center; justify-content: space-between; color: #a47c68; font-size: 9px; }
.empty-state { padding: 28px 15px; color: #85938c; text-align: center; font-size: 11px; }
.empty-state strong { display: block; margin-bottom: 5px; color: #4b6259; font-size: 12px; }
.app-footer { display: flex; justify-content: space-between; padding: 13px clamp(20px, 3vw, 46px); border-top: 1px solid #e1e9e4; color: #94a19a; background: rgba(255,255,255,.48); font-size: 9px; }
.app-footer span:last-child { display: flex; align-items: center; gap: 6px; }
.app-footer i { width: 5px; height: 5px; border-radius: 50%; background: #d6a44f; }
.toolbar-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 13px; }
.filter-select { min-height: 33px; padding: 0 10px; border: 1px solid #e1e8e4; border-radius: 4px; color: #567067; background: #fff; font-size: 10px; }
.record-title { display: inline-flex; align-items: center; gap: 8px; }
.record-title b { color: #334b44; font-size: 10px; }
.record-title small { display: block; margin-top: 3px; color: #8a9891; font-size: 9px; }
.table-note { margin: 0; padding: 11px 14px; border-top: 1px solid #eef2ef; color: #87958f; font-size: 9px; }
.reminder-row { display: grid; grid-template-columns: 36px minmax(0,1fr) auto auto; align-items: center; gap: 13px; padding: 14px 16px; border-bottom: 1px solid #edf1ee; }
.reminder-row:last-child { border-bottom: 0; }
.reminder-icon { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; color: #916e30; background: #f8f0dd; }
.reminder-copy b { display: block; color: #334b44; font-size: 11px; }
.reminder-copy small { display: block; margin-top: 4px; color: #829189; font-size: 9px; }
.reminder-date { color: #6e7d77; font-size: 10px; }
.reminder-row.sent-row { opacity: .72; }
.profile-detail { display: flex; align-items: center; gap: 14px; padding: 20px; border-bottom: 1px solid #edf1ee; }
.profile-detail .mini-avatar { width: 38px; height: 38px; font-size: 11px; }
.profile-detail b { color: #314b44; font-size: 12px; }
.profile-detail small { display: block; margin-top: 4px; color: #899790; font-size: 10px; }
.action-dialog { width: min(520px, calc(100% - 28px)); max-height: min(88vh, 760px); padding: 0; border: 1px solid #dfe7e2; border-radius: 7px; color: var(--ink); box-shadow: var(--shadow); }
.action-dialog::backdrop { background: rgba(20, 43, 39, .42); backdrop-filter: blur(2px); }
.help-dialog { display: flex; flex-direction: column; width: min(1040px, calc(100% - 28px)); height: min(88vh, 820px); padding: 0; border: 1px solid #dfe7e2; border-radius: 7px; color: var(--ink); background: #fff; box-shadow: var(--shadow); }
.help-dialog::backdrop { background: rgba(20, 43, 39, .42); backdrop-filter: blur(2px); }
.help-dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; padding: 22px 24px 16px; border-bottom: 1px solid var(--line); }
.help-dialog-heading .eyebrow { margin-bottom: 7px; }
.help-dialog-heading h2 { margin: 0; font: 600 24px/1.2 'Playfair Display', Georgia, serif; }
.help-manual-frame { display: block; flex: 1; width: 100%; min-height: 0; border: 0; background: #fff; }
.action-dialog form { padding: 23px; }
.dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 20px; }
.dialog-heading .eyebrow { margin-bottom: 7px; }
.dialog-heading h2 { margin: 0; font: 600 24px/1.2 'Playfair Display', Georgia, serif; }
.dialog-close { width: 28px; height: 28px; font-size: 18px; }
.dialog-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 13px 12px; }
.field.full { grid-column: 1 / -1; }
.field textarea { min-height: 76px; resize: vertical; }
.field .checkbox-line { display: flex; align-items: center; gap: 8px; color: #546c63; font-size: 11px; }
.field .checkbox-line input { width: 15px; min-height: 15px; accent-color: var(--green); }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 24px; }
.toast { position: fixed; z-index: 9; right: 24px; bottom: 22px; max-width: min(380px, calc(100% - 32px)); padding: 12px 16px; border: 1px solid #cadecf; border-radius: 4px; color: #264d42; background: #f6fbf7; box-shadow: 0 8px 24px rgba(24, 59, 55, .12); font-size: 11px; opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity .2s, transform .2s; }
.toast.visible { opacity: 1; transform: translateY(0); }
@keyframes rise-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* Student workspace refinements: match the admin console's calmer panel system. */
.student-portal-header { position: sticky; z-index: 5; top: 0; min-height: 72px; box-shadow: 0 4px 18px rgba(30, 57, 50, .035); }
.student-portal-main { width: min(100% - 48px, 1240px); padding-top: 42px; }
.student-portal-main > .eyebrow { margin-bottom: 10px; }
.student-portal-main h1 { font-size: 42px; }
.student-portal-intro { margin-bottom: 25px; }
.student-emergency { border-radius: 7px; box-shadow: 0 3px 12px rgba(136, 75, 55, .035); }
.student-dashboard-grid { gap: 20px; }
.student-dashboard-side { gap: 20px; }
.student-portal-notice { max-width: none; border-radius: 7px; box-shadow: 0 3px 14px rgba(30, 57, 50, .035); }
.student-dashboard-panel { padding: 22px; }
.student-profile-card, .feedback-card { margin-top: 20px; }
.student-dashboard-panel .student-profile-heading h2 { font-size: 16px; }
.student-dashboard-panel .student-profile-heading p { font-size: 12px; }
.student-appointment-row, .student-history-row { min-height: 58px; }
.student-empty-state { border-radius: 4px; background: #f7faf8; }
.student-referral-card { margin-top: 20px; }
.student-referral-form { display: grid; grid-template-columns: minmax(0, 1fr) 190px auto; gap: 14px; align-items: end; margin: 18px 0 24px; }
.student-referral-form .field textarea { width: 100%; min-height: 74px; padding: 12px 13px; border: 1px solid #dbe4df; border-radius: 5px; color: var(--ink); background: #fff; font: inherit; font-size: 13px; line-height: 1.5; resize: vertical; }
.student-referral-form .field textarea:focus { border-color: #6a9a8c; outline: none; box-shadow: 0 0 0 3px rgba(77, 132, 114, .12); }
.student-referral-form > button { min-height: 46px; white-space: nowrap; }

.analytics-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 18px 0 30px; }
.metric-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.sidebar { overflow-y: auto; }
.analytics-panel { min-width: 0; min-height: 285px; padding: 18px; }
.analytics-panel h2 { margin: 0 0 12px; color: #334b44; font-size: 13px; }
.chart-box { position: relative; width: 100%; height: 220px; }
.chart-box canvas { display: block; }
.chart-empty { display: grid; place-items: center; height: 100%; margin: 0; color: var(--muted); font-size: 12px; text-align: center; }
.chart-caption { margin: -5px 0 10px; color: var(--muted); font-size: 10px; }
.report-filters { align-items: center; }
.report-filters .filter-select { min-width: 120px; flex: 1 1 135px; }
.report-print-header { display: none; }
.backup-notice { margin: 16px 0; padding: 16px 18px; border-left: 3px solid #c99b49; }
.backup-notice strong { color: #334b44; font-size: 12px; }
.backup-notice p { margin: 7px 0 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.table-wrap td small { display: block; margin-top: 3px; color: var(--muted); font-size: 9px; }

@media (max-width: 900px) {
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .analytics-grid { grid-template-columns: minmax(0, 1fr); }
}

@media print {
  body { min-width: 0; background: #fff; }
  .sidebar, .topbar, .app-footer, .page-heading .heading-actions, .report-filters, .toolbar-row, .toast { display: none !important; }
  .app-shell, .main-area, .content { display: block !important; width: 100% !important; height: auto !important; overflow: visible !important; background: #fff !important; }
  .content { padding: 0 !important; }
  .report-print-header { display: block; margin: 0 0 18px; }
  .report-print-header p { margin: 0 0 6px; font-size: 11px; }
  .report-print-header h2 { margin: 0 0 6px; }
  .table-wrap { overflow: visible !important; border: 0; box-shadow: none; }
  table { width: 100%; font-size: 9px; }
  th, td { padding: 5px !important; color: #111 !important; }
  tr { break-inside: avoid; }
}

@media (max-width: 760px) {
  .metric-grid { grid-template-columns: minmax(0, 1fr); }
  .student-portal-header { min-height: 64px; padding-inline: 16px; }
  .student-portal-main { width: min(100% - 28px, 600px); padding-top: 30px; }
  .student-portal-main h1 { font-size: 34px; }
  .student-dashboard-panel { padding: 18px; }
  .student-portal-notice { padding: 18px; }
  .student-referral-form { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 760px) {
  body:has(.login-screen:not([hidden])) { min-width: 320px; }
  body:has(.student-portal:not([hidden])) { min-width: 320px; }
  .student-portal-main { width: min(100% - 28px, 600px); padding: 32px 0 44px; }
  .student-portal-main h1 { font-size: 34px; }
  .student-dashboard-grid { grid-template-columns: minmax(0, 1fr); }
  .student-dashboard-side { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
  .student-emergency { padding: 17px; }
  .login-screen { grid-template-columns: minmax(0, 1fr); }
  .login-aside { display: none; }
  .login-main { min-height: 100vh; padding: 28px 18px; }
  .login-form { width: min(100%, 386px); }
  .login-form h2 { font-size: 30px; }
  .muted { margin-bottom: 22px; }
  .role-switch { margin-bottom: 18px; }
  .login-form input { margin-bottom: 16px; }
  .login-form .password-control { margin-bottom: 16px; }
  .captcha-fields { margin-bottom: 17px; }
}

@media (max-width: 390px) {
  .login-main { padding: 22px 14px; }
  .captcha-challenge img { width: min(180px, calc(100vw - 92px)); }
}


/* Demo accounts box on the login page */
.demo-accounts { margin-top: 18px; padding: 12px; border: 1px dashed #9aa5b1; border-radius: 10px; background: rgba(120, 140, 170, 0.08); display: grid; gap: 8px; }
.demo-accounts-title { margin: 0; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.demo-accounts-title span { font-weight: 400; text-transform: none; opacity: 0.7; }
.demo-account { display: flex; justify-content: space-between; align-items: center; gap: 12px; width: 100%; padding: 8px 12px; border: 1px solid #c4ccd6; border-radius: 8px; background: #fff; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.demo-account:hover { border-color: #3b6fd4; background: #f1f6ff; }
.demo-account span { font-family: Consolas, monospace; font-size: 0.82rem; opacity: 0.8; }
