:root {
  --bg: #f5f5f7;
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --panel: rgba(255, 255, 255, 0.82);
  --line: rgba(29, 29, 31, 0.12);
  --blue: #0071e3;
  --blue-strong: #005bbf;
  --green: #16833f;
  --amber: #b45309;
  --red: #b42318;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.1);
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: linear-gradient(180deg, #ffffff 0%, var(--bg) 46%, #edf1f7 100%);
  letter-spacing: 0;
}

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

.app-shell {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
  padding: max(16px, env(safe-area-inset-top)) 0 42px;
}

.app-shell.wide {
  width: min(1180px, calc(100vw - 32px));
}

.glass-bar {
  position: sticky;
  top: 12px;
  z-index: 20;
  min-height: 58px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: saturate(180%) blur(22px);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.08);
}

.bar-title,
.bar-stack {
  min-width: 0;
}

.traffic {
  display: flex;
  gap: 7px;
  align-items: center;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.dot.red {
  background: #ff5f57;
}

.dot.yellow {
  background: #ffbd2e;
}

.dot.green {
  background: #28c840;
}

.bar-title,
.bar-stack strong {
  display: block;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bar-stack span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.82rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bar-link {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  padding: 0 12px;
  border-radius: 999px;
  border: 0;
  background: #eef6ff;
  color: var(--blue);
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

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

.button-link {
  font-size: 0.9rem;
}

.hero {
  padding: 70px 0 24px;
  text-align: center;
}

.hero.compact {
  padding: 46px 0 18px;
  text-align: left;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--blue);
  font-weight: 900;
}

h1 {
  margin: 0;
  font-size: clamp(2.5rem, 8vw, 5.2rem);
  line-height: 0.98;
  font-weight: 850;
  letter-spacing: 0;
}

.compact h1 {
  font-size: clamp(2.3rem, 6vw, 4.4rem);
}

.hero-meta {
  margin: 16px auto 0;
  max-width: 680px;
  color: var(--muted);
  font-size: clamp(1rem, 2.5vw, 1.24rem);
  line-height: 1.5;
}

.compact .hero-meta {
  margin-left: 0;
}

.segmented {
  display: grid;
  gap: 4px;
  padding: 4px;
  margin: 0 auto 18px;
  border-radius: 999px;
  border: 1px solid rgba(118, 118, 128, 0.16);
  background: rgba(118, 118, 128, 0.12);
}

.segmented.two {
  width: min(420px, 100%);
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.course-list {
  padding: clamp(46px, 8vw, 86px) 0 0;
}

.course-block {
  border-bottom: 0;
}

.course-trigger {
  width: 100%;
  display: grid;
  gap: 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  text-align: center;
  padding: clamp(28px, 6vw, 58px) 0;
  cursor: pointer;
}

.course-trigger:focus-visible {
  outline: 4px solid rgba(0, 113, 227, 0.16);
  outline-offset: -4px;
}

.course-title {
  margin: 0;
  font-size: clamp(2.25rem, 7.2vw, 5.8rem);
  line-height: 0.95;
  font-weight: 850;
  letter-spacing: 0;
}

.course-meta {
  color: var(--muted);
  font-size: clamp(1.15rem, 2.4vw, 2rem);
  line-height: 1.35;
  font-weight: 650;
}

.status-inline {
  color: var(--blue);
  font-weight: 850;
}

.status-inline.nearly-full {
  color: #d97706;
}

.status-inline.waitlist {
  color: var(--amber);
}

.status-inline.closed {
  color: var(--red);
}

.course-details {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-8px);
  transition: max-height 280ms ease, opacity 180ms ease, transform 220ms ease;
}

.course-block.open .course-details {
  max-height: 1200px;
  opacity: 1;
  transform: translateY(0);
}

.course-form-dock {
  width: min(760px, 100%);
  margin: 0 auto clamp(28px, 5vw, 56px);
  padding: clamp(8px, 2vw, 14px) 0 0;
}

.event-content-preview {
  display: grid;
  gap: 12px;
  margin: 0 auto 18px;
  text-align: center;
  color: var(--ink);
  line-height: 1.65;
}

.event-content-text {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1rem, 2.5vw, 1.18rem);
  font-weight: 750;
}

.event-fee-line {
  display: inline-flex;
  justify-self: center;
  align-items: center;
  gap: 10px;
  min-height: 38px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(29, 29, 31, 0.06);
  color: var(--muted);
  font-weight: 850;
}

.event-fee-line strong {
  color: var(--ink);
}

.course-form-dock .actions {
  justify-content: center;
}

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

.event-carousel {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-padding-inline: 4px;
  scroll-snap-type: x proximity;
  padding: 4px 4px 16px;
  margin-inline: -4px;
  -webkit-overflow-scrolling: touch;
}

.event-carousel::-webkit-scrollbar {
  height: 8px;
}

.event-carousel::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(118, 118, 128, 0.24);
}

