/* =========================================================
   pages/teacher-dashboard.css
   ---------------------------------------------------------
   Teacher dashboard, date controls, schedule table, quick
   actions, quick schedule and responsive dashboard rules.

   Notes:
   - Dashboard V2 styles are scoped mostly to .nn-teacher-v2.
   - Final mobile overrides must stay at the bottom.
   ========================================================= */


/* =========================================================
   1) LEGACY FILTER BAR / SHARED TEACHER TABLE HELPERS
   ---------------------------------------------------------
   Kept for older dashboard/filter components that may still
   appear in tools, exports, or legacy teacher screens.
   ========================================================= */

.nn-teacher > .card:first-of-type {
  margin-top: 8px;
}

.nn-filter--topbar {
  padding: 12px 16px;
}

.nn-filter__form--topbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr);
  gap: 16px;
  align-items: center;
}

.nn-filter__searchCol,
.nn-filter__actionCol {
  min-width: 0;
}

.nn-filter__dateCol {
  display: flex;
  justify-content: center;
}

.nn-filter__search {
  position: relative;
  display: flex;
  align-items: center;
}

.nn-filter__search input[type="search"] {
  width: 100%;
  height: 40px;
  padding: 0 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--card);
  color: var(--text);
  font-size: 16px;
}

.nn-filter__actionCol {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.nn-filter__schedule-btn {
  min-height: 40px;
  white-space: nowrap;
}

.nn-date-center--topbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: nowrap;
}

.nn-date-arrow {
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--card);
  color: var(--text);
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
}

.nn-date-display-wrap {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--card);
  color: var(--text);
}

.nn-date-display-wrap--strong {
  border-color: #d0d5dd;
}

.nn-date-text {
  font-weight: 700;
  font-size: 0.95rem;
  white-space: nowrap;
}

.nn-date-icon {
  opacity: 0.6;
}

.nn-date-display-wrap #nn-date-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.nn-date-today {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid #d0d5dd;
  border-radius: 999px;
  background: #fff;
  color: #1f2937;
}

.nn-date-today:hover {
  background: #f7f8fa;
  color: #111827;
  text-decoration: none;
}

.nn-search-results {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 1002;
  margin: 0;
  padding: 0;
  list-style: none;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.nn-search-results:empty {
  display: none;
}

.nn-search-results li {
  padding: 8px 10px;
  border-bottom: 1px solid #eee;
  cursor: pointer;
}

.nn-search-results li:last-child {
  border-bottom: 0;
}

.nn-search-results li:hover {
  background: #f2f2f2;
}


/* =========================================================
   2) LEGACY TABLE HELPERS
   ---------------------------------------------------------
   These target .nn-table, not the V2 dashboard table.
   Keep them unless you are sure no old teacher screens use
   .nn-table.
   ========================================================= */

.nn-table {
  width: 100%;
  border-collapse: collapse;
}

.nn-table th,
.nn-table td {
  border-bottom: 1px solid #d8dee6;
}

.nn-table th {
  color: #475467;
  font-weight: 600;
}

.nn-table a i {
  color: var(--muted-3);
}

.nn-table tbody tr:hover {
  background: #f7f8fa;
}

.nn-table tr.is-now {
  background: #eef6ff;
}

.nn-row-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
}

.nn-row-edit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #cfd5dc;
  border-radius: 10px;
  background: #fff;
  color: #1f2937;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.nn-row-edit:hover {
  background: #f7f8fa;
  border-color: #bfc7d1;
  color: #111827;
  text-decoration: none;
}

.nn-row-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 1px solid #cfd5dc;
  border-radius: 10px;
  background: #fff;
  color: #667085;
  text-decoration: none;
}

.nn-row-icon:hover {
  background: #f7f8fa;
  border-color: #bfc7d1;
  color: #111827;
  text-decoration: none;
}

.nn-row-icon--danger:hover {
  background: #fff5f4;
  border-color: #f1b5ae;
  color: #b42318;
}


/* =========================================================
   3) STUDENT / KIT MINI BADGES
   ---------------------------------------------------------
   Used inside dashboard lesson rows.
   ========================================================= */

.nn-kit-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 18px;
  padding: 0 6px;
  margin-left: 6px;
  border: 1px solid #cfd5dc;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  vertical-align: middle;
  white-space: nowrap;
}

