/* ═══════════════════════════════════════════════════════════════
   MY TICKETS PAGE — DCF Theme
   Sage-green background, batik floral ornaments, premium feel
   ═══════════════════════════════════════════════════════════════ */

/* ── Reset & Fonts ────────────────────────────────────────────── */
.myt-page *,
.myt-page *::before,
.myt-page *::after,
.myt-container *,
.myt-container *::before,
.myt-container *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  background-color: #a8afad;
}

.myt-page {
  height: 100svh;
  width: 100%;
  box-sizing: border-box;
  padding: 28px;
  background: linear-gradient(#F3E3C2, #a8afad);
  font-family: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: #1a2e1a;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.myt-container {
  position: relative;
  z-index: 1;
  max-width: 1320px;
  width: 100%;
  border: 4px solid transparent;
  border-radius: 22px;
  corner-shape: scoop;
  box-shadow: inset 4px 4px 8px #6d5e4678, inset -4px -4px 8px #8b7d654d;
  background:
    linear-gradient(rgba(248, 240, 214, 0.98), rgba(232, 208, 155, 0.98)) padding-box,
    linear-gradient(#c1b59b, #c1b59b) border-box,
    radial-gradient(circle at 50% 18%, rgba(255, 249, 233, 0.94), rgba(242, 228, 188, 0.98) 48%, rgba(228, 208, 155, 0.98) 100%);
  margin: 0 auto;
  height: 100%;
  overflow: hidden;
  /* Clip ornaments to container border */
}

/* ── Decorative Corner Ornaments ─────────────────────────────── */
.myt-container::before,
.myt-container::after {
  content: '';
  position: absolute;
  /* Relative to myt-container */
  width: 100%;
  height: 100%;
  background-image: url('/static/front/eventiva/assets/images/dcf-flower.png');
  background-size: contain;
  background-repeat: no-repeat;
  pointer-events: none;
  z-index: 0;
  opacity: 0.55;
}

.myt-container::before {
  bottom: -450px;
  left: -450px;
  transform: rotate(15deg);
}

.myt-container::after {
  bottom: -450px;
  right: -450px;
  transform: scaleX(-1) rotate(15deg);
}

/* ── Shell / Container ───────────────────────────────────────── */
.myt-shell {
  height: 100%;
  overflow-y: auto;
  position: relative;
  z-index: 1;
  padding: 56px 44px 62px;
  /* Hide scrollbar but keep scrollability */
  scrollbar-width: none;
  /* Firefox */
  -ms-overflow-style: none;
  /* IE/Edge */
}

.myt-shell::-webkit-scrollbar {
  display: none;
  /* Chrome, Safari, Opera */
}

/* ── Top Bar (logo + back btn) ───────────────────────────────── */
.myt-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  /* position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 240, 214, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  margin-top: -56px;
  padding-top: 56px;
  padding-bottom: 16px;
  margin-left: -44px;
  margin-right: -44px;
  padding-left: 44px;
  padding-right: 44px;
  border-bottom: 1.5px solid rgba(18, 18, 18, 0.1); */
}

.myt-logo {
  height: 44px;
  width: auto;
  object-fit: contain;
}

.myt-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 8px;
  background: #2d3a2d;
  color: #f0edd6;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.2px;
  transition: background .2s, transform .15s;
  border: none;
  cursor: pointer;
}

.myt-back-btn:hover {
  background: #1e2b1e;
  transform: translateY(-1px);
}

/* ── Page Title ──────────────────────────────────────────────── */
.myt-title {
  font-family: 'Cormorant Garamond', 'Georgia', serif;
  font-size: clamp(3rem, 5.5vw, 5rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #1a2e1a;
  line-height: 1.05;
  margin-bottom: 8px;
  background-color: #475350;
  color: transparent;
  text-shadow: 0px 3px 3px rgba(255, 255, 255, 0.5);
  -webkit-background-clip: text;
  -moz-background-clip: text;
  background-clip: text;
}

.myt-subtitle {
  font-size: clamp(1rem, 4vw, 12px);
  color: #3d4f3a;
  line-height: 1.55;
  margin-bottom: 36px;
  font-family: "Cormorant Garamond", serif;
}

/* ── Ticket List ─────────────────────────────────────────────── */
.myt-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 836px;
}

