/* ============================================================
   TicketMaster Pro — Frontend CSS
   Clean minimal design for public-facing elements
   ============================================================ */
:root {
  --tmp-f-primary: #6366f1;
  --tmp-f-bg: #ffffff;
  --tmp-f-surface: #f9f9f9;
  --tmp-f-border: #e5e7eb;
  --tmp-f-text: #111827;
  --tmp-f-text-2: #6b7280;
  --tmp-f-radius: 12px;
  --tmp-f-font: 'DM Sans', -apple-system, sans-serif;
}

/* Events list */
.tmp-events-list { font-family: var(--tmp-f-font); }
.tmp-layout-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; }
.tmp-layout-list { display: flex; flex-direction: column; gap: 16px; }
.tmp-layout-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 24px; }

.tmp-event-card {
  background: var(--tmp-f-bg); border-radius: var(--tmp-f-radius);
  border: 1.5px solid var(--tmp-f-border); overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease;
}
.tmp-event-card:hover { transform: translateY(-3px); box-shadow: 0 12px 40px rgba(0,0,0,.1); }
.tmp-card-image img { width: 100%; height: 180px; object-fit: cover; display: block; }
.tmp-card-body { padding: 20px; }
.tmp-card-date { font-size: 12px; font-weight: 700; color: var(--event-color, var(--tmp-f-primary)); text-transform: uppercase; letter-spacing: .5px; display: block; margin-bottom: 6px; }
.tmp-card-title { font-size: 17px; font-weight: 700; margin: 0 0 6px; }
.tmp-card-title a { text-decoration: none; color: var(--tmp-f-text); }
.tmp-card-title a:hover { color: var(--event-color, var(--tmp-f-primary)); }
.tmp-card-venue { font-size: 12.5px; color: var(--tmp-f-text-2); display: block; margin-bottom: 8px; }
.tmp-card-excerpt { font-size: 13.5px; color: var(--tmp-f-text-2); line-height: 1.55; margin: 0 0 14px; }
.tmp-card-btn {
  display: inline-block; padding: 9px 18px; background: var(--event-color, var(--tmp-f-primary));
  color: #fff; border-radius: 8px; text-decoration: none; font-size: 13.5px; font-weight: 700;
  transition: filter .2s;
}
.tmp-card-btn:hover { filter: brightness(.9); }
.tmp-no-events { text-align: center; padding: 40px; color: var(--tmp-f-text-2); font-family: var(--tmp-f-font); }

