@import url("./tokens.css");

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

body {
  font-family: var(--yorovr-font-sans);
  line-height: 1.6;
  color: var(--yorovr-color-text-primary);
  background-color: var(--yorovr-color-surface-50);
  text-rendering: optimizeLegibility;
}

.container {
  max-width: var(--yorovr-layout-content-max);
  margin: 0 auto;
  padding: 0 var(--yorovr-layout-gutter);
}

.hidden {
  display: none !important;
}

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

.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--yorovr-color-surface-inverse);
  color: var(--yorovr-color-text-inverse);
  padding: var(--yorovr-space-2) var(--yorovr-space-4);
  text-decoration: none;
  font-weight: 700;
  z-index: 100;
  border-radius: var(--yorovr-radius-md);
  transition: top var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard);
  border: 2px solid var(--yorovr-color-brand-500);
}

.skip-link:focus {
  top: var(--yorovr-space-2);
  outline: 2px solid var(--yorovr-color-text-inverse);
  outline-offset: 2px;
}

/* Hero Section */
.hero {
  background: linear-gradient(
    140deg,
    var(--yorovr-color-surface-inverse) 0%,
    rgba(16, 16, 16, 0.92) 100%
  );
  color: var(--yorovr-color-text-inverse);
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: var(--yorovr-space-20) 0;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    url("../../doc/design/placeholders/hero_glow_light.svg") center/cover
      no-repeat,
    radial-gradient(
      circle at 20% 20%,
      rgba(79, 125, 255, 0.32),
      transparent 60%
    ),
    radial-gradient(
      circle at 80% 0%,
      rgba(239, 111, 46, 0.28),
      transparent 55%
    );
  opacity: 0.8;
  pointer-events: none;
  animation: heroGlow var(--yorovr-motion-extended)
    var(--yorovr-motion-ease-standard) infinite alternate;
}

@keyframes heroGlow {
  0% {
    transform: scale(1);
    opacity: 0.8;
  }
  100% {
    transform: scale(1.05);
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero::before,
  .cta-button,
  .share-button,
  .email-input {
    animation: none;
    transition: none;
  }

  .cta-button:hover,
  .email-input:focus {
    transform: none;
  }
}

.hero-content {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--yorovr-space-12);
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-title {
  font-size: var(--yorovr-type-display-md-size);
  line-height: var(--yorovr-type-display-md-line);
  font-weight: 700;
  letter-spacing: -0.05em;
  margin-bottom: var(--yorovr-space-4);
  text-shadow: 0 16px 40px rgba(2, 2, 2, 0.36);
}

.highlight {
  background: linear-gradient(
    45deg,
    var(--yorovr-color-brand-500),
    var(--yorovr-color-accent-electric)
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: var(--yorovr-type-body-lg-size);
  line-height: var(--yorovr-type-body-lg-line);
  margin-bottom: var(--yorovr-space-6);
  color: var(--yorovr-color-text-inverse-secondary);
  max-width: 36rem;
}

/* Waitlist Form */
.waitlist-form {
  margin-bottom: var(--yorovr-space-4);
}

.form-group {
  display: flex;
  gap: var(--yorovr-space-3);
  margin-bottom: var(--yorovr-space-3);
}

.email-input {
  flex: 1;
  padding: var(--yorovr-space-3) var(--yorovr-space-4);
  font-size: var(--yorovr-type-body-md-size);
  border: 1px solid var(--yorovr-color-overlay-border);
  border-radius: var(--yorovr-radius-xl);
  background-color: var(--yorovr-color-overlay-light);
  color: var(--yorovr-color-text-inverse);
  transition:
    border var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard),
    box-shadow var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard),
    transform var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard);
  backdrop-filter: blur(10px);
}

.email-input::placeholder {
  color: rgba(246, 244, 243, 0.52);
}

.email-input:focus {
  outline: none;
  transform: translateY(-2px);
  border-color: var(--yorovr-color-brand-500);
  box-shadow: 0 18px 36px rgba(239, 111, 46, 0.28);
}

.cta-button,
.share-button {
  padding: var(--yorovr-space-3) var(--yorovr-space-5);
  font-family: var(--yorovr-font-mono);
  font-size: var(--yorovr-type-body-md-size);
  font-weight: 600;
  border: none;
  border-radius: var(--yorovr-radius-lg);
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: var(--yorovr-type-label-letter-tight);
  transition:
    transform var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard),
    box-shadow var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard),
    background var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard);
  position: relative;
  overflow: hidden;
}

.cta-button {
  background: linear-gradient(
    45deg,
    var(--yorovr-color-brand-500),
    var(--yorovr-color-brand-600)
  );
  color: var(--yorovr-color-brand-on-inverse);
  white-space: nowrap;
  box-shadow: var(--yorovr-shadow-strong);
}

