/* Gym Management System */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@600;700&display=swap');

body {
  min-height: 100vh;
}

header h1,
.gym-brand-title {
  font-family: 'Outfit', ui-sans-serif, system-ui, sans-serif !important;
  font-weight: 700;
  letter-spacing: -0.03em;
}

body.min-h-screen.flex.flex-col {
  height: 100vh;
  max-height: 100vh;
  overflow: hidden;
}

body.min-h-screen.flex.flex-col > header {
  flex-shrink: 0;
  z-index: 10;
}

body.min-h-screen.flex.flex-col > .flex.flex-1 {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

body.min-h-screen.flex.flex-col > .flex.flex-1 > nav.w-64 {
  flex-shrink: 0;
  height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
}

body.min-h-screen.flex.flex-col > .flex.flex-1 > main {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.gym-nav-link {
  display: flex;
  align-items: center;
}

.gym-nav-badge {
  margin-left: auto;
  min-width: 1.125rem;
  height: 1.125rem;
  padding: 0 0.35rem;
  border-radius: 9999px;
  background: #ef4444;
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 700;
  line-height: 1.125rem;
  text-align: center;
  flex-shrink: 0;
  box-shadow: 0 0 0 2px #fff;
}

a.bg-primary .gym-nav-badge {
  box-shadow: 0 0 0 2px #1e40af;
}

.gym-admin-invite {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid #e5e7eb;
}

.gym-admin-invite-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.625rem;
}

.gym-admin-invite-head i {
  color: #1e40af;
}

.gym-admin-invite-btn {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  background: #eff6ff;
  color: #1e40af;
  font-size: 0.8125rem;
  font-weight: 600;
  border: 1px solid #bfdbfe;
  transition: background 0.15s;
}

.gym-admin-invite-btn:hover {
  background: #dbeafe;
}

.gym-admin-invite-result {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  margin-top: 0.625rem;
}

.gym-admin-invite-result.hidden {
  display: none;
}

.gym-admin-invite-code {
  flex: 1;
  min-width: 0;
  padding: 0.375rem 0.5rem;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 0.375rem;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #0f172a;
}

.gym-admin-invite-copy {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.375rem;
  color: #64748b;
  border: 1px solid #e2e8f0;
  background: #fff;
}

.gym-admin-invite-copy:hover {
  color: #1e40af;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.gym-admin-invite-hint {
  margin-top: 0.5rem;
  font-size: 0.6875rem;
  line-height: 1.4;
  color: #94a3b8;
}

.gym-admin-invite-expiry {
  margin-top: 0.25rem;
  font-size: 0.6875rem;
  font-weight: 600;
  color: #059669;
}

.register-role-hint {
  padding: 0.625rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.8125rem;
  line-height: 1.45;
}

.register-role-hint.is-member {
  background: #f5f3ff;
  color: #5b21b6;
  border: 1px solid #ddd6fe;
}

.register-role-hint.is-trainer {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.trainer-setup-field-hint {
  font-size: 0.75rem;
  color: #94a3b8;
  margin-top: 0.25rem;
}

main {
  background-color: #f9fafb;
}

/* Schedule page tables */
.schedule-picker-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.875rem;
}

.schedule-picker-table thead th {
  background: #f8fafc;
  color: #475569;
  font-weight: 600;
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 2px solid #e2e8f0;
}

.schedule-picker-table tbody tr {
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.schedule-picker-table tbody tr:hover {
  background: #f1f5f9;
}

.schedule-picker-table tbody tr.is-selected {
  background: #eff6ff;
}

.schedule-picker-table tbody tr.is-selected td:first-child {
  box-shadow: inset 3px 0 0 #1e40af;
}

.schedule-picker-table tbody td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #e2e8f0;
  color: #334155;
  vertical-align: middle;
}

.schedule-grid-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 0.75rem;
}

.schedule-grid-table thead th {
  background: #dbeafe;
  color: #1e40af;
  font-weight: 600;
  text-align: left;
  padding: 0.625rem 0.5rem;
  border: 1px solid #bfdbfe;
}

.schedule-grid-table thead th:first-child {
  text-align: left;
  width: 6.5rem;
  background: #eff6ff;
  color: #334155;
}

.schedule-grid-table tbody td {
  border: 1px solid #e2e8f0;
  padding: 0.35rem 0.5rem;
  text-align: left;
  vertical-align: middle;
  height: auto;
}

.schedule-grid-table tbody td.schedule-time {
  background: #f8fafc;
  font-weight: 600;
  color: #1e40af;
  text-align: left;
  white-space: nowrap;
  vertical-align: middle;
  width: 6.5rem;
}

.schedule-grid-table tbody tr:nth-child(even) td:not(.schedule-time):not(.schedule-filled) {
  background: #fafafa;
}

.schedule-grid-table tbody td.schedule-empty {
  color: #cbd5e1;
  text-align: center;
  vertical-align: middle;
  padding: 0.25rem 0.5rem;
}

.schedule-grid-table tbody td.schedule-filled {
  background: #eff6ff;
  padding: 0.625rem 0.5rem;
  text-align: center;
  vertical-align: middle;
  min-height: 5.5rem;
}

.schedule-class-card {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  text-align: center;
  align-items: center;
  justify-content: center;
}

.schedule-class-name {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #1e3a8a;
  line-height: 1.3;
  margin-bottom: 0.125rem;
  text-align: center;
}

.schedule-class-meta {
  font-size: 0.6875rem;
  color: #475569;
  line-height: 1.35;
  text-align: center;
}

/* Notifications page */
.notif-compose-card {
  border: 1px solid #e2e8f0;
}

.notif-compose-textarea {
  resize: vertical;
  min-height: 7rem;
  border-color: #e2e8f0;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.notif-compose-textarea:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.notif-compose-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-top: 1rem;
  margin-top: 1rem;
  border-top: 1px solid #f1f5f9;
}

.notif-compose-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.notif-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: 1px solid transparent;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}

.notif-btn-primary {
  background: #1e40af;
  color: #fff;
}

.notif-btn-primary:hover {
  background: #1e3a8a;
}

.notif-btn-secondary {
  background: #fff;
  color: #1e40af;
  border-color: #bfdbfe;
}

.notif-btn-secondary:hover {
  background: #eff6ff;
  border-color: #93c5fd;
}

.notif-btn-ghost {
  background: transparent;
  color: #64748b;
  border-color: #e2e8f0;
}

.notif-btn-ghost:hover {
  background: #f8fafc;
  color: #334155;
}

.notif-btn-danger {
  background: #fff;
  color: #dc2626;
  border-color: #fecaca;
}

.notif-btn-danger:hover {
  background: #fef2f2;
}

.notif-btn-icon {
  padding: 0.5rem;
  min-width: 2.25rem;
}

.notif-item {
  border: 1px solid #e2e8f0;
  transition: box-shadow 0.15s ease;
}

