/* ============================================
   SKY — Waitlist Page
   ============================================ */

/* --- CSS Variables --- */
:root {
  --color-bg: #0B1120;
  --color-bg-alt: #111827;
  --color-primary: #06B6D4;
  --color-primary-light: #7DD3FC;
  --color-primary-dim: rgba(6, 182, 212, 0.12);
  --color-secondary: #3B82F6;
  --color-secondary-dim: rgba(59, 130, 246, 0.12);
  --color-accent: #7DD3FC;
  --color-text: #FFFFFF;
  --color-text-muted: #94A3B8;
  --color-border: rgba(255, 255, 255, 0.08);
  --color-border-focus: var(--color-primary);
  --font-main: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Space Grotesk', 'Inter', sans-serif;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --shadow-glow: 0 0 60px rgba(6, 182, 212, 0.15);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.5);
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --max-width: 600px;
}

/* --- Reset --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-main);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(6, 182, 212, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 20% 80%, rgba(59, 130, 246, 0.05) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 70%, rgba(125, 211, 252, 0.05) 0%, transparent 50%),
    linear-gradient(180deg, #0B1120 0%, #111827 50%, #0B1120 100%);
  color: var(--color-text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* --- Skip Link --- */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 10002;
  padding: 12px 24px;
  background: var(--color-primary);
  color: var(--color-bg);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}
.skip-link:focus {
  top: 16px;
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

/* --- Stars Layer (static stars) --- */
.stars-layer {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.stars-layer::before {
  content: '';
  position: absolute;
  width: 2px;
  height: 2px;
  background: white;
  border-radius: 50%;
  box-shadow:
    5vw 8vh 0 0 rgba(255,255,255,0.5),
    12vw 15vh 0 0 rgba(255,255,255,0.4),
    22vw 5vh 0 0 rgba(255,255,255,0.6),
    35vw 22vh 0 0 rgba(255,255,255,0.4),
    48vw 12vh 0 0 rgba(255,255,255,0.5),
    55vw 28vh 0 0 rgba(255,255,255,0.4),
    65vw 8vh 0 0 rgba(255,255,255,0.6),
    78vw 18vh 0 0 rgba(255,255,255,0.4),
    88vw 25vh 0 0 rgba(255,255,255,0.5),
    8vw 35vh 0 0 rgba(255,255,255,0.4),
    18vw 42vh 0 0 rgba(255,255,255,0.5),
    28vw 38vh 0 0 rgba(255,255,255,0.4),
    42vw 45vh 0 0 rgba(255,255,255,0.6),
    58vw 35vh 0 0 rgba(255,255,255,0.4),
    72vw 42vh 0 0 rgba(255,255,255,0.5),
    85vw 38vh 0 0 rgba(255,255,255,0.4),
    95vw 50vh 0 0 rgba(255,255,255,0.5),
    3vw 55vh 0 0 rgba(255,255,255,0.4),
    15vw 62vh 0 0 rgba(255,255,255,0.5),
    32vw 58vh 0 0 rgba(255,255,255,0.4),
    45vw 65vh 0 0 rgba(255,255,255,0.6),
    62vw 55vh 0 0 rgba(255,255,255,0.4),
    75vw 68vh 0 0 rgba(255,255,255,0.5),
    90vw 60vh 0 0 rgba(255,255,255,0.4);
  animation: twinkle 4s ease-in-out infinite;
}

.stars-layer::after {
  content: '';
  position: absolute;
  width: 1px;
  height: 1px;
  background: white;
  border-radius: 50%;
  box-shadow:
    10vw 12vh 0 0 rgba(255,255,255,0.4),
    25vw 8vh 0 0 rgba(255,255,255,0.5),
    40vw 18vh 0 0 rgba(255,255,255,0.4),
    52vw 5vh 0 0 rgba(255,255,255,0.6),
    68vw 15vh 0 0 rgba(255,255,255,0.4),
    82vw 10vh 0 0 rgba(255,255,255,0.5),
    20vw 32vh 0 0 rgba(255,255,255,0.4),
    38vw 40vh 0 0 rgba(255,255,255,0.5),
    50vw 52vh 0 0 rgba(255,255,255,0.4),
    70vw 48vh 0 0 rgba(255,255,255,0.6),
    92vw 55vh 0 0 rgba(255,255,255,0.4),
    6vw 72vh 0 0 rgba(255,255,255,0.5),
    25vw 78vh 0 0 rgba(255,255,255,0.4),
    55vw 75vh 0 0 rgba(255,255,255,0.5),
    80vw 82vh 0 0 rgba(255,255,255,0.4),
    96vw 88vh 0 0 rgba(255,255,255,0.5);
  animation: twinkle 4s ease-in-out infinite 2s;
}

@keyframes twinkle {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

/* --- GSAP Animated Particles --- */
#particles-container {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.gsap-particle {
  position: absolute;
  width: 3px;
  height: 3px;
  background: radial-gradient(circle, rgba(255,255,255,0.9), rgba(0,180,255,0.5), transparent 70%);
  border-radius: 50%;
  box-shadow: 0 0 6px rgba(255,255,255,0.5), 0 0 12px rgba(0,150,255,0.3);
}

/* --- Light Rays --- */
.ray {
  position: absolute;
  top: -100px;
  background: linear-gradient(180deg, rgba(200,230,255,0.1) 0%, transparent 80%);
  transform-origin: top center;
  pointer-events: none;
  z-index: 0;
}

.ray-1 {
  left: 12%;
  width: 70px;
  height: 600px;
  transform: rotate(18deg);
  animation: ray-fade 4.5s ease-in-out infinite alternate;
}

.ray-2 {
  left: 30%;
  width: 45px;
  height: 700px;
  transform: rotate(6deg);
  animation: ray-fade 5s ease-in-out infinite alternate-reverse;
}

.ray-3 {
  left: 52%;
  width: 90px;
  height: 500px;
  transform: rotate(-4deg);
  animation: ray-fade 3.8s ease-in-out infinite alternate;
}

.ray-4 {
  left: 72%;
  width: 55px;
  height: 620px;
  transform: rotate(-14deg);
  animation: ray-fade 5.5s ease-in-out infinite alternate-reverse;
}

@keyframes ray-fade {
  0% { opacity: 0.4; }
  100% { opacity: 0.8; }
}

/* --- Ambient Background --- */
.ambient-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0;
  display: none;
}

.orb-1, .orb-2, .orb-3 {
  display: none;
}

@keyframes float-orb {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -30px) scale(1.05); }
  66% { transform: translate(-20px, 20px) scale(0.95); }
}