.event-card {
  min-height: 150px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  text-align: left;
  border: 1px solid rgba(29, 29, 31, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--ink);
  padding: 18px;
  cursor: pointer;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.08);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.event-carousel .event-card {
  flex: 0 0 min(390px, 82vw);
  scroll-snap-align: center;
}

.event-card:hover {
  transform: translateY(-2px);
}

.event-card.active {
  border-color: rgba(0, 113, 227, 0.75);
  background: #eef6ff;
}

.event-card.past {
  opacity: 0.58;
  background: rgba(255, 255, 255, 0.58);
  filter: grayscale(0.2);
}

.event-card.past.active {
  opacity: 0.82;
  filter: none;
}

.event-card-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.course-status {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 900;
  background: rgba(118, 118, 128, 0.12);
  color: var(--muted);
}

.course-status.open {
  background: #eaf7ee;
  color: var(--green);
}

.course-status.closed {
  background: #f1f1f3;
  color: var(--muted);
}

.event-card strong {
  display: block;
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  line-height: 1.08;
}

.event-title-link {
  color: inherit;
  text-decoration: none;
}

.event-title-link:hover {
  color: var(--blue);
}

.event-card small,
.event-foot {
  color: var(--muted);
  line-height: 1.45;
  word-break: break-word;
}

.segmented.five {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.segmented.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.segmented.six {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.segment {
  min-height: 40px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-weight: 850;
  cursor: pointer;
  white-space: nowrap;
}

.segment.active {
  background: #ffffff;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.1);
}

.panel {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  backdrop-filter: saturate(180%) blur(18px);
  box-shadow: var(--shadow);
  padding: clamp(18px, 4vw, 32px);
}

.panel + .panel {
  margin-top: 18px;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 14px;
  margin-bottom: 16px;
}

.panel h2 {
  margin: 0;
  font-size: clamp(1.35rem, 3vw, 2.1rem);
  letter-spacing: 0;
}

.soft-pill,
.metric {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 11px;
  border-radius: 999px;
  background: rgba(118, 118, 128, 0.12);
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 850;
  white-space: nowrap;
}

.summary-strip {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.event-overview {
  margin: 10px 0 18px;
}

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

.event-overview h2 {
  margin: 0 0 10px;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  letter-spacing: 0;
}

.overview-metrics,
.overview-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.pill-toggle {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 13px 0 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(118, 118, 128, 0.14);
  color: var(--muted);
  font-weight: 850;
  cursor: pointer;
  white-space: nowrap;
  transition: background 160ms ease, color 160ms ease;
}

.pill-toggle-knob {
  position: relative;
  width: 48px;
  height: 28px;
  border-radius: 999px;
  background: rgba(118, 118, 128, 0.28);
  transition: background 160ms ease;
}

.pill-toggle-knob::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.16);
  transition: transform 160ms ease;
}

.pill-toggle.active {
  background: #eef6ff;
  color: var(--blue);
}

.pill-toggle.active .pill-toggle-knob {
  background: var(--blue);
}

.pill-toggle.active .pill-toggle-knob::after {
  transform: translateX(20px);
}

.metric.blue {
  background: #eef6ff;
  color: var(--blue);
}

.metric.green-text {
  background: #eaf7ee;
  color: var(--green);
}

.metric.amber {
  background: #fff4df;
  color: var(--amber);
}

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

.wide-field {
  grid-column: 1 / -1;
}

.input-action {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

label {
  display: grid;
  min-width: 0;
  gap: 7px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 850;
}

input,
select,
textarea {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  border: 1px solid rgba(118, 118, 128, 0.24);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  padding: 11px 13px;
  outline: none;
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.03);
}

.form-select {
  height: 48px;
  line-height: 1.2;
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(29, 29, 31, 0.55) 50%),
    linear-gradient(135deg, rgba(29, 29, 31, 0.55) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 52%,
    calc(100% - 13px) 52%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 36px;
}

.form-select.placeholder {
  color: var(--muted);
}

.form-select option {
  color: var(--ink);
}

.form-select option[value=""] {
  color: var(--muted);
}

.time-combo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.time-combo select {
  text-align: center;
  font-weight: 850;
}

.time-combo .form-select {
  padding-right: 30px;
}

.create-event-drawer {
  width: 100%;
  margin-top: 14px;
}

.create-event-drawer .panel {
  width: min(100%, 900px);
}

textarea {
  min-height: 96px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.14);
}

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

.btn {
  min-height: 46px;
  border: 0;
  border-radius: 999px;
  padding: 0 19px;
  background: rgba(118, 118, 128, 0.14);
  color: var(--ink);
  font-weight: 850;
  cursor: pointer;
  transition: transform 160ms ease, background 160ms ease;
}

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