.notif-item:hover {
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

.notif-item-actions {
  display: flex;
  gap: 0.25rem;
  opacity: 0.85;
}

.notif-recipient-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  color: #64748b;
  margin-top: 0.35rem;
}

.notif-role-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1.25rem 1rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
  background: #fff;
  transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.notif-role-card:hover {
  border-color: #93c5fd;
  background: #f8fafc;
  box-shadow: 0 2px 8px rgba(30, 64, 175, 0.08);
}

.notif-role-card i {
  font-size: 1.5rem;
  color: #1e40af;
}

.notif-recipient-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 0.75rem;
  border: 1px solid #f1f5f9;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.notif-recipient-row:hover {
  background: #f8fafc;
  border-color: #e2e8f0;
}

.notif-recipient-row input[type='checkbox'] {
  width: 1rem;
  height: 1rem;
  accent-color: #1e40af;
}

.notif-updated-label {
  font-size: 0.75rem;
  color: #94a3b8;
  margin-top: 0.125rem;
}

.notif-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: #94a3b8;
  font-size: 0.875rem;
}

/* Trainers page */
.trainers-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
  gap: 1rem;
}

.trainers-stat-card {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 1rem 1.125rem;
  background: #fff;
  border: 1px solid #f1f5f9;
  border-radius: 0.75rem;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.trainers-stat-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.625rem;
  font-size: 1rem;
  flex-shrink: 0;
}

.trainers-stat-icon.is-blue { background: #dbeafe; color: #1e40af; }
.trainers-stat-icon.is-green { background: #dcfce7; color: #16a34a; }
.trainers-stat-icon.is-slate { background: #e2e8f0; color: #475569; }
.trainers-stat-icon.is-teal { background: #ccfbf1; color: #0f766e; }
.trainers-stat-icon.is-indigo { background: #e0e7ff; color: #4338ca; }

.trainers-stat-label {
  font-size: 0.75rem;
  color: #64748b;
  margin: 0;
}

.trainers-stat-value {
  font-size: 1.375rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0.125rem 0 0;
  line-height: 1.2;
}

.trainers-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.trainer-filter-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.trainer-filter-btn {
  padding: 0.45rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #475569;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.trainer-filter-btn:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.trainer-filter-btn.is-active {
  background: #1e40af;
  border-color: #1e40af;
  color: #fff;
}

.trainers-search-input {
  width: 100%;
  max-width: 22rem;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
}

.trainers-search-input:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.trainer-card {
  background: #fff;
  padding: 1.25rem 1.375rem 1.375rem;
  border-radius: 0.75rem;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
  border: 1px solid #f1f5f9;
}

.trainer-card-hidden {
  opacity: 0.72;
  background: #f8fafc;
  border-style: dashed;
  border-color: #cbd5e1;
}

.trainer-hidden-badge {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #64748b;
  background: #e2e8f0;
  padding: 0.2rem 0.5rem;
  border-radius: 9999px;
  flex-shrink: 0;
}

.trainer-card-head {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
}

.trainer-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 9999px;
  background: linear-gradient(135deg, #dbeafe, #eff6ff);
  color: #1e40af;
  font-size: 0.875rem;
  font-weight: 700;
  flex-shrink: 0;
}

.trainer-card-head-text {
  flex: 1;
  min-width: 0;
}

.trainer-card-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.trainer-card-name {
  font-size: 1.0625rem;
  font-weight: 600;
  color: #0f172a;
  margin: 0;
}

.trainer-card-specialties {
  font-size: 0.875rem;
  color: #64748b;
  margin: 0.25rem 0 0;
}

.trainer-linked-account {
  font-size: 0.75rem;
  color: #94a3b8;
  margin: 0.35rem 0 0;
}

.trainer-linked-account code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.6875rem;
  color: #475569;
  background: #f1f5f9;
  padding: 0.1rem 0.35rem;
  border-radius: 0.25rem;
}

.trainer-onsite-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.6875rem;
  font-weight: 600;
  color: #047857;
  background: #ecfdf5;
  padding: 0.15rem 0.5rem;
  border-radius: 9999px;
}

.trainer-onsite-dot {
  width: 0.4375rem;
  height: 0.4375rem;
  border-radius: 9999px;
  background: #10b981;
}

.trainer-card-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  margin-top: 1rem;
  font-size: 0.8125rem;
  color: #64748b;
}

.trainer-card-stats strong {
  color: #0f172a;
  font-weight: 600;
}

.trainer-class-preview {
  list-style: none;
  margin: 0.875rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.trainer-class-preview li {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.5rem 0.625rem;
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  border-radius: 0.5rem;
}

.trainer-class-name {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #334155;
}

.trainer-class-schedule {
  font-size: 0.75rem;
  color: #64748b;
}

.trainer-card-orphan {
  border: 1px dashed #fbbf24;
  background: #fffbeb;
}

.trainer-orphan-badge {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #b45309;
  background: #fef3c7;
  padding: 0.15rem 0.5rem;
  border-radius: 9999px;
}

.trainer-card-meta {
  margin-top: 0.375rem;
  font-size: 0.75rem;
  color: #64748b;
}

.trainer-card-bio {
  margin-top: 0.375rem;
  font-size: 0.8125rem;
  line-height: 1.45;
  color: #64748b;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.trainer-card-meta.trainer-card-empty {
  margin-top: 0.875rem;
  font-size: 0.8125rem;
  color: #94a3b8;
}

.trainer-pending-badge {
  display: inline-block;
  margin-top: 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #b45309;
  background: #fef3c7;
  padding: 0.25rem 0.625rem;
  border-radius: 9999px;
  text-decoration: none;
}

.trainer-pending-badge:hover {
  background: #fde68a;
}

.trainer-card-links {
  margin-top: 0.875rem;
}

.trainer-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #1e40af;
  text-decoration: none;
}

.trainer-link-btn:hover {
  color: #1e3a8a;
  text-decoration: underline;
}

.trainer-hidden-note {
  margin: 0.75rem 0 0;
  font-size: 0.75rem;
  line-height: 1.45;
  color: #64748b;
}

.trainer-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #f1f5f9;
}

.trainer-action-btn {
  padding: 0.45rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: 1px solid transparent;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.trainer-action-secondary {
  background: #fff;
  color: #475569;
  border-color: #e2e8f0;
}

.trainer-action-secondary:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.trainer-action-danger {
  background: #fff;
  color: #dc2626;
  border-color: #fecaca;
}

.trainer-action-danger:hover {
  background: #fef2f2;
}

/* Dashboard layout */
.dashboard-page {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.dashboard-page-header {
  margin-bottom: 0.25rem;
}

.dashboard-stat-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.dashboard-stat-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 6.25rem;
  padding: 1.25rem;
  background: #fff;
  border: 1px solid #f1f5f9;
  border-radius: 0.875rem;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.dashboard-stat-icon {
  width: 3rem;
  height: 3rem;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.625rem;
  font-size: 1.125rem;
}

.dashboard-stat-icon.is-blue {
  background: #dbeafe;
  color: #1e40af;
}

.dashboard-stat-icon.is-green {
  background: #dcfce7;
  color: #15803d;
}

.dashboard-stat-icon.is-yellow {
  background: #fef9c3;
  color: #a16207;
}

.dashboard-stat-content {
  min-width: 0;
  flex: 1;
}

.dashboard-stat-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #64748b;
}

.dashboard-stat-value {
  font-size: 1.75rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.2;
  margin-top: 0.125rem;
}

.dashboard-stat-hint {
  font-size: 0.75rem;
  color: #94a3b8;
  margin-top: 0.125rem;
  min-height: 1rem;
}

.dashboard-two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  align-items: stretch;
}

.dashboard-panel {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #f1f5f9;
  border-radius: 0.875rem;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
  overflow: hidden;
}

.dashboard-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  min-height: 3.75rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #f1f5f9;
}

