/*!
 * Desert SpeedFest — Real Ticket Card Design
 */

/* ── Base ───────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: #07070f;
  font-family: 'Cairo', 'Tajawal', sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ── Page shell ─────────────────────────────── */
.ticket-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.ticket-stage {
  width: 100%;
  padding: 3rem 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ticket-wrap {
  position: relative;
  width: 100%;
  max-width: 820px;
}

/* ── Ambient blobs ──────────────────────────── */
.t-blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
  z-index: 0;
}
.t-blob--1 {
  width: 500px; height: 500px;
  background: rgba(220,38,38,.18);
  top: -160px; left: -180px;
  animation: blobDrift 12s ease-in-out infinite;
}
.t-blob--2 {
  width: 360px; height: 360px;
  background: rgba(234,179,8,.12);
  bottom: -120px; right: -120px;
  animation: blobDrift 16s ease-in-out infinite reverse;
}
@keyframes blobDrift {
  0%,100% { transform: translate(0,0); }
  50%     { transform: translate(28px,-20px); }
}

/* ── Ticket card ────────────────────────────── */
.ticket-card {
  position: relative;
  z-index: 1;
  background:
    repeating-linear-gradient(
      45deg,
      rgba(255,255,255,.012) 0px,
      rgba(255,255,255,.012) 1px,
      transparent 1px,
      transparent 8px
    ),
    linear-gradient(160deg, #0d0d1a 0%, #130a1f 50%, #0a0d18 100%);
  border: 1px solid rgba(220,38,38,.4);
  border-radius: 1.5rem;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(220,38,38,.1),
    0 0 50px rgba(220,38,38,.2),
    0 0 100px rgba(220,38,38,.08),
    inset 0 1px 0 rgba(255,255,255,.06);
  animation: cardIn .7s cubic-bezier(.22,1,.36,1) both;
}
@keyframes cardIn {
  from { opacity:0; transform: translateY(30px) scale(.97); }
  to   { opacity:1; transform: translateY(0) scale(1); }
}

/* ── Header bar ─────────────────────────────── */
.tc-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .85rem 2rem;
  background: linear-gradient(90deg, #b91c1c 0%, #7f1d1d 50%, #991b1b 100%);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.tc-header__left {
  display: flex;
  align-items: center;
  gap: .6rem;
}
.tc-flag { font-size: 1.1rem; }
.tc-brand {
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .22em;
  color: rgba(255,255,255,.95);
  text-transform: uppercase;
}
.tc-live {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .15em;
  color: rgba(255,255,255,.85);
}
.tc-live-dot {
  width: 7px; height: 7px;
  background: #fbbf24;
  border-radius: 50%;
  animation: livePulse 1.4s ease-in-out infinite;
}
@keyframes livePulse {
  0%,100% { opacity:1; transform:scale(1); }
  50%     { opacity:.35; transform:scale(.6); }
}

/* ── Body ───────────────────────────────────── */
.tc-body {
  display: flex;
  align-items: stretch;
  padding: 2.5rem 2rem;
}

.tc-info { flex: 1; }

.tc-eyebrow {
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .22em;
  color: #dc2626;
  margin-bottom: .75rem;
  text-transform: uppercase;
}

.tc-title {
  font-size: clamp(2.6rem, 7.5vw, 4.2rem);
  font-weight: 900;
  line-height: .92;
  color: #f8fafc;
  margin-bottom: .2rem;
  text-transform: uppercase;
  letter-spacing: .02em;
}
.tc-title-grad {
  background: linear-gradient(135deg, #fbbf24 0%, #dc2626 60%, #f59e0b 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradShift 4s ease-in-out infinite alternate;
}
@keyframes gradShift {
  from { background-position: 0% center; }
  to   { background-position: 100% center; }
}

.tc-year {
  font-size: clamp(.9rem, 2.5vw, 1.25rem);
  font-weight: 900;
  color: rgba(220,38,38,.35);
  letter-spacing: .35em;
  margin-bottom: 1.75rem;
}

.tc-meta {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: .65rem;
}
.tc-meta-item {
  display: flex;
  align-items: center;
  gap: .55rem;
  font-size: .85rem;
  color: #94a3b8;
}
.tc-meta-item i { color: #dc2626; width: 14px; text-align: center; flex-shrink: 0; }

/* ── Divider ────────────────────────────────── */
.tc-divider {
  width: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  margin: 0 1.75rem;
  position: relative;
}
.tc-notch {
  width: 22px; height: 22px;
  background: #07070f;
  border-radius: 50%;
  flex-shrink: 0;
  position: absolute;
  z-index: 2;
}
.tc-notch--t { top: -2.5rem; }
.tc-notch--b { bottom: -2.5rem; }
.tc-dashes {
  display: block;
  width: 2px;
  height: 100%;
  background: repeating-linear-gradient(
    to bottom,
    rgba(220,38,38,.55) 0, rgba(220,38,38,.55) 5px,
    transparent 5px, transparent 11px
  );
}

/* ── Stub / QR ──────────────────────────────── */
.tc-stub {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .65rem;
  min-width: 130px;
}
.tc-stub__tier { margin-bottom: .25rem; }
.tc-tier-badge {
  display: inline-block;
  padding: .25rem .9rem;
  border-radius: 9999px;
  font-size: .62rem;
  font-weight: 800;
  letter-spacing: .18em;
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  color: #07070f;
  text-transform: uppercase;
}
.tc-qr {
  width: 96px; height: 96px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(220,38,38,.3);
  border-radius: .85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: rgba(220,38,38,.5);
  transition: border-color .3s, color .3s;
}
.ticket-card:hover .tc-qr {
  border-color: rgba(220,38,38,.7);
  color: rgba(220,38,38,.8);
}
.tc-stub-label {
  font-size: .52rem;
  font-weight: 700;
  letter-spacing: .2em;
  color: #334155;
  text-transform: uppercase;
}
.tc-tiers {
  display: flex;
  gap: .35rem;
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .1em;
  color: #dc2626;
}
.tc-seat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .1rem;
  margin-top: .25rem;
}
.tc-seat-label {
  font-size: .5rem;
  font-weight: 700;
  letter-spacing: .2em;
  color: #334155;
  text-transform: uppercase;
}
.tc-seat-num {
  font-size: 1.1rem;
  font-weight: 900;
  color: #f8fafc;
  letter-spacing: .1em;
}

/* ── Footer / buttons ───────────────────────── */
.tc-footer { padding: 0 2rem 2rem; }

.tc-tear {
  height: 2px;
  background: repeating-linear-gradient(
    90deg,
    rgba(220,38,38,.45) 0, rgba(220,38,38,.45) 7px,
    transparent 7px, transparent 14px
  );
  margin-bottom: 1.75rem;
  position: relative;
}
.tc-tear::before,
.tc-tear::after {
  content: '';
  position: absolute;
  top: 50%; transform: translateY(-50%);
  width: 22px; height: 22px;
  background: #07070f;
  border-radius: 50%;
}
.tc-tear::before { left: -2.25rem; }
.tc-tear::after  { right: -2.25rem; }

.tc-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ── Buttons ────────────────────────────────── */
.tc-btn {
  flex: 1;
  min-width: 160px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  padding: .9rem 1.5rem;
  border-radius: 9999px;
  font-size: .925rem;
  font-weight: 800;
  text-decoration: none;
  letter-spacing: .03em;
  transition: transform .25s ease, box-shadow .25s ease;
  cursor: pointer;
}
.tc-btn:focus-visible {
  outline: 2px solid #fbbf24;
  outline-offset: 3px;
}
.tc-btn--primary {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  color: #fff;
  box-shadow: 0 0 24px rgba(220,38,38,.5);
}
.tc-btn--primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 40px rgba(220,38,38,.8);
}
.tc-btn--ghost {
  background: rgba(220,38,38,.07);
  border: 1px solid rgba(220,38,38,.35);
  color: #fca5a5;
}
.tc-btn--ghost:hover {
  background: rgba(220,38,38,.15);
  border-color: rgba(220,38,38,.6);
  transform: translateY(-3px);
}

/* ── Responsive ─────────────────────────────── */
@media (max-width: 620px) {
  .tc-body    { flex-direction: column; gap: 1.5rem; padding: 1.75rem 1.25rem; }
  .tc-divider { width: 100%; height: 24px; flex-direction: row; margin: 0; }
  .tc-notch--t { left: -1.5rem; top: 50%; transform: translateY(-50%); }
  .tc-notch--b { right: -1.5rem; top: 50%; transform: translateY(-50%); }
  .tc-dashes {
    width: 100%; height: 2px;
    background: repeating-linear-gradient(
      90deg,
      rgba(220,38,38,.55) 0, rgba(220,38,38,.55) 5px,
      transparent 5px, transparent 11px
    );
  }
  .tc-stub    { flex-direction: row; flex-wrap: wrap; justify-content: flex-start; min-width: unset; gap: 1rem; }
  .tc-actions { flex-direction: column; }
  .tc-btn     { min-width: unset; flex: unset; width: 100%; }
  .tc-header  { padding: .75rem 1.25rem; }
  .tc-footer  { padding: 0 1.25rem 1.5rem; }
}
