:root {
  /* Design tokens (Primary / Secondary / Accent) */
  --bg: #0b1426;        /* app background */
  --panel: #0f1d34;     /* sections/panels */
  --panel2: #0d1930;    /* secondary panels */
  --card: #102241;      /* cards */
  --text: #eaf2ff;      /* primary text */
  --muted: #b7c4e4;     /* secondary text */
  --border: rgba(255, 255, 255, .14);
  --primary: #4f46e5;   /* indigo (primary) */
  --primary2: #14b8a6;  /* teal (accent) */
  --danger: #ff4d6d;
  --success: #2fe39b;
  --warn: #ffd166;
  --shadow: 0 14px 40px rgba(0, 0, 0, .35);
  --radius: 16px;
  --radius2: 12px;
  --max: 1200px;
  --pad: 16px;
  --s1: 8px;
  --s2: 16px;
  --s3: 24px;
  --s4: 32px;
  --header-offset: 72px;
}

* {
  box-sizing: border-box
}

html,
body {
  height: 100%
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--text);
  font-size: 16px;
  /* Keep the whole app on a single solid base color */
  background: var(--bg);
  line-height: 1.55;
  overflow-x: hidden;
  /* no horizontal scroll on mobile */
}

a {
  color: inherit;
  text-decoration: none
}

a:hover {
  text-decoration: underline
}

/* Core container requirement */
.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad)
}

.site-main {
  display: block;
  width: 100%;
  flex: 1 0 auto;
  min-height: 0;
  padding-top: var(--header-offset)
}

/* In-page anchors: clear fixed header */
#teacher-classes,
#teacher-test-results,
#teacher-attendance {
  scroll-margin-top: calc(var(--header-offset) + 12px);
}

/* Ensure footer is never rendered on top of content */
.site-main,
.site-footer {
  z-index: auto;
}

img,
video,
canvas,
svg {
  max-width: 100%;
  height: auto
}

.py-48 {
  padding-top: 48px;
  padding-bottom: 48px
}

.mt-8 {
  margin-top: 8px
}

.mt-12 {
  margin-top: 12px
}

.mt-16 {
  margin-top: 16px
}

.mt-24 {
  margin-top: 24px
}

.ml-8 {
  margin-left: 8px
}

.w-full {
  width: 100%
}

.mx-auto {
  margin-left: auto;
  margin-right: auto
}

.max-w-560 {
  max-width: 560px
}

.max-w-720 {
  max-width: 720px
}

.inline {
  display: inline
}

.h1,
.h2,
.h3,
.h4,
.h5 {
  margin: 0
}

.h2 {
  font-size: clamp(22px, 2.6vw, 34px);
  letter-spacing: -.02em
}

.h4 {
  font-size: 18px
}

.h5 {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--muted)
}

.muted {
  color: var(--muted)
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 50;
  backdrop-filter: saturate(140%) blur(14px);
  /* Solid header background (no gradient) */
  background: rgba(18, 32, 70, .78);
  border-bottom: 1px solid rgba(255, 255, 255, .18);
  transition: transform .18s ease, box-shadow .18s ease;
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 60px
}

.site-header--compact .site-header__inner {
  min-height: 46px
}

