:root {
  --ink: #18211d;
  --muted: #5e6a61;
  --paper: #f7f4ec;
  --surface: #fffdf8;
  --sage: #53685d;
  --sage-2: #d7e0d7;
  --clay: #b56345;
  --clay-dark: #7f3f31;
  --gold: #c79b43;
  --blue: #263f58;
  --line: rgba(24, 33, 29, 0.14);
  --shadow: 0 18px 50px rgba(24, 33, 29, 0.12);
  --radius: 8px;
  --header-height: 76px;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: var(--ink);
  background: var(--paper);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(83, 104, 93, 0.12), rgba(247, 244, 236, 0) 420px),
    var(--paper);
  color: var(--ink);
}

body.modal-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

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

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(199, 155, 67, 0.76);
  outline-offset: 3px;
}

.skip-link {
  background: var(--blue);
  color: white;
  left: 16px;
  padding: 10px 14px;
  position: fixed;
  top: -80px;
  z-index: 1000;
}

.skip-link:focus {
  top: 16px;
}

.site-header {
  align-items: center;
  background: rgba(247, 244, 236, 0.88);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(24, 33, 29, 0.1);
  display: grid;
  gap: 20px;
  grid-template-columns: auto 1fr auto;
  left: 0;
  min-height: var(--header-height);
  padding: 12px clamp(18px, 4vw, 56px);
  position: sticky;
  right: 0;
  top: 0;
  z-index: 100;
}

.brand {
  align-items: center;
  display: inline-flex;
  gap: 12px;
  min-height: 44px;
  min-width: 0;
}

.brand-mark {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0) 42%),
    conic-gradient(from 220deg, var(--clay), var(--gold), var(--sage), var(--blue), var(--clay));
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.45);
  display: inline-block;
  flex: 0 0 auto;
  height: 36px;
  width: 36px;
}

.brand strong {
  display: block;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.05rem;
  letter-spacing: 0;
  line-height: 1.05;
}

.brand small {
  color: var(--muted);
  display: block;
  font-size: 0.78rem;
  line-height: 1.1;
  text-transform: lowercase;
}

.main-nav {
  align-items: center;
  display: flex;
  gap: clamp(12px, 2.2vw, 28px);
  justify-content: center;
}

.main-nav a {
  color: var(--muted);
  font-size: 0.92rem;
  min-height: 44px;
  align-items: center;
  display: inline-flex;
  transition:
    color 180ms ease,
    transform 180ms ease;
}

.main-nav a:hover {
  color: var(--ink);
  transform: translateY(-1px);
}

.header-actions,
.hero-actions,
.form-actions,
.slot-header,
.split-heading {
  align-items: center;
  display: flex;
  gap: 12px;
}

.header-actions {
  justify-content: flex-end;
}

.primary-button,
.secondary-button,
.ghost-button,
.icon-button {
  align-items: center;
  border: 1px solid transparent;
  border-radius: var(--radius);
  display: inline-flex;
  font-weight: 700;
  gap: 8px;
  justify-content: center;
  min-height: 44px;
  padding: 11px 16px;
  transition:
    background 180ms ease,
    border-color 180ms ease,
    color 180ms ease,
    transform 180ms ease,
    box-shadow 180ms ease;
  white-space: nowrap;
}

.primary-button svg,
.secondary-button svg,
.ghost-button svg,
.icon-button svg {
  height: 18px;
  stroke-width: 2;
  width: 18px;
}

.primary-button {
  background: var(--clay);
  box-shadow: 0 10px 28px rgba(127, 63, 49, 0.22);
  color: white;
}

.primary-button:hover {
  background: var(--clay-dark);
  transform: translateY(-1px);
}

.secondary-button {
  background: rgba(255, 253, 248, 0.92);
  color: var(--ink);
}

.secondary-button:hover,
.ghost-button:hover,
.icon-button:hover {
  background: var(--surface);
  border-color: rgba(24, 33, 29, 0.2);
  transform: translateY(-1px);
}

.ghost-button,
.icon-button {
  background: rgba(255, 253, 248, 0.5);
  border-color: rgba(24, 33, 29, 0.12);
  color: var(--ink);
}

