@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&display=swap");

:root {
  --ts-bg: #f5f7fa;
  --ts-surface: #ffffff;
  --ts-surface-soft: #f7fafc;
  --ts-text: #1e232b;
  --ts-text-dim: #707a89;
  --ts-border: #d8e0e9;
  --ts-primary: #1065b0;
  --ts-primary-dark: #0b4c85;
  --ts-primary-soft: #e6f0fa;
  --ts-accent: #33b3ec;
  --ts-success: #16845b;
  --ts-success-soft: #e7f7f0;
  --ts-warning: #9a5b00;
  --ts-warning-soft: #fff4dd;
  --ts-error: #c03403;
  --ts-radius: 18px;
  --ts-shadow: 0 12px 32px rgba(30, 35, 43, 0.08);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  color-scheme: light;
}

body.ts-page {
  margin: 0;
  min-height: 100vh;
  background: var(--ts-bg);
  color: var(--ts-text);
  font-family: "Space Grotesk", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

.ts-shell {
  width: min(100%, 720px);
  margin: 0 auto;
  padding: 20px 18px calc(120px + env(safe-area-inset-bottom));
}

.ts-shell--compact {
  width: min(100%, 620px);
}

.ts-brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  color: var(--ts-primary-dark);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.ts-language {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin: -52px 0 18px auto;
}

.ts-language label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.ts-language select {
  min-height: 34px;
  padding: 5px 9px;
  border: 1px solid var(--ts-border);
  border-radius: 10px;
  background: var(--ts-surface);
  color: var(--ts-text);
  font: inherit;
  font-size: 13px;
}

.ts-brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 12px;
  background: var(--ts-primary);
  color: #fff;
  font-size: 19px;
}

.ts-hero {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  border-radius: 22px;
  background: linear-gradient(135deg, var(--ts-primary-dark), var(--ts-primary));
  background-position: center;
  background-size: cover;
  box-shadow: var(--ts-shadow);
}

.ts-hero img {
  width: 100%;
  height: 230px;
  display: block;
  object-fit: cover;
}

.ts-hero-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  background: linear-gradient(180deg, rgba(11, 14, 19, 0.04) 18%, rgba(11, 14, 19, 0.82) 100%);
  color: #fff;
}

.ts-hero h1,
.ts-hero p {
  margin: 0;
}

.ts-hero h1 {
  font-size: clamp(25px, 7vw, 36px);
  line-height: 1.05;
}

.ts-hero p {
  margin-top: 8px;
  opacity: 0.9;
}

.ts-stack {
  display: grid;
  gap: 16px;
  margin-top: 16px;
}

.ts-card {
  padding: 20px;
  border: 1px solid var(--ts-border);
  border-radius: var(--ts-radius);
  background: var(--ts-surface);
  box-shadow: 0 4px 16px rgba(30, 35, 43, 0.035);
}

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

