/* ============================================================
   join.css - روح السعودية (تجربة تسجيل الزوار الفاخرة)
   Visit Saudi Premium Mobile-First Visitor Experience
   ============================================================ */

:root {
  --sa-bg: #030f08;
  --sa-emerald-950: #04140b;
  --sa-emerald-900: #072514;
  --sa-emerald-800: #0d3b22;
  --sa-emerald-700: #145934;
  --sa-emerald-500: #1fa45c;
  --sa-gold-300: #fff0a6;
  --sa-gold-400: #ffd666;
  --sa-gold-500: #d4af37;
  --sa-gold-600: #aa8620;
  --sa-gold-gradient: linear-gradient(135deg, #ffe58f 0%, #d4af37 50%, #997300 100%);
  --sa-gold-glow: 0 0 25px rgba(212, 175, 55, 0.35);
  --sa-glass-bg: rgba(13, 40, 24, 0.55);
  --sa-glass-border: rgba(212, 175, 55, 0.22);
  --sa-font: 'Tajawal', system-ui, -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.hidden {
  display: none !important;
}

body.join-page {
  min-height: 100vh;
  background-color: var(--sa-bg);
  background-image: 
    radial-gradient(ellipse at 50% -10%, rgba(20, 89, 52, 0.45) 0%, transparent 70%),
    radial-gradient(circle at 10% 30%, rgba(212, 175, 55, 0.1) 0%, transparent 40%),
    radial-gradient(circle at 90% 70%, rgba(31, 164, 92, 0.12) 0%, transparent 50%),
    linear-gradient(180deg, #05160d 0%, #020a05 100%);
  background-attachment: fixed;
  color: #fff;
  font-family: var(--sa-font);
  direction: rtl;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 16px 14px 40px;
  position: relative;
  overflow-x: hidden;
}

/* Ambient glow blobs */
.join-ambient-blob {
  position: fixed;
  width: 450px;
  height: 450px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  filter: blur(90px);
  opacity: 0.35;
}
.join-ambient-top {
  top: -120px;
  right: 50%;
  transform: translateX(50%);
  background: radial-gradient(circle, #1a6b3a 0%, #0d3b22 100%);
}
.join-ambient-gold {
  bottom: 10%;
  left: -100px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.3) 0%, transparent 70%);
}

/* Container */
.join-container {
  width: 100%;
  max-width: 480px;
  position: relative;
  z-index: 1;
  margin: 0 auto;
}

/* Brand Header */
.join-brand-hero {
  text-align: center;
  padding: 24px 10px 20px;
  animation: saFadeDown 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.brand-emblem-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.25), rgba(13, 59, 34, 0.8));
  border: 1.5px solid rgba(212, 175, 55, 0.45);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), inset 0 0 16px rgba(212, 175, 55, 0.25);
  margin-bottom: 14px;
  position: relative;
}

.brand-emblem-wrap::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px dashed rgba(212, 175, 55, 0.3);
  animation: saRotateSlow 24s linear infinite;
}

.brand-emblem-icon {
  font-size: 2.2rem;
  line-height: 1;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.5));
}

.brand-heading-ar {
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, #ffffff 30%, #f6d365 75%, #d4af37 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 4px;
  text-shadow: 0 2px 14px rgba(212, 175, 55, 0.25);
}

.brand-heading-en {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 3.5px;
  color: var(--sa-gold-400);
  text-transform: uppercase;
  opacity: 0.88;
  margin-bottom: 12px;
}

/* Source Pill Badge */
.source-pill-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(212, 175, 55, 0.3);
  backdrop-filter: blur(10px);
  padding: 6px 16px;
  border-radius: 50px;
  font-size: 0.82rem;
  color: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.source-pill-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #27ae60;
  box-shadow: 0 0 0 rgba(39, 174, 96, 0.5);
  animation: saPulseDot 1.8s infinite;
}

/* Luxury Main Card */
.join-card {
  background: var(--sa-glass-bg);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid var(--sa-glass-border);
  border-radius: 24px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  padding: 26px 20px;
  margin-bottom: 24px;
  animation: saFadeUp 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.join-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent 0%, var(--sa-gold-500) 50%, transparent 100%);
}

/* Card Hero Teaser */
.card-teaser {
  text-align: center;
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.card-teaser-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.card-teaser-desc {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.5;
}

.teaser-features-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.feature-pill {
  font-size: 0.76rem;
  color: var(--sa-gold-300);
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid rgba(212, 175, 55, 0.22);
  border-radius: 30px;
  padding: 3px 12px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

/* Form Groups */
.form-field-group {
  margin-bottom: 18px;
}

.form-field-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.88rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 8px;
}

.label-req {
  color: var(--sa-gold-400);
  font-size: 0.8rem;
}

/* Input Containers */
.input-control-wrap {
  position: relative;
  display: flex;
  align-items: center;
  background: rgba(4, 20, 11, 0.65);
  border: 1.5px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  transition: all 0.25s ease;
  overflow: hidden;
}

.input-control-wrap:focus-within {
  border-color: var(--sa-gold-500);
  background: rgba(4, 20, 11, 0.85);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2), 0 8px 20px rgba(0, 0, 0, 0.4);
}

