/* ===== ClasmAI HomePage - Estilos ===== */
:root {
  --primary: #6c3ee8;
  --primary-light: #8b5cf6;
  --primary-dark: #5b21b6;
  --accent: #06b6d4;
  --bg-dark: #0f0f12;
  --bg-card: #18181c;
  --text: #fafafa;
  --text-muted: #a1a1aa;
  --border: rgba(255, 255, 255, 0.08);
  --font-heading: 'Fraunces', Georgia, serif;
  --font-body: 'DM Sans', system-ui, sans-serif;
  --radius: 12px;
  --radius-lg: 20px;
  --transition: 0.2s ease;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-dark);
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ----- Header ----- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 0;
  background: rgba(15, 15, 18, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

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

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.nav-logo-img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.nav-logo-text {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.25rem;
  color: var(--text);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.9375rem;
  color: var(--text-muted);
  transition: color var(--transition);
}

.nav-links a:hover {
  color: var(--text);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  border-radius: var(--radius);
  transition: all var(--transition);
  cursor: pointer;
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover {
  background: var(--primary-light);
  transform: translateY(-1px);
}

.btn-hero {
  background: white;
  color: var(--primary-dark);
  padding: 1rem 2rem;
  font-size: 1.0625rem;
}

.btn-hero:hover {
  background: #f5f5f5;
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.btn-hero svg {
  transition: transform var(--transition);
}

.btn-hero:hover svg {
  transform: translateX(4px);
}

.btn-cta {
  background: var(--primary);
  color: white;
  padding: 1rem 2.5rem;
  font-size: 1.0625rem;
}

.btn-cta:hover {
  background: var(--primary-light);
  transform: translateY(-2px);
}

/* ----- Hero ----- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 8rem 0 6rem;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(108, 62, 232, 0.35), transparent),
    radial-gradient(ellipse 60% 40% at 90% 50%, rgba(6, 182, 212, 0.15), transparent),
    radial-gradient(ellipse 50% 30% at 10% 80%, rgba(108, 62, 232, 0.2), transparent);
  pointer-events: none;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: 
    linear-gradient(180deg, transparent 0%, var(--bg-dark) 100%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.hero-badge {
  display: inline-block;
  padding: 0.375rem 0.875rem;
  margin-bottom: 1.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--primary-light);
  background: rgba(108, 62, 232, 0.15);
  border: 1px solid rgba(108, 62, 232, 0.3);
  border-radius: 999px;
  letter-spacing: 0.02em;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}

.hero-title em {
  font-style: italic;
  color: var(--primary-light);
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 2.5rem;
  max-width: 600px;
}

.hero-cta {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.hero-cta-note {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.hero-scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

.hero-scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--primary), transparent);
  border-radius: 1px;
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 1; transform: scaleY(1); }
  50% { opacity: 0.5; transform: scaleY(0.7); }
}

/* ----- Features ----- */
.features {
  padding: 6rem 0;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 600;
  text-align: center;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}

.section-subtitle {
  text-align: center;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto 3.5rem;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}

.feature-card {
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
}

.feature-card:hover {
  border-color: rgba(108, 62, 232, 0.4);
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.feature-icon {
  width: 48px;
  height: 48px;
  margin-bottom: 1.25rem;
  color: var(--primary-light);
}

.feature-icon svg {
  width: 100%;
  height: 100%;
}

.feature-card h3 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.feature-card p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ----- How it works ----- */
.how-it-works {
  padding: 6rem 0;
  background: rgba(0, 0, 0, 0.2);
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.step {
  text-align: center;
  padding: 2rem;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 1.25rem;
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(108, 62, 232, 0.15);
  border-radius: 50%;
}

.step h3 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.step p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ----- CTA Section ----- */
.cta-section {
  padding: 6rem 0;
}

.cta-box {
  text-align: center;
  padding: 4rem 2rem;
  background: linear-gradient(135deg, rgba(108, 62, 232, 0.2), rgba(6, 182, 212, 0.1));
  border: 1px solid rgba(108, 62, 232, 0.3);
  border-radius: var(--radius-lg);
}

.cta-box h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.cta-box p {
  color: var(--text-muted);
  margin-bottom: 2rem;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

/* ----- Footer ----- */
.footer {
  padding: 2.5rem 0;
  border-top: 1px solid var(--border);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
}

.footer-logo {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}

.footer-copy {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.footer-link {
  font-size: 0.875rem;
  color: var(--primary-light);
  transition: color var(--transition);
}

.footer-link:hover {
  color: var(--primary);
}

/* ----- Modal Token ----- */
.token-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.token-modal.is-open {
  opacity: 1;
  visibility: visible;
}

.token-modal[aria-hidden="false"] {
  opacity: 1;
  visibility: visible;
}

.token-modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
}

.token-modal-content {
  position: relative;
  width: 100%;
  max-width: 400px;
  padding: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.token-modal-title {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
  color: var(--text);
}

.token-modal-input {
  width: 100%;
  padding: 0.75rem 1rem;
  margin-bottom: 1.5rem;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--text);
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  outline: none;
  transition: border-color var(--transition);
}

.token-modal-input:focus {
  border-color: var(--primary);
}

.token-modal-input::placeholder {
  color: var(--text-muted);
}

.token-modal-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
}

.btn-token-cancel {
  padding: 0.75rem 1.5rem;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
}

.btn-token-cancel:hover {
  color: var(--text);
  border-color: var(--text-muted);
}

.btn-token-accept {
  padding: 0.75rem 1.5rem;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  color: white;
  background: var(--primary);
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
}

.btn-token-accept:hover {
  background: var(--primary-light);
}

/* ----- Responsive ----- */
@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    flex-direction: column;
    align-items: flex-start;
    padding: 5rem 2rem 2rem;
    background: var(--bg-card);
    border-left: 1px solid var(--border);
    transition: right 0.3s ease;
  }

  .nav-links.is-open {
    right: 0;
  }

  .nav-toggle {
    display: flex;
  }

  .hero {
    padding: 6rem 0 4rem;
  }

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