.nn-kit-badge i {
  font-size: 10px;
  line-height: 1;
}

.nn-kit-badge__text {
  display: inline-block;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}

.nn-kit-badge--acoustic {
  background: #f3f4f6;
  color: #374151;
}

.nn-kit-badge--electric {
  background: #eef6ff;
  color: #1d4ed8;
}

.nn-student-year {
  display: inline-flex;
  align-items: center;
  color: var(--muted);
  font-size: 0.82em;
  white-space: nowrap;
}


/* =========================================================
   4) TEACHER DASHBOARD V2 WRAPPER
   ---------------------------------------------------------
   Refreshed dashboard layout.
   ========================================================= */

.nn-teacher-v2 {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 1440px;
  margin: 0 auto;
}


/* =========================================================
   5) DASHBOARD HERO
   ---------------------------------------------------------
   Welcome heading and teacher profile chip.
   ========================================================= */

.nn-teacher-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 4px 2px 0;
}

.nn-teacher-hero h1 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(1.65rem, 2vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.nn-teacher-hero p {
  margin: 8px 0 0;
  color: #64748b;
  font-size: 1.02rem;
}

.nn-teacher-hero__profile {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  min-width: 180px;
}

.nn-teacher-avatar,
.nn-student-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 12%, #fff);
  color: #087780;
  font-weight: 700;
}

.nn-teacher-avatar {
  width: 46px;
  height: 46px;
  background: linear-gradient(135deg, var(--accent), #10b7c0);
  color: #fff;
}

.nn-teacher-hero__profileText {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.nn-teacher-hero__profileText strong {
  color: #0f172a;
  font-weight: 700;
}

.nn-teacher-hero__profileText small {
  margin-top: 3px;
  color: #64748b;
}


/* =========================================================
   6) SHARED DASHBOARD CARDS
   ---------------------------------------------------------
   Used by schedule and quick actions cards.
   ========================================================= */

.nn-dashboard-card {
  border: 1px solid #e6edf2;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
}

.nn-dashboard-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 26px 14px;
}

.nn-dashboard-card__titlewrap {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.nn-dashboard-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  color: #087780;
  font-size: 1.35rem;
}

.nn-dashboard-card h2 {
  margin: 0;
  color: #0f172a;
  font-size: 1.18rem;
  font-weight: 800;
  letter-spacing: -0.015em;
}

.nn-dashboard-card p {
  margin: 3px 0 0;
  color: #64748b;
}


/* =========================================================
   7) SCHEDULE HEADER / DATE CONTROLS
   ---------------------------------------------------------
   Date arrows and schedule lesson button.
   ========================================================= */

.nn-dashboard-schedule {
  border: 2px solid var(--accent);
}

.nn-dashboard-schedule__head {
  background: #0F9FA8;
  color: #fff;
}

.nn-filter__form--dashboard {
  margin-left: auto;
}

.nn-dashboard-schedule__button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-color: color-mix(in srgb, var(--accent) 45%, #dbe7ef);
  background: #fff;
  color: #087780;
}

.nn-dashboard-schedule .nn-school-day-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 26px 16px;
  padding: 12px 14px;
  border: 1px solid #dbe7ef;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: none;
}

.nn-dashboard-schedule .nn-school-day-banner__main {
  display: grid;
  gap: 3px;
}

.nn-dashboard-schedule .nn-school-day-banner strong {
  color: #0f172a;
  font-weight: 900;
}

.nn-dashboard-schedule .nn-school-day-banner span,
.nn-dashboard-schedule .nn-school-day-banner__note {
  color: #64748b;
  font-size: 0.9rem;
}

.nn-dashboard-schedule .nn-school-day-banner.is-open {
  border-color: color-mix(in srgb, var(--accent) 35%, #dbe7ef);
  background: #f0fdfa;
}

.nn-dashboard-schedule .nn-school-day-banner.is-closed {
  border-color: #fecaca;
  background: #fff5f5;
}

.nn-dashboard-schedule .nn-school-day-banner.is-closed strong {
  color: #991b1b;
}

.nn-dashboard-schedule .nn-school-day-banner.is-out_of_term {
  border-color: #fde68a;
  background: #fffbeb;
}

.nn-dashboard-schedule .nn-school-day-banner.is-no_school {
  border-color: #e2e8f0;
  background: #f8fafc;
}

@media (max-width: 700px) {
  .nn-dashboard-schedule .nn-school-day-banner {
    display: grid;
    margin: 0 12px 12px;
    padding: 12px;
  }
}


/* =========================================================
   8) SCHEDULE TABLE
   ---------------------------------------------------------
   Main dashboard lesson table.
   ========================================================= */

.nn-dashboard-table-wrap {
  overflow-x: auto;
  padding: 0 26px 16px;
}

.nn-dashboard-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: auto;
}