/* Thank-you tickets */
.tmp-thankyou-tickets { font-family: var(--tmp-f-font); margin: 32px 0; }
.tmp-thankyou-tickets h2 { font-size: 20px; font-weight: 800; margin: 0 0 8px; }
.tmp-ticket-list { display: flex; flex-direction: column; gap: 12px; margin-top: 20px; }
.tmp-ticket-card {
  display: flex; align-items: center; gap: 16px;
  border: 1.5px solid var(--tmp-f-border); border-radius: var(--tmp-f-radius); padding: 16px 20px;
  background: var(--tmp-f-bg);
}
.tmp-ticket-info { flex: 1; }
.tmp-ticket-info strong { display: block; font-size: 15px; font-weight: 700; margin-bottom: 4px; }
.tmp-ticket-info code { font-size: 12px; color: var(--tmp-f-primary); background: #f0f0ff; padding: 2px 8px; border-radius: 4px; }
.tmp-qr-preview { width: 72px; height: 72px; border-radius: 8px; }
.tmp-download-btn {
  padding: 9px 16px; background: var(--tmp-f-primary); color: #fff !important;
  border-radius: 8px; text-decoration: none; font-size: 13px; font-weight: 700;
  white-space: nowrap;
}

/* My tickets */
.tmp-my-tickets { font-family: var(--tmp-f-font); }
.tmp-my-tickets h3 { font-size: 18px; font-weight: 800; margin: 0 0 16px; }
.tmp-my-ticket-item {
  display: flex; align-items: center; gap: 16px;
  border: 1.5px solid var(--tmp-f-border); border-radius: var(--tmp-f-radius); padding: 16px;
  margin-bottom: 12px; background: var(--tmp-f-bg);
}
.tmp-my-ticket-info { flex: 1; }
.tmp-my-ticket-info strong { display: block; font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.tmp-my-ticket-info code { font-size: 11.5px; color: var(--tmp-f-primary); background: #f0f0ff; padding: 2px 6px; border-radius: 4px; display: block; margin-bottom: 4px; }
.tmp-ticket-status { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--tmp-f-text-2); }
.tmp-status-active .tmp-ticket-status { color: #15803d; }
.tmp-status-used .tmp-ticket-status { color: #6b7280; }
.tmp-status-cancelled .tmp-ticket-status { color: #ef4444; }
.tmp-my-qr { width: 64px; height: 64px; border-radius: 6px; }
.tmp-login-notice, .tmp-no-tickets { font-family: var(--tmp-f-font); padding: 24px; text-align: center; color: var(--tmp-f-text-2); border: 1.5px dashed var(--tmp-f-border); border-radius: var(--tmp-f-radius); }
.tmp-login-notice a { color: var(--tmp-f-primary); font-weight: 600; }
.tmp-access-denied { font-family: var(--tmp-f-font); padding: 24px; text-align: center; color: #ef4444; }

/* ── Waitlist form ── */
.tmp-waitlist-form {
  max-width: 420px; padding: 20px; border-radius: 14px;
  background: #f7f7f9; border: 1.5px solid #e5e7eb;
  font-family: 'DM Sans', -apple-system, sans-serif;
}
.tmp-waitlist-title { font-size: 17px; font-weight: 700; margin: 0 0 4px; color: #111; }
.tmp-waitlist-sub { font-size: 13px; color: #6b7280; margin: 0 0 14px; }
.tmp-waitlist-form .tmp-input {
  width: 100%; padding: 11px 13px; margin-bottom: 9px;
  border: 1.5px solid #e5e7eb; border-radius: 10px;
  font-size: 14px; font-family: inherit; box-sizing: border-box;
}
.tmp-waitlist-form .tmp-input:focus { outline: none; border-color: #6366f1; box-shadow: 0 0 0 3px rgba(99,102,241,.12); }
.tmp-waitlist-btn {
  width: 100%; padding: 12px; border: none; border-radius: 10px;
  background: #6366f1; color: #fff; font-size: 14px; font-weight: 700;
  cursor: pointer; font-family: inherit; transition: filter .15s;
}
.tmp-waitlist-btn:hover { filter: brightness(1.08); }
.tmp-waitlist-btn:disabled { opacity: .6; cursor: default; }
.tmp-waitlist-msg { margin-top: 10px; padding: 9px 12px; border-radius: 8px; font-size: 13px; font-weight: 500; }
.tmp-waitlist-msg.ok { background: #ecfdf5; color: #059669; }
.tmp-waitlist-msg.err { background: #fef2f2; color: #ef4444; }

/* ════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════ */
@media (max-width: 640px) {
  .tmp-ticket-card { flex-wrap: wrap; }
  .tmp-ticket-card .tmp-download-btn,
  .tmp-ticket-card .button { width: 100%; text-align: center; margin-top: 8px; }
  .tmp-waitlist-form { padding: 16px; }
  .tmp-single-event-header { flex-direction: column; }
  .tmp-event-meta-grid { grid-template-columns: 1fr !important; }
}
@media (max-width: 480px) {
  .tmp-layout-grid,
  .tmp-layout-cards { grid-template-columns: 1fr; }
}

/* ── Cart attendee summary ── */
.tmp-cart-attendee { display: flex; flex-direction: column; gap: 4px; margin-top: 4px; }
.tmp-cart-row { display: flex; align-items: center; gap: 6px; font-size: 13px; line-height: 1.4; }
.tmp-cart-thumb { width: 24px; height: 24px; object-fit: cover; border-radius: 5px; border: 1px solid #e5e7eb; }
.tmp-cart-k { color: #6b7280; }
.tmp-cart-v { color: #111; font-weight: 600; }
.tmp-cart-discount input { text-transform: uppercase; }

/* ── Wallet buttons ── */
.tmp-wallet-btn { display: inline-block; padding: 9px 14px; border-radius: 8px; text-decoration: none; font-weight: 600; font-size: 13px; margin: 4px 4px 0 0; }
.tmp-wallet-apple { background: #000; color: #fff; }
.tmp-wallet-google { background: #4285F4; color: #fff; }
.tmp-wallet-btn:hover { filter: brightness(1.1); }