/* ── Ticket Card ─────────────────────────────────────────────── */
.myt-card {
  border: 3px solid rgb(0 0 0 / 0%);
  border-radius: 18px;
  padding: 28px 28px 24px;
  /* box-shadow: inset 4px 4px 8px #6d5e4678, inset -4px -4px 8px #8b7d654d; */
  box-shadow: inset 4px 4px 8px #6d5e4678, inset -4px -4px 8px #8b7d654d;
  transition: box-shadow .25s, transform .2s;
  position: relative;
  overflow: hidden;
  corner-shape: scoop;
  background:
    linear-gradient(rgba(248, 240, 214, 0.98), rgba(232, 208, 155, 0.98)) padding-box,
    linear-gradient(#f0e4c4, #ecdcb3) border-box,
    radial-gradient(circle at 50% 18%, rgba(255, 249, 233, 0.94), rgba(242, 228, 188, 0.98) 48%, rgba(228, 208, 155, 0.98) 100%);
}

.myt-card:hover {
  box-shadow:
    0 8px 32px rgba(40, 50, 30, .12),
    0 2px 6px rgba(40, 50, 30, .08);
  transform: translateY(-2px);
}

/* ── Card: Top Section (Header + Badge) ──────────────────────── */
.myt-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.myt-event-name {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #1a2e1a;
  line-height: 1.3;
}

.myt-event-date {
  font-size: 13px;
  color: #6b7c68;
  margin-bottom: 14px;
}

/* ── Status Badge ────────────────────────────────────────────── */
.myt-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 18px;
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  white-space: nowrap;
  flex-shrink: 0;
}

.myt-badge--active {
  background: #22a355;
  color: #fff;
}

.myt-badge--used {
  background: #d97706;
  color: #fff;
}

.myt-badge--cancelled {
  background: #dc2626;
  color: #fff;
}

/* ── Ticket Code ─────────────────────────────────────────────── */
.myt-code-label {
  font-size: 12.5px;
  color: #7a8a76;
  margin-bottom: 2px;
}

.myt-code {
  font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 1.05rem;
  font-weight: 700;
  color: #1a2e1a;
  letter-spacing: 0.5px;
  margin-bottom: 20px;
}

/* ── Card Body: Info + QR side-by-side ───────────────────────── */
.myt-card-body {
  display: flex;
  align-items: flex-start;
  gap: 28px;
}

/* Left: ticket info */
.myt-info {
  flex: 1;
  min-width: 0;
}

.myt-info-row {
  display: flex;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 14px;
  line-height: 1.5;
  color: #2d3d2a;
}

.myt-info-row strong {
  color: #1a2e1a;
  font-weight: 600;
  white-space: nowrap;
}