.cta-button::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 7px,
    rgba(255, 255, 255, 0.08) 7px,
    rgba(255, 255, 255, 0.08) 14px
  );
  opacity: 0;
  transition: opacity var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard);
}

.cta-button:hover {
  transform: translateY(-3px);
}

.cta-button:hover::before {
  opacity: 1;
}

.cta-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.form-note {
  font-size: var(--yorovr-type-body-sm-size);
  color: var(--yorovr-color-text-inverse-secondary);
  text-align: center;
}

/* Success State */
.success-state {
  text-align: center;
  background: rgba(255, 255, 255, 0.12);
  padding: var(--yorovr-space-6);
  border-radius: var(--yorovr-radius-3xl);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(18px);
}

.success-state.hidden {
  display: none;
}

.success-icon {
  font-size: 3rem;
  margin-bottom: var(--yorovr-space-2);
}

.share-button {
  background: rgba(255, 255, 255, 0.16);
  color: var(--yorovr-color-text-inverse);
  border: 1px solid rgba(255, 255, 255, 0.24);
  margin-top: var(--yorovr-space-3);
}

.share-button:hover {
  transform: translateY(-2px);
}

/* Player Card */
.hero-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.player-card {
  background: linear-gradient(
    135deg,
    var(--yorovr-color-surface-inverse) 0%,
    var(--yorovr-color-surface-inverse-alt) 100%
  );
  border-radius: var(--yorovr-radius-3xl);
  padding: var(--yorovr-space-8);
  color: var(--yorovr-color-text-inverse);
  width: 100%;
  max-width: 320px;
  box-shadow: var(--yorovr-shadow-strong);
  position: relative;
  overflow: hidden;
  animation: cardFloat var(--yorovr-motion-extended)
    var(--yorovr-motion-ease-standard) infinite alternate;
}

@keyframes cardFloat {
  0%,
  100% {
    transform: translateY(0) rotate(-1deg);
  }
  50% {
    transform: translateY(-12px) rotate(1deg);
  }
}

.player-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(79, 125, 255, 0.2),
    rgba(239, 111, 46, 0.25),
    rgba(79, 125, 255, 0.2)
  );
  background-size: 200% 100%;
  animation: shimmer 3s var(--yorovr-motion-ease-standard) infinite;
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--yorovr-space-3);
}

.player-name {
  font-size: var(--yorovr-type-heading-lg-size);
  font-weight: 700;
  margin-bottom: var(--yorovr-space-1);
}

.player-position {
  font-size: var(--yorovr-type-body-sm-size);
  color: rgba(246, 244, 243, 0.72);
  letter-spacing: var(--yorovr-type-label-letter-tight);
}

.ovr-badge {
  background: linear-gradient(
    135deg,
    var(--yorovr-color-brand-500),
    var(--yorovr-color-brand-600)
  );
  border-radius: 50%;
  width: 70px;
  height: 70px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--yorovr-color-brand-on-inverse);
}

.ovr-number {
  font-size: 1.8rem;
  font-weight: 800;
  line-height: 1;
}

.ovr-label {
  font-size: var(--yorovr-type-label-xs-size);
  font-weight: 600;
  letter-spacing: var(--yorovr-type-label-letter-tight);
  opacity: 0.85;
}

.tier-badge {
  display: inline-block;
  padding: var(--yorovr-space-2) var(--yorovr-space-4);
  border-radius: var(--yorovr-radius-pill);
  font-size: var(--yorovr-type-body-sm-size);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--yorovr-type-label-letter-tight);
  margin-bottom: var(--yorovr-space-5);
}

.tier-badge.gold {
  background: linear-gradient(
    135deg,
    #ffb547,
    var(--yorovr-color-accent-highlight)
  );
  color: var(--yorovr-color-brand-on-inverse);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--yorovr-space-3);
  margin-bottom: var(--yorovr-space-3);
}

.stat {
  text-align: center;
}

.stat-value {
  display: block;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--yorovr-color-accent-electric);
}

.stat-label {
  font-size: var(--yorovr-type-label-xs-size);
  letter-spacing: var(--yorovr-type-label-letter-tight);
  text-transform: uppercase;
  color: rgba(246, 244, 243, 0.7);
}

.matches-played {
  text-align: center;
  font-size: var(--yorovr-type-body-sm-size);
  color: rgba(246, 244, 243, 0.7);
  padding-top: var(--yorovr-space-3);
  border-top: 1px solid rgba(246, 244, 243, 0.12);
}

/* Progress Animation */
.progress-demo {
  margin-top: var(--yorovr-space-6);
  text-align: center;
  animation: bounce 2s var(--yorovr-motion-ease-standard) infinite;
}

@keyframes bounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