.dashboard-panel-title {
  font-size: 1.0625rem;
  font-weight: 600;
  color: #0f172a;
  margin: 0;
}

.dashboard-panel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dashboard-panel-body {
  padding: 1.25rem 1.5rem 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.dashboard-subheading {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  margin: 0 0 0.75rem;
}

.dashboard-subheading-inline {
  margin-bottom: 0;
}

.dashboard-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
}

.dashboard-action-btn.is-primary {
  background: #1e40af;
  color: #fff;
}

.dashboard-action-btn.is-primary:hover {
  background: #1e3a8a;
}

.dashboard-action-btn.is-secondary {
  background: #64748b;
  color: #fff;
}

.dashboard-action-btn.is-secondary:hover {
  background: #475569;
}

.dashboard-action-btn.is-danger {
  background: #dc2626;
  color: #fff;
}

.dashboard-action-btn.is-danger:hover {
  background: #b91c1c;
}

.dashboard-split-body {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  flex: 1;
}

.dashboard-split-col {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.dashboard-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid #f1f5f9;
  border-radius: 0.625rem;
  overflow: hidden;
  flex: 1;
}

.dashboard-list-item {
  padding: 0.875rem 1rem;
  border-bottom: 1px solid #f1f5f9;
}

.dashboard-list-item:last-child {
  border-bottom: none;
}

.dashboard-list-item-title {
  font-size: 0.875rem;
  font-weight: 500;
  color: #1e293b;
}

.dashboard-list-item-meta {
  font-size: 0.75rem;
  color: #94a3b8;
  margin-top: 0.125rem;
}

.dashboard-notify-body {
  gap: 1rem;
}

.dashboard-compose {
  width: 100%;
  padding: 0.75rem;
  font-size: 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.625rem;
  resize: vertical;
  min-height: 5.5rem;
}

.dashboard-compose:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.dashboard-compose-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dashboard-notify-list-wrap {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.dashboard-notify-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: 16rem;
  overflow-y: auto;
}

.dashboard-attendance-body {
  gap: 1.5rem;
}

.dashboard-attendance-summary {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.dashboard-attendance-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.75rem;
}

.dashboard-metric-card {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  padding: 0.875rem 1rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.625rem;
  min-height: 4.5rem;
}

.dashboard-metric-card.is-peak {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.dashboard-metric-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: #64748b;
}

.dashboard-metric-value {
  font-size: 1.375rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.2;
}

.dashboard-metric-value-sm {
  font-size: 0.9375rem;
  font-weight: 600;
}

.dashboard-charts-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  align-items: stretch;
}

.dashboard-chart-panel {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  padding: 1rem 1.125rem 1.125rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
}

.dashboard-chart-panel .dashboard-subheading {
  margin-bottom: 0.875rem;
}

.dashboard-chart-controls {
  margin-bottom: 0.875rem;
}

.dashboard-filter-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.dashboard-filter-btns-flush {
  margin-top: 0;
}

.dashboard-trend-apply-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.dashboard-date-range {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  flex: 1;
  min-width: 0;
}

.dashboard-trend-apply-btn {
  flex-shrink: 0;
  align-self: flex-end;
  margin-top: 4px;
}

.dashboard-filter-note {
  font-size: 0.75rem;
  color: #94a3b8;
  margin: 0.625rem 0 0;
  min-height: 1rem;
}

.dashboard-chart-box {
  height: 14rem;
  min-height: 14rem;
  padding: 0.5rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 0.625rem;
  flex: 1;
}

.dashboard-chart-canvas {
  width: 100%;
  height: 100%;
}

.dashboard-timer-section {
  padding-top: 0.25rem;
  border-top: 1px solid #f1f5f9;
}

@media (max-width: 1024px) {
  .dashboard-two-col,
  .dashboard-charts-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-attendance-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-metric-card.is-peak {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .dashboard-stat-grid,
  .dashboard-split-body {
    grid-template-columns: 1fr;
  }

  .dashboard-attendance-metrics {
    grid-template-columns: 1fr;
  }

  .dashboard-trend-apply-row {
    flex-direction: column;
    align-items: stretch;
  }

  .dashboard-trend-apply-btn {
    align-self: flex-end;
    width: auto;
  }
}

/* Dashboard attendance */
.attendance-category {
  padding: 1rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
}

.attendance-category-title {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #1e40af;
  margin-bottom: 0.75rem;
}

.attendance-stat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.35rem 0;
}

.attendance-stat-row + .attendance-stat-row {
  border-top: 1px solid #e2e8f0;
  margin-top: 0.25rem;
  padding-top: 0.5rem;
}

.attendance-stat-label {
  font-size: 0.875rem;
  color: #64748b;
}

.attendance-stat-value {
  font-size: 1.125rem;
  font-weight: 700;
  color: #0f172a;
}

.attendance-peak-row {
  padding: 0.875rem 1rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
}

.attendance-filters {
  padding: 0.75rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
}

.attendance-filter-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: #64748b;
  margin-bottom: 0.35rem;
}

.attendance-filter-input {
  width: 100%;
  padding: 0.5rem 0.625rem;
  font-size: 0.8125rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  background: #fff;
  color: #0f172a;
}

.attendance-filter-input:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.attendance-filter-btn {
  padding: 0.45rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: 1px solid #e2e8f0;
  background: #fff;
  color: #475569;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.attendance-filter-btn:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.attendance-filter-btn.is-active {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1e40af;
}

.attendance-filter-btn-primary {
  background: #1e40af;
  border-color: #1e40af;
  color: #fff;
}

.attendance-filter-btn-primary:hover {
  background: #1e3a8a;
  border-color: #1e3a8a;
}

.attendance-chart-block + .attendance-chart-block {
  padding-top: 0;
  border-top: none;
}

/* Check In / Out page */
.checkin-panel {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
  padding: 1.25rem;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.checkin-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #f1f5f9;
}

