/*
 * GridGames — mybooking.css
 * Styles for the My Booking page template.
 *
 * Uses only existing theme tokens from global.css (:root).
 * BEM prefix: .gg-mb__*
 *
 * Place in:  wp-content/themes/gridgames/assets/css/mybooking.css
 *
 * Property of JWM Entertainment Limited. All rights reserved.
 */

/* =========================================================
   Layout wrapper
   ========================================================= */
.gg-mb {
  max-width: 560px;
  margin: 0 auto;
  padding: 48px 0 80px;
}

/* =========================================================
   Step progress indicator
   ========================================================= */
.gg-mb__steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 44px;
}

.gg-mb__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.gg-mb__step-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;

  font-family: var(--gg-font-ui);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.35);

  transition:
    border-color 280ms ease,
    color 280ms ease,
    background 280ms ease,
    box-shadow 280ms ease;
}

.gg-mb__step-label {
  font-family: var(--gg-font-ui);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.3);
  transition: color 280ms ease;
}

/* Active step */
.gg-mb__step.is-active .gg-mb__step-num {
  border-color: var(--gg-fire);
  color: #fff;
  background: var(--gg-fire-bg);
  box-shadow: 0 0 14px var(--gg-fire-glow);
}

.gg-mb__step.is-active .gg-mb__step-label {
  color: var(--gg-neon-orange);
}

/* Completed step */
.gg-mb__step.is-done .gg-mb__step-num {
  border-color: var(--gg-fire);
  background: var(--gg-fire-soft);
  color: var(--gg-neon-orange);
}

.gg-mb__step.is-done .gg-mb__step-label {
  color: rgba(255, 255, 255, 0.5);
}

/* Connector line */
.gg-mb__step-line {
  flex: 1;
  height: 2px;
  max-width: 64px;
  margin: 0 8px;
  margin-bottom: 22px; /* align with circle centres */
  background: rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  transition: background 280ms ease;
}

/* =========================================================
   Panel (one per step)
   ========================================================= */
.gg-mb__panel {
  animation: gg-mb-fadein 0.35s ease both;
}

@keyframes gg-mb-fadein {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.gg-mb__panel-head {
  text-align: center;
  margin-bottom: 28px;
}

/* =========================================================
   Typography
   ========================================================= */
.gg-mb__title {
  font-family: var(--gg-font-ui);
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  margin: 0 0 8px;

  /* Neon text accent */
  text-shadow:
    0 0 18px rgba(255, 122, 24, 0.25),
    0 0 32px rgba(255, 122, 24, 0.12);
}

.gg-mb__subtitle {
  font-family: var(--gg-font-body);
  font-size: 14px;
  color: var(--gg-dim);
  margin: 0;
  line-height: 1.6;
}

.gg-mb__section-label {
  font-family: var(--gg-font-ui);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gg-neon-orange);
  margin: 0 0 14px;
}

/* =========================================================
   Card
   ========================================================= */
.gg-mb__card {
  background:
    radial-gradient(
      600px 200px at 50% -20px,
      rgba(39, 244, 255, 0.06),
      transparent 60%
    ),
    linear-gradient(180deg, rgba(10, 14, 35, 0.9), rgba(5, 8, 22, 0.95));

  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  padding: 28px 28px 32px;
  margin-bottom: 16px;

  /* Subtle top sheen */
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 8px 40px rgba(0, 0, 0, 0.4);
}

/* Summary card — slightly different tint */
.gg-mb__card--summary {
  background:
    radial-gradient(
      500px 160px at 50% 0,
      rgba(255, 122, 24, 0.07),
      transparent 55%
    ),
    linear-gradient(180deg, rgba(14, 10, 5, 0.9), rgba(5, 8, 22, 0.95));
  border-color: var(--gg-fire-soft);
}

/* Success card */
.gg-mb__card--success {
  text-align: center;
  padding: 48px 28px;
  border-color: rgba(39, 244, 255, 0.2);
  background:
    radial-gradient(
      500px 200px at 50% 0,
      rgba(39, 244, 255, 0.07),
      transparent 60%
    ),
    linear-gradient(180deg, rgba(5, 14, 20, 0.95), rgba(5, 8, 22, 0.98));
}