.ts-title {
  margin: 0;
  font-size: clamp(25px, 7vw, 34px);
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.ts-subtitle {
  margin: 8px 0 0;
  color: var(--ts-text-dim);
  line-height: 1.5;
}

.ts-kicker {
  margin: 0 0 7px;
  color: var(--ts-primary);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ts-grid {
  display: grid;
  gap: 14px;
}

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

.ts-field {
  display: grid;
  gap: 7px;
}

.ts-label {
  font-size: 14px;
  font-weight: 600;
}

.ts-input,
.ts-select {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  border: 1px solid var(--ts-border);
  border-radius: 14px;
  outline: none;
  background: var(--ts-surface);
  color: var(--ts-text);
  font: inherit;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.ts-input:focus,
.ts-select:focus {
  border-color: var(--ts-primary);
  box-shadow: 0 0 0 4px rgba(16, 101, 176, 0.12);
}

.ts-help,
.ts-error {
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
}

.ts-help {
  color: var(--ts-text-dim);
}

.ts-error {
  color: var(--ts-error);
}

.ts-button {
  display: inline-flex;
  width: 100%;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: var(--ts-primary);
  color: #fff;
  font: inherit;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform 120ms ease, background 160ms ease, opacity 160ms ease;
}

.ts-button:hover {
  background: var(--ts-primary-dark);
}

.ts-button:active {
  transform: translateY(1px);
}

.ts-button:disabled {
  opacity: 0.48;
  cursor: not-allowed;
}

.ts-button--secondary {
  border-color: var(--ts-border);
  background: var(--ts-surface);
  color: var(--ts-primary-dark);
}

.ts-button--secondary:hover {
  background: var(--ts-primary-soft);
}

.ts-button--quiet {
  background: transparent;
  color: var(--ts-primary);
}

.ts-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.ts-price {
  font-size: 21px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.ts-stepper {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px;
  border: 1px solid var(--ts-border);
  border-radius: 14px;
}

.ts-stepper button {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 0;
  border-radius: 11px;
  background: var(--ts-bg);
  color: var(--ts-text);
  font: inherit;
  font-size: 21px;
  cursor: pointer;
}

.ts-stepper output {
  min-width: 28px;
  text-align: center;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.ts-alert {
  padding: 15px 16px;
  border: 1px solid var(--ts-border);
  border-radius: 15px;
  line-height: 1.45;
}

.ts-alert strong {
  display: block;
  margin-bottom: 3px;
}

.ts-alert--warning {
  border-color: #f0cf91;
  background: var(--ts-warning-soft);
  color: #633b00;
}

.ts-alert--success {
  border-color: #a8dfca;
  background: var(--ts-success-soft);
  color: #0b5f40;
}

.ts-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
  color: var(--ts-text-dim);
  font-size: 13px;
}

.ts-divider::before,
.ts-divider::after {
  height: 1px;
  flex: 1;
  background: var(--ts-border);
  content: "";
}

.ts-footer {
  position: fixed;
  z-index: 20;
  right: 0;
  bottom: 0;
  left: 0;
  padding: 14px 18px calc(14px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--ts-border);
  background: rgba(245, 247, 250, 0.94);
  backdrop-filter: blur(16px);
}

.ts-footer-inner {
  width: min(100%, 684px);
  margin: 0 auto;
}

.ts-qr {
  display: block;
  width: min(72vw, 280px);
  height: auto;
  margin: 8px auto;
  padding: 12px;
  border: 1px solid var(--ts-border);
  border-radius: 18px;
  background: #fff;
}

.ts-meta {
  display: grid;
  gap: 8px;
  margin: 0;
}

.ts-meta-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--ts-border);
}

.ts-meta-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.ts-meta dt {
  color: var(--ts-text-dim);
}

.ts-meta dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}

.ts-chip {
  display: inline-flex;
  align-items: center;
  padding: 7px 10px;
  border-radius: 999px;
  background: var(--ts-primary-soft);
  color: var(--ts-primary-dark);
  font-size: 13px;
  font-weight: 600;
}

.ts-actions {
  display: grid;
  gap: 10px;
}

.ts-segmented {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  padding: 5px;
  border: 1px solid var(--ts-border);
  border-radius: 15px;
  background: var(--ts-bg);
}

.ts-segmented button {
  min-height: 42px;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: var(--ts-text-dim);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.ts-segmented button.is-selected {
  background: var(--ts-surface);
  color: var(--ts-primary-dark);
  box-shadow: 0 2px 8px rgba(30, 35, 43, 0.08);
}

.ts-consent {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  color: var(--ts-text-dim);
  font-size: 13px;
  line-height: 1.45;
  cursor: pointer;
}

.ts-consent input {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  margin: 0;
  accent-color: var(--ts-primary);
}

.ts-steps {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.ts-step {
  height: 5px;
  flex: 1;
  overflow: hidden;
  border-radius: 999px;
  background: var(--ts-border);
}

.ts-step--active {
  background: var(--ts-primary);
}

.ts-ticket-option {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--ts-border);
  border-radius: 15px;
  background: var(--ts-surface);
}

.ts-ticket-option.is-selected {
  border-color: var(--ts-primary);
  box-shadow: 0 0 0 3px rgba(16, 101, 176, 0.12);
}

.ts-empty {
  padding: 28px 16px;
  color: var(--ts-text-dim);
  text-align: center;
}

@media (max-width: 560px) {
  .ts-grid--2 {
    grid-template-columns: 1fr;
  }

  .ts-card {
    padding: 18px;
  }

  .ts-hero,
  .ts-hero img {
    min-height: 190px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