.icon-button {
  padding: 11px;
  width: 44px;
}

.nav-toggle {
  display: none;
  justify-self: end;
}

.hero {
  color: white;
  display: grid;
  min-height: calc(100dvh - var(--header-height));
  overflow: clip;
  place-items: end start;
  position: relative;
}

.hero-media,
.hero-overlay {
  inset: 0;
  position: absolute;
}

.hero-media {
  background:
    url("https://images.unsplash.com/photo-1739172064113-0e8c54fe9d6c?auto=format&fit=crop&fm=jpg&q=76&w=1800")
      center / cover no-repeat;
  transform: scale(1.01);
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(18, 26, 24, 0.9) 0%, rgba(18, 26, 24, 0.62) 43%, rgba(18, 26, 24, 0.14) 100%),
    linear-gradient(0deg, rgba(18, 26, 24, 0.52), rgba(18, 26, 24, 0.05) 44%);
}

.hero-content {
  max-width: 760px;
  padding: clamp(68px, 12vw, 140px) clamp(18px, 5vw, 76px) 128px;
  position: relative;
  z-index: 1;
}

.eyebrow {
  color: var(--clay);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  margin: 0 0 14px;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #f4c86d;
}

.hero h1,
.section-heading h2,
.booking-copy h2,
.teacher-section h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: 0;
}

.hero h1 {
  font-size: clamp(3.1rem, 8vw, 7.8rem);
  line-height: 0.93;
  margin: 0;
  max-width: 850px;
}

.hero-content p:not(.eyebrow) {
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(1rem, 1.5vw, 1.18rem);
  line-height: 1.7;
  max-width: 650px;
}

.hero-actions {
  flex-wrap: wrap;
  margin-top: 30px;
}

.hero-status {
  align-items: stretch;
  background: rgba(247, 244, 236, 0.92);
  bottom: 0;
  color: var(--ink);
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  left: 0;
  position: absolute;
  right: 0;
  z-index: 1;
}

.hero-status span {
  background: rgba(255, 253, 248, 0.7);
  min-height: 64px;
  padding: 20px clamp(16px, 3vw, 32px);
}

.intro-band {
  background: var(--ink);
  color: white;
}

.intro-grid {
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 auto;
  max-width: 1440px;
}

.intro-grid article {
  background: rgba(255, 255, 255, 0.045);
  min-height: 220px;
  padding: clamp(26px, 4vw, 52px);
}

.intro-grid span {
  color: #f0c069;
  display: block;
  font-weight: 800;
  margin-bottom: 38px;
}

.intro-grid h2,
.offering-item h3,
.teacher-card h3,
.admin-card h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.35rem, 2vw, 2rem);
  font-weight: 500;
  margin: 0 0 12px;
}

.intro-grid p {
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.7;
  margin: 0;
  max-width: 430px;
}

.section,
.teacher-section,
.booking-section {
  padding: clamp(72px, 10vw, 132px) clamp(18px, 5vw, 76px);
}

.section-heading {
  margin: 0 auto 42px;
  max-width: 1040px;
}

.section-heading h2,
.booking-copy h2,
.teacher-section h2 {
  font-size: clamp(2.2rem, 5vw, 4.8rem);
  line-height: 1;
  margin: 0;
}

.section-heading p:not(.eyebrow),
.booking-copy p {
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.75;
  max-width: 720px;
}

.split-heading {
  justify-content: space-between;
  max-width: 1180px;
}

.split-heading h2 {
  max-width: 820px;
}

.offering-list {
  display: grid;
  gap: 18px;
  margin: 0 auto;
  max-width: 1180px;
}

.offering-item {
  align-items: stretch;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  grid-template-columns: minmax(220px, 0.85fr) minmax(0, 1.3fr);
  min-height: 280px;
  overflow: hidden;
}

.offering-item img {
  height: 100%;
  min-height: 260px;
  object-fit: cover;
  width: 100%;
}

.offering-item div {
  align-self: center;
  padding: clamp(24px, 4vw, 56px);
}

.offering-item p {
  color: var(--muted);
  line-height: 1.7;
  max-width: 620px;
}