.checkin-count-badge {
  font-size: 0.75rem;
  font-weight: 600;
  color: #1e40af;
  background: #eff6ff;
  padding: 0.25rem 0.625rem;
  border-radius: 9999px;
}

.checkin-search-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: #64748b;
  margin-bottom: 0.35rem;
}

.checkin-search-input {
  width: 100%;
  padding: 0.625rem 0.75rem;
  font-size: 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
}

.checkin-search-input:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.checkin-subheading {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  margin-bottom: 0.5rem;
}

.checkin-active-list,
.checkin-people-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.checkin-active-list {
  margin-bottom: 0.25rem;
}

.checkin-active-item,
.checkin-person-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem;
  border: 1px solid #f1f5f9;
  border-radius: 0.5rem;
  margin-bottom: 0.5rem;
}

.checkin-active-item {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.checkin-person-item.is-in-gym {
  background: #f8fafc;
}

.checkin-btn {
  padding: 0.4rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: 1px solid transparent;
  white-space: nowrap;
  flex-shrink: 0;
}

.checkin-btn-in {
  background: #1e40af;
  color: #fff;
}

.checkin-btn-in:hover {
  background: #1e3a8a;
}

.checkin-btn-out {
  background: #fff;
  color: #dc2626;
  border-color: #fecaca;
}

.checkin-btn-out:hover {
  background: #fef2f2;
}

.checkin-status {
  font-size: 0.75rem;
  color: #94a3b8;
}

.checkin-status-in {
  color: #1e40af;
  font-weight: 500;
}

.checkin-empty {
  font-size: 0.875rem;
  color: #94a3b8;
  padding: 0.75rem;
  text-align: center;
  border: 1px dashed #e2e8f0;
  border-radius: 0.5rem;
}

.checkin-search-results {
  margin-top: 0.5rem;
}

.checkin-search-results[hidden] {
  display: none;
}

.checkin-view-more-wrap {
  margin-top: 0.25rem;
  text-align: center;
}

.checkin-view-more {
  font-size: 0.8125rem;
  font-weight: 500;
  color: #1e40af;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.375rem 0.75rem;
  border-radius: 0.375rem;
}

.checkin-view-more:hover {
  background: #eff6ff;
  text-decoration: underline;
}

.checkin-log-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.checkin-log-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid #f1f5f9;
}

.checkin-log-item:last-child {
  border-bottom: none;
}

.checkin-log-icon {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  font-size: 0.75rem;
}

.checkin-log-item.is-active .checkin-log-icon {
  background: #dcfce7;
  color: #15803d;
}

.checkin-log-item.is-completed .checkin-log-icon {
  background: #eff6ff;
  color: #1e40af;
}

.checkin-log-body {
  flex: 1;
  min-width: 0;
}

.checkin-log-title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.375rem;
}

.checkin-log-role {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  background: #f1f5f9;
  padding: 0.125rem 0.375rem;
  border-radius: 0.25rem;
}

.checkin-log-times {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem 0.75rem;
  font-size: 0.8125rem;
  color: #64748b;
  margin-top: 0.25rem;
}

.checkin-log-time-row {
  display: inline-flex;
  align-items: baseline;
  gap: 0.375rem;
}

.checkin-log-time-label {
  font-weight: 600;
  color: #475569;
}

.checkin-log-status {
  font-weight: 500;
  color: #15803d;
}

.checkin-log-duration {
  font-weight: 500;
  color: #1e40af;
}

.checkin-log-duration::before {
  content: '·';
  margin-right: 0.375rem;
  color: #cbd5e1;
}

/* Class details modal */
.class-modal-panel {
  animation: classModalIn 0.18s ease-out;
}

@keyframes classModalIn {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.class-modal-section + .class-modal-section {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid #f1f5f9;
}

.class-modal-subheading {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  margin-bottom: 0.75rem;
}

.class-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem 1rem;
}

.class-detail-row {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.class-detail-label {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
}

.class-detail-value {
  font-size: 0.875rem;
  color: #1e293b;
}

.class-modal-description {
  margin-top: 0.875rem;
}

.class-modal-description p {
  margin-top: 0.375rem;
  font-size: 0.875rem;
  color: #475569;
  line-height: 1.5;
}

.class-assigned-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 9rem;
  overflow-y: auto;
}

.class-assigned-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.5rem 0.75rem;
  border: 1px solid #f1f5f9;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  color: #334155;
  margin-bottom: 0.375rem;
  background: #f8fafc;
}

.class-assigned-name {
  min-width: 0;
  flex: 1;
}

.class-unassign-btn {
  flex-shrink: 0;
  font-size: 0.75rem;
  font-weight: 500;
  color: #dc2626;
  background: #fef2f2;
  border: none;
  border-radius: 0.375rem;
  padding: 0.25rem 0.625rem;
  cursor: pointer;
}

.class-unassign-btn:hover {
  background: #fee2e2;
}

.class-assigned-empty {
  font-size: 0.875rem;
  color: #94a3b8;
  padding: 0.75rem;
  text-align: center;
  border: 1px dashed #e2e8f0;
  border-radius: 0.5rem;
}

.class-assign-row {
  display: flex;
  gap: 0.5rem;
}

.class-assign-select {
  flex: 1;
  min-width: 0;
  padding: 0.625rem 0.75rem;
  font-size: 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  background: #fff;
}

.class-assign-select:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.class-assign-btn {
  flex-shrink: 0;
  padding: 0.625rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #fff;
  background: #1e40af;
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
}

.class-assign-btn:hover:not(:disabled) {
  background: #1e3a8a;
}

.class-assign-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.class-modal-actions {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid #f1f5f9;
}

.class-modal-edit-btn {
  font-size: 0.875rem;
  font-weight: 500;
  color: #475569;
  background: #f1f5f9;
  border: none;
  border-radius: 0.5rem;
  padding: 0.625rem 1rem;
  cursor: pointer;
}

.class-modal-edit-btn:hover {
  background: #e2e8f0;
}

.class-modal-form {
  display: flex;
  flex-direction: column;
}

.class-modal-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.875rem 1rem;
}

.class-modal-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.class-modal-field-full {
  grid-column: 1 / -1;
}

.class-modal-input {
  width: 100%;
  padding: 0.625rem 0.75rem;
  font-size: 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  color: #1e293b;
  background: #fff;
}

.class-modal-input:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.english-date-picker {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
}

.english-date-picker select {
  flex: 1 1 7rem;
  min-width: 0;
}

.english-date-picker .english-date-year {
  flex: 0 1 5.5rem;
  min-width: 4.5rem;
}

.class-modal-textarea {
  resize: vertical;
  min-height: 4.5rem;
}