.input-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  font-size: 1.15rem;
  color: var(--sa-gold-400);
  pointer-events: none;
}

.input-field-core {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--sa-font);
  font-size: 1.05rem;
  font-weight: 600;
  color: #fff;
  padding: 15px 12px 15px 14px;
  min-height: 52px;
}

.input-field-core::placeholder {
  color: rgba(255, 255, 255, 0.35);
  font-weight: 400;
}

/* Language Switcher */
.join-lang-switch-wrap {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 8px;
}

.join-lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(212, 175, 55, 0.35);
  color: var(--sa-gold-300);
  border-radius: 30px;
  padding: 5px 14px;
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none;
  backdrop-filter: blur(8px);
  transition: all 0.2s ease;
}

.join-lang-btn:hover {
  background: rgba(212, 175, 55, 0.2);
  color: #fff;
  border-color: var(--sa-gold-500);
}

/* Phone Row Dual Select/Input (Strictly LTR in both AR & EN) */
.phone-composite-wrap {
  display: flex;
  gap: 10px;
  direction: ltr !important;
}

.country-select-wrap {
  width: 140px;
  flex-shrink: 0;
  position: relative;
  background: rgba(4, 20, 11, 0.65);
  border: 1.5px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  transition: all 0.25s ease;
  direction: ltr !important;
}

.phone-composite-wrap .input-control-wrap {
  direction: ltr !important;
}

.phone-composite-wrap .input-field-core {
  direction: ltr !important;
  text-align: left !important;
}

.country-select-wrap:focus-within {
  border-color: var(--sa-gold-500);
  background: rgba(4, 20, 11, 0.85);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

.country-select-core {
  width: 100%;
  height: 100%;
  min-height: 52px;
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-family: var(--sa-font);
  font-size: 0.95rem;
  font-weight: 700;
  padding: 0 12px;
  direction: ltr;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.country-select-core option {
  background: #0a2517;
  color: #fff;
  font-weight: 600;
  padding: 10px;
}

.country-select-arrow {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 0.7rem;
  color: var(--sa-gold-400);
}

/* Interests Grid (Interactive Chips) */
.interests-grid-modern {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.interest-chip-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.interest-chip-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(212, 175, 55, 0.4);
  transform: translateY(-1px);
}

.interest-chip-card.active,
.interest-chip-card:has(input:checked) {
  background: linear-gradient(135deg, rgba(20, 89, 52, 0.6) 0%, rgba(13, 59, 34, 0.8) 100%);
  border-color: var(--sa-gold-500);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3), inset 0 0 12px rgba(212, 175, 55, 0.15);
}

.chip-icon {
  font-size: 1.35rem;
  line-height: 1;
  flex-shrink: 0;
}

.chip-label {
  font-size: 0.83rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.3;
}

.interest-chip-card.active .chip-label,
.interest-chip-card:has(input:checked) .chip-label {
  color: #fff;
  font-weight: 700;
}

.chip-checkbox-hidden {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.chip-check-indicator {
  position: absolute;
  top: 8px;
  left: 8px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  color: transparent;
  transition: all 0.2s ease;
}

.interest-chip-card:has(input:checked) .chip-check-indicator {
  background: var(--sa-gold-500);
  border-color: var(--sa-gold-500);
  color: #04140b;
  font-weight: 900;
}

/* Privacy Consent Notice */
.privacy-consent-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 14px;
  margin-bottom: 22px;
  cursor: pointer;
}

.privacy-consent-box input[type="checkbox"] {
  accent-color: var(--sa-gold-500);
  width: 18px;
  height: 18px;
  margin-top: 2px;
  cursor: pointer;
}

.privacy-consent-text {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.45;
}

/* Luxury CTA Button */
.btn-submit-gold {
  width: 100%;
  min-height: 56px;
  background: var(--sa-gold-gradient);
  color: #081a10;
  border: none;
  border-radius: 16px;
  font-family: var(--sa-font);
  font-size: 1.15rem;
  font-weight: 900;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(212, 175, 55, 0.35), 0 2px 4px rgba(0, 0, 0, 0.3);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-submit-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(212, 175, 55, 0.45);
  filter: brightness(1.05);
}

.btn-submit-gold:active {
  transform: translateY(1px);
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.3);
}

.btn-submit-gold:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

/* Shine overlay */
.btn-submit-gold::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    60deg,
    transparent 20%,
    rgba(255, 255, 255, 0.45) 50%,
    transparent 80%
  );
  transform: rotate(25deg);
  animation: saShine 4s infinite;
}

/* Alert Notification */
.join-modern-alert {
  padding: 14px 16px;
  border-radius: 14px;
  font-size: 0.92rem;
  font-weight: 600;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: saFadeDown 0.3s ease;
}