.btn.primary {
  background: var(--blue);
  color: #ffffff;
}

.btn.primary:hover {
  background: var(--blue-strong);
}

.btn.good {
  background: var(--green);
  color: #ffffff;
}

.btn.bad {
  background: #fff0ee;
  color: var(--red);
}

.btn:disabled {
  cursor: not-allowed;
  opacity: 0.58;
  transform: none;
}

.notice {
  display: none;
  margin: 0 0 16px;
  border-radius: 14px;
  padding: 12px 14px;
  background: #eef6ff;
  color: #1f4f82;
  font-weight: 800;
  line-height: 1.5;
}

.notice.show {
  display: block;
}

.notice.good {
  background: #eaf7ee;
  color: var(--green);
}

.notice.warn {
  background: #fff4df;
  color: var(--amber);
}

.notice.bad {
  background: #fff0ee;
  color: var(--red);
}

.ticket {
  grid-template-columns: minmax(0, 1fr) minmax(220px, 300px);
  gap: 18px;
  align-items: center;
  margin-top: 18px;
  text-align: center;
}

.ticket:not(.hidden) {
  display: grid;
}

.ticket-kicker {
  margin: 0 0 10px;
  color: var(--blue);
  font-weight: 900;
}

.ticket-summary {
  display: grid;
  justify-items: center;
  gap: 6px;
  text-align: center;
}

.ticket-name {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 3.2rem);
  line-height: 1.05;
}

.ticket-meta,
.muted {
  color: var(--muted);
  line-height: 1.5;
}

.qr-card {
  width: min(100%, 300px);
  justify-self: center;
  display: grid;
  place-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid rgba(29, 29, 31, 0.1);
  background: #ffffff;
}

.qr-ticket-info {
  width: 100%;
  display: grid;
  gap: 4px;
  text-align: center;
  color: var(--muted);
  line-height: 1.35;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.qr-ticket-info strong {
  color: var(--ink);
  font-size: 1.05rem;
  line-height: 1.2;
}

.qr-ticket-info span {
  display: block;
  font-size: 0.92rem;
  max-width: 100%;
}

.qr-mount canvas,
.qr-mount img,
.qr-mount svg {
  display: block;
  width: min(220px, 100%);
  height: auto;
  image-rendering: pixelated;
}

.qr-mount.large canvas,
.qr-mount.large img,
.qr-mount.large svg {
  width: min(540px, calc(100vw - 80px));
}

.qr-text {
  max-width: 100%;
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  text-align: center;
  word-break: break-all;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: none;
  place-items: center;
  padding: 18px;
  background: rgba(245, 245, 247, 0.96);
  backdrop-filter: saturate(180%) blur(18px);
}

.modal.show {
  display: grid;
}

.modal-card {
  width: min(100%, 620px);
  display: grid;
  gap: 16px;
  place-items: center;
  padding: 22px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid rgba(29, 29, 31, 0.12);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.16);
}

.modal-qr-info {
  max-width: 520px;
}

.checkin-modal {
  z-index: 80;
  background: rgba(245, 245, 247, 0.7);
}

.checkin-modal-card {
  width: min(100%, 720px);
  place-items: stretch;
  gap: 18px;
  padding: clamp(22px, 4vw, 34px);
}

.checkin-modal-head {
  display: grid;
  gap: 10px;
}

.checkin-modal-head h2 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1.05;
}

.checkin-modal-head p {
  margin: 0;
  font-size: clamp(1rem, 2.8vw, 1.2rem);
  font-weight: 750;
}

.checkin-modal-actions {
  margin-top: 6px;
}

.checkin-modal-actions .btn {
  min-height: 54px;
  padding-inline: 24px;
  font-size: 1.08rem;
}

.login-panel {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin-bottom: 18px;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 18px;
  align-items: start;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.reader-shell {
  overflow: hidden;
  min-height: 360px;
  display: grid;
  place-items: center;
  border-radius: 22px;
  border: 1px solid rgba(29, 29, 31, 0.12);
  background: #111318;
  color: #ffffff;
}

#reader {
  width: 100%;
  min-height: 360px;
}

#reader video {
  object-fit: cover !important;
}

.camera-note {
  min-height: 360px;
  display: grid;
  gap: 12px;
  place-items: center;
  align-content: center;
  text-align: center;
  padding: 28px;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.55;
}

.camera-note strong {
  color: #ffffff;
  font-size: clamp(1.35rem, 5vw, 2.35rem);
  line-height: 1.08;
}

.camera-note span {
  max-width: 420px;
  color: rgba(255, 255, 255, 0.72);
  font-weight: 800;
}

.result-card {
  display: grid;
  gap: 8px;
}