.site-header__actions {
  margin-left: auto;
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.nav {
  display: flex;
  gap: 14px;
  align-items: center
}

.nav__link {
  color: var(--muted);
  font-weight: 600;
  font-size: 14px
}

.nav__link:hover {
  color: var(--text);
  text-decoration: none
}

.brand {
  display: flex;
  gap: 10px;
  align-items: center;
  font-weight: 800
}

.brand__mark {
  width: 48px;
  height: 48px;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  display: grid;
  place-items: center;
  box-shadow: 0 10px 24px rgba(20, 184, 166, .22)
}

.site-header .brand__mark {
  width: 56px;
  height: 44px;
  border-radius: 12px;
}

.site-header--compact .brand__mark {
  /* Keep logo fully inside the compact header height */
  width: 42px;
  height: 34px;
  border-radius: 10px;
}

.brand__mark--img {
  /* Logo image should fit inside the existing brand icon size */
  display: block;
  background: transparent;
  box-shadow: none;
  object-fit: cover;
  width: 100%;
  height: 100%;
}

.site-header .brand__mark--img {
  /* Do not crop header logo; keep full image visible */
  object-fit: contain;
}

.brand__name {
  letter-spacing: -.02em
}

.brand--footer .brand__mark {
  width: 54px;
  height: 34px;
  border-radius: 12px;
  overflow: hidden;
}

.site-footer .brand__mark--img {
  /* Do not crop footer logo; show full image */
  object-fit: contain;
}

/* Profile dropdown (avatar -> My profile + Sign out) */
.profile-dropdown{
  position:relative;
  display:inline-block;
}
.profile-dropdown__summary{
  list-style:none;
  cursor:pointer;
}
.profile-dropdown__summary::-webkit-details-marker{
  display:none;
}
.profile-avatar{
  width:44px;
  height:44px;
  border-radius:16px;
  display:block;
  object-fit:cover;
  border:1px solid rgba(255,255,255,.16);
  box-shadow:0 10px 24px rgba(20,184,166,.12);
}
.profile-avatar--fallback{
  width:44px;
  height:44px;
  border-radius:16px;
  display:grid;
  place-items:center;
  background:linear-gradient(135deg, rgba(20,184,166,.22), rgba(96,165,250,.16));
  font-weight:900;
  letter-spacing:-.02em;
  color:var(--text);
  border:1px solid rgba(255,255,255,.14);
}
.profile-dropdown__menu{
  display:none;
  position:absolute;
  right:0;
  top:52px;
  min-width:220px;
  background:rgba(18, 32, 70, .98);
  backdrop-filter:saturate(140%) blur(14px);
  border:1px solid rgba(255,255,255,.14);
  border-radius:16px;
  padding:10px;
  box-shadow:0 24px 70px rgba(0,0,0,.5);
  z-index:60;
  color: var(--text);
}
 .profile-dropdown__name{
  padding:10px 12px;
  border-bottom:1px solid rgba(255,255,255,.10);
  color:var(--text);
  font-weight:700;
}
details[open] .profile-dropdown__menu{
  display:block;
}
.profile-dropdown__link{
  display:block;
  padding:10px 12px;
  border-radius:12px;
  color:var(--text);
  font-weight:800;
}
.profile-dropdown__link:hover{
  text-decoration:none;
  background:rgba(255,255,255,.06);
}
.profile-dropdown__form{
  margin:6px 0 0 0;
}
.profile-dropdown__link--button{
  width:100%;
  text-align:left;
  background:transparent;
  border:0;
  cursor:pointer;
  color:var(--text);
  font:inherit;
  padding:10px 12px;
}
.profile-dropdown__link--button:hover{
  background:rgba(255,255,255,.06);
}

.nav-toggle {
  display: none;
  margin-left: 10px;
  border: 1px solid var(--border);
  background: transparent;
  border-radius: 12px;
  padding: 10px
}

.nav-toggle__bar {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text);
  margin: 4px 0;
  border-radius: 2px
}

.subbar {
  padding: 10px 0 14px 0;
  color: var(--muted);
  font-size: 13px;
}

.btn {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  border-radius: 14px;
  padding: 10px 14px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  display: inline-flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-1px)
}

.btn:active {
  transform: translateY(0)
}

.btn--lg {
  padding: 12px 16px;
  border-radius: 16px
}

.btn--sm {
  padding: 8px 10px;
  border-radius: 12px;
  font-size: 13px
}

.btn--primary {
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  box-shadow: 0 14px 28px rgba(20, 184, 166, .18)
}

.btn--primary:hover {
  filter: brightness(1.02)
}

.btn--outline {
  border-color: var(--border);
  background: rgba(255, 255, 255, .04)
}

.btn--ghost {
  background: rgba(255, 255, 255, .03)
}