.nn-dashboard-table th {
  padding: 14px 10px 12px;
  border-bottom: 1px solid #e6edf2;
  color: #475569;
  font-size: 0.84rem;
  font-weight: 800;
  text-align: left;
}

.nn-dashboard-table td {
  padding: 20px 10px;
  border-bottom: 1px solid #edf2f7;
  vertical-align: middle;
}

.nn-dashboard-table tbody tr:last-child td {
  border-bottom: 0;
}

.nn-dashboard-table tbody tr.is-now {
  background: rgba(15,159,168,.10);
  border-left: 5px solid var(--accent);
}

.nn-dashboard-table__time {
  width: 90px;
  color: #087780;
  font-size: 1rem;
  font-weight: 800;
  white-space: nowrap;
}

.nn-dashboard-table__student {
  display: table-cell;
  min-width: 0;
}

.nn-dashboard-table__student > .nn-student-avatar,
.nn-dashboard-table__student > .nn-dashboard-studentText {
  vertical-align: middle;
}

.nn-dashboard-table__student .nn-student-avatar {
  width: 46px;
  height: 46px;
  margin-right: 14px;
  font-size: 1.05rem;
}

.nn-student-avatar,
a.nn-student-avatar {
  color: #087780;
  text-decoration: none;
}

a.nn-student-avatar:hover,
a.nn-student-avatar:focus-visible {
  background: color-mix(in srgb, var(--accent) 18%, #ffffff);
  color: #075e66;
  text-decoration: none;
}

.nn-dashboard-studentText {
  display: inline-flex;
  flex-direction: column;
  gap: 3px;
  vertical-align: middle;
}

.nn-dashboard-studentText a,
.nn-dashboard-studentText strong {
  color: #0f172a;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
}

.nn-dashboard-studentText a:hover {
  color: #087780;
}

.nn-dashboard-studentText small {
  color: #64748b;
  font-size: 0.92rem;
  font-weight: 500;
}

.nn-dashboard-table__attendance {
  width: 150px;
}

.nn-dashboard-table__year,
.nn-dashboard-table__yearHead {
  width: 140px;
}

.nn-dashboard-table__year {
  color: #64748b;
  font-size: 0.88rem;
}

.nn-dashboard-table__practice,
.nn-dashboard-table__practiceHead {
  width: 56px;
  text-align: center;
}

.nn-dashboard-practice-indicator {
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #15803d;
  background: #f0fdf4;
  font-size: 0.9rem;
  text-decoration: none;
}

.nn-dashboard-practice-indicator:hover,
.nn-dashboard-practice-indicator:focus-visible {
  color: #166534;
  background: #dcfce7;
  text-decoration: none;
}

.nn-attendance-select-form {
  margin: 0;
}

.nn-attendance-select {
  width: auto;
  min-width: 116px;
  min-height: 30px;
  padding: 3px 28px 3px 10px;
  border: 1px solid #dbe7ef;
  border-radius: 8px;
  background-color: #fff;
  color: #0f172a;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 750;
  line-height: 1.2;
  cursor: pointer;
}

.nn-attendance-select.is-attended {
  border-color: #86efac;
  color: #166534;
}

.nn-attendance-select.is-missed {
  border-color: #fecaca;
  color: #b91c1c;
}

.nn-attendance-select.is-no-charge {
  border-color: #fde68a;
  color: #92400e;
}

.nn-attendance-select.is-saving {
  opacity: 0.6;
  cursor: wait;
}

.nn-dashboard-table__actions {
  width: 120px;
  text-align: right;
  white-space: nowrap;
}

.nn-dashboard-table__actionsHead {
  text-align: right;
}

.nn-dashboard-table__actions .nn-row-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  color: #475569;
  text-decoration: none;
}

.nn-row-icon__label {
  display: none;
}

.nn-dashboard-table__actions .nn-row-icon:hover {
  background: #f1f5f9;
  color: #087780;
}