@keyframes pulse-orb {
  0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.4; }
  50% { transform: translate(-50%, -50%) scale(1.2); opacity: 0.6; }
}



/* --- Main Content --- */
main {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 4vh 24px 60px;
}

/* --- Hero --- */
.hero {
  width: 100%;
  max-width: var(--max-width);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: 0;
  gap: 0;
}

/* --- Badge --- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  background: var(--color-primary-dim);
  border: 1px solid rgba(0, 212, 255, 0.3);
  border-radius: 100px;
  margin-bottom: 32px;
}

.badge-icon {
  font-size: 14px;
}

.badge-text {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-primary);
}

/* --- Sky AI Title --- */
.sky-ai-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 24px;
  position: relative;
  z-index: 2;
}

.sky-ai-text {
  font-family: var(--font-display);
  font-size: clamp(28px, 5vw, 42px);
  font-weight: 700;
  letter-spacing: 6px;
  text-transform: uppercase;
  color: #ffffff;
}

.sky-ai-accent {
  font-family: var(--font-display);
  font-size: clamp(28px, 5vw, 42px);
  font-weight: 700;
  letter-spacing: 2px;
  color: #06B6D4;
  padding: 4px 16px;
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.3);
  border-radius: 6px;
}

/* --- SKY Logo Center --- */
.sky-logo-center {
  position: relative;
  width: clamp(320px, 85vw, 700px);
  margin: 0 auto 30px;
}

.sky-logo-main {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 0 100px rgba(6, 182, 212, 0.6));
}

/* --- Tagline Overlay on Logo --- */
.tagline-overlay {
  position: absolute;
  top: 48%;
  left: 54%;
  transform: translate(-50%, -50%);
  text-align: center;
  z-index: 2;
  width: 65%;
}

.tagline-text {
  font-family: var(--font-display);
  font-size: clamp(16px, 3.5vw, 28px);
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #ffffff;
  text-shadow: 0 0 20px rgba(6, 182, 212, 0.8), 0 0 40px rgba(6, 182, 212, 0.4);
  white-space: nowrap;
}

@media (max-width: 640px) {
  .sky-logo-center {
    width: clamp(240px, 75vw, 400px);
  }
  .tagline-text {
    font-size: clamp(12px, 3vw, 18px);
    letter-spacing: 2px;
  }
}

/* --- Discover Text --- */
.discover-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin-bottom: 40px;
  text-align: center;
  width: 100%;
  max-width: 700px;
}

.discover-line {
  font-family: var(--font-display);
  font-size: clamp(24px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  text-shadow: 0 0 30px rgba(6, 182, 212, 0.5), 0 2px 4px rgba(0, 0, 0, 0.3);
  line-height: 1.2;
  background: linear-gradient(90deg, #06B6D4, #ffffff, #06B6D4);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: text-gradient 4s linear infinite;
}

@keyframes text-gradient {
  0% { background-position: 0% center; }
  100% { background-position: 200% center; }
}

/* --- Divider --- */
.divider {
  width: 80px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--color-primary), transparent);
  margin: 0 auto 40px;
  border-radius: 2px;
}

/* --- Waitlist Section --- */
.waitlist-section {
  width: 100%;
  max-width: 540px;
  background: linear-gradient(180deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.01) 100%);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: 48px 40px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-card);
  margin-top: auto;
}

@media (max-width: 640px) {
  .waitlist-section {
    padding: 32px 24px;
    border-radius: var(--radius-lg);
  }
}

.waitlist-title {
  font-family: var(--font-display);
  font-size: clamp(24px, 5vw, 32px);
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 8px;
}