.btn[disabled] {
  opacity: .6;
  cursor: not-allowed;
  transform: none
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .04);
  color: var(--muted)
}

.badge--info {
  background: rgba(96, 165, 250, .10);
  border-color: rgba(96, 165, 250, .28);
  color: #dbeafe
}

.badge--warn {
  background: rgba(255, 209, 102, .10);
  border-color: rgba(255, 209, 102, .25);
  color: #fff3c2
}

.badge--active {
  background: rgba(47, 227, 155, .10);
  border-color: rgba(47, 227, 155, .28);
  color: #d1fae5
}

.badge--coming {
  background: rgba(96, 165, 250, .10);
  border-color: rgba(96, 165, 250, .28);
  color: #dbeafe
}

.badge--passed {
  background: rgba(255, 255, 255, .03);
  border-color: rgba(255, 255, 255, .14);
  color: var(--muted)
}

.badge--cancelled {
  background: rgba(255, 77, 109, .10);
  border-color: rgba(255, 77, 109, .28);
  color: #ffd1db
}

/* DB record status (classes.status) — distinct from time-based session badge */
.badge--status-scheduled {
  background: rgba(129, 140, 248, .14);
  border-color: rgba(129, 140, 248, .4);
  color: #e0e7ff
}

.badge--status-completed {
  background: rgba(20, 184, 166, .14);
  border-color: rgba(20, 184, 166, .38);
  color: #ccfbf1
}

.badge--status-cancelled {
  background: rgba(251, 113, 133, .14);
  border-color: rgba(251, 113, 133, .4);
  color: #ffe4e8
}

.classes-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px
}

.classes-toolbar .input,
.classes-toolbar .select {
  min-height: 32px;
  padding: 6px 10px;
  font-size: 12px;
  border-radius: 8px
}

.classes-toolbar__search {
  flex: 1 1 180px;
  max-width: 260px
}

.classes-toolbar__select {
  width: auto;
  min-width: 130px
}

.alert {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, .04)
}

.alert--danger {
  border-color: rgba(255, 77, 109, .35);
  background: rgba(255, 77, 109, .09)
}

.alert--success {
  border-color: rgba(47, 227, 155, .32);
  background: rgba(47, 227, 155, .08)
}

.hero {
  padding: 48px 0 24px 0
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 22px;
  align-items: center
}

.hero__title {
  margin-top: 14px;
  font-size: clamp(30px, 4.2vw, 52px);
  letter-spacing: -.03em;
  line-height: 1.05;
}

.hero__subtitle {
  margin-top: 14px;
  color: var(--muted);
  font-size: clamp(1rem, 1.35vw, 1.05rem);
  max-width: 58ch
}

.hero__actions {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px
}

.hero__stats {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 22px
}

.stat {
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .03);
  border-radius: 14px
}

.stat__value {
  font-weight: 900
}

.stat__label {
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px
}

/* Hero highlights (replaces old "Simple/Reliable/Secure" stats) */
.hero__highlights {
  margin-top: 22px;
  display: grid;
  gap: 10px;
  max-width: 720px
}

.highlight {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .03);
  border-radius: 16px;
}

.highlight__icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(20, 184, 166, .30), rgba(96, 165, 250, .18));
  border: 1px solid rgba(255, 255, 255, .14);
  color: var(--text);
  flex: 0 0 auto;
}

.highlight__title {
  font-weight: 950
}

.highlight__text {
  color: var(--muted);
  font-size: 13px;
  margin-top: 4px
}


.card {
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .02));
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.card--link {
  display: block
}

.card--link:hover {
  text-decoration: none;
  transform: translateY(-2px)
}

.card--link:active {
  transform: translateY(0)
}

.card--glass {
  background: linear-gradient(180deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .02))
}

.card__body {
  padding: 18px
}

.section {
  padding: 44px 0
}

.section--alt {
  background: linear-gradient(180deg, rgba(255, 255, 255, .03), rgba(255, 255, 255, .00));
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px
}

.icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(20, 184, 166, .30), rgba(96, 165, 250, .18));
  border: 1px solid rgba(255, 255, 255, .14);
  font-weight: 900;
}

.steps {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  align-items: start
}

.step-list {
  display: grid;
  gap: 12px
}

.step {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .03);
  border-radius: 16px;
  padding: 14px
}

.step__num {
  width: 30px;
  height: 30px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(20, 184, 166, .16);
  border: 1px solid rgba(20, 184, 166, .26);
  font-weight: 900
}

.step__title {
  font-weight: 900
}

.mock {
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 16px;
  overflow: hidden;
  background: rgba(0, 0, 0, .16)
}

.mock__top {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .10);
  background: rgba(255, 255, 255, .04)
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  display: inline-block
}

.dot--r {
  background: #ff5d5d
}

.dot--y {
  background: #ffd166
}

.dot--g {
  background: #2fe39b
}

.mock__content {
  padding: 14px
}

.divider {
  height: 1px;
  background: rgba(255, 255, 255, .10);
  margin: 14px 0
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px
}

.mini-card {
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 14px;
  padding: 12px;
  background: rgba(255, 255, 255, .03)
}

.mini-card__title {
  font-weight: 900
}

.mini-card__text {
  color: var(--muted);
  font-size: 13px;
  margin-top: 4px
}

.meeting-card {
  display: flex;
  gap: 12px;
  align-items: center
}

.meeting-card__img {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(96, 165, 250, .30), rgba(20, 184, 166, .16));
  border: 1px solid rgba(255, 255, 255, .14);
}

.meeting-card__title {
  font-weight: 900
}

.meeting-card__meta {
  color: var(--muted);
  font-size: 13px;
  margin-top: 2px
}

.meeting-card__actions {
  margin-top: 10px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap
}

.hero-illus {
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .03);
}

.hero-illus__caption {
  font-size: 13px;
  color: var(--muted);
  margin-top: 10px
}

/* Light sections (white background) */
.section--light {
  background: #ffffff;
  color: #0b1020;
  border-top: 1px solid rgba(2, 6, 23, .10);
  border-bottom: 1px solid rgba(2, 6, 23, .10);
}

.section--light .muted {
  color: #4b5563
}

.section--light .card {
  background: linear-gradient(180deg, rgba(2, 6, 23, .04), rgba(2, 6, 23, .02));
  border-color: rgba(2, 6, 23, .12);
  box-shadow: 0 12px 34px rgba(2, 6, 23, .12);
}

.section--light .badge {
  background: rgba(2, 6, 23, .04);
  border-color: rgba(2, 6, 23, .12);
  color: #4b5563;
}

.section--light .badge--info {
  background: rgba(96, 165, 250, .14);
  border-color: rgba(96, 165, 250, .35);
  color: #0b1020;
}

.section--light .btn--outline {
  background: rgba(2, 6, 23, .03);
  border-color: rgba(2, 6, 23, .14);
  color: #0b1020;
}

.section--light .btn--ghost {
  background: rgba(2, 6, 23, .02);
  color: #0b1020;
}

.section--light .link {
  color: #0b1020
}

/* Modern inline SVG icons */
.icon-svg {
  width: 22px;
  height: 22px;
  display: block
}

.icon {
  display: grid;
  place-items: center;
}

.icon--svg {
  background: linear-gradient(135deg, rgba(20, 184, 166, .30), rgba(96, 165, 250, .18));
}

.section--light .icon--svg {
  background: linear-gradient(135deg, rgba(20, 184, 166, .18), rgba(96, 165, 250, .14));
  border-color: rgba(2, 6, 23, .12);
}

.field {
  margin-top: 12px
}

.label {
  display: block;
  font-weight: 800;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 6px
}

.input,
.select,
.textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .03);
  color: var(--text);
  border-radius: 14px;
  padding: 11px 12px;
  outline: none;
}

.input[type="file"] {
  padding: 10px 12px;
}