/* =========================================================
   Form fields
   ========================================================= */
.gg-mb__fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 20px;
}

.gg-mb__field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.gg-mb__label {
  font-family: var(--gg-font-ui);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.gg-mb__input {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 12px 14px;

  font-family: var(--gg-font-body);
  font-size: 14px;
  color: #fff;

  outline: none;
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease;
  width: 100%;
}

.gg-mb__input::placeholder {
  color: rgba(255, 255, 255, 0.2);
}

.gg-mb__input:focus {
  border-color: var(--gg-fire);
  box-shadow:
    0 0 0 2px var(--gg-fire-soft),
    0 0 10px var(--gg-fire-glow);
}

/* =========================================================
   Booking summary rows (populated by JS)
   ========================================================= */
.gg-mb__meta {
  display: grid;
  gap: 10px;
}

.gg-mb__meta-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  font-size: 13px;
  font-family: var(--gg-font-body);
}

.gg-mb__meta-key {
  color: var(--gg-dim);
  flex-shrink: 0;
}

.gg-mb__meta-val {
  font-weight: 600;
  color: #fff;
  text-align: right;
}

.gg-mb__meta-val--accent {
  font-family: var(--gg-font-ui);
  color: var(--gg-neon-orange);
  font-size: 15px;
}

.gg-mb__meta-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--gg-font-ui);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 20px;
  background: rgba(39, 244, 255, 0.1);
  color: var(--gg-neon-cyan);
  border: 1px solid rgba(39, 244, 255, 0.2);
}

/* =========================================================
   Pricing tiers
   ========================================================= */
.gg-mb__tiers {
  display: grid;
  gap: 8px;
  margin-bottom: 24px;
}

.gg-mb__tier {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.02);
  font-size: 13px;
  font-family: var(--gg-font-body);

  transition:
    border-color 200ms ease,
    background 200ms ease;
}

.gg-mb__tier-range {
  color: var(--gg-dim);
}

.gg-mb__tier-price {
  font-weight: 600;
  color: rgba(255, 255, 255, 0.5);
}

/* Active / current tier */
.gg-mb__tier.is-active {
  border-color: var(--gg-fire-soft);
  background: var(--gg-fire-bg);
  box-shadow: 0 0 10px var(--gg-fire-glow);
}

.gg-mb__tier.is-active .gg-mb__tier-range {
  color: #fff;
}

.gg-mb__tier.is-active .gg-mb__tier-price {
  color: var(--gg-neon-orange);
}

/* =========================================================
   Divider
   ========================================================= */
.gg-mb__divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.07);
  margin: 20px 0;
  border-radius: 999px;
}

/* =========================================================
   Player stepper
   ========================================================= */
.gg-mb__stepper-row {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
}

.gg-mb__stepper {
  display: flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  overflow: hidden;
}

.gg-mb__step-btn {
  width: 48px;
  height: 48px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 160ms ease;
  font-family: var(--gg-font-body);
}

.gg-mb__step-btn:hover:not(:disabled) {
  background: var(--gg-fire-bg);
}

.gg-mb__step-btn:focus-visible {
  outline: 2px solid var(--gg-fire);
  outline-offset: -2px;
}

.gg-mb__step-btn:disabled {
  color: rgba(255, 255, 255, 0.15);
  cursor: not-allowed;
}

.gg-mb__step-count {
  min-width: 60px;
  text-align: center;
  font-family: var(--gg-font-ui);
  font-size: 24px;
  font-weight: 700;
  color: #fff;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0 8px;
  line-height: 48px;
}

.gg-mb__capacity-note {
  font-size: 12px;
  font-family: var(--gg-font-body);
  color: rgba(255, 255, 255, 0.4);
  margin: 0;
  line-height: 1.5;
}

.gg-mb__capacity-note strong {
  color: var(--gg-neon-cyan);
  font-weight: 600;
}

/* =========================================================
   Cost breakdown
   ========================================================= */
