/* ========================================
   RESET & BASE STYLES
   ======================================== */

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

body {
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  color: rgba(255, 255, 255, 0.92);
  background:
    radial-gradient(900px 520px at 15% 10%, rgba(121, 64, 254, 0.16), transparent 60%),
    radial-gradient(700px 420px at 85% 20%, rgba(255, 255, 255, 0.06), transparent 55%),
    radial-gradient(900px 520px at 55% 90%, rgba(121, 64, 254, 0.10), transparent 60%),
    linear-gradient(180deg, #07090d, #0b0f17);
  text-align: center;
  padding: 20px;
}

/* ========================================
   ACCESSIBILITY - SKIP LINK
   ======================================== */

.skip-link {
  position: absolute;
  top: -48px;
  left: 8px;
  background: #7940FE;
  color: white;
  padding: 12px 20px;
  text-decoration: none;
  border-radius: 4px;
  font-weight: 600;
  z-index: 1000;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 8px;
  outline: 3px solid #ffffff;
  outline-offset: 2px;
}

/* ========================================
   ACCESSIBILITY - VISUALLY HIDDEN
   ======================================== */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ========================================
   ACCESSIBILITY - FOCUS INDICATORS
   ======================================== */

a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus {
  outline: 3px solid #7940FE;
  outline-offset: 2px;
}

a:focus:not(:focus-visible),
button:focus:not(:focus-visible) {
  outline: none;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid #7940FE;
  outline-offset: 2px;
}

/* ========================================
   LAYOUT
   ======================================== */

.container {
  max-width: 1200px;
  width: 100%;
  padding: 0 20px;
}

.logo {
  width: 120px;
  height: 120px;
  margin: 0 auto 32px;
  display: block;
  border-radius: 26px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.10);
  animation: fadeInScale 0.6s ease-out;
}

/* ========================================
   TYPOGRAPHY
   ======================================== */

h1 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
  animation: fadeIn 0.8s ease-out 0.2s both;
}

.subtitle {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.85); /* Improved from 0.70 for better contrast */
  margin-bottom: 40px;
  animation: fadeIn 0.8s ease-out 0.4s both;
}

.small-text {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.78); /* Improved from 0.55 for better contrast */
  margin-top: 20px;
}

.small {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.78);
  margin-top: 20px;
}

/* ========================================
   COMPONENTS - SPINNER
   ======================================== */

.spinner {
  border: 4px solid rgba(255, 255, 255, 0.2);
  border-top: 4px solid #7940FE;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  margin: 0 auto 40px;
  animation: spin 1s linear infinite;
}

/* ========================================
   COMPONENTS - INFO & BADGES
   ======================================== */

.info {
  animation: fadeIn 0.8s ease-out 0.6s both;
}

.coming-soon {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
  padding: 12px 24px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 12px;
  display: inline-block;
  backdrop-filter: blur(10px);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.40);
}

.app-store-badge {
  display: inline-block;
  width: 180px;
  margin-top: 24px;
  transition: transform 0.2s ease;
  opacity: 0.95;
}

.app-store-badge:hover,
.app-store-badge:focus {
  transform: scale(1.05);
  opacity: 1;
}

/* ========================================
   ANIMATIONS
   ======================================== */

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

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

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ========================================
   NAVIGATION
   ======================================== */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  margin-bottom: 40px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
  transition: opacity 0.2s ease;
}

.brand:hover,
.brand:focus {
  opacity: 0.8;
}

.brand-logo {
  width: 40px;
  height: 40px;
  border-radius: 8px;
}

.brand-name {
  font-size: 20px;
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 16px;
}

.nav-link {
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  font-size: 15px;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link:focus {
  color: rgba(255, 255, 255, 0.95);
}

.nav-link.active {
  color: #7940FE;
  font-weight: 600;
}

/* ========================================
   PILLS & BADGES
   ======================================== */

.pill {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
}

.pill.accent {
  background: rgba(121, 64, 254, 0.15);
  color: #b99aff;
  border: 1px solid rgba(121, 64, 254, 0.3);
}

.pill.subtle {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.10);
}

/* ========================================
   CARDS
   ======================================== */

.card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  padding: 40px 32px;
  backdrop-filter: blur(10px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  margin-bottom: 24px;
}

.hero {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 992px) {
  .hero {
    grid-template-columns: 2fr 1fr;
  }
  
  .hero .card:first-child {
    grid-column: 1;
  }
  
  .hero .sidebar {
    grid-column: 2;
  }
}

/* ========================================
   MAIN CONTENT
   ======================================== */

.h1 {
  font-size: 48px;
  font-weight: 800;
  line-height: 1.1;
  margin: 16px 0;
  letter-spacing: -0.03em;
}

.sub {
  font-size: 20px;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 32px;
}