.scan-result-card {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid rgba(29, 29, 31, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
}

.detail-list {
  display: grid;
  gap: 0;
  margin: 10px 0 0;
  border: 1px solid rgba(29, 29, 31, 0.09);
  border-radius: 16px;
  overflow: hidden;
  background: #ffffff;
}

.detail-list div {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 14px;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(29, 29, 31, 0.08);
}

.detail-list div:last-child {
  border-bottom: 0;
}

.detail-list dt,
.detail-list dd {
  margin: 0;
  line-height: 1.45;
}

.detail-list dt {
  color: var(--muted);
  font-weight: 850;
}

.detail-list dd {
  color: var(--ink);
  font-weight: 800;
  word-break: break-word;
}

.big-status {
  margin: 0;
  font-size: clamp(1.5rem, 4vw, 2.8rem);
  line-height: 1.08;
  font-weight: 850;
}

.manual-form {
  margin-top: 16px;
}

.manual-matches {
  margin-top: 10px;
}

.manual-matches .record {
  background: #ffffff;
}

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

.search-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: nowrap;
}

.search-actions .btn {
  min-width: 86px;
}

.records {
  display: grid;
  gap: 10px;
}

.record {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 13px;
  border-radius: 16px;
  border: 1px solid rgba(29, 29, 31, 0.1);
  background: rgba(255, 255, 255, 0.72);
}

.record strong {
  display: block;
  font-size: 1.05rem;
  word-break: break-word;
}

.record small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.4;
  word-break: break-word;
}

.record-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.switches {
  margin-top: 12px;
}

.switch-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  min-height: 54px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(29, 29, 31, 0.09);
  color: var(--ink);
}

.switch {
  position: relative;
  width: 52px;
  height: 32px;
  flex: 0 0 auto;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  inset: 0;
  cursor: pointer;
  border-radius: 999px;
  background: rgba(118, 118, 128, 0.28);
  transition: background 160ms ease;
}

.slider::after {
  content: "";
  position: absolute;
  width: 28px;
  height: 28px;
  top: 2px;
  left: 2px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  transition: transform 160ms ease;
}

.switch input:checked + .slider {
  background: #34c759;
}

.switch input:checked + .slider::after {
  transform: translateX(20px);
}

.empty {
  min-height: 130px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
  border: 1px dashed rgba(118, 118, 128, 0.24);
  border-radius: 16px;
  padding: 20px;
  font-weight: 850;
}

.compact-empty {
  min-height: 70px;
}

.fixed-field {
  background: #ffffff;
}

.field-fixed-pill {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 19px;
  border-radius: 999px;
  background: rgba(118, 118, 128, 0.14);
  color: var(--muted);
  font-size: 1rem;
  font-weight: 850;
  white-space: nowrap;
}

.admin-only.blocked {
  opacity: 0.48;
  pointer-events: none;
  filter: grayscale(0.25);
}

.hidden {
  display: none !important;
}

@media (max-width: 900px) {
  .app-shell,
  .app-shell.wide {
    width: min(100% - 22px, 760px);
  }

  .glass-bar {
    top: 8px;
  }

  .hero {
    padding-top: 56px;
    text-align: left;
  }

  .course-list {
    padding-top: 36px;
  }

  .course-title {
    font-size: clamp(2.15rem, 12vw, 4rem);
  }

  .course-meta {
    font-size: clamp(1.05rem, 5vw, 1.45rem);
  }

  .segmented {
    border-radius: 22px;
  }

  .event-overview-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .segmented.five,
  .segmented.six,
  .segmented.four {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .segment {
    border-radius: 18px;
  }

  .form-grid,
  .ticket,
  .split,
  .course-form-dock,
  .search-row,
  .record,
  .input-action,
  .login-panel {
    grid-template-columns: 1fr;
  }

  .login-panel {
    display: grid;
  }

  .wide-field {
    grid-column: auto;
  }

  .event-cards:not(.event-carousel) {
    grid-template-columns: 1fr;
  }

  .event-carousel .event-card {
    flex-basis: min(330px, 86vw);
  }

  .ticket-summary .actions,
  .modal-card .actions {
    justify-content: center;
  }

  .ticket {
    width: min(100%, 430px);
    margin-left: auto;
    margin-right: auto;
  }

  .qr-card {
    width: 100%;
    max-width: 360px;
  }

  .qr-card {
    padding: 16px 10px;
  }

  .checkin-modal {
    align-items: end;
    justify-items: center;
    padding: 0 10px max(10px, env(safe-area-inset-bottom));
  }

  .checkin-modal-card {
    width: 100%;
    max-height: min(86dvh, 900px);
    overflow: auto;
    border-radius: 28px;
  }

  .checkin-modal-card .detail-list div {
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 18px 16px;
  }

  .checkin-modal-actions {
    position: sticky;
    bottom: 0;
    padding-top: 10px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), #ffffff 28%);
  }

  .record-actions {
    justify-content: flex-start;
  }

  .detail-list div {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