.offering-item a {
  color: var(--clay-dark);
  display: inline-flex;
  font-weight: 800;
  margin-top: 10px;
  min-height: 44px;
  align-items: center;
}

.course-section {
  background: #ecefe7;
}

.course-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 auto 26px;
  max-width: 1180px;
}

.filter-pill {
  background: rgba(255, 253, 248, 0.72);
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: 999px;
  color: var(--muted);
  min-height: 44px;
  padding: 9px 16px;
}

.filter-pill.active,
.filter-pill:hover {
  background: var(--ink);
  color: white;
}

.course-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 auto;
  max-width: 1180px;
}

.course-card,
.booking-panel,
.admin-card,
.teacher-card,
.auth-modal {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 18px 44px rgba(24, 33, 29, 0.08);
}

.course-card {
  display: flex;
  flex-direction: column;
  min-height: 360px;
  overflow: hidden;
}

.course-card .course-image {
  background: var(--sage-2);
  height: 166px;
  overflow: hidden;
}

.course-card img {
  height: 100%;
  object-fit: cover;
  transition: transform 300ms ease;
  width: 100%;
}

.course-card:hover img {
  transform: scale(1.035);
}

.course-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 16px;
  padding: 22px;
}

.course-card h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.55rem;
  font-weight: 500;
  line-height: 1.1;
  margin: 0;
}

.course-meta {
  align-items: center;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  font-size: 0.92rem;
  gap: 8px 12px;
}

.course-meta span {
  align-items: center;
  display: inline-flex;
  gap: 6px;
}

.course-card p {
  color: var(--muted);
  line-height: 1.65;
  margin: 0;
}

.course-card-footer {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-top: auto;
}

.price {
  color: var(--clay-dark);
  font-size: 1.15rem;
  font-weight: 800;
}

.booking-section {
  align-items: start;
  background: var(--blue);
  color: white;
  display: grid;
  gap: clamp(30px, 6vw, 82px);
  grid-template-columns: minmax(0, 0.9fr) minmax(420px, 1fr);
}

.booking-copy {
  position: sticky;
  top: calc(var(--header-height) + 34px);
}

.booking-copy .eyebrow {
  color: #f4c86d;
}

.booking-copy p {
  color: rgba(255, 255, 255, 0.78);
}

.booking-note {
  align-items: flex-start;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius);
  color: rgba(255, 255, 255, 0.84);
  display: flex;
  gap: 10px;
  line-height: 1.55;
  margin-top: 28px;
  padding: 16px;
}

.booking-note svg {
  flex: 0 0 auto;
  height: 20px;
  margin-top: 2px;
  width: 20px;
}

.booking-panel {
  color: var(--ink);
  padding: clamp(20px, 4vw, 34px);
}

.stepper {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 28px;
}

.step {
  background: #ecefe7;
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 800;
  min-height: 42px;
  padding: 11px 12px;
  text-align: center;
}

.step.active {
  background: var(--ink);
  color: white;
}

.booking-form label,
.admin-card label,
.auth-form label {
  color: var(--ink);
  display: block;
  font-size: 0.9rem;
  font-weight: 800;
  margin: 16px 0 8px;
}

input,
select,
textarea {
  background: white;
  border: 1px solid rgba(24, 33, 29, 0.18);
  border-radius: var(--radius);
  color: var(--ink);
  min-height: 46px;
  padding: 12px 13px;
  width: 100%;
}

textarea {
  line-height: 1.55;
  resize: vertical;
}

.form-step,
.payment-detail {
  display: none;
}

.form-step.active,
.payment-detail.active {
  display: block;
}

.form-next {
  margin-top: 20px;
  width: 100%;
}

.checkout-contact {
  background: #f5f7f1;
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: var(--radius);
  margin-bottom: 20px;
  padding: 18px;
}

.checkout-contact h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.45rem;
  font-weight: 500;
  margin: 0 0 6px;
}

.checkout-contact p {
  color: var(--muted);
  line-height: 1.55;
  margin: 0 0 10px;
}

.slot-header {
  align-items: end;
  justify-content: space-between;
}

.slot-header > div {
  flex: 1;
}

.slot-months {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  margin: 12px 0 4px;
}