.class-modal-actions-split {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.class-modal-actions-main {
  display: flex;
  gap: 0.5rem;
  margin-left: auto;
}

.class-modal-save-btn {
  font-size: 0.875rem;
  font-weight: 500;
  color: #fff;
  background: #1e40af;
  border: none;
  border-radius: 0.5rem;
  padding: 0.625rem 1rem;
  cursor: pointer;
}

.class-modal-save-btn:hover {
  background: #1e3a8a;
}

.class-modal-cancel-btn {
  font-size: 0.875rem;
  font-weight: 500;
  color: #475569;
  background: #f1f5f9;
  border: none;
  border-radius: 0.5rem;
  padding: 0.625rem 1rem;
  cursor: pointer;
}

.class-modal-cancel-btn:hover {
  background: #e2e8f0;
}

.class-modal-delete-btn {
  font-size: 0.875rem;
  font-weight: 500;
  color: #dc2626;
  background: #fef2f2;
  border: none;
  border-radius: 0.5rem;
  padding: 0.625rem 1rem;
  cursor: pointer;
}

.class-modal-delete-btn:hover {
  background: #fee2e2;
}

/* App dialog (confirm / alert) */
.gym-dialog-panel {
  background: #fff;
  border-radius: 0.875rem;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.18);
  width: 100%;
  max-width: 22rem;
  padding: 1.5rem;
  text-align: center;
  animation: classModalIn 0.18s ease-out;
  border-top: 4px solid #e2e8f0;
}

.gym-dialog-panel.is-success {
  border-top-color: #15803d;
}

.gym-dialog-panel.is-error {
  border-top-color: #dc2626;
}

.gym-dialog-panel.is-warning {
  border-top-color: #b45309;
}

.gym-dialog-panel.is-info {
  border-top-color: #1e40af;
}

.gym-dialog-icon {
  width: 3rem;
  height: 3rem;
  margin: 0 auto 1rem;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
}

.gym-dialog-icon.is-info {
  background: #eff6ff;
  color: #1e40af;
}

.gym-dialog-icon.is-success {
  background: #dcfce7;
  color: #15803d;
}

.gym-dialog-icon.is-error {
  background: #fee2e2;
  color: #dc2626;
}

.gym-dialog-icon.is-warning {
  background: #fef3c7;
  color: #b45309;
}

.gym-dialog-title {
  font-size: 1.0625rem;
  font-weight: 600;
  color: #0f172a;
  margin: 0 0 0.5rem;
}

.gym-dialog-message {
  font-size: 0.875rem;
  color: #64748b;
  line-height: 1.5;
  margin: 0 0 1.25rem;
}

.gym-dialog-actions {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
}

.gym-dialog-btn {
  flex: 1;
  max-width: 9rem;
  padding: 0.625rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
}

.gym-dialog-btn-cancel {
  color: #475569;
  background: #f1f5f9;
}

.gym-dialog-btn-cancel:hover {
  background: #e2e8f0;
}

.gym-dialog-btn-confirm {
  color: #fff;
  background: #1e40af;
}

.gym-dialog-btn-confirm:hover {
  background: #1e3a8a;
}

.gym-dialog-btn-confirm.is-success {
  background: #15803d;
}

.gym-dialog-btn-confirm.is-success:hover {
  background: #166534;
}

.gym-dialog-btn-confirm.is-error {
  background: #dc2626;
}

.gym-dialog-btn-confirm.is-error:hover {
  background: #b91c1c;
}

.gym-dialog-input-wrap {
  margin-bottom: 1rem;
}

.gym-dialog-textarea {
  width: 100%;
  padding: 0.625rem 0.75rem;
  border: 1px solid #cbd5e1;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  resize: vertical;
  min-height: 4.5rem;
}

.gym-dialog-textarea:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

/* Course selection & gym booking */
.course-select-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.course-select-tab {
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #475569;
  background: #f1f5f9;
  border: 1px solid transparent;
}

.course-select-tab.is-active {
  background: #3b82f6;
  color: #fff;
}

.course-status-badge {
  display: inline-block;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.course-status-badge.is-enrolled {
  background: #dcfce7;
  color: #166534;
}

.course-status-badge.is-pending {
  background: #fef3c7;
  color: #92400e;
}

.course-status-badge.is-available {
  background: #dbeafe;
  color: #1e40af;
}

.course-status-badge.is-full {
  background: #f1f5f9;
  color: #64748b;
}

.gym-slot-cell {
  cursor: pointer;
  transition: background 0.15s;
}

.schedule-grid-table tbody td.gym-slot-cell.is-available {
  color: #64748b;
  font-size: 0.75rem;
  font-weight: 600;
}

.gym-slot-cell.is-available:hover {
  background: #e0f2fe !important;
}

.gym-slot-cell.is-pending {
  background: #fef3c7 !important;
  color: #92400e;
  font-size: 0.75rem;
  font-weight: 600;
}

.gym-slot-cell.is-approved {
  background: #86efac !important;
  color: #166534;
  font-size: 0.75rem;
  font-weight: 600;
}

.gym-slot-cell.is-full {
  background: #e2e8f0 !important;
  color: #64748b;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: not-allowed;
}

.gym-slot-cell.is-blocked {
  background: #cbd5e1 !important;
  color: #475569;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: not-allowed;
}

.admin-gym-day-head.is-blocked {
  background: #e2e8f0 !important;
}

.admin-gym-day-toggle {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  width: 100%;
  padding: 0.25rem 0.15rem;
  border: none;
  background: transparent;
  cursor: pointer;
  font: inherit;
  color: inherit;
  border-radius: 0.375rem;
  transition: background-color 0.15s ease;
}

.admin-gym-day-toggle:hover {
  background: rgba(30, 64, 175, 0.08);
}

.admin-gym-day-head.is-blocked .admin-gym-day-toggle:hover {
  background: rgba(15, 23, 42, 0.06);
}

.admin-gym-day-status {
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #64748b;
}

.admin-gym-day-head.is-blocked .admin-gym-day-status {
  color: #b45309;
}

.admin-gym-heat-cell.is-day-blocked {
  background: #e2e8f0 !important;
  color: #94a3b8 !important;
}

.admin-gym-legend-swatch.is-blocked-day {
  background: #e2e8f0;
  color: #64748b;
}

.admin-gym-capacity-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  margin-bottom: 1rem;
  padding: 0.875rem 1rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.625rem;
}

.admin-gym-capacity-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #334155;
}

.admin-gym-capacity-input {
  width: 4.5rem;
  padding: 0.4rem 0.625rem;
  font-size: 0.875rem;
  border: 1px solid #cbd5e1;
  border-radius: 0.5rem;
}

.admin-gym-capacity-input:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.admin-gym-capacity-hint {
  flex: 1 1 100%;
  margin: 0;
  font-size: 0.75rem;
  color: #64748b;
}

.admin-gym-visit-table .admin-gym-heat-cell {
  text-align: center;
  font-size: 0.75rem;
  min-width: 3.25rem;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.admin-gym-heat-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  margin-top: 0.875rem;
  font-size: 0.75rem;
  color: #64748b;
}