.gg-mb__cost {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 20px;

  animation: gg-mb-fadein 0.25s ease both;
}

.gg-mb__cost-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  font-family: var(--gg-font-body);
  color: var(--gg-dim);
  padding: 4px 0;
}

.gg-mb__cost-row--total {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  padding-top: 12px;
  margin-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.gg-mb__cost-row--total output {
  font-family: var(--gg-font-ui);
  font-size: 18px;
  color: var(--gg-neon-orange);
}

/* =========================================================
   Alerts
   ========================================================= */
.gg-mb__alert {
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 13px;
  font-family: var(--gg-font-body);
  line-height: 1.5;
  margin-bottom: 16px;
  animation: gg-mb-fadein 0.25s ease both;
}

.gg-mb__alert--error {
  background: rgba(255, 60, 60, 0.1);
  border: 1px solid rgba(255, 60, 60, 0.25);
  color: #ff9090;
}

.gg-mb__alert--info {
  background: rgba(39, 244, 255, 0.07);
  border: 1px solid rgba(39, 244, 255, 0.18);
  color: var(--gg-neon-cyan);
  margin-top: 20px;
}

/* =========================================================
   Buttons
   ========================================================= */
.gg-mb__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.gg-mb__actions[hidden] {
  display: none;
}

.gg-mb__btn {
  width: 100%;
  padding: 14px 20px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-family: var(--gg-font-ui);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition:
    background 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease,
    opacity 180ms ease;
}

/* Primary — fire orange */
.gg-mb__btn--primary {
  background: var(--gg-fire);
  color: #fff;
  box-shadow: 0 0 14px var(--gg-fire-glow);
}

.gg-mb__btn--primary:hover:not(:disabled) {
  background: var(--gg-neon-orange);
  box-shadow: 0 0 24px var(--gg-fire-glow);
  transform: translateY(-1px);
}

.gg-mb__btn--primary:focus-visible {
  outline: 2px solid var(--gg-fire);
  outline-offset: 3px;
}

.gg-mb__btn--primary:disabled {
  background: rgba(255, 122, 24, 0.2);
  color: rgba(255, 255, 255, 0.3);
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

/* Ghost */
.gg-mb__btn--ghost {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--gg-dim);
}

.gg-mb__btn--ghost:hover {
  border-color: rgba(255, 255, 255, 0.3);
  color: #fff;
}

.gg-mb__btn--ghost:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.4);
  outline-offset: 3px;
}

/* Toggle (full-width ghost with arrow indicator) */
.gg-mb__btn--toggle {
  margin-bottom: 12px;
  text-align: left;
  padding-left: 20px;
  position: relative;
}

.gg-mb__btn--toggle::after {
  content: "\203A";
  position: absolute;
  right: 20px;
  font-size: 18px;
  transition: transform 200ms ease;
}

.gg-mb__btn--toggle.is-open::after {
  transform: rotate(90deg);
}

/* Loading state */
.gg-mb__btn.is-loading {
  pointer-events: none;
  opacity: 0.7;
}

.gg-mb__btn.is-loading::before {
  content: "";
  display: inline-block;
  width: 13px;
  height: 13px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: gg-mb-spin 0.65s linear infinite;
  vertical-align: middle;
  margin-right: 8px;
}

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

/* =========================================================
   Success icon
   ========================================================= */
.gg-mb__success-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 2px solid rgba(39, 244, 255, 0.35);
  background: rgba(39, 244, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin: 0 auto 24px;
  box-shadow: 0 0 20px rgba(39, 244, 255, 0.2);
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 600px) {
  .gg-mb {
    padding: 32px 0 60px;
  }

  .gg-mb__card {
    padding: 20px 16px 24px;
  }

  .gg-mb__fields {
    grid-template-columns: 1fr;
  }

  .gg-mb__stepper-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .gg-mb__step-line {
    max-width: 40px;
  }
}

/* =========================================================
   Calendar
   ========================================================= */
.gg-mb__calendar {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 16px;
}

.gg-mb__cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.gg-mb__cal-header-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