.slot-month-chip {
  background: #f5f7f1;
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: 8px;
  color: var(--muted);
  display: grid;
  gap: 3px;
  min-height: 58px;
  padding: 9px 11px;
  text-align: left;
}

.slot-month-chip span {
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 800;
  line-height: 1.2;
}

.slot-month-chip small {
  color: inherit;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1.2;
}

.slot-month-chip.has-slots {
  background: var(--ink);
  border-color: var(--ink);
  color: rgba(255, 255, 255, 0.78);
}

.slot-month-chip.has-slots span {
  color: white;
}

.slot-month-chip.is-empty {
  opacity: 0.56;
}

.slot-month-chip.active {
  box-shadow: 0 0 0 3px rgba(34, 113, 209, 0.22);
  outline: 2px solid #2271d1;
  outline-offset: 2px;
}

.slot-list {
  display: grid;
  gap: 10px;
  margin: 16px 0 22px;
  max-height: 360px;
  overflow: auto;
  padding-right: 4px;
}

.booking-form .slot-option {
  align-items: center;
  background: #f5f7f1;
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: var(--radius);
  display: flex;
  gap: 12px;
  min-height: 74px;
  padding: 12px;
}

.booking-form .slot-option input {
  flex: 0 0 auto;
  height: 20px;
  min-height: 20px;
  width: 20px;
}

.booking-form .slot-option > span:not(.slot-capacity) {
  flex: 1 1 auto;
  min-width: 0;
}

.booking-form .slot-option strong {
  display: block;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.booking-form .slot-option small {
  color: var(--muted);
  display: block;
  line-height: 1.35;
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.slot-capacity {
  align-self: center;
  background: white;
  border-radius: 999px;
  color: var(--sage);
  font-size: 0.8rem;
  font-weight: 800;
  justify-self: end;
  padding: 7px 10px;
  white-space: nowrap;
}

.payment-methods {
  border: 0;
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  margin: 0 0 20px;
  padding: 0;
}

.payment-methods legend {
  font-size: 0.9rem;
  font-weight: 800;
  margin: 0 0 10px;
}

.payment-methods label {
  margin: 0;
}

.payment-methods input {
  clip: rect(0 0 0 0);
  height: 1px;
  overflow: hidden;
  position: absolute;
  width: 1px;
}

.payment-methods span {
  align-items: center;
  background: #f5f7f1;
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  font-size: 0.92rem;
  font-weight: 800;
  gap: 8px;
  justify-content: center;
  min-height: 90px;
  padding: 12px;
  text-align: center;
}

.payment-methods svg {
  height: 24px;
  width: 24px;
}

.payment-methods input:checked + span {
  background: var(--ink);
  border-color: var(--ink);
  color: white;
}

.form-row {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-row.compact {
  grid-template-columns: minmax(0, 0.55fr) minmax(0, 0.45fr);
}

.payment-detail {
  margin-bottom: 22px;
}

.qr-payment,
.bank-payment,
.offline-payment,
.empty-state,
.payment-summary {
  background: #f5f7f1;
  border: 1px dashed rgba(24, 33, 29, 0.24);
  border-radius: var(--radius);
  color: var(--muted);
  line-height: 1.6;
  padding: 18px;
}

.qr-payment img,
.qr-preview img {
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: var(--radius);
  max-height: 210px;
  object-fit: contain;
  width: min(210px, 100%);
}

.qr-payment strong,
.bank-payment strong,
.offline-payment strong {
  color: var(--ink);
  display: block;
  margin-bottom: 8px;
}

.account-section {
  background: var(--paper);
}

.booking-list,
.admin-bookings {
  display: grid;
  gap: 12px;
  margin: 0 auto;
  max-width: 1180px;
}

.calendar-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 18px 44px rgba(24, 33, 29, 0.08);
  margin: 24px auto 0;
  max-width: 1180px;
  padding: clamp(18px, 3vw, 28px);
}

.schedule-card {
  grid-column: 1 / -1;
}

.calendar-toolbar {
  align-items: end;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  margin-bottom: 18px;
}

.calendar-toolbar h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.35rem, 2vw, 2rem);
  font-weight: 500;
  margin: 0 0 6px;
}