/* ========================================
   BUTTONS & CTA
   ======================================== */

.cta-row {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 12px 28px;
  background: #7940FE;
  color: white;
  text-decoration: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  transition: all 0.2s ease;
  border: 2px solid transparent;
}

.btn:hover,
.btn:focus {
  background: #8a5aff;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(121, 64, 254, 0.4);
}

.btn.ghost {
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.92);
}

.btn.ghost:hover,
.btn.ghost:focus {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

/* ========================================
   FEATURES GRID
   ======================================== */

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 40px;
  text-align: left;
}

@media (min-width: 768px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.feature {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 24px;
  transition: all 0.2s ease;
}

.feature:hover,
.feature:focus-within {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(121, 64, 254, 0.3);
  transform: translateY(-2px);
}

.feature h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.95);
}

.feature p {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.5;
}

/* ========================================
   SIDEBAR
   ======================================== */

.sidebar {
  text-align: left;
}

.panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.panel-title h2 {
  font-size: 24px;
  font-weight: 700;
}

.kpis {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.kpi {
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.kpi:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.kpi .label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 6px;
  font-weight: 600;
}

.kpi .value {
  font-size: 20px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 8px;
}

.kpi .hint {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.5;
}

/* ========================================
   FOOTER
   ======================================== */

.footer {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.78);
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links {
  display: flex;
  gap: 20px;
}

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

.footer-links a:hover,
.footer-links a:focus {
  color: rgba(255, 255, 255, 0.95);
}

/* ========================================
   DOCUMENT PAGES (Terms/Privacy)
   ======================================== */

.doc {
  text-align: left;
  max-width: 900px;
  margin: 0 auto;
}

.doc h1 {
  font-size: 36px;
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.95);
}

.doc h2 {
  font-size: 24px;
  margin-top: 40px;
  margin-bottom: 16px;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 700;
}

.doc h3 {
  font-size: 20px;
  margin-top: 32px;
  margin-bottom: 12px;
  color: rgba(255, 255, 255, 0.90);
  font-weight: 600;
}

.doc p {
  margin-bottom: 16px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.85);
}

.doc ul,
.doc ol {
  margin-bottom: 16px;
  margin-left: 24px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.85);
}

.doc li {
  margin-bottom: 8px;
}

.doc a {
  color: #9b7dff;
  text-decoration: none;
  border-bottom: 1px solid rgba(155, 125, 255, 0.3);
  transition: all 0.2s ease;
}

.doc a:hover,
.doc a:focus {
  color: #b99aff;
  border-bottom-color: rgba(185, 154, 255, 0.6);
}

.doc strong {
  font-weight: 700;
  color: rgba(255, 255, 255, 0.95);
}

.doc em {
  font-style: italic;
}

.meta {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.65);
  margin-bottom: 32px;
}

/* ========================================
   TABLES
   ======================================== */

.doc table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  overflow: hidden;
}

.doc thead {
  background: rgba(121, 64, 254, 0.1);
}

.doc th {
  padding: 14px 16px;
  text-align: left;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.95);
  border-bottom: 2px solid rgba(255, 255, 255, 0.12);
}

.doc td {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.85);
}

.doc tbody tr:last-child td {
  border-bottom: none;
}

.doc tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

/* ========================================
   RESPONSIVE - TABLET & MOBILE
   ======================================== */

@media (min-width: 1400px) {
  .container {
    max-width: 1400px;
  }
}

@media (min-width: 769px) and (max-width: 991px) {
  .hero {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .nav {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .nav-links {
    flex-wrap: wrap;
    justify-content: center;
  }

  .h1 {
    font-size: 36px;
  }

  .sub {
    font-size: 18px;
  }

  .footer {
    flex-direction: column;
    text-align: center;
  }

  .doc table {
    font-size: 14px;
  }

  .doc th,
  .doc td {
    padding: 10px 12px;
  }
}

@media (max-width: 480px) {
  .logo {
    width: 100px;
    height: 100px;
  }

  h1 {
    font-size: 28px;
  }

  .h1 {
    font-size: 32px;
  }

  .subtitle,
  .sub {
    font-size: 16px;
  }

  .card {
    padding: 28px 20px;
  }

  .cta-row {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .doc h1 {
    font-size: 28px;
  }

  .doc h2 {
    font-size: 22px;
  }

  .doc h3 {
    font-size: 18px;
  }

  /* Make tables scrollable on very small screens */
  .doc table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}

/* ========================================
   PRINT STYLES
   ======================================== */

@media print {
  .skip-link,
  .nav,
  .footer,
  .cta-row {
    display: none;
  }

  body {
    background: white;
    color: black;
  }

  .card {
    border: 1px solid #ccc;
    box-shadow: none;
  }
}

/* ========================================
   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 {
    transition: none;
  }
}