.progress-text {
  background: linear-gradient(
    135deg,
    var(--yorovr-color-accent-electric),
    #3ac7f3
  );
  color: var(--yorovr-color-brand-on-inverse);
  padding: var(--yorovr-space-3) var(--yorovr-space-4);
  border-radius: var(--yorovr-radius-pill);
  font-weight: 600;
  display: inline-block;
  margin-bottom: var(--yorovr-space-2);
}

.arrow-up {
  font-size: 2rem;
  color: var(--yorovr-color-accent-electric);
}

/* Features Section */
.features {
  padding: var(--yorovr-space-20) 0;
  background: #f8f9ff;
}

.features h2 {
  text-align: center;
  font-size: var(--yorovr-type-heading-xl-size);
  font-weight: 700;
  margin-bottom: var(--yorovr-space-8);
  color: var(--yorovr-color-text-primary);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--yorovr-space-6);
}

.feature {
  background: var(--yorovr-color-surface-0);
  padding: var(--yorovr-space-6);
  border-radius: var(--yorovr-radius-2xl);
  text-align: center;
  box-shadow: var(--yorovr-shadow-soft);
  transition: transform var(--yorovr-motion-normal)
    var(--yorovr-motion-ease-standard);
}

.feature:hover {
  transform: translateY(-10px);
}

.feature-icon {
  font-size: 3rem;
  margin-bottom: var(--yorovr-space-3);
}

.feature h3 {
  font-size: var(--yorovr-type-heading-md-size);
  font-weight: 600;
  margin-bottom: var(--yorovr-space-3);
  color: var(--yorovr-color-text-primary);
}

.feature p {
  color: var(--yorovr-color-text-secondary);
  line-height: 1.6;
}

/* Social Proof */
.social-proof {
  padding: var(--yorovr-space-16) 0;
  background: var(--yorovr-color-surface-0);
  text-align: center;
}

.testimonial {
  max-width: 600px;
  margin: 0 auto var(--yorovr-space-8) auto;
}

.testimonial p {
  font-size: var(--yorovr-type-heading-lg-size);
  font-style: italic;
  color: var(--yorovr-color-text-primary);
  margin-bottom: var(--yorovr-space-3);
}

.testimonial cite {
  font-size: var(--yorovr-type-body-md-size);
  color: var(--yorovr-color-text-secondary);
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--yorovr-space-6);
}

.stat-item {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 3rem;
  font-weight: 800;
  color: var(--yorovr-color-accent-electric);
  margin-bottom: var(--yorovr-space-2);
}

.stat-text {
  font-size: var(--yorovr-type-body-sm-size);
  color: var(--yorovr-color-text-secondary);
  text-transform: uppercase;
  letter-spacing: var(--yorovr-type-label-letter-tight);
}

/* Footer CTA */
.footer-cta {
  padding: var(--yorovr-space-16) 0;
  background: linear-gradient(
    135deg,
    var(--yorovr-color-surface-inverse-alt) 0%,
    var(--yorovr-color-brand-500) 100%
  );
  color: var(--yorovr-color-brand-on-inverse);
  text-align: center;
}

.footer-cta h2 {
  font-size: var(--yorovr-type-heading-xl-size);
  font-weight: 700;
  margin-bottom: var(--yorovr-space-4);
}

.footer-cta p {
  font-size: var(--yorovr-type-body-lg-size);
  margin-bottom: var(--yorovr-space-6);
  color: rgba(255, 255, 255, 0.85);
}

.footer-form {
  display: flex;
  justify-content: center;
  gap: var(--yorovr-space-3);
  max-width: 500px;
  margin: 0 auto;
}

.footer-form input {
  flex: 1;
  padding: var(--yorovr-space-3) var(--yorovr-space-4);
  border: none;
  border-radius: var(--yorovr-radius-xl);
  font-size: var(--yorovr-type-body-md-size);
}

.footer-form button {
  padding: var(--yorovr-space-3) var(--yorovr-space-5);
  background: linear-gradient(
    45deg,
    var(--yorovr-color-brand-500),
    var(--yorovr-color-brand-600)
  );
  color: var(--yorovr-color-brand-on-inverse);
  border: none;
  border-radius: var(--yorovr-radius-xl);
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--yorovr-motion-fast)
    var(--yorovr-motion-ease-standard);
}

.footer-form button:hover {
  transform: translateY(-2px);
}

/* Footer */
.footer {
  background: var(--yorovr-color-surface-inverse-alt);
  color: var(--yorovr-color-text-inverse);
  padding: var(--yorovr-space-10) 0;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-brand h3 {
  font-size: var(--yorovr-type-heading-md-size);
  font-weight: 700;
  margin-bottom: var(--yorovr-space-2);
}

.footer-brand p {
  color: rgba(246, 244, 243, 0.64);
}

.footer-links {
  display: flex;
  gap: var(--yorovr-space-6);
}

.footer-links a {
  color: var(--yorovr-color-text-inverse);
  text-decoration: none;
  opacity: 0.7;
  transition: opacity var(--yorovr-motion-fast)
    var(--yorovr-motion-ease-standard);
}

.footer-links a:hover {
  opacity: 1;
}

/* Loading Spinner */
.loading-spinner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--yorovr-space-2);
  font-size: var(--yorovr-type-body-sm-size);
  color: var(--yorovr-color-text-inverse);
}