.calendar-toolbar p {
  color: var(--muted);
  line-height: 1.55;
  margin: 0;
}

.calendar-toolbar label {
  color: var(--ink);
  display: grid;
  flex: 0 0 min(230px, 100%);
  font-size: 0.86rem;
  font-weight: 800;
  gap: 8px;
  margin: 0;
}

.course-calendar {
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  overflow: hidden;
}

.calendar-weekday,
.calendar-day {
  background: #f5f7f1;
}

.calendar-weekday {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  min-height: 38px;
  padding: 12px 8px;
  text-align: center;
  text-transform: uppercase;
}

.calendar-day {
  min-height: 118px;
  padding: 9px;
}

.calendar-day.outside {
  background: rgba(245, 247, 241, 0.42);
  color: rgba(94, 106, 97, 0.58);
}

.calendar-date {
  color: var(--muted);
  display: block;
  font-size: 0.8rem;
  font-weight: 900;
  margin-bottom: 7px;
}

.calendar-event {
  background: white;
  border-left: 3px solid var(--clay);
  border-radius: 6px;
  color: var(--ink);
  display: block;
  font-size: 0.78rem;
  line-height: 1.3;
  margin-top: 6px;
  overflow-wrap: anywhere;
  padding: 7px 8px;
}

.calendar-event strong {
  color: var(--clay-dark);
  display: block;
  font-size: 0.76rem;
  margin-bottom: 2px;
}

.calendar-more {
  color: var(--muted);
  display: block;
  font-size: 0.74rem;
  font-weight: 800;
  margin-top: 6px;
}

.calendar-empty {
  background: #f5f7f1;
  border: 1px dashed rgba(24, 33, 29, 0.24);
  border-radius: var(--radius);
  color: var(--muted);
  grid-column: 1 / -1;
  line-height: 1.6;
  padding: 18px;
}

.agenda-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.agenda-item {
  align-items: center;
  background: #f5f7f1;
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: var(--radius);
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr auto;
  padding: 14px;
}

.agenda-item strong {
  display: block;
}

.agenda-item span {
  color: var(--muted);
  display: block;
  margin-top: 4px;
}

.booking-record,
.admin-booking-record {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr auto;
  padding: 18px;
}

.booking-record h3,
.admin-booking-record h4 {
  margin: 0 0 6px;
}

.booking-record p,
.admin-booking-record p {
  color: var(--muted);
  line-height: 1.5;
  margin: 0;
}

.booking-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.small-button {
  min-height: 38px;
  padding: 8px 12px;
}

.danger-button {
  border-color: rgba(172, 73, 55, 0.26);
  color: #9f3f2c;
}

.reschedule-panel {
  background: #f5f7f1;
  border: 1px dashed rgba(24, 33, 29, 0.2);
  border-radius: var(--radius);
  margin-top: 14px;
  padding: 14px;
}

.reschedule-panel label {
  color: var(--ink);
  display: block;
  font-size: 0.86rem;
  font-weight: 800;
  margin: 0 0 8px;
}

.status-pill {
  align-self: start;
  background: var(--sage-2);
  border-radius: 999px;
  color: var(--sage);
  font-size: 0.8rem;
  font-weight: 800;
  padding: 7px 10px;
  white-space: nowrap;
}

.teacher-section {
  background: #eef2f1;
}

.teacher-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 auto;
  max-width: 1180px;
}

.teacher-card {
  overflow: hidden;
}

.teacher-card img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
  width: 100%;
}

.teacher-card h3,
.teacher-card p {
  margin-left: 22px;
  margin-right: 22px;
}

.teacher-card h3 {
  margin-top: 22px;
}

.teacher-card p {
  color: var(--muted);
  line-height: 1.55;
  margin-bottom: 24px;
}

.admin-section {
  background: #f1efe6;
}

.admin-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0 auto;
  max-width: 1180px;
}

.admin-card {
  padding: clamp(20px, 3vw, 28px);
}

.admin-card h3 {
  margin-bottom: 18px;
}

.admin-card .primary-button {
  margin-top: 18px;
  width: 100%;
}