.gg-mb__cal-month {
  font-family: var(--gg-font-ui);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
}

.gg-mb__cal-nav {
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #fff;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 160ms ease;
}

.gg-mb__cal-nav:hover:not(:disabled) {
  background: var(--gg-fire-bg);
  border-color: var(--gg-fire-soft);
}

.gg-mb__cal-nav:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}

.gg-mb__cal-refresh,
.gg-mb__cal-clear {
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    background 160ms ease,
    color 160ms ease;
}

.gg-mb__cal-refresh:hover,
.gg-mb__cal-clear:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.gg-mb__cal-clear:hover {
  background: rgba(255, 80, 80, 0.15);
  border-color: rgba(255, 80, 80, 0.3);
  color: #ff6b6b;
}

.gg-mb__cal-clear[hidden] {
  display: none;
}

.gg-mb__cal-days-header {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 6px;
}

.gg-mb__cal-days-header span {
  text-align: center;
  font-family: var(--gg-font-ui);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.3);
  padding: 4px 0;
}

.gg-mb__cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.gg-mb__cal-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  font-family: var(--gg-font-body);
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  transition:
    background 160ms ease,
    border-color 160ms ease,
    color 160ms ease;
}

.gg-mb__cal-day--empty {
  background: transparent;
  border: none;
  cursor: default;
}

.gg-mb__cal-day:hover:not(:disabled):not(.gg-mb__cal-day--empty) {
  background: var(--gg-fire-bg);
  border-color: var(--gg-fire-soft);
  color: #fff;
}

.gg-mb__cal-day.is-today {
  border-color: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.gg-mb__cal-day.is-selected {
  background: var(--gg-fire);
  border-color: var(--gg-fire);
  color: #fff;
  box-shadow: 0 0 12px var(--gg-fire-glow);
}

.gg-mb__cal-day.is-disabled,
.gg-mb__cal-day:disabled {
  color: rgba(255, 255, 255, 0.15);
  cursor: not-allowed;
  background: transparent;
}

/* =========================================================
   Time slots
   ========================================================= */
.gg-mb__slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.gg-mb__slot {
  padding: 10px 8px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  font-family: var(--gg-font-body);
  font-size: 13px;
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  text-align: center;
  transition:
    background 160ms ease,
    border-color 160ms ease;
}

.gg-mb__slot:hover:not(:disabled):not(.is-occupied):not(.is-current) {
  background: var(--gg-fire-bg);
  border-color: var(--gg-fire-soft);
  color: #fff;
}

.gg-mb__slot.is-selected {
  background: var(--gg-fire);
  border-color: var(--gg-fire);
  color: #fff;
  box-shadow: 0 0 10px var(--gg-fire-glow);
}

.gg-mb__slot.is-occupied,
.gg-mb__slot:disabled {
  color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.06);
  cursor: not-allowed;
  position: relative;
}

.gg-mb__slot.is-occupied::after,
.gg-mb__slot:disabled:not(.is-current)::after {
  content: "\00D7";
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  font-size: 14px;
  color: rgba(255, 255, 255, 0.2);
  line-height: 1;
}

/* Current booking slot — cyan highlight */
.gg-mb__slot.is-current {
  color: var(--gg-neon-cyan);
  background: rgba(39, 244, 255, 0.07);
  border-color: rgba(39, 244, 255, 0.25);
  cursor: not-allowed;
}

.gg-mb__slot.is-current::after {
  content: none;
}

@media (max-width: 400px) {
  .gg-mb__slots {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* =========================================================
   Combined actions block (bottom of step 2)
   ========================================================= */
.gg-mb__combined-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.gg-mb__combined-actions[hidden] {
  display: none;
}

.gg-mb__reschedule-unavailable {
  color: rgba(255, 255, 255, 0.4);
  font-size: 14px;
  font-style: italic;
  margin: 4px 0 0;
}

.gg-mb__reschedule-unavailable {
  color: rgba(255, 255, 255, 0.45);
  font-size: 14px;
  margin: 0;
  padding: 4px 0 6px;
}