.nn-dashboard-table__actions .nn-row-icon--danger:hover {
  color: #b91c1c;
}

.nn-dashboard-save-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0 26px 22px;
  color: #475569;
  font-size: 0.92rem;
}

.nn-dashboard-empty {
  padding: 24px 10px;
  color: #64748b;
}

.nn-dashboard-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.nn-dashboard-pagination a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid #dbe7ef;
  border-radius: 10px;
  background: #fff;
  color: #0f172a;
  font-weight: 700;
  text-decoration: none;
}

.nn-dashboard-pagination a.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}


/* =========================================================
   9) QUICK ACTIONS
   ---------------------------------------------------------
   Action grid underneath schedule table.
   ========================================================= */

.nn-dashboard-actions {
  padding-bottom: 26px;
}

.nn-quick-actions-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
  padding: 10px 26px 0;
}

.nn-quick-actions-grid a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 80px;
  border: 1px solid #dbe7ef;
  border-radius: 14px;
  background: #fff;
  color: #087780;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.nn-quick-actions-grid a:hover,
.nn-quick-actions-grid a:focus-visible {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent) 45%, #dbe7ef);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.nn-quick-actions-grid i {
  font-size: 1.7rem;
}


/* =========================================================
   10) QUICK SCHEDULE
   ---------------------------------------------------------
   Quick schedule helper at bottom of dashboard.
   ========================================================= */

.nn-quick-schedule {
  margin-top: var(--space-m);
}

.nn-dashboard-quick-schedule {
  margin-top: 0;
}

.nn-quick-schedule__head {
  margin-bottom: 12px;
}

.nn-quick-schedule__title {
  margin: 0 0 4px;
  font-size: 1.05rem;
}

.nn-quick-schedule__hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.nn-quick-schedule__hint code {
  padding: 2px 6px;
  border-radius: 6px;
  background: #f3f4f7;
  font-size: 0.9em;
}

