/* ═══════════════════════════════════════════════════════════
   GTF Daily Result Page — Pixel-perfect clone
   Covers: sub-header bar, nav bar, results table,
           no-record state, custom date-picker modal
═══════════════════════════════════════════════════════════ */

/* ── Sub-header bar ──────────────────────────────────────── */
.gtf-subheader {
  background: #1e2d8a;
  padding: 11px 16px;
  text-align: center;
}
.gtf-subheader h2 {
  color: rgba(255,255,255,.82);
  font-size: 15px;
  font-weight: 400;
  letter-spacing: .2px;
}

/* ── Nav bar (back ← | date | calendar icon) ─────────────── */
.gtf-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #fff;
  border-bottom: 1px solid #e8e8e8;
}
.gtf-nav-back {
  background: none; border: none; cursor: pointer;
  padding: 4px 8px 4px 0;
  display: flex; align-items: center;
  text-decoration: none;
}
.gtf-nav-back svg {
  width: 28px; height: 28px;
  display: block;
}
.gtf-nav-date {
  font-size: 15px;
  color: #222;
  font-weight: 400;
  letter-spacing: .2px;
}
.gtf-nav-cal {
  background: none; border: none; cursor: pointer;
  padding: 4px;
  display: flex; align-items: center;
  position: relative;
}
.gtf-nav-cal svg { width: 30px; height: 30px; }

/* ── Results container ───────────────────────────────────── */
.gtf-results {
  background: #f5f5f5;
  min-height: 300px;
}

/* Date heading bar — gray with white bold text */
.gtf-date-bar {
  background: #757575;
  padding: 10px 14px;
}
.gtf-date-bar span {
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: .1px;
}

/* Single draw block */
.gtf-draw {
  display: flex;
  align-items: flex-start;
  padding: 18px 14px 14px;
  background: #fff;
  border-bottom: 1px solid #d8d8d8;
}

/* Left column: prize badge + time */
.gtf-draw-left {
  width: 110px;
  flex-shrink: 0;
  padding-right: 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.gtf-prize-badge {
  font-size: 13px;
  color: #444;
  margin-bottom: 3px;
}
.gtf-draw-time {
  font-size: 22px;
  font-weight: 900;
  color: #111;
  line-height: 1.1;
  letter-spacing: -.3px;
}

/* Right column: prize rows */
.gtf-prizes {
  flex: 1;
}
.gtf-prize-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 5px 0;
}
.gtf-prize-label {
  font-size: 15px;
  font-weight: 700;
  color: #222;
  width: 76px;
  flex-shrink: 0;
}
.gtf-prize-num {
  font-size: 15px;
  font-weight: 700;
  color: #111;
  text-align: right;
  letter-spacing: .5px;
}

/* ── No record state ─────────────────────────────────────── */
.gtf-no-record {
  background: #fff0f0;
  margin: 0;
  padding: 30px 20px;
  text-align: center;
}
.gtf-no-record p {
  color: #e53030;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .2px;
}

/* ── Loading spinner ─────────────────────────────────────── */
.gtf-loading {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px;
}
.gtf-spinner {
  width: 36px; height: 36px;
  border: 3px solid #e0e0e0;
  border-top-color: #1e2d8a;
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Refresh icon in header (page-level override) ────────── */
.header-refresh-btn {
  background: none; border: none; cursor: pointer;
  padding: 6px; display: flex; align-items: center;
  justify-content: center; text-decoration: none;
  margin-left: 2px;
}
.header-refresh-btn svg {
  width: 24px; height: 24px; fill: #fff;
}
.header-refresh-btn.spinning svg {
  animation: spin .7s linear infinite;
}

/* ══════════════════════════════════════════════════════════
   CUSTOM DATE PICKER MODAL
   Purple header + dark charcoal calendar — exact screenshot
══════════════════════════════════════════════════════════ */
.dp-backdrop {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 600;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  opacity: 0; pointer-events: none;
  transition: opacity .2s;
}
.dp-backdrop.open { opacity: 1; pointer-events: all; }

.dp-modal {
  width: 100%; max-width: 340px;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,.45);
  transform: scale(.94);
  transition: transform .22s cubic-bezier(.22,.68,0,1.18);
}
.dp-backdrop.open .dp-modal { transform: scale(1); }

/* Purple header */
.dp-header {
  background: #a855f7;
  padding: 16px 20px 18px;
}
.dp-select-label {
  font-size: 11px;
  font-weight: 700;
  color: rgba(255,255,255,.75);
  letter-spacing: 1.2px;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.dp-header-date-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.dp-header-date {
  font-size: 26px;
  font-weight: 900;
  color: #fff;
  letter-spacing: -.3px;
}
.dp-pencil {
  background: none; border: none; cursor: pointer; padding: 4px;
}
.dp-pencil svg { width: 22px; height: 22px; fill: #fff; }

/* Dark calendar body */
.dp-body {
  background: #2d2d2d;
  padding: 16px 14px 10px;
}

/* Month/year row */
.dp-month-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.dp-month-label {
  font-size: 14px;
  font-weight: 700;
  color: #a855f7;
  letter-spacing: .5px;
  display: flex; align-items: center; gap: 4px;
  cursor: pointer;
}
.dp-month-label svg { width: 14px; height: 14px; fill: #a855f7; }
.dp-nav-btns { display: flex; gap: 4px; }
.dp-nav-btn {
  background: none; border: none; cursor: pointer;
  padding: 4px 8px; color: #ccc; font-size: 18px;
  line-height: 1; border-radius: 50%;
  transition: background .15s;
}
.dp-nav-btn:hover { background: rgba(255,255,255,.1); }

/* Day-of-week headers */
.dp-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  margin-bottom: 4px;
}
.dp-weekday {
  text-align: center;
  font-size: 12px;
  color: #aaa;
  padding: 4px 0;
  font-weight: 500;
}

/* Day grid */
.dp-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  row-gap: 2px;
}
.dp-day {
  aspect-ratio: 1;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
  color: #e0e0e0;
  cursor: pointer;
  border-radius: 50%;
  transition: background .14s;
  border: none; background: none;
  font-family: inherit;
}
.dp-day:hover { background: rgba(168,85,247,.25); }
.dp-day.today {
  border: 1.5px solid rgba(255,255,255,.6);
  color: #fff;
}
.dp-day.selected {
  background: #a855f7;
  color: #fff;
  font-weight: 700;
  border: none;
}
.dp-day.empty { cursor: default; pointer-events: none; }
.dp-day:disabled { color: #555; cursor: default; }

/* Action buttons row */
.dp-actions {
  background: #2d2d2d;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 6px 12px 14px;
}
.dp-action-btn {
  background: none; border: none; cursor: pointer;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 700;
  color: #a855f7;
  letter-spacing: .8px;
  text-transform: uppercase;
  border-radius: 4px;
  transition: background .15s;
}
.dp-action-btn:hover { background: rgba(168,85,247,.12); }