.admin-gym-legend-label {
  font-weight: 600;
  color: #475569;
}

.admin-gym-legend-swatch {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 0.375rem;
  font-weight: 600;
}

.admin-gym-legend-swatch.is-low {
  background: hsl(142, 72%, 94%);
  color: #334155;
}

.admin-gym-legend-swatch.is-high {
  background: hsl(20, 72%, 66%);
  color: #fff;
}

.admin-gym-legend-swatch.is-full {
  background: #fecaca;
  color: #991b1b;
}

.admin-gym-legend-arrow {
  color: #94a3b8;
}

.dashboard-admin-gym-section {
  margin-bottom: 1.5rem;
}

.dashboard-admin-only.hidden {
  display: none !important;
}

.schedule-grid-table tbody td.schedule-gym-visit {
  background: #ecfdf5;
}

.schedule-grid-table tbody td.schedule-gym-visit .schedule-class-name {
  color: #047857;
}

.request-card {
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
  padding: 1rem 1.25rem;
  background: #fff;
}

.request-card-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.request-approve-btn {
  background: #16a34a;
  color: #fff;
  padding: 0.375rem 0.875rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
}

.request-reject-btn {
  background: #fff;
  color: #dc2626;
  border: 1px solid #fecaca;
  padding: 0.375rem 0.875rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
}

.pref-chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.pref-chip {
  cursor: pointer;
}

.pref-chip-label {
  display: inline-block;
  padding: 0.375rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.8125rem;
  font-weight: 500;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #475569;
  transition: all 0.15s;
}

.pref-chip.is-selected .pref-chip-label,
.pref-chip-input:checked + .pref-chip-label {
  background: #3b82f6;
  border-color: #3b82f6;
  color: #fff;
}

.pref-radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.pref-radio {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.875rem;
  color: #475569;
  cursor: pointer;
}

.dashboard-member-section {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.dashboard-member-top {
  margin-bottom: 0;
}

.dashboard-member-prefs .dashboard-panel-body {
  padding-top: 1rem;
  padding-bottom: 1.25rem;
}

.prefs-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem 1.5rem;
}

@media (max-width: 768px) {
  .prefs-summary-grid {
    grid-template-columns: 1fr;
  }
}

.dashboard-member-ai .dashboard-panel-header {
  align-items: flex-start;
}

.dashboard-ai-header-text {
  min-width: 0;
}

.dashboard-ai-subtitle {
  font-size: 0.8125rem;
  color: #64748b;
  margin: 0.25rem 0 0;
  line-height: 1.4;
}

.dashboard-ai-body {
  padding-top: 1rem;
}

.ai-rec-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

@media (min-width: 1280px) {
  .ai-rec-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .ai-rec-grid {
    grid-template-columns: 1fr;
  }
}

.ai-rec-card {
  display: flex;
  flex-direction: column;
  min-height: 11.5rem;
  padding: 1rem 1.125rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
  background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
  transition: border-color 0.15s, box-shadow 0.15s;
}

a.ai-rec-card-link,
button.ai-rec-card-link {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  width: 100%;
  text-align: left;
  font: inherit;
}

a.ai-rec-card-link:hover,
button.ai-rec-card-link:hover {
  text-decoration: none;
}

.ai-rec-card:hover {
  border-color: #bfdbfe;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.08);
}

.ai-rec-card-body {
  flex: 1;
  min-width: 0;
}

.ai-rec-card-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #0f172a;
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ai-rec-card-meta {
  font-size: 0.75rem;
  color: #64748b;
  margin: 0.375rem 0 0;
  line-height: 1.35;
}

.ai-rec-card-reason {
  font-size: 0.8125rem;
  color: #475569;
  margin: 0.625rem 0 0;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ai-rec-card-btn {
  display: block;
  margin-top: 0.875rem;
  padding: 0.5rem 0.75rem;
  text-align: center;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #fff;
  background: #3b82f6;
  border-radius: 0.5rem;
  transition: background 0.15s;
}

a.ai-rec-card-link:hover .ai-rec-card-btn,
button.ai-rec-card-link:hover .ai-rec-card-btn {
  background: #2563eb;
}

.ai-rec-card-btn:hover {
  background: #2563eb;
  text-decoration: none;
}

.ai-rec-empty,
.ai-rec-loading {
  text-align: center;
  font-size: 0.875rem;
  color: #64748b;
  padding: 2rem 1rem;
}

.ai-rec-batch-hint {
  font-size: 0.75rem;
  color: #94a3b8;
  text-align: center;
  margin-top: 0.75rem;
}

.member-schedule-cols {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
}

@media (max-width: 768px) {
  .member-schedule-cols {
    grid-template-columns: 1fr;
  }
}

.member-schedule-list {
  margin-top: 0.5rem;
}

.member-schedule-empty {
  font-size: 0.8125rem;
  color: #64748b;
  margin-top: 0.5rem;
}

.member-gym-status {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.125rem 0.375rem;
  border-radius: 0.25rem;
  margin-left: 0.375rem;
}

.member-gym-status.is-approved {
  color: #15803d;
  background: #dcfce7;
}

.member-gym-status.is-pending {
  color: #b45309;
  background: #fef3c7;
}

.dashboard-member-gym-time .dashboard-gym-time-chart-box {
  position: relative;
  flex: none;
  flex-shrink: 0;
  height: 16rem;
  min-height: 16rem;
}

.dashboard-member-gym-time #memberGymTimeChart {
  width: 100%;
  height: 15rem;
  min-height: 15rem;
}

.member-gym-time-empty {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1.25rem;
  font-size: 0.875rem;
  line-height: 1.5;
  color: #64748b;
  background: #f8fafc;
  border-radius: 0.5rem;
}

.member-gym-time-empty.hidden {
  display: none;
}

.gym-booking-note {
  font-size: 0.75rem;
  color: #64748b;
  line-height: 1.45;
}

.schedule-grid-table .gym-col-day {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #1e40af;
}

.schedule-grid-table .gym-col-date {
  display: block;
  font-size: 0.6875rem;
  font-weight: 500;
  color: #64748b;
  margin-top: 0.125rem;
}

.prefs-summary-label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  margin-bottom: 0.125rem;
}

.prefs-summary-value {
  font-size: 0.875rem;
  color: #334155;
}

.ai-rec-item {
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #f1f5f9;
}

.ai-rec-reason {
  font-size: 0.8125rem;
  color: #64748b;
  margin-top: 0.25rem;
  line-height: 1.4;
}

.ai-rec-link {
  display: inline-block;
  margin-top: 0.375rem;
  font-size: 0.8125rem;
  color: #3b82f6;
  font-weight: 500;
}

.ai-rec-link:hover {
  text-decoration: underline;
}

/* Admin activity log */
.admin-log-toolbar {
  display: grid;
  grid-template-columns: 1fr 14rem;
  gap: 1rem;
  align-items: end;
  padding-top: 0.25rem;
  padding-bottom: 0.25rem;
}