.nn-quick-schedule__linkline {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.nn-quick-schedule__linkline a {
  font-weight: 600;
  text-decoration: none;
}

.nn-quick-schedule__linkline a:hover {
  text-decoration: underline;
}

.nn-quick-schedule__row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nn-quick-schedule__row input {
  flex: 1 1 auto;
  min-width: 0;
  height: 42px;
  padding: 0 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
}

.nn-quick-schedule__result {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fafafa;
}

.nn-quick-schedule__result.is-error {
  background: #fff6f5;
  border-color: #f1b5ae;
}

.nn-quick-schedule__result.is-success {
  background: #f6fffb;
  border-color: #b8e6d3;
}

.nn-qs-msg {
  color: #475467;
}

.nn-qs-preview {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.nn-qs-preview__main {
  display: grid;
  gap: 3px;
}

.nn-qs-preview__main strong {
  font-size: 0.98rem;
}

.nn-qs-preview__main span,
.nn-qs-preview__main small {
  color: var(--muted);
}

.nn-qs-preview__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.nn-qs-cancel {
  background: #eef2f4;
  border-color: #d9e1e5;
  color: #1f2937;
}

.nn-qs-cancel:hover {
  background: #e4eaee;
  border-color: #ccd6dc;
  color: #111827;
}

.nn-qs-matchlist {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.nn-qs-match {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border: 1px solid #d8dee6;
  border-radius: 10px;
  background: #fff;
  color: #111827;
  text-decoration: none;
}

.nn-qs-match:hover {
  background: #f7f8fa;
  text-decoration: none;
}

.nn-qs-match span,
.nn-qs-match small {
  color: var(--muted);
}


/* =========================================================
   11) TABLET / IPAD RESPONSIVE
   ========================================================= */

@media (min-width: 768px) and (max-width: 1180px) {
  .nn-filter__form--topbar {
    grid-template-columns: minmax(180px, 1fr) auto minmax(180px, 1fr);
    gap: 12px;
  }

  .nn-date-center--topbar {
    gap: 8px;
  }

  .nn-date-display-wrap {
    padding: 0 12px;
  }

  .nn-date-text {
    font-size: 15px;
  }
}

@media (max-width: 1180px) {
  .nn-dashboard-card__head,
  .nn-dashboard-schedule__head {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .nn-filter__form--dashboard {
    order: 3;
    width: 100%;
    margin-left: 0;
  }

  .nn-filter__form--dashboard .nn-date-center--topbar {
    justify-content: flex-start;
  }

  .nn-quick-actions-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}


/* =========================================================
   12) PHONE RESPONSIVE
   ---------------------------------------------------------
   Phone rules for the current V2 dashboard.
   ========================================================= */

@media (max-width: 700px) {
  .nn-teacher-v2 {
    gap: 18px;
  }

  .nn-teacher-hero {
    display: block;
    padding: 6px 2px 0;
  }

  .nn-teacher-hero__profile {
    display: none;
  }

  .nn-teacher-hero h1 {
    max-width: none;
    color: #0f172a;
    font-size: 1.65rem;
    line-height: 1.12;
    word-break: normal;
    overflow-wrap: normal;
  }

  .nn-teacher-hero p {
    max-width: none;
    color: #64748b;
    font-size: 0.96rem;
    line-height: 1.4;
  }

  .nn-dashboard-card {
    border-radius: 16px;
  }

  .nn-dashboard-card__head {
    padding: 16px;
  }

  .nn-dashboard-card__titlewrap {
    gap: 10px;
  }

  .nn-dashboard-card__icon {
    width: 36px;
    height: 36px;
    font-size: 1.1rem;
  }

  .nn-dashboard-card h2 {
    font-size: 1.05rem;
  }

  .nn-dashboard-card p {
    font-size: 0.88rem;
  }

  .nn-dashboard-schedule__button {
    min-height: 38px;
    padding-inline: 12px;
  }

  .nn-dashboard-schedule__button span {
    display: none;
  }

  .nn-filter__form--dashboard {
    display: block;
    width: 100%;
    order: 3;
  }

  .nn-filter__form--dashboard .nn-date-center--topbar {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) 38px;
    gap: 8px;
    width: 100%;
  }

  .nn-filter__form--dashboard .nn-date-arrow {
    width: 38px;
    height: 38px;
  }

  .nn-filter__form--dashboard .nn-date-display-wrap {
    min-width: 0;
    width: 100%;
    height: 38px;
    justify-content: center;
    padding: 0 10px;
  }

  .nn-filter__form--dashboard .nn-date-text {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .nn-filter__form--dashboard .nn-date-today {
    display: none;
  }

  .nn-dashboard-save-note {
    display: none;
  }

  .nn-quick-actions-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    padding: 4px 16px 18px;
  }

  .nn-quick-actions-grid a {
    min-height: 78px;
    gap: 6px;
    border-radius: 12px;
    font-size: 0.76rem;
  }

  .nn-quick-actions-grid i {
    font-size: 1.25rem;
  }

  .nn-dashboard-quick-schedule,
  .nn-quick-schedule {
    display: none;
  }

  .nn-quick-schedule__row {
    flex-direction: column;
    align-items: stretch;
  }

  .nn-quick-schedule__row .btn,
  .nn-qs-preview .btn,
  .nn-qs-preview__actions .btn {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .nn-qs-preview {
    align-items: stretch;
  }

  .nn-qs-preview__actions {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }
}


/* =========================================================
   15) DASHBOARD SCHEDULE POLISH
   ========================================================= */

.nn-dashboard-schedule {
  overflow: hidden;
  border: 2px solid #031A28;
  border-radius: 18px;
}

.nn-dashboard-schedule__head {
  border-bottom: 1px solid #e6edf2;
  background: #ffffff;
  color: #0f172a;
}

.nn-dashboard-schedule__head h2 {
  color: #0f172a;
}

.nn-dashboard-schedule__head p {
  color: #475569;
}

.nn-dashboard-schedule__head .nn-dashboard-card__icon {
  color: var(--accent);
}

.nn-dashboard-schedule .nn-date-text,
.nn-dashboard-schedule .nn-date-icon {
  color: #111827;
}

.nn-dashboard-schedule .nn-dashboard-schedule__button {
  border-color: color-mix(in srgb, var(--accent) 45%, #dbe7ef);
  background: #ffffff;
  color: #087780;
}

.nn-dashboard-table th {
  color: #334155;
  font-weight: 900;
}

/* =========================================================
   16) FINAL IPHONE LESSON ROWS
   ---------------------------------------------------------
   Single authoritative mobile lesson-row layout. Edit and
   delete are intentionally hidden on phones; View remains
   in-flow so controls cannot overflow the viewport.
   ========================================================= */

@media (max-width: 700px) {
  .nn-dashboard-table-wrap {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    padding: 0 12px 12px;
    box-sizing: border-box;
  }

  .nn-dashboard-table,
  .nn-dashboard-table tbody {
    display: block;
    width: 100%;
    max-width: 100%;
  }

  .nn-dashboard-table thead {
    display: none;
  }

  .nn-dashboard-table tbody tr {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr) 40px 52px;
    grid-template-areas:
      "time student student actions"
      "time year year actions"
      "time attendance practice actions";
    align-items: center;
    column-gap: 8px;
    row-gap: 4px;

    width: 100%;
    max-width: 100%;
    min-height: 0;
    margin: 0;
    padding: 10px 2px;

    border-bottom: 1px solid #e5eaf0;
    background: transparent;
    box-sizing: border-box;
  }

  .nn-dashboard-table tbody tr:last-child {
    border-bottom: 0;
  }

  .nn-dashboard-table tbody tr > td {
    display: block;
    width: auto;
    min-width: 0;
    height: auto;
    margin: 0;
    padding: 0;
    border: 0;
    box-sizing: border-box;
  }

  .nn-dashboard-table tbody tr > td:not(.nn-dashboard-table__time):not(.nn-dashboard-table__student):not(.nn-dashboard-table__year):not(.nn-dashboard-table__attendance):not(.nn-dashboard-table__practice):not(.nn-dashboard-table__actions) {
    display: none !important;
  }

  .nn-dashboard-table__time {
    grid-area: time;
    align-self: start;
    width: auto;
    padding-top: 1px;
    color: #334155;
    font-size: 0.93rem;
    font-weight: 800;
    line-height: 1.25;
    white-space: nowrap;
  }

  .nn-dashboard-table__student {
    grid-area: student;
    display: block;
    min-width: 0;
    padding: 0;
  }

  .nn-dashboard-table__student .nn-student-avatar {
    display: none;
  }

  .nn-dashboard-studentText {
    display: block;
    min-width: 0;
    margin: 0;
    padding: 0;
  }

  .nn-dashboard-studentText a,
  .nn-dashboard-studentText strong {
    display: block;
    max-width: 100%;
    margin: 0;
    overflow: hidden;
    color: #0f172a;
    font-size: 0.96rem;
    font-weight: 650;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .nn-dashboard-table__year {
    grid-area: year;
    width: auto;
    color: #64748b;
    font-size: 0.78rem;
    line-height: 1.25;
  }

  .nn-dashboard-table__attendance {
    grid-area: attendance;
    justify-self: start;
    width: auto;
    margin: 0;
  }

  .nn-attendance-select-form {
    margin: 0;
  }

  .nn-attendance-select {
    width: auto;
    min-width: 106px;
    min-height: 34px;
    margin: 0;
    padding: 2px 26px 2px 9px;
    border-radius: 8px;
    font-size: 0.77rem;
    line-height: 1;
  }

  .nn-dashboard-table__practice {
    grid-area: practice;
    align-self: center;
    justify-self: start;
    width: 36px;
    text-align: center;
  }

  .nn-dashboard-practice-indicator {
    width: 36px;
    height: 36px;
  }

  .nn-dashboard-table__actions {
    grid-area: actions;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    margin: 0;
    padding: 0;
    white-space: nowrap;
  }

  .nn-dashboard-table__actions .nn-row-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 34px;
    margin: 0;
    padding: 0;
    border-radius: 9px;
    box-sizing: border-box;
  }

  .nn-dashboard-table__actions .nn-row-icon--edit,
  .nn-dashboard-table__actions .nn-row-icon--delete {
    display: none !important;
  }

  .nn-dashboard-table__actions .nn-row-icon--view i {
    display: none;
  }

  .nn-dashboard-table__actions .nn-row-icon__label {
    display: inline;
    font-size: 0.75rem;
    font-weight: 750;
  }

  .nn-kit-badge,
  .nn-dashboard-save-note {
    display: none;
  }

  /* Preserve the empty-state row. */
  .nn-dashboard-table tbody tr:has(.nn-dashboard-empty) {
    display: block;
    padding: 0;
  }

  .nn-dashboard-table td.nn-dashboard-empty {
    display: block !important;
    width: auto;
    padding: 22px 14px;
    color: #64748b;
    line-height: 1.4;
    white-space: normal;
  }
}