.admin-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.admin-form-actions .primary-button {
  flex: 1 1 180px;
  margin-top: 0;
  width: auto;
}

.admin-form-actions .ghost-button {
  flex: 0 1 auto;
}

.admin-course-list {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 10px;
  margin-top: 22px;
  padding-top: 18px;
}

.admin-course-list h4 {
  margin: 0 0 4px;
}

.admin-course-item {
  background: #f5f7f1;
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: var(--radius);
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1fr) auto;
  padding: 14px;
}

.admin-course-item strong,
.admin-course-item small {
  display: block;
}

.admin-course-item p {
  color: var(--muted);
  line-height: 1.45;
  margin: 5px 0;
}

.admin-course-item small {
  color: var(--muted);
  font-weight: 800;
  line-height: 1.35;
}

.admin-course-actions {
  align-items: start;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.form-help {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
  margin: 8px 0 0;
}

.switch-row {
  align-items: center;
  background: #f5f7f1;
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: var(--radius);
  display: flex !important;
  gap: 18px;
  justify-content: space-between;
  padding: 14px;
}

.switch-row small {
  color: var(--muted);
  display: block;
  font-weight: 500;
  margin-top: 4px;
}

.switch-row input {
  flex: 0 0 auto;
  height: 24px;
  min-height: 24px;
  width: 24px;
}

.qr-preview {
  margin-top: 12px;
}

.contact-image {
  border-radius: var(--radius);
  display: block;
  margin-top: 16px;
  max-height: 180px;
  object-fit: cover;
  width: min(260px, 100%);
}

.site-footer {
  background: var(--ink);
  color: white;
  display: grid;
  gap: 28px;
  grid-template-columns: 1.2fr 0.65fr 0.65fr;
  padding: clamp(42px, 7vw, 76px) clamp(18px, 5vw, 76px);
}

.site-footer p,
.site-footer a {
  color: rgba(255, 255, 255, 0.72);
  display: block;
  line-height: 1.7;
  max-width: 520px;
}

.site-footer h2 {
  font-size: 0.95rem;
  margin: 0 0 14px;
}

.footer-brand {
  color: white;
  margin-bottom: 16px;
}

.footer-brand small {
  color: rgba(255, 255, 255, 0.68);
}

.modal-backdrop {
  align-items: center;
  background: rgba(24, 33, 29, 0.62);
  display: flex;
  inset: 0;
  justify-content: center;
  padding: 18px;
  position: fixed;
  z-index: 1000;
}

.modal-backdrop[hidden],
[hidden] {
  display: none !important;
}

.auth-modal {
  max-height: min(760px, calc(100dvh - 36px));
  max-width: 460px;
  overflow: auto;
  padding: 28px;
  position: relative;
  width: 100%;
}

.auth-modal h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
  font-weight: 500;
  line-height: 1.05;
  margin: 0 0 18px;
}

.modal-close {
  position: absolute;
  right: 16px;
  top: 16px;
}

.auth-tabs {
  background: #ecefe7;
  border-radius: var(--radius);
  display: grid;
  gap: 4px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 18px;
  padding: 4px;
}

.account-summary {
  align-items: center;
  background: #f5f7f1;
  border: 1px solid rgba(24, 33, 29, 0.12);
  border-radius: var(--radius);
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin: 0 0 18px;
  padding: 12px;
}

.account-summary strong,
.account-summary span {
  display: block;
}

.account-summary span {
  color: var(--muted);
  font-size: 0.88rem;
  margin-top: 3px;
}

.auth-tabs button {
  background: transparent;
  border: 0;
  border-radius: 6px;
  font-weight: 800;
  min-height: 40px;
}

.auth-tabs button.active {
  background: white;
  box-shadow: 0 8px 20px rgba(24, 33, 29, 0.08);
}

.auth-form {
  display: grid;
  gap: 10px;
}

.auth-form label {
  margin: 0;
}

.auth-form input {
  display: block;
}

.auth-form .primary-button {
  margin-top: 10px;
  width: 100%;
}

.verification-row {
  align-items: end;
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(0, 1fr) auto;
}

.verification-row .ghost-button {
  min-width: 128px;
}