.admin-log-search-row {
  position: relative;
}

.admin-log-search-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 0.875rem;
  pointer-events: none;
}

.admin-log-search-input {
  width: 100%;
  padding: 0.625rem 0.75rem 0.625rem 2.25rem;
  font-size: 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  background: #fff;
}

.admin-log-search-input:focus {
  outline: none;
  border-color: #1e40af;
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.admin-log-filter-select {
  width: 100%;
  padding: 0.625rem 0.75rem;
  font-size: 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  background: #fff;
  color: #1e293b;
}

.admin-log-count {
  font-size: 0.8125rem;
  font-weight: 500;
  color: #64748b;
  background: #f1f5f9;
  padding: 0.25rem 0.625rem;
  border-radius: 9999px;
}

.admin-log-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 36rem;
  overflow-y: auto;
}

.admin-log-item {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #f1f5f9;
}

.admin-log-item:last-child {
  border-bottom: none;
}

.admin-log-icon {
  flex-shrink: 0;
  width: 2.25rem;
  height: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  background: #eff6ff;
  color: #1e40af;
  font-size: 0.875rem;
}

.admin-log-body {
  flex: 1;
  min-width: 0;
}

.admin-log-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.375rem 0.625rem;
  margin-bottom: 0.25rem;
}

.admin-log-action {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #1e40af;
  background: #eff6ff;
  padding: 0.125rem 0.5rem;
  border-radius: 0.25rem;
}

.admin-log-actor {
  font-size: 0.75rem;
  color: #64748b;
}

.admin-log-summary {
  font-size: 0.875rem;
  color: #334155;
  margin: 0;
  line-height: 1.45;
}

.admin-log-time {
  flex-shrink: 0;
  font-size: 0.75rem;
  color: #94a3b8;
  white-space: nowrap;
}

.admin-log-empty {
  padding: 2rem 1.5rem;
  text-align: center;
  font-size: 0.875rem;
  color: #94a3b8;
}

@media (max-width: 640px) {
  .admin-log-toolbar {
    grid-template-columns: 1fr;
  }

  .admin-log-item {
    flex-wrap: wrap;
  }

  .admin-log-time {
    width: 100%;
    padding-left: 3.125rem;
  }
}

/* Responsive application shell */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  max-width: 100%;
}

body {
  overflow-x: hidden;
}

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

main,
main * {
  min-width: 0;
}

main .overflow-x-auto {
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-inline: contain;
}

main .overflow-x-auto > table {
  width: 100%;
}

.schedule-grid-table {
  min-width: 48rem;
}

.admin-gym-visit-table {
  min-width: 54rem;
}

.schedule-picker-table {
  min-width: 34rem;
}

main .overflow-x-auto > table.w-full:not(.schedule-grid-table):not(.schedule-picker-table) {
  min-width: 42rem;
}