/* Make the native "Choose file / No file chosen" button match the UI */
.input[type="file"]::-webkit-file-upload-button {
  background: rgba(20, 184, 166, .16);
  border: 1px solid rgba(20, 184, 166, .28);
  color: var(--text);
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 800;
  cursor: pointer;
}

.input[type="file"]::file-selector-button {
  background: rgba(20, 184, 166, .16);
  border: 1px solid rgba(20, 184, 166, .28);
  color: var(--text);
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 800;
  cursor: pointer;
}

.textarea {
  min-height: 100px;
  resize: vertical
}

.input:focus,
.select:focus,
.textarea:focus {
  border-color: rgba(20, 184, 166, .55);
  box-shadow: 0 0 0 4px rgba(20, 184, 166, .12)
}

.table-wrap {
  overflow: auto;
  border-radius: 16px;
  border: 1px solid var(--border);
  /* Make table area non-transparent */
  background: rgba(255, 255, 255, .03);
}

/* Table enhancer controls (search + rows per page) — compact */
.table-controls {
  margin: 8px 0 8px 0;
}

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

.table-controls__pageSize {
  min-width: 72px !important;
  max-width: 88px !important;
  width: auto !important;
  height: 32px !important;
  padding: 4px 8px !important;
  font-size: 11px !important;
  line-height: 1.2 !important;
  border-radius: 8px !important;
  background: rgba(255, 255, 255, .06) !important;
  color: var(--text) !important;
  border-color: rgba(255, 255, 255, .22) !important;
}

.table-controls__search {
  max-width: 220px;
  flex: 0 1 200px !important;
  width: 100% !important;
  min-height: 32px !important;
  height: 32px !important;
  padding: 6px 10px !important;
  font-size: 11px !important;
  line-height: 1.2 !important;
  border-radius: 8px !important;
  background: rgba(255, 255, 255, .06) !important;
  color: var(--text) !important;
  border-color: rgba(255, 255, 255, .22) !important;
}

.table-controls__search::placeholder{
  color: rgba(183, 196, 228, .9);
}

.table-controls__pageSize option {
  background: #0b1426;
  color: var(--text);
}

.table-controls__pager {
  gap: 8px !important;
  margin-top: 8px !important;
}

.table-controls__pager .btn {
  padding: 5px 10px !important;
  border-radius: 8px !important;
  font-size: 11px !important;
  min-height: 32px !important;
}

.table-controls__pageInfo {
  font-size: 11px !important;
  font-weight: 800 !important;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: rgba(255, 255, 255, .035)
}

th,
td {
  padding: 10px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  text-align: left
}

th {
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted)
}

tr:hover td {
  background: rgba(255, 255, 255, .04)
}

/* Zebra striping for table readability */
tbody tr:nth-child(odd) td {
  background: rgba(255, 255, 255, .015);
}

tbody tr:nth-child(even) td {
  background: rgba(255, 255, 255, .03);
}

tbody tr td {
  transition: background .15s ease, transform .15s ease;
}

thead th{
  background: rgba(255, 255, 255, .02);
}

.page-head {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  justify-content: space-between
}

.row-title {
  font-weight: 900
}

.td-actions {
  white-space: nowrap;
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap
}

/* Make tables fit better on smaller screens */
@media (max-width: 768px) {
  th,
  td {
    padding: 10px 8px;
    font-size: 12px
  }

  th {
    font-size: 11px
  }

  .td-actions {
    white-space: normal
  }

  table {
    width: 100%
  }
}

.link {
  color: #cfefff
}

.link:hover {
  text-decoration: none;
  color: var(--text)
}

.cards--grid {
  grid-template-columns: repeat(2, minmax(0, 1fr))
}

.class-card {
  display: flex;
  gap: 14px;
  align-items: flex-start
}

