/* Respect conditional form and confirmation visibility in every trial entry. */
.trial-shell [hidden] { display: none !important; }
:root {
  --ink: #17324d;
  --accent: #e65f3c;
  --muted: #52606d;
  --paper: #ffffff;
  --shell: #f6f8fa;
  --soft: #eef2f5;
  --warm: #fff5f1;
  --line: #d7dee5;
  --green: #16805b;
  --shadow: 0 10px 30px rgba(23, 50, 77, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: transparent;
  color: var(--ink);
  font-family: inherit;
  line-height: 1.5;
}

.trial-shell {
  max-width: 1180px;
  margin: auto;
  color: var(--ink);
}

.trial-header {
  max-width: 800px;
  margin: 0 auto 24px;
  text-align: center;
}

.eyebrow {
  margin: 0;
  color: var(--accent);
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin: 4px 0 10px;
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1.04;
  font-weight: 800;
}

.trial-header p {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.trial-panel {
  padding: clamp(18px, 4vw, 38px);
  border-radius: 22px;
  background: var(--shell);
}

.filter-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 22px;
}

label {
  display: block;
  margin-top: 13px;
  color: var(--ink);
  font-weight: 700;
}

.filter-bar label {
  margin-top: 0;
}

select,
input,
textarea {
  width: 100%;
  margin-top: 6px;
  border: 1px solid #a7b0ba;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  padding: 12px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

select:focus,
input:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(230, 95, 60, 0.16);
  outline: none;
}

textarea {
  resize: vertical;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.85fr);
  gap: 24px;
}

.section-title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.section-title h2,
.booking-box h2 {
  margin-bottom: 0;
  font-size: clamp(25px, 4vw, 36px);
  line-height: 1.12;
  font-weight: 800;
}

.booking-box h2 {
  font-size: 25px;
}

#resultCount {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.class-list {
  display: grid;
  gap: 11px;
}

.class-fit-cta{margin-top:18px;padding:20px;border:1px solid #d9cbea;border-radius:13px;background:#f8f4fd}
.class-fit-cta h3{margin:0 0 7px;font-size:1.15rem}
.class-fit-cta p{margin:0 0 13px;line-height:1.45}
.class-fit-cta a{display:inline-flex;align-items:center;min-height:44px;padding:10px 16px;border-radius:999px;background:#783bce;color:#fff;font-weight:800;text-decoration:none}
.class-fit-cta a:hover{filter:brightness(.92)}

.class-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  border: 2px solid transparent;
  border-radius: 13px;
  background: #fff;
  padding: 17px;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.class-card.is-selected {
  border-color: var(--accent);
}

.class-card:hover {
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}

.class-card-main {
  min-width: 0;
  flex: 1;
}

.class-card h3 {
  margin: 0 0 5px;
  font-size: 1.08rem;
  line-height: 1.25;
  font-weight: 800;
}

.class-meta {
  display: grid;
  gap: 2px;
  color: var(--muted);
  font-size: 14px;
}

.openings {
  color: var(--green);
  font-weight: 800;
}

.class-description {
  margin: 11px 0 0;
  padding: 12px;
  border-radius: 9px;
  background: var(--soft);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.5;
}

.class-description[hidden] {
  display: none;
}

.class-details-toggle {
  display: flex;
  width: 100%;
  min-height: 44px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 11px;
  padding: 10px 12px !important;
  border: 1px solid #d9cbea !important;
  border-radius: 9px !important;
  background: #faf7fe !important;
  color: var(--accent) !important;
  font-size: 14px !important;
  line-height: 1.35;
  text-align: left;
}

.class-details-toggle:hover {
  border-color: var(--accent) !important;
  background: #f5effd !important;
  transform: none !important;
}

.class-details-toggle:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

.class-details-arrow {
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translate(-1px, -1px);
  transition: transform 160ms ease;
}

.class-details-toggle[aria-expanded="true"] .class-details-arrow {
  transform: rotate(225deg) translate(-1px, -1px);
}

.class-card-action {
  display: grid;
  min-width: 116px;
}

.class-card button,
.booking-form button {
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  padding: 13px 19px;
  transition: opacity 160ms ease, transform 160ms ease, background-color 160ms ease;
}

.class-card button {
  background: var(--ink);
  color: #fff;
}

.booking-form button {
  width: 100%;
  margin-top: 18px;
  background: var(--accent);
  color: #fff;
}

.class-card button:hover,
.booking-form button:hover {
  transform: translateY(-1px);
}

.booking-form button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.booking-box,
.confirmation {
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow);
}

.booking-box {
  position: sticky;
  top: 18px;
  align-self: start;
  padding: 22px;
}

.selected-empty,
.selected-summary {
  margin: 14px 0;
  border-radius: 10px;
  padding: 15px;
  background: var(--soft);
  color: var(--muted);
  line-height: 1.5;
}

.selected-summary {
  border-left: 5px solid var(--accent);
  background: var(--warm);
  color: var(--ink);
}

.selected-summary strong {
  display: block;
  color: var(--ink);
}

.booking-form {
  display: grid;
  gap: 0;
}

.consent-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: var(--ink);
  font-weight: 400;
  line-height: 1.4;
}

.consent-row input {
  width: auto;
  margin-top: 4px;
}

.confirmation {
  margin-top: 24px;
  padding: 22px;
}

.confirmation h2 {
  margin-bottom: 6px;
}

.confirmation-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.confirmation-actions button {
  padding: 13px 19px;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.confirmation-actions a {
  color: var(--ink);
  font-weight: 700;
}

@media (max-width: 900px) {
  .content-grid {
    grid-template-columns: 1fr;
  }

  .filter-bar {
    grid-template-columns: 1fr 1fr;
  }

  .booking-box {
    position: static;
  }
}

@media (max-width: 580px) {
  .confirmation-actions > * {
    width: 100%;
    text-align: center;
  }

  .filter-bar {
    grid-template-columns: 1fr;
  }

  .trial-panel {
    border-radius: 16px;
  }

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

  .class-card-action,
  .class-card button {
    width: 100%;
  }
}