.join-modern-alert.danger {
  background: rgba(220, 53, 69, 0.15);
  border: 1px solid rgba(220, 53, 69, 0.4);
  color: #ff8b94;
}

.join-modern-alert.success {
  background: rgba(39, 174, 96, 0.15);
  border: 1px solid rgba(39, 174, 96, 0.4);
  color: #6ee7a0;
}

/* ============================================================
   VIP Ticket (Success State)
   ============================================================ */
.vip-ticket-screen {
  text-align: center;
  animation: saFadeUp 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.ticket-celebrate-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(39, 174, 96, 0.2);
  border: 1px solid rgba(39, 174, 96, 0.4);
  color: #6ee7a0;
  border-radius: 50px;
  padding: 6px 18px;
  font-size: 0.88rem;
  font-weight: 700;
  margin-bottom: 14px;
}

.ticket-congrats-title {
  font-size: 1.8rem;
  font-weight: 900;
  color: #fff;
  margin-bottom: 6px;
}

.ticket-congrats-sub {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 22px;
}

/* Boarding Pass / Ticket Element */
.vip-digital-pass {
  background: linear-gradient(145deg, #092c19 0%, #04160c 100%);
  border: 2px solid var(--sa-gold-500);
  border-radius: 20px;
  padding: 24px 20px;
  position: relative;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7), 0 0 25px rgba(212, 175, 55, 0.25);
  overflow: hidden;
  margin-bottom: 20px;
}

.pass-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px dashed rgba(212, 175, 55, 0.3);
  padding-bottom: 14px;
  margin-bottom: 16px;
}

.pass-brand {
  font-weight: 900;
  color: var(--sa-gold-400);
  font-size: 1.05rem;
}

.pass-tag {
  background: rgba(212, 175, 55, 0.15);
  color: var(--sa-gold-300);
  border: 1px solid rgba(212, 175, 55, 0.3);
  padding: 2px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
}

.pass-label-small {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 4px;
}

.pass-participant-box {
  background: rgba(0, 0, 0, 0.45);
  border: 1.5px solid rgba(212, 175, 55, 0.4);
  border-radius: 14px;
  padding: 16px 12px;
  margin: 12px 0 16px;
}

.pass-number-highlight {
  font-size: 2.2rem;
  font-weight: 900;
  letter-spacing: 2px;
  color: var(--sa-gold-400);
  font-family: 'Tajawal', monospace;
  text-shadow: 0 0 15px rgba(212, 175, 55, 0.5);
  display: block;
}

.pass-user-meta {
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 10px 0;
  border-top: 1px dashed rgba(212, 175, 55, 0.3);
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.8);
}

.pass-barcode-graphic {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  height: 32px;
  margin-top: 14px;
  opacity: 0.75;
}

.bar-line {
  height: 100%;
  background: var(--sa-gold-400);
}

/* Ticket Action Buttons */
.pass-actions-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 18px;
}

.btn-pass-action {
  padding: 13px 14px;
  border-radius: 12px;
  font-family: var(--sa-font);
  font-size: 0.92rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-pass-copy {
  background: rgba(212, 175, 55, 0.15);
  border: 1.5px solid var(--sa-gold-500);
  color: var(--sa-gold-300);
}

.btn-pass-copy:hover {
  background: rgba(212, 175, 55, 0.28);
}

.btn-pass-winners {
  background: rgba(255, 255, 255, 0.08);
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  color: #fff;
}

.btn-pass-winners:hover {
  background: rgba(255, 255, 255, 0.15);
}

/* Footer */
.join-footer-links {
  text-align: center;
  margin-top: 24px;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.join-footer-links a {
  color: rgba(255, 255, 255, 0.65);
  text-decoration: none;
  transition: color 0.2s ease;
}

.join-footer-links a:hover {
  color: var(--sa-gold-400);
}

/* Confetti Container */
.confetti-canvas-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
}

/* Keyframes */
@keyframes saFadeDown {
  from { opacity: 0; transform: translateY(-16px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes saFadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes saRotateSlow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes saPulseDot {
  0% { box-shadow: 0 0 0 0 rgba(39, 174, 96, 0.6); }
  70% { box-shadow: 0 0 0 8px rgba(39, 174, 96, 0); }
  100% { box-shadow: 0 0 0 0 rgba(39, 174, 96, 0); }
}

@keyframes saShine {
  0% { transform: translateX(-100%) rotate(25deg); }
  35%, 100% { transform: translateX(200%) rotate(25deg); }
}

/* Mobile fine-tuning */
@media (max-width: 420px) {
  body.join-page {
    padding: 12px 10px 32px;
  }
  .join-card {
    padding: 22px 16px;
    border-radius: 20px;
  }
  .brand-heading-ar {
    font-size: 1.75rem;
  }
  .interests-grid-modern {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .pass-number-highlight {
    font-size: 1.85rem;
  }
  .pass-actions-grid {
    grid-template-columns: 1fr;
  }
}