.class-card__img {
  width: 84px;
  height: 84px;
  border-radius: 18px;
  flex: 0 0 auto;
  background: linear-gradient(135deg, rgba(20, 184, 166, .20), rgba(96, 165, 250, .14));
  border: 1px solid rgba(255, 255, 255, .14);
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.class-card__img-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.class-detail__img {
  width: 100%;
  max-width: 360px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  display: block;
  object-fit: cover;
  aspect-ratio: 1 / 1;
}

/* Student dashboard: square "tile" cards (not narrow rows) */
#student-classes.cards--grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 12px;
}

@media (max-width: 1024px) {
  #student-classes.cards--grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 768px) {
  #student-classes.cards--grid {
    grid-template-columns: 1fr !important;
  }
}

#student-classes .card{
  border-radius: 16px;
  height: 100%;
}

#student-classes .card__body {
  padding: 8px;
  height: 100%;
}

#student-classes .class-card {
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
}

#student-classes .class-card__img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
}

/* Reduce text/spacing (keep image size) */
#student-classes .class-card__title{
  font-size: 15px;
}

#student-classes .class-card__meta{
  font-size: 12px;
  margin-top: 3px;
}

#student-classes .class-card__actions{
  margin-top: 6px;
  gap: 6px;
}

#student-classes .class-card__img-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Used in admin "Classes" table */
.admin-class-thumb {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  flex: 0 0 auto;
  background: linear-gradient(135deg, rgba(20, 184, 166, .20), rgba(96, 165, 250, .14));
  border: 1px solid rgba(255, 255, 255, .14);
  background-size: cover;
  background-position: center;
}

.class-card__title {
  font-weight: 950;
  font-size: 16px
}

.class-card__meta {
  color: var(--muted);
  font-size: 13px;
  margin-top: 6px
}

.class-card__actions {
  margin-top: 12px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center
}

.tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap
}

.tab {
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .03);
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
}

.tab:hover {
  text-decoration: none;
  color: var(--text)
}

.tab--active {
  background: rgba(20, 184, 166, .16);
  border-color: rgba(20, 184, 166, .30);
  color: var(--text)
}

.modal {
  display: none
}

.modal--open {
  display: block
}

.modal__backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .55);
  backdrop-filter: blur(10px);
}

.modal__dialog {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(680px, calc(100vw - 16px));
  max-height: calc(100vh - 16px);
  overflow: auto;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, .14);
  background: linear-gradient(180deg, rgba(15, 26, 58, .98), rgba(11, 16, 32, .98));
  box-shadow: 0 24px 70px rgba(0, 0, 0, .55);
}

.modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, .10)
}

.modal__body {
  padding: 12px 12px 14px
}

/* Class creation modals: smaller + avoid hiding bottom fields */
#createClassModal .modal__dialog,
#createClassAdminModal .modal__dialog {
  width: min(560px, calc(100vw - 16px));
  display: flex;
  flex-direction: column;
}

#createClassModal .modal__body,
#createClassAdminModal .modal__body {
  overflow: auto;
  max-height: calc(100vh - 170px);
}

/* Make labels/help text/icons white inside class modals */
#createClassModal .label,
#createClassModal .muted,
#createClassAdminModal .label,
#createClassAdminModal .muted {
  color: var(--text);
}

#createClassModal .select,
#createClassAdminModal .select {
  background: rgba(255,255,255,.06);
  color: var(--text);
}

/* Native select options styling is inconsistent across browsers,
   but this helps on common browsers where text becomes low-contrast. */
#createClassModal .select option,
#createClassAdminModal .select option {
  color: #0b1426;
  background: #eaf2ff;
}

#createClassModal svg,
#createClassModal .icon,
#createClassAdminModal svg,
#createClassAdminModal .icon {
  color: var(--text);
}

#createClassModal svg *,
#createClassAdminModal svg * {
  fill: var(--text);
  stroke: var(--text);
}

body.modal-open {
  overflow: hidden
}

.site-footer {
  margin-top: auto;
  flex: 0 0 auto;
  flex-shrink: 0;
  width: 100%;
  position: relative;
  border-top: 1px solid var(--border);
  background: #0a1324
}