.loading-spinner::before {
  content: "";
  width: 18px;
  height: 18px;
  margin: -10px 0 0 -10px;
  border: 2px solid transparent;
  border-top: 2px solid var(--yorovr-color-text-inverse);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

/* Feedback States */
.error {
  border: 2px solid var(--yorovr-color-state-error) !important;
  background-color: rgba(224, 67, 76, 0.12) !important;
}

.form-message {
  font-size: var(--yorovr-type-body-sm-size);
  margin-top: var(--yorovr-space-2);
  text-align: center;
  line-height: 1.4;
}

.form-message.is-error {
  color: var(--yorovr-color-state-error);
}

.form-message.is-success {
  color: var(--yorovr-color-state-success);
}

/* Toast */
.yo-toast {
  position: fixed;
  bottom: var(--yorovr-space-6);
  right: var(--yorovr-space-6);
  background: rgba(16, 16, 16, 0.92);
  color: var(--yorovr-color-text-inverse);
  padding: var(--yorovr-space-3) var(--yorovr-space-4);
  border-radius: var(--yorovr-radius-lg);
  box-shadow: var(--yorovr-shadow-soft);
  opacity: 0;
  transform: translateY(var(--yorovr-space-3));
  transition:
    opacity var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard),
    transform var(--yorovr-motion-fast) var(--yorovr-motion-ease-standard);
  z-index: 1000;
}

.yo-toast.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive Design */
@media (max-width: var(--yorovr-breakpoint-md)) {
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: var(--yorovr-space-8);
  }

  .hero-title {
    font-size: var(--yorovr-type-heading-xl-size);
  }

  .hero-subtitle {
    margin: 0 auto var(--yorovr-space-6);
  }

  .form-group {
    flex-direction: column;
  }

  .cta-button {
    width: 100%;
  }

  .player-card {
    max-width: 280px;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .stats {
    grid-template-columns: repeat(3, 1fr);
  }

  .footer-form {
    flex-direction: column;
  }

  .footer-content {
    flex-direction: column;
    gap: var(--yorovr-space-6);
    text-align: center;
  }

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

@media (max-width: 480px) {
  .container {
    padding: 0 var(--yorovr-space-3);
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1.1rem;
  }

  .features h2,
  .footer-cta h2 {
    font-size: 2rem;
  }
}

@media (prefers-color-scheme: dark) {
  .hero::before {
    background:
      url("../../doc/design/placeholders/hero_glow_dark.svg") center/cover
        no-repeat,
      radial-gradient(
        circle at 20% 20%,
        rgba(131, 163, 255, 0.18),
        transparent 60%
      ),
      radial-gradient(
        circle at 75% 5%,
        rgba(255, 122, 51, 0.22),
        transparent 55%
      );
  }
}
/* Data tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--yorovr-space-6) 0;
  background-color: var(--yorovr-color-surface-0);
  color: var(--yorovr-color-text-primary);
  border-radius: var(--yorovr-radius-lg);
  overflow: hidden;
}

table thead th {
  text-transform: uppercase;
  letter-spacing: -0.02em;
  font-family: var(--yorovr-font-mono);
  font-weight: 600;
  padding: var(--yorovr-space-3) var(--yorovr-space-5);
  background-color: var(--yorovr-color-surface-100);
  border-bottom: 1px solid var(--yorovr-color-border);
}

table tbody td {
  padding: var(--yorovr-space-3) var(--yorovr-space-5);
  border-bottom: 1px solid var(--yorovr-color-border);
}

table tbody tr:nth-child(odd) {
  background-color: var(--yorovr-color-surface-50);
}

table tbody tr:hover {
  background-color: var(--yorovr-color-accent-electric-surface);
}

/* Informational banners */
.banner {
  display: flex;
  align-items: center;
  gap: var(--yorovr-space-3);
  padding: var(--yorovr-space-4) var(--yorovr-space-5);
  border-radius: var(--yorovr-radius-lg);
  background-color: var(--yorovr-color-surface-100);
  border: 1px solid var(--yorovr-color-border);
}

.banner__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--yorovr-color-accent-electric-surface);
  color: var(--yorovr-color-accent-electric);
}

.banner--warning {
  border-color: var(--yorovr-color-state-warning);
  background-color: rgba(255, 181, 71, 0.12);
}

.banner--success {
  border-color: var(--yorovr-color-state-success);
  background-color: rgba(36, 180, 126, 0.12);
}