.verification-help {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
  margin: -2px 0 0;
}

.auth-hint {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 0;
}

.toast {
  background: var(--ink);
  border-radius: var(--radius);
  bottom: 20px;
  box-shadow: var(--shadow);
  color: white;
  left: 50%;
  max-width: min(460px, calc(100vw - 36px));
  opacity: 0;
  padding: 14px 16px;
  pointer-events: none;
  position: fixed;
  transform: translate(-50%, 18px);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
  z-index: 1100;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

@media (max-width: 1040px) {
  .site-header {
    grid-template-columns: auto auto;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .main-nav,
  .header-actions {
    background: rgba(247, 244, 236, 0.98);
    border-bottom: 1px solid rgba(24, 33, 29, 0.1);
    display: none;
    grid-column: 1 / -1;
    justify-content: stretch;
  }

  .main-nav.open,
  .header-actions.open {
    display: grid;
  }

  .main-nav {
    gap: 0;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .main-nav a {
    justify-content: center;
  }

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

  .course-grid,
  .teacher-grid,
  .admin-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .booking-section {
    grid-template-columns: 1fr;
  }

  .booking-copy {
    position: static;
  }
}

@media (max-width: 760px) {
  :root {
    --header-height: 68px;
  }

  .site-header {
    padding-inline: 14px;
  }

  .brand strong {
    font-size: 0.98rem;
  }

  .main-nav,
  .header-actions {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: 760px;
    place-items: start;
  }

  .hero-overlay {
    background:
      linear-gradient(180deg, rgba(18, 26, 24, 0.72) 0%, rgba(18, 26, 24, 0.58) 52%, rgba(18, 26, 24, 0.88) 100%),
      linear-gradient(90deg, rgba(18, 26, 24, 0.72), rgba(18, 26, 24, 0.18));
  }

  .hero-content {
    padding: 58px 18px 220px;
  }

  .hero h1 {
    font-size: clamp(3rem, 15vw, 4.8rem);
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-actions a {
    width: 100%;
  }

  .hero-status,
  .intro-grid,
  .course-grid,
  .teacher-grid,
  .admin-grid,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .intro-grid article {
    min-height: auto;
  }

  .offering-item {
    grid-template-columns: 1fr;
  }

  .offering-item img {
    height: 260px;
  }

  .split-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-entry {
    width: 100%;
  }

  .booking-section {
    padding-inline: 14px;
  }

  .booking-panel {
    padding: 18px;
  }

  .stepper,
  .payment-methods,
  .form-row,
  .form-row.compact,
  .admin-form-actions,
  .admin-course-item,
  .booking-record,
  .admin-booking-record {
    grid-template-columns: 1fr;
  }

  .admin-course-actions {
    justify-content: flex-start;
  }

  .slot-header,
  .calendar-toolbar,
  .form-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .calendar-toolbar label {
    flex-basis: auto;
    width: 100%;
  }

  .calendar-weekday {
    font-size: 0.68rem;
    padding-inline: 3px;
  }

  .calendar-day {
    min-height: 92px;
    padding: 5px;
  }

  .calendar-event {
    border: 0;
    border-radius: 999px;
    display: inline-block;
    font-size: 0.68rem;
    height: 8px;
    margin: 5px 2px 0 0;
    overflow: hidden;
    padding: 0;
    text-overflow: ellipsis;
    white-space: nowrap;
    width: 8px;
  }

  .calendar-event strong {
    display: none;
  }

  .agenda-item {
    grid-template-columns: 1fr;
  }

  .form-actions button,
  .form-actions .primary-button,
  .form-actions .ghost-button {
    width: 100%;
  }

  .booking-form .slot-option {
    align-items: start;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-left: 46px;
    position: relative;
  }

  .booking-form .slot-option input {
    left: 14px;
    position: absolute;
    top: 18px;
  }

  .booking-form .slot-option > span:not(.slot-capacity) {
    min-width: 0;
    width: 100%;
  }

  .slot-capacity {
    justify-self: start;
    margin-top: 0;
  }

  .verification-row {
    grid-template-columns: 1fr;
  }

  .verification-row .ghost-button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