/* Right: QR + Download */
.myt-qr-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.myt-qr-wrap {
  width: 155px;
  height: 155px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  overflow: hidden;
  corner-shape: scoop;
  box-shadow: inset 2px 2px 4px #6d5e4678, inset -4px -4px 8px #8b7d654d;
  background: linear-gradient(#EED09E, #EED09E) padding-box, linear-gradient(#121212, #121212) border-box, radial-gradient(circle at 50% 18%, rgba(255, 249, 233, 0.94), #EED09E 48%, #EED09E 100%);
  padding: 8px;
  border: 1.5px solid transparent;
}

.myt-qr-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ── Download Button ─────────────────────────────────────────── */
.myt-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 6px;
  border: 1.5px solid #2d3a2d;
  color: #1a2e1a;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background .2s, color .2s, transform .15s;
  white-space: nowrap;
  corner-shape: scoop;
  box-shadow: inset 2px 2px 4px #6d5e4678, inset -4px -4px 8px #8b7d654d;
  background: linear-gradient(#EED09E, #EED09E) padding-box,
    linear-gradient(#121212, #121212) border-box,
    radial-gradient(circle at 50% 18%, rgba(255, 249, 233, 0.94), #EED09E 48%, #EED09E 100%);
}

.myt-download-btn:hover {
  background: #2d3a2d;
  color: #f0edd6;
  transform: translateY(-1px);
}

.myt-download-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* ── Pickup Point Info ───────────────────────────────────────── */
.myt-pickup {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed rgba(100, 120, 90, .25);
}

.myt-pickup-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: #7a8a76;
  margin-bottom: 6px;
}

/* ── Empty State ─────────────────────────────────────────────── */
.myt-empty {
  text-align: center;
  padding: 48px 24px;
  background: rgba(255, 254, 247, .7);
  border-radius: 18px;
  border: 1px dashed rgba(180, 170, 140, .4);
}

.myt-empty-icon {
  font-size: 3rem;
  margin-bottom: 12px;
  opacity: 0.5;
}

.myt-empty h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: #1a2e1a;
  margin-bottom: 8px;
}

.myt-empty p {
  font-size: 14px;
  color: #6b7c68;
}

/* ── Loading Spinner ─────────────────────────────────────────── */
.myt-loading {
  text-align: center;
  padding: 60px 20px;
  color: #3d4f3a;
  font-size: 14px;
}

.myt-loading::before {
  content: '';
  display: block;
  width: 36px;
  height: 36px;
  margin: 0 auto 16px;
  border: 3px solid rgba(45, 58, 45, .2);
  border-top-color: #2d3a2d;
  border-radius: 50%;
  animation: myt-spin .7s linear infinite;
}

@keyframes myt-spin {
  to {
    transform: rotate(360deg);
  }
}

/* ── Details (collapsible extra info) ────────────────────────── */
.myt-details {
  margin-top: 14px;
}

.myt-details summary {
  cursor: pointer;
  color: #4a6848;
  font-weight: 700;
  font-size: 13.5px;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
  user-select: none;
}

.myt-details summary::-webkit-details-marker {
  display: none;
}

.myt-details summary::before {
  content: '▸';
  display: inline-block;
  transition: transform .2s;
}

.myt-details[open] summary::before {
  transform: rotate(90deg);
}

.myt-details-box {
  margin-top: 10px;
  padding: 20px;
  border-radius: 12px;
  border: 2px solid rgb(255 255 255 / 0%);
  corner-shape: scoop;
  box-shadow: inset 4px 4px 8px #6d5e4678, inset -4px -4px 8px #8b7d654d;
  background: linear-gradient(rgba(248, 240, 214, 0.98), rgba(232, 208, 155, 0.98)) padding-box, linear-gradient(#121212, #121212) border-box, radial-gradient(circle at 50% 18%, rgba(255, 249, 233, 0.94), rgba(242, 228, 188, 0.98) 48%, rgba(228, 208, 155, 0.98) 100%);
}

.myt-details-box .myt-info-row {
  font-size: 13.5px;
  margin-bottom: 4px;
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 700px) {
  .myt-page {
    padding: 12px;
  }

  .myt-shell {
    padding: 24px 16px 115px;
  }

  .myt-topbar {
    /* margin-top: -24px;
    padding-top: 24px;
    margin-left: -16px;
    margin-right: -16px;
    padding-left: 16px;
    padding-right: 16px; */
    margin-bottom: 20px;
  }

  .myt-logo {
    height: 36px;
  }

  .myt-back-btn {
    padding: 8px 14px;
    font-size: 12px;
  }

  .myt-title {
    margin-bottom: 6px;
    text-align: center;
    letter-spacing: -1.04px;
  }

  .myt-subtitle {
    margin-bottom: 24px;
    padding: 20px;
    line-height: 1.2;
  }

  .myt-card {
    padding: 20px 18px 18px;
    border-radius: 14px;
  }

  /* Stack body vertically on mobile */
  .myt-card-body {
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
  }

  .myt-qr-col {
    align-items: center;
  }

  .myt-qr-wrap {
    width: 180px;
    height: 180px;
  }

  /* Ornaments smaller on mobile */
  .myt-container::before,
  .myt-container::after {
    width: 250px;
    height: 250px;
    transform: scale(1.5);
  }

  .myt-container::before {
    bottom: -120px;
    left: -120px;
  }

  .myt-container::after {
    bottom: -120px;
    right: -120px;
  }

  .myt-card-header {
    flex-direction: column;
  }
}

@media (max-width: 400px) {
  .myt-event-name {
    font-size: 1rem;
  }

  .myt-code {
    font-size: .95rem;
  }

  .myt-card {
    padding: 16px 14px 14px;
  }

  .myt-qr-wrap {
    width: 90%;
    height: auto;
  }
}
/* ── Kartu Warga Dieng ─────────────────────────────────────────
   Dipakai oleh DUA halaman tiket: /tickets/my/ yang dirender Django
   dan /user/dashboard/booking/tickets yang dirender JS. Gaya kartunya
   harus tinggal di sini, bukan di salah satu halaman, supaya keduanya
   tidak pernah berbeda tampilan. */
.myt-warga {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px dashed rgba(26, 46, 26, .18);
}

.myt-warga-label {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #6b8066;
}

.myt-warga-hint {
  margin-top: 4px;
  font-size: .82rem;
  color: #6b8066;
  max-width: 46ch;
}

.myt-warga-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.myt-warga-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid #b8b394;
  background: #fffcf2;
  color: #1a2e1a;
  font-size: .82rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: filter .15s;
}

.myt-warga-btn:hover { filter: brightness(.97); color: #1a2e1a; }

.myt-warga-btn--primary {
  background: #1a2e1a;
  border-color: #1a2e1a;
  color: #fffcf2;
}

.myt-warga-btn--primary:hover { color: #fffcf2; }
.myt-warga-btn[disabled] { opacity: .6; cursor: progress; }

@media (max-width: 640px) {
  .myt-warga { flex-direction: column; align-items: stretch; }
  .myt-warga-actions .myt-warga-btn { flex: 1; }
}

/* ── Pratinjau Kartu Warga ─────────────────────────────────────
   Pengguna harus melihat kartunya dulu sebelum memutuskan mengunduh
   atau membagikan. Mengunduh gambar yang belum pernah dilihat membuat
   orang ragu dan tombolnya tidak pernah ditekan. */
body.wcp-open { overflow: hidden; }

.wcp-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(16, 26, 16, .72);
  backdrop-filter: blur(2px);
}

.wcp-overlay[hidden] { display: none; }

.wcp-dialog {
  display: flex;
  flex-direction: column;
  width: min(560px, 100%);
  max-height: 92vh;
  border-radius: 20px;
  background: #fffcf2;
  border: 1px solid #b8b394;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
  overflow: hidden;
}

.wcp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(26, 46, 26, .12);
}

.wcp-title {
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #1a2e1a;
}

.wcp-close {
  border: 0;
  background: transparent;
  font-size: 1.6rem;
  line-height: 1;
  color: #6b8066;
  cursor: pointer;
  padding: 0 4px;
}

.wcp-close:hover { color: #1a2e1a; }

.wcp-body {
  flex: 1;
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  overflow: auto;
  background: repeating-conic-gradient(#f4f1e6 0% 25%, #fffcf2 0% 50%) 50% / 22px 22px;
}

.wcp-image {
  max-width: 100%;
  max-height: 62vh;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
}

.wcp-status {
  font-size: .88rem;
  font-weight: 600;
  color: #6b8066;
}

.wcp-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 18px;
  border-top: 1px solid rgba(26, 46, 26, .12);
}

.wcp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid #b8b394;
  background: #fffcf2;
  color: #1a2e1a;
  font-size: .84rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.wcp-btn:hover { filter: brightness(.97); color: #1a2e1a; }

.wcp-btn--primary {
  background: #1a2e1a;
  border-color: #1a2e1a;
  color: #fffcf2;
}

.wcp-btn--primary:hover { color: #fffcf2; }
.wcp-btn[hidden] { display: none; }

@media (max-width: 640px) {
  .wcp-foot { justify-content: stretch; }
  .wcp-foot .wcp-btn { flex: 1; }
}
