:root {
  --navy: #032f50;
  --navy-2: #064c78;
  --blue: #078dce;
  --cyan: #19b9e6;
  --sky: #eaf8fd;
  --yellow: #ffc23e;
  --orange: #ff8f32;
  --green: #20a878;
  --white: #fff;
  --ink: #102f43;
  --muted: #678091;
  --line: #dceaf1;
  --surface: #f5fafc;
  --danger: #d94a53;
  --shadow: 0 18px 50px rgba(8, 58, 89, .12);
  --radius: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); font-family: Inter, "Segoe UI", Arial, sans-serif; background: var(--surface); -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
.container { width: min(1160px, calc(100% - 40px)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

.site-header { height: 78px; color: var(--white); background: var(--navy); position: relative; z-index: 20; }
.site-header.compact { background: transparent; position: absolute; width: 100%; }
.nav-wrap { height: 100%; display: flex; align-items: center; justify-content: space-between; }
.brand img { width: 160px; height: auto; }
.nav-links { display: flex; align-items: center; gap: 30px; font-size: 14px; font-weight: 650; }
.nav-links > a:not(.button) { color: rgba(255,255,255,.78); transition: color .2s; }
.nav-links > a:hover, .nav-links > a.active { color: var(--white); }
.menu-button { display: none; color: white; border: 0; background: transparent; font-size: 24px; cursor: pointer; }
.back-link { color: rgba(255,255,255,.8); font-size: 14px; font-weight: 700; }

.button { border: 0; border-radius: 10px; min-height: 48px; padding: 0 22px; display: inline-flex; justify-content: center; align-items: center; gap: 14px; font-weight: 800; font-size: 14px; cursor: pointer; transition: transform .2s, box-shadow .2s, background .2s; }
.button:hover { transform: translateY(-2px); }
.button:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.button-primary { color: var(--white); background: linear-gradient(135deg, var(--blue), #0579bc); box-shadow: 0 10px 24px rgba(7, 141, 206, .23); }
.button-yellow { color: var(--navy); background: var(--yellow); box-shadow: 0 10px 24px rgba(255, 194, 62, .22); }
.button-secondary { color: var(--navy); background: var(--sky); }
.button-ghost { min-height: 40px; padding: 0 18px; border: 1px solid rgba(255,255,255,.38); background: transparent; color: white; }
.button-small { min-height: 40px; padding: 0 16px; }
.button.full { width: 100%; }
.text-link { display: inline-flex; gap: 14px; align-items: center; color: var(--white); font-size: 14px; font-weight: 800; }
.text-link.dark { color: var(--blue); }
.link-button { display: block; margin: 20px auto 0; background: transparent; border: 0; color: var(--blue); font-weight: 750; cursor: pointer; }

.hero { color: var(--white); min-height: 650px; background: radial-gradient(circle at 75% 50%, #0b709b 0, transparent 36%), linear-gradient(125deg, #032f50 35%, #075d85 100%); position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; opacity: .12; background-image: radial-gradient(circle at 1px 1px, #fff 1px, transparent 0); background-size: 24px 24px; mask-image: linear-gradient(90deg, transparent 35%, #000); }
.hero-grid { min-height: 585px; display: grid; grid-template-columns: .92fr 1.08fr; align-items: center; position: relative; z-index: 2; }
.hero-copy { padding: 50px 0 70px; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; color: var(--cyan); font-size: 12px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.eyebrow > span { width: 25px; height: 3px; background: var(--yellow); border-radius: 4px; }
.eyebrow.dark { color: var(--blue); }
.hero h1 { margin: 18px 0 20px; font-size: clamp(46px, 5vw, 70px); letter-spacing: -.055em; line-height: .98; }
h1 em, h2 em { color: var(--cyan); font-style: normal; }
.hero-copy > p { max-width: 520px; margin: 0; color: rgba(255,255,255,.72); font-size: 17px; line-height: 1.7; }
.hero-actions { display: flex; align-items: center; gap: 30px; margin-top: 32px; }
.hero-trust { display: flex; align-items: center; gap: 13px; margin-top: 35px; }
.avatar-stack { display: flex; padding-left: 8px; }
.avatar-stack span { display: grid; place-items: center; width: 34px; height: 34px; margin-left: -8px; border: 2px solid var(--navy); border-radius: 50%; color: var(--navy); background: var(--yellow); font-size: 11px; font-weight: 900; }
.avatar-stack span:nth-child(2) { background: var(--cyan); }
.avatar-stack span:nth-child(3) { background: var(--orange); }
.hero-trust p { margin: 0; color: rgba(255,255,255,.6); font-size: 12px; line-height: 1.4; }
.hero-trust strong { color: white; font-size: 13px; }
.hero-visual { align-self: stretch; position: relative; display: grid; place-items: center; }
.hero-visual > img { width: 100%; max-height: 570px; filter: saturate(.95); }
.floating-card { position: absolute; right: 3%; bottom: 18%; display: flex; align-items: center; gap: 12px; padding: 13px 17px; color: var(--ink); background: rgba(255,255,255,.94); box-shadow: var(--shadow); border-radius: 13px; transform: rotate(2deg); }
.floating-card .floating-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 9px; color: #a66300; background: #fff2ca; }
.floating-card strong, .floating-card small { display: block; }
.floating-card strong { font-size: 18px; }.floating-card small { color: var(--muted); font-size: 10px; margin-top: 2px; }
.bubble { position: absolute; border: 2px solid rgba(255,255,255,.42); border-radius: 50%; }
.bubble-one { width: 17px; height: 17px; left: 8%; top: 22%; }.bubble-two { width: 10px; height: 10px; right: 7%; top: 30%; }
.wave-cut { position: absolute; height: 60px; left: -2%; right: -2%; bottom: -34px; background: var(--surface); border-radius: 50% 50% 0 0 / 65% 65% 0 0; }

.section { padding: 95px 0; }
.section-heading.centered { max-width: 700px; text-align: center; }
.section-heading h2, .steps-grid h2 { margin: 15px 0; font-size: clamp(35px, 4vw, 52px); letter-spacing: -.045em; line-height: 1.05; }
.section-heading p, .steps-grid > div > p { color: var(--muted); line-height: 1.7; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 45px; }
.feature-card { padding: 32px 30px; background: white; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 10px 30px rgba(8,58,89,.05); transition: transform .2s; }
.feature-card:hover { transform: translateY(-5px); }
.feature-card.featured { border-top: 4px solid var(--cyan); }
.feature-icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 13px; color: var(--blue); background: var(--sky); font-size: 26px; font-weight: 900; }
.feature-card:nth-child(2) .feature-icon { color: #bd7200; background: #fff4d2; }.feature-card:nth-child(3) .feature-icon { color: #e66e10; background: #fff0e4; }
.feature-card h3 { margin: 23px 0 10px; font-size: 19px; }.feature-card p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.65; }
.steps-section { background: white; }
.steps-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 100px; align-items: center; }
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.steps li { display: flex; gap: 22px; padding: 22px; border-radius: 14px; transition: background .2s; }.steps li:hover { background: var(--sky); }
.steps li > span { flex: 0 0 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; color: var(--white); background: var(--blue); font-weight: 900; }
.steps li:nth-child(2) > span { background: var(--orange); }.steps li:nth-child(3) > span { color: var(--navy); background: var(--yellow); }
.steps h3 { margin: 2px 0 6px; }.steps p { margin: 0; color: var(--muted); font-size: 14px; }
.cta-section { padding: 65px 0; background: var(--surface); }.cta-box { padding: 45px 55px; display: flex; align-items: center; justify-content: space-between; color: var(--white); background: linear-gradient(120deg, var(--navy), var(--navy-2)); border-radius: 25px; overflow: hidden; position: relative; }.cta-box::after { content: "≈"; position: absolute; right: 30%; font-size: 180px; color: rgba(255,255,255,.04); transform: rotate(-12deg); }.cta-box h2 { margin: 12px 0 0; font-size: 36px; letter-spacing: -.04em; }
.site-footer { color: rgba(255,255,255,.6); background: #02253f; }.footer-wrap { min-height: 100px; display: flex; justify-content: space-between; align-items: center; gap: 20px; font-size: 12px; }.footer-wrap img { width: 135px; }

/* Authentication */
.auth-page { min-height: 100vh; background: radial-gradient(circle at 80% 18%, rgba(25,185,230,.3), transparent 24%), linear-gradient(140deg, var(--navy) 0 38%, var(--surface) 38%); }
.auth-main { min-height: 100vh; padding: 110px 20px 50px; display: grid; place-items: center; }
.auth-card { width: min(470px, 100%); padding: 38px 42px; background: white; border-radius: 22px; box-shadow: 0 30px 90px rgba(0,29,49,.24); position: relative; }
.auth-icon { width: 52px; height: 52px; display: grid; place-items: center; position: absolute; right: 35px; top: 35px; color: #9b6100; background: #fff2c8; border-radius: 14px; font-size: 23px; }
.auth-card h1 { margin: 13px 0 10px; font-size: 33px; letter-spacing: -.04em; }.auth-card > div > p { color: var(--muted); font-size: 14px; line-height: 1.6; }
.form-stack { display: grid; gap: 17px; margin-top: 26px; }
label { display: grid; gap: 8px; color: var(--ink); font-size: 12px; font-weight: 800; }label small { color: var(--muted); font-weight: 500; }
input, select { width: 100%; height: 48px; padding: 0 14px; color: var(--ink); background: #f9fcfd; border: 1px solid var(--line); border-radius: 9px; outline: 0; transition: border .2s, box-shadow .2s; }
input:focus, select:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(25,185,230,.13); }
.code-input { height: 61px; text-align: center; font-size: 27px; font-weight: 900; letter-spacing: .34em; padding-left: calc(14px + .34em); }
.form-note { text-align: center; margin: 20px 0 0 !important; font-size: 12px !important; }
.form-feedback { min-height: 20px; margin-top: 14px; color: var(--danger); text-align: center; font-size: 13px; font-weight: 700; }
.form-feedback.success { color: var(--green); }.dev-code { margin: 17px 0 -8px; padding: 12px; text-align: center; color: #775100; background: #fff6d8; border: 1px dashed #e5b836; border-radius: 9px; font-size: 13px; }.dev-code strong { font-size: 18px; letter-spacing: .15em; }

/* Signed-in application */
.app-page { min-height: 100vh; }.dashboard-main { padding-bottom: 70px; }.page-hero { min-height: 255px; display: flex; align-items: center; color: white; background: radial-gradient(circle at 78% 35%, #0d7ba3, transparent 24%), linear-gradient(120deg, var(--navy), #075b82); }.page-hero.small { min-height: 210px; }.page-hero h1 { margin: 12px 0 6px; font-size: clamp(34px, 4vw, 48px); letter-spacing: -.045em; }.page-hero p { margin: 0; color: rgba(255,255,255,.68); }.user-chip { padding: 9px 13px; border-radius: 20px; background: rgba(255,255,255,.12); font-size: 12px; }.user-chip.professor { color: var(--navy); background: var(--yellow); }
.content-panel { margin-top: -35px; padding: 30px; position: relative; background: white; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }.panel-heading { margin-bottom: 26px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }.panel-heading h2 { margin: 0 0 5px; font-size: 23px; letter-spacing: -.025em; }.panel-heading p { margin: 0; color: var(--muted); font-size: 13px; }
.loading-state, .empty-state { min-height: 180px; display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--muted); text-align: center; }.loading-state { flex-direction: row; gap: 12px; font-size: 14px; }.spinner { width: 22px; height: 22px; border: 3px solid var(--line); border-top-color: var(--cyan); border-radius: 50%; animation: spin .75s linear infinite; }.empty-state > span { width: 50px; height: 50px; display: grid; place-items: center; color: var(--blue); background: var(--sky); border-radius: 50%; font-size: 28px; font-weight: 900; }.empty-state h3 { margin: 14px 0 4px; }.empty-state p { margin: 0 0 20px; font-size: 14px; }@keyframes spin { to { transform: rotate(360deg); } }
.schedule-days { display: grid; gap: 28px; }.day-group { display: grid; grid-template-columns: 180px 1fr; gap: 25px; padding-top: 24px; border-top: 1px solid var(--line); }.day-group:first-child { padding-top: 0; border-top: 0; }.day-label strong, .day-label span { display: block; }.day-label strong { font-size: 16px; text-transform: capitalize; }.day-label span { margin-top: 5px; color: var(--muted); font-size: 12px; }.time-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }.time-slot { min-height: 70px; padding: 11px 13px; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: #fbfdfe; cursor: pointer; transition: border .2s, transform .2s, background .2s; }.time-slot:hover { border-color: var(--cyan); background: var(--sky); transform: translateY(-2px); }.time-slot strong { font-size: 17px; }.time-slot small { color: var(--green); margin-top: 4px; font-size: 10px; font-weight: 800; text-transform: uppercase; }.time-slot:disabled { color: #a1b1ba; background: #f2f5f6; cursor: not-allowed; transform: none; }.time-slot:disabled small { color: #9aa9b1; }
.class-list { display: grid; gap: 12px; }.class-card { padding: 20px; display: grid; grid-template-columns: 72px 1fr auto; align-items: center; gap: 20px; border: 1px solid var(--line); border-radius: 13px; }.date-badge { padding: 10px; color: var(--blue); background: var(--sky); border-radius: 10px; text-align: center; }.date-badge strong, .date-badge span { display: block; }.date-badge strong { font-size: 25px; line-height: 1; }.date-badge span { margin-top: 4px; font-size: 10px; font-weight: 900; text-transform: uppercase; }.class-details h3 { margin: 0 0 7px; font-size: 18px; }.class-details p { margin: 0; color: var(--muted); font-size: 13px; }.class-actions { display: flex; align-items: center; gap: 15px; }.status-pill { display: inline-flex; padding: 6px 10px; border-radius: 20px; color: var(--green); background: #e9f8f2; font-size: 10px; font-weight: 900; text-transform: uppercase; }.status-pill.cancelled { color: #87949b; background: #f0f3f4; }.status-pill.available { color: var(--green); background: #e9f8f2; }.status-pill.reserved { color: #096da4; background: #e6f5fc; }.status-pill.blocked { color: #b76d19; background: #fff1df; }.cancel-button, .row-action { padding: 8px; color: var(--danger); background: transparent; border: 0; font-size: 12px; font-weight: 800; cursor: pointer; }.row-action { color: var(--blue); }
.toast { position: fixed; right: 25px; bottom: 25px; z-index: 50; max-width: min(380px, calc(100% - 40px)); padding: 14px 18px; color: white; background: var(--navy); border-radius: 10px; box-shadow: var(--shadow); font-size: 13px; font-weight: 750; opacity: 0; transform: translateY(20px); pointer-events: none; transition: .25s; }.toast.visible { opacity: 1; transform: none; }.toast.error { background: var(--danger); }

/* Professor */
.professor-content { margin-top: -32px; position: relative; }.metrics-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }.metrics-grid article { min-height: 105px; padding: 20px; display: flex; align-items: center; gap: 15px; background: white; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 10px 30px rgba(8,58,89,.07); }.metric-icon { flex: 0 0 44px; height: 44px; display: grid; place-items: center; border-radius: 11px; font-weight: 900; }.metric-icon.blue { color: var(--blue); background: var(--sky); }.metric-icon.yellow { color: #a46700; background: #fff4d3; }.metric-icon.orange { color: #cd681d; background: #ffecdf; }.metric-icon.green { color: var(--green); background: #e9f8f2; }.metrics-grid small, .metrics-grid strong { display: block; }.metrics-grid small { color: var(--muted); font-size: 11px; }.metrics-grid strong { margin-top: 3px; font-size: 25px; }.schedule-admin { margin: 20px 0 0; }.admin-actions { display: flex; align-items: end; gap: 10px; }.date-control { gap: 3px; }.date-control input { height: 40px; }.table-wrap { overflow-x: auto; }.schedule-table { width: 100%; border-collapse: collapse; font-size: 13px; }.schedule-table th { padding: 11px 14px; color: var(--muted); background: #f3f8fa; text-align: left; font-size: 10px; letter-spacing: .07em; text-transform: uppercase; }.schedule-table th:first-child { border-radius: 8px 0 0 8px; }.schedule-table th:last-child { border-radius: 0 8px 8px 0; }.schedule-table td { padding: 17px 14px; border-bottom: 1px solid var(--line); }.schedule-table td:first-child { font-size: 16px; font-weight: 850; }.student-button { padding: 0; color: var(--blue); background: transparent; border: 0; font-weight: 750; cursor: pointer; }.table-actions { display: flex; justify-content: flex-end; gap: 8px; }.tiny-button { min-height: 31px; padding: 0 10px; border: 1px solid var(--line); border-radius: 7px; color: var(--ink); background: white; font-size: 10px; font-weight: 850; cursor: pointer; }.tiny-button.danger { color: var(--danger); }.empty-state.compact { min-height: 160px; }
.modal { width: min(480px, calc(100% - 30px)); padding: 0; border: 0; border-radius: 18px; box-shadow: 0 30px 80px rgba(0,33,54,.3); }.modal::backdrop { background: rgba(1,31,50,.66); backdrop-filter: blur(3px); }.modal > form, .modal > div { padding: 34px; position: relative; }.modal h2 { margin: 12px 0 22px; letter-spacing: -.03em; }.modal-close { position: absolute; right: 18px; top: 15px; width: 34px; height: 34px; border: 0; border-radius: 50%; color: var(--muted); background: var(--surface); font-size: 22px; cursor: pointer; }.form-grid { display: grid; gap: 15px; }.modal #student-email { margin-bottom: 26px; color: var(--muted); }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr 1fr; }.hero h1 { font-size: 48px; }.feature-grid { gap: 12px; }.steps-grid { gap: 40px; }.time-grid { grid-template-columns: repeat(3, 1fr); }.metrics-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 720px) {
  .container { width: min(100% - 28px, 1160px); }.site-header { height: 68px; }.brand img { width: 142px; }.menu-button { display: block; }.nav-links { display: none; position: absolute; top: 66px; left: 14px; right: 14px; padding: 20px; flex-direction: column; align-items: stretch; gap: 16px; color: white; background: var(--navy); border: 1px solid rgba(255,255,255,.12); border-radius: 13px; box-shadow: var(--shadow); }.nav-links.open { display: flex; }.nav-links .button { width: 100%; }.user-chip { text-align: center; }.back-link { font-size: 12px; }
  .hero { min-height: auto; }.hero-grid { min-height: auto; grid-template-columns: 1fr; }.hero-copy { padding: 60px 0 20px; }.hero h1 { font-size: 45px; }.hero-copy > p { font-size: 15px; }.hero-actions { align-items: stretch; flex-direction: column; gap: 20px; }.hero-actions .button { width: 100%; }.hero-actions .text-link { justify-content: center; }.hero-visual { height: 370px; }.hero-visual > img { width: 115%; max-width: none; }.floating-card { right: 0; bottom: 15%; }.wave-cut { height: 40px; }
  .section { padding: 70px 0; }.section-heading h2, .steps-grid h2 { font-size: 36px; }.feature-grid { grid-template-columns: 1fr; }.steps-grid { grid-template-columns: 1fr; gap: 30px; }.steps li { padding: 17px 5px; }.cta-section { padding: 35px 0; }.cta-box { padding: 35px 25px; align-items: stretch; flex-direction: column; gap: 25px; }.cta-box h2 { font-size: 29px; }.footer-wrap { padding: 28px 0; align-items: flex-start; flex-direction: column; }.footer-wrap p { margin: 0; }
  .auth-page { background: linear-gradient(180deg, var(--navy) 0 180px, var(--surface) 180px); }.site-header.compact .back-link { display: none; }.auth-main { padding: 92px 14px 30px; align-items: start; }.auth-card { padding: 32px 24px; }.auth-icon { display: none; }
  .page-hero, .page-hero.small { min-height: 205px; padding-bottom: 25px; }.page-hero h1 { font-size: 34px; }.content-panel { padding: 20px 16px; }.panel-heading { align-items: flex-start; flex-direction: column; }.day-group { grid-template-columns: 1fr; gap: 12px; }.day-label { display: flex; justify-content: space-between; }.day-label span { margin: 0; }.time-grid { grid-template-columns: repeat(2, 1fr); }.class-card { grid-template-columns: 62px 1fr; gap: 13px; }.class-actions { grid-column: 1 / -1; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 12px; }.metrics-grid { grid-template-columns: 1fr 1fr; gap: 9px; }.metrics-grid article { min-height: 90px; padding: 13px; }.metric-icon { display: none; }.professor-content { width: calc(100% - 20px); }.admin-heading { align-items: stretch; }.admin-actions { align-items: stretch; flex-direction: column; }.schedule-admin { padding-inline: 13px; }.schedule-table { min-width: 620px; }.modal > form, .modal > div { padding: 30px 22px; }
}

@media (max-width: 390px) {
  .hero h1 { font-size: 39px; }.time-grid { grid-template-columns: 1fr 1fr; }.metrics-grid { grid-template-columns: 1fr 1fr; }.metrics-grid strong { font-size: 22px; }
}