@media (max-width: 900px) {
  body.min-h-screen.flex.flex-col {
    height: auto;
    max-height: none;
    min-height: 100vh;
    min-height: 100svh;
    overflow-x: hidden;
    overflow-y: auto;
  }

  body.min-h-screen.flex.flex-col > header {
    position: relative;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.875rem 1rem !important;
  }

  body.min-h-screen.flex.flex-col > header > .flex:first-child {
    flex: 1 1 12rem;
    min-width: 0;
  }

  body.min-h-screen.flex.flex-col > header > .flex:last-child {
    flex: 1 1 100%;
    justify-content: space-between;
    gap: 0.75rem;
    min-width: 0;
  }

  body.min-h-screen.flex.flex-col > header .space-x-4 > :not([hidden]) ~ :not([hidden]) {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  body.min-h-screen.flex.flex-col > header h1 {
    font-size: 1.125rem;
    line-height: 1.25;
  }

  [data-user-label] {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body.min-h-screen.flex.flex-col > .flex.flex-1 {
    flex-direction: column;
    min-height: auto;
    overflow: visible;
  }

  body.min-h-screen.flex.flex-col > .flex.flex-1 > nav.w-64 {
    width: 100% !important;
    height: auto;
    padding: 0.75rem 1rem !important;
    overflow: visible;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    box-shadow: none;
  }

  body.min-h-screen.flex.flex-col > .flex.flex-1 > nav.w-64 [data-gym-nav] {
    display: flex;
    flex: 0 0 auto;
    gap: 0.5rem;
    margin: 0;
    padding: 0 0 0.25rem;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
  }

  body.min-h-screen.flex.flex-col > .flex.flex-1 > nav.w-64 [data-gym-nav] > :not([hidden]) ~ :not([hidden]) {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
  }

  body.min-h-screen.flex.flex-col > .flex.flex-1 > nav.w-64 [data-gym-nav] > li {
    flex: 0 0 auto;
    scroll-snap-align: start;
  }

  .gym-nav-link {
    min-height: 2.5rem;
    padding: 0.55rem 0.8rem !important;
    white-space: nowrap;
  }

  .gym-admin-invite {
    margin-top: 0.75rem;
    padding: 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.625rem;
    background: #f8fafc;
  }

  body.min-h-screen.flex.flex-col > .flex.flex-1 > main {
    min-height: auto;
    overflow: visible;
    padding: 1rem !important;
  }

  main > [class*='max-w-'],
  main .dashboard-page {
    width: 100%;
  }

  .dashboard-page {
    gap: 1rem;
  }

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

  .dashboard-attendance-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-metric-card.is-peak {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  body.min-h-screen.flex.flex-col > header {
    padding: 0.75rem !important;
  }

  body.min-h-screen.flex.flex-col > header h1,
  main h2.text-2xl {
    font-size: 1.25rem !important;
    line-height: 1.3;
  }

  body.min-h-screen.flex.flex-col > header > .flex:last-child {
    align-items: stretch;
  }

  body.min-h-screen.flex.flex-col > header .whitespace-nowrap,
  main .whitespace-nowrap {
    white-space: normal !important;
  }

  body.min-h-screen.flex.flex-col > header button {
    min-height: 2.5rem;
    padding-left: 0.875rem !important;
    padding-right: 0.875rem !important;
  }

  body.min-h-screen.flex.flex-col > .flex.flex-1 > nav.w-64 {
    padding: 0.625rem 0.75rem !important;
  }

  body.min-h-screen.flex.flex-col > .flex.flex-1 > main {
    padding: 0.875rem !important;
  }

  main .p-6 {
    padding: 1rem !important;
  }

  main .px-6 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }

  main .py-4 {
    padding-top: 0.875rem !important;
    padding-bottom: 0.875rem !important;
  }

  main .mb-6 {
    margin-bottom: 1rem !important;
  }

  main .gap-6 {
    gap: 1rem !important;
  }

  .dashboard-panel-header,
  .dashboard-panel-body {
    padding: 1rem;
  }

  .dashboard-panel-header {
    align-items: flex-start;
  }

  .dashboard-panel-actions,
  .dashboard-compose-actions,
  .notif-compose-actions,
  .trainer-card-actions,
  .request-card-actions,
  .class-modal-actions-main,
  .dashboard-filter-btns {
    width: 100%;
  }

  .dashboard-panel-actions,
  .dashboard-compose-actions,
  .notif-compose-actions,
  .trainer-card-actions,
  .request-card-actions,
  .class-modal-actions-main {
    display: grid;
    grid-template-columns: 1fr;
  }

  .dashboard-filter-btns,
  .trainer-filter-btns,
  .course-select-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 0.125rem;
    -webkit-overflow-scrolling: touch;
  }

  .dashboard-action-btn,
  .notif-btn,
  .trainer-action-btn,
  .request-approve-btn,
  .request-reject-btn,
  .class-modal-save-btn,
  .class-modal-cancel-btn,
  .class-modal-delete-btn,
  .class-modal-edit-btn,
  .class-assign-btn,
  .attendance-filter-btn {
    min-height: 2.5rem;
    white-space: normal;
    text-align: center;
  }

  .dashboard-panel-actions .dashboard-action-btn,
  .dashboard-compose-actions .dashboard-action-btn,
  .notif-compose-actions .notif-btn,
  .trainer-card-actions .trainer-action-btn,
  .request-card-actions button,
  .class-modal-actions-main button,
  .class-modal-delete-btn,
  .class-assign-btn {
    width: 100%;
  }

  .dashboard-stat-grid,
  .dashboard-attendance-metrics,
  .dashboard-two-col,
  .dashboard-split-body,
  .dashboard-charts-grid,
  .member-schedule-cols,
  .ai-rec-grid,
  .prefs-summary-grid,
  .class-detail-grid,
  .class-modal-fields {
    grid-template-columns: 1fr;
  }

  .dashboard-stat-card {
    min-height: auto;
    padding: 1rem;
  }

  .dashboard-stat-icon {
    width: 2.625rem;
    height: 2.625rem;
  }

  .dashboard-stat-value {
    font-size: 1.5rem;
  }

  .dashboard-date-range,
  .admin-log-toolbar {
    grid-template-columns: 1fr;
  }

  .dashboard-trend-apply-row {
    flex-direction: column;
    align-items: stretch;
  }

  .dashboard-trend-apply-btn {
    width: 100%;
    align-self: stretch;
  }

  .dashboard-chart-box {
    height: 12rem;
    min-height: 12rem;
  }

  .dashboard-member-gym-time .dashboard-gym-time-chart-box {
    height: 13rem;
    min-height: 13rem;
  }

  .dashboard-member-gym-time #memberGymTimeChart {
    height: 12rem;
    min-height: 12rem;
  }

  .trainers-stat-grid {
    grid-template-columns: 1fr;
  }

  .trainers-toolbar {
    align-items: stretch;
  }

  .trainers-search-input {
    max-width: none;
  }

  .trainer-card {
    padding: 1rem;
  }

  .trainer-card-head {
    flex-wrap: wrap;
  }

  .trainer-avatar {
    width: 2.625rem;
    height: 2.625rem;
  }

  .trainer-hidden-badge,
  .trainer-orphan-badge,
  .trainer-onsite-badge {
    max-width: 100%;
    white-space: normal;
  }

  .notif-compose-toolbar {
    align-items: stretch;
  }

  .notif-item > .flex {
    flex-direction: column;
  }

  .notif-item-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr;
  }

  #notificationList > .notif-item .flex.justify-end {
    justify-content: stretch;
    flex-direction: column;
  }

  .notif-role-card {
    padding: 1rem;
  }

  #recipientRoleStep .grid {
    grid-template-columns: 1fr;
  }

  .request-card {
    padding: 1rem;
  }

  .request-card > .flex {
    flex-direction: column;
  }

  #memberList > li {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.125rem;
  }

  .checkin-panel {
    padding: 1rem;
  }

  .checkin-panel-header,
  .checkin-active-item,
  .checkin-person-item {
    align-items: flex-start;
  }

  .checkin-active-item,
  .checkin-person-item {
    flex-direction: column;
  }

  .checkin-btn {
    width: 100%;
    min-height: 2.5rem;
  }

  .checkin-log-item {
    gap: 0.625rem;
  }

  .checkin-log-times,
  .checkin-log-time-row {
    align-items: flex-start;
  }

  .checkin-log-time-row {
    flex-direction: column;
    gap: 0.125rem;
  }

  .checkin-log-duration::before {
    content: none;
  }

  .admin-log-item {
    padding: 1rem;
  }

  .admin-log-time {
    padding-left: 0;
  }

  .class-assign-row,
  .class-modal-actions-split {
    flex-direction: column;
    align-items: stretch;
  }

  .class-modal-actions-main {
    margin-left: 0;
  }

  .class-assigned-item {
    align-items: flex-start;
    flex-direction: column;
  }

  .class-unassign-btn {
    width: 100%;
    min-height: 2.25rem;
  }

  .english-date-picker {
    display: grid;
    grid-template-columns: 1fr;
  }

  .english-date-picker select,
  .english-date-picker .english-date-year {
    width: 100%;
    min-width: 0;
  }

  .pref-chip-label {
    padding: 0.5rem 0.75rem;
  }

  .pref-radio-group {
    flex-direction: column;
  }

  #timerPopup,
  #courseDetailsModal,
  #classDetailsModal,
  #recipientModal,
  .gym-dialog {
    align-items: flex-start !important;
    overflow-y: auto;
    padding: 0.75rem !important;
  }

  #timerPopup > div,
  #courseDetailsModal > div,
  #recipientModal > div,
  .class-modal-panel,
  .gym-dialog-panel {
    width: 100% !important;
    max-width: 100% !important;
    max-height: calc(100svh - 1.5rem) !important;
  }

  #timerPopup > div,
  #courseDetailsModal > div,
  #recipientModal > div,
  .gym-dialog-panel {
    margin: auto 0;
    overflow-y: auto;
  }

  #courseModalBody,
  #classModalBody,
  #recipientCheckboxes {
    padding: 1rem !important;
  }

  .gym-dialog-actions {
    flex-direction: column;
  }

  .gym-dialog-btn {
    max-width: none;
    width: 100%;
  }
}

@media (max-width: 420px) {
  body.min-h-screen.flex.flex-col > header > .flex:last-child {
    flex-direction: column;
  }

  [data-user-label] {
    width: 100%;
  }

  body.min-h-screen.flex.flex-col > header button {
    width: 100%;
  }

  .dashboard-stat-card,
  .trainers-stat-card {
    align-items: flex-start;
  }

  .admin-gym-capacity-row {
    align-items: stretch;
  }

  .admin-gym-capacity-input,
  #saveGymVisitCapacityBtn {
    width: 100%;
  }
}