.waitlist-subtitle {
  font-size: 16px;
  color: var(--color-text-muted);
  margin-bottom: 28px;
}

/* --- Trust Badges --- */
.trust-badges {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 28px;
}

.trust-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 20px;
  background: rgba(0, 150, 255, 0.08);
  border: 1px solid rgba(0, 150, 255, 0.2);
  border-radius: var(--radius-md);
  color: #7ec8e3;
  font-size: 13px;
  font-weight: 500;
}

.trust-badge svg {
  flex-shrink: 0;
}

/* --- Form --- */
.waitlist-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 480px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
}

.form-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text-muted);
  letter-spacing: 0.5px;
}

.form-input {
  width: 100%;
  padding: 14px 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text);
  font-family: var(--font-main);
  font-size: 16px;
  transition: var(--transition);
  min-height: 48px;
}

.form-input::placeholder {
  color: rgba(148, 163, 184, 0.5);
}

.form-input:hover {
  border-color: rgba(255, 255, 255, 0.15);
}

.form-input:focus {
  outline: none;
  border-color: var(--color-border-focus);
  background: rgba(0, 212, 255, 0.05);
  box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.1);
}

.form-input.error {
  border-color: #EF4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

/* --- Consent Checkbox --- */
.consent-group {
  padding: 4px 0;
}

.consent-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  cursor: pointer;
  text-align: left;
}

.consent-checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.checkbox-mark {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border: 2px solid var(--color-border);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.02);
  transition: var(--transition);
  position: relative;
  margin-top: 2px;
}

.consent-checkbox input[type="checkbox"]:checked + .checkbox-mark {
  background: var(--color-primary);
  border-color: var(--color-primary);
}

.consent-checkbox input[type="checkbox"]:checked + .checkbox-mark::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 2px;
  width: 6px;
  height: 12px;
  border: solid var(--color-bg);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.consent-checkbox input[type="checkbox"]:focus-visible + .checkbox-mark {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

.consent-checkbox input[type="checkbox"]:checked + .checkbox-mark {
  background: #0099cc;
  border-color: #0099cc;
}

.consent-text {
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.consent-link {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.consent-link:hover {
  color: #7ec8e3;
}

.consent-optional .consent-text {
  font-style: italic;
  opacity: 0.8;
}

/* --- Submit Button --- */
.btn-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 16px 32px;
  min-height: 56px;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  border: none;
  border-radius: var(--radius-md);
  color: var(--color-bg);
  font-family: var(--font-main);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  margin-top: 8px;
}

.btn-submit::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.2) 0%, transparent 50%);
  opacity: 0;
  transition: var(--transition);
}

.btn-submit:hover::before {
  opacity: 1;
}

.btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 212, 255, 0.4);
}

.btn-submit:active {
  transform: translateY(0);
}

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

.btn-icon {
  display: flex;
  transition: var(--transition);
}

.btn-submit:hover .btn-icon {
  transform: translateX(4px);
}

/* --- Success Modal Popup --- */
.success-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.success-modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 13, 26, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: backdrop-in 0.3s ease-out;
}

@keyframes backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-content {
  position: relative;
  background: linear-gradient(180deg, rgba(0, 40, 80, 0.8) 0%, rgba(0, 20, 50, 0.9) 100%);
  border: 1px solid rgba(0, 150, 255, 0.3);
  border-radius: var(--radius-xl);
  padding: 48px 40px;
  text-align: center;
  max-width: 420px;
  width: 100%;
  box-shadow: 0 0 80px rgba(0, 150, 255, 0.3), 0 20px 60px rgba(0, 0, 0, 0.5);
  animation: modal-pop 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes modal-pop {
  0% { opacity: 0; transform: scale(0.8) translateY(20px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-icon {
  color: var(--color-primary);
  margin-bottom: 24px;
  animation: success-glow 2s ease-in-out infinite;
}

@keyframes success-glow {
  0%, 100% { filter: drop-shadow(0 0 20px rgba(0, 150, 255, 0.5)); }
  50% { filter: drop-shadow(0 0 40px rgba(0, 150, 255, 0.8)); }
}

.modal-title {
  font-family: var(--font-display);
  font-size: clamp(24px, 5vw, 32px);
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 16px;
  text-shadow: 0 0 20px rgba(0, 150, 255, 0.5);
}

.modal-position {
  font-family: var(--font-display);
  font-size: clamp(48px, 10vw, 72px);
  font-weight: 900;
  background: linear-gradient(135deg, #00D4FF 0%, #ffffff 50%, #00D4FF 100%);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-shift 3s ease-in-out infinite;
  margin-bottom: 16px;
  line-height: 1;
}

@keyframes gradient-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.modal-text {
  font-size: 16px;
  color: var(--color-text-muted);
  margin-bottom: 0;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: var(--transition);
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  transform: rotate(90deg);
}

/* --- Reveal Animations (initial state for JS) --- */
.reveal-item {
  opacity: 1;
}

/* --- Focus Styles --- */
*:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

/* --- Custom Scrollbar --- */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg);
}

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.2);
}