.site-footer,
.site-footer .muted,
.site-footer .list a,
.site-footer .list li {
  font-size: 12px;
}

.site-footer .h5{
  font-size: 11px;
}

.site-footer__bottom .muted{
  font-size: 11px;
}

.site-footer__section{
  background: transparent;
}

.site-footer__section--bottom{
  background: rgba(255, 255, 255, .02);
  border-top: 1px solid rgba(255, 255, 255, .10);
}

.site-footer--compact{
  margin-top: auto;
}

.site-footer--compact .site-footer__grid{
  padding: 12px 0;
  grid-template-columns: 1.2fr .8fr .8fr;
  gap: 14px;
}

.site-footer--compact .site-footer__bottom{
  padding: 10px 0;
}

.site-footer--compact .brand--footer .brand__mark{
  width: 40px;
  height: 26px;
  border-radius: 10px;
}

.site-footer--compact .brand--footer .brand__name{
  display:none;
}

.site-footer--compact .site-footer__grid .muted.mt-12{
  display:none;
}

.site-footer--compact .h5{
  font-size: 12px;
}

.site-footer--compact .list{
  margin-top: 6px;
  gap: 6px;
}

.site-footer--compact .list a,
.site-footer--compact .list li{
  font-size: 13px;
}

.site-footer__grid {
  padding: 28px 0;
  display: grid;
  grid-template-columns: 1.2fr .8fr .8fr;
  gap: 22px
}

.site-footer__bottom {
  padding: 14px 0;
  border-top: 0;
}

.list {
  list-style: none;
  padding: 0;
  margin: 10px 0 0 0;
  display: grid;
  gap: 8px
}

.list a {
  color: var(--muted)
}

.list a:hover {
  color: var(--text);
  text-decoration: none
}

/* tablets */
@media (max-width: 1024px) {
  .hero__grid {
    grid-template-columns: 1fr;
    gap: 18px
  }

  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr))
  }

  .steps {
    grid-template-columns: 1fr
  }

  .site-footer__grid {
    grid-template-columns: 1fr
  }
}

/* mobile */
@media (max-width: 768px) {
  .cards {
    grid-template-columns: 1fr
  }

  .cards--grid {
    grid-template-columns: 1fr
  }

  .page-head {
    flex-direction: column;
    align-items: stretch
  }

  .page-head .btn {
    width: 100%
  }

  .hero__actions .btn {
    flex: 1 1 100%
  }

  /* Navbar: hamburger + smooth dropdown */
  .nav-toggle {
    display: inline-flex
  }

  .nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 68px;
    padding: 0 var(--pad);
    background: rgba(18, 32, 70, .85);
    border-bottom: 1px solid rgba(255, 255, 255, .18);
    flex-direction: column;
    align-items: flex-start;
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    pointer-events: none;
    transition: max-height .22s ease, opacity .18s ease;
  }

  .nav__link {
    padding: 12px 0;
    width: 100%
  }

  body.nav-open .nav {
    max-height: 260px;
    opacity: 1;
    pointer-events: auto;
  }

  /* Modal should fit on smaller screens */
  .modal__dialog {
    width: calc(100vw - 16px);
    max-height: calc(100vh - 16px)
  }

  .modal__head {
    padding: 12px 12px
  }

  .modal__body {
    padding: 12px 12px 14px
  }
}

/* small mobile */
@media (max-width: 480px) {
  .hero {
    padding: 32px 0 18px 0
  }

  .py-48 {
    padding-top: 32px;
    padding-bottom: 32px
  }

  .btn {
    width: 100%
  }

  .site-header__actions {
    gap: 8px
  }

  .brand__name {
    display: none
  }

  .class-card {
    flex-direction: column
  }

  .class-card__img {
    width: 100%;
    height: 160px
  }

  .class-card__img-img {
    width: 100%;
    height: 160px;
  }

  .hero__highlights {
    max-width: 100%
  }
}

/* large screens */
@media (min-width: 1441px) {
  :root {
    --max: 1200px;
  }
}