/* sim-ai.org - Seapunk AI Simulation Platform */
/* Colors: #1a1a2e (deep base), #4a90d9 (primary blue), #f5f0e8 (warm off-white), #e8b84b (accent gold), #6c757d (muted gray) */
/* Font: Inter */

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

:root {
  --deep-base: #1a1a2e;
  --primary-blue: #4a90d9;
  --warm-white: #f5f0e8;
  --accent-gold: #e8b84b;
  --muted-gray: #6c757d;
  --dark-surface: #0f0f23;
  --card-bg: rgba(26, 26, 46, 0.85);
  --card-border: rgba(74, 144, 217, 0.2);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--dark-surface);
  color: var(--warm-white);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Bubble Canvas */
#bubbleCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* Navigation */
#mainNav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 2rem;
  transition: background 0.4s ease, backdrop-filter 0.4s ease;
}

#mainNav.scrolled {
  background: rgba(15, 15, 35, 0.92);
  backdrop-filter: blur(12px);
  box-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.logo-fish {
  transition: transform 0.3s ease;
}

.nav-logo:hover .logo-fish {
  transform: translateX(4px);
}

.logo-text {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--warm-white);
  letter-spacing: -0.02em;
}

.logo-dot {
  color: var(--accent-gold);
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: var(--muted-gray);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.3s ease;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-blue);
  transition: width 0.3s ease;
}

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

.nav-links a:hover::after {
  width: 100%;
}

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

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--warm-white);
  transition: all 0.3s ease;
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-nav {
  display: none;
  position: fixed;
  top: 60px;
  left: 0;
  right: 0;
  background: rgba(15, 15, 35, 0.98);
  backdrop-filter: blur(12px);
  z-index: 99;
  flex-direction: column;
  padding: 1.5rem 2rem;
  gap: 1rem;
  transform: translateY(-100%);
  opacity: 0;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.mobile-nav.open {
  transform: translateY(0);
  opacity: 1;
}

.mobile-nav a {
  color: var(--warm-white);
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 500;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(74, 144, 217, 0.15);
}

/* Hero */
#hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 2rem 4rem;
  z-index: 1;
  overflow: hidden;
}

#hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(74, 144, 217, 0.12) 0%, transparent 60%),
              radial-gradient(ellipse at 70% 30%, rgba(232, 184, 75, 0.08) 0%, transparent 50%);
  z-index: -1;
}

.hero-content {
  max-width: 600px;
  z-index: 2;
}

.hero-badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  background: rgba(74, 144, 217, 0.15);
  border: 1px solid rgba(74, 144, 217, 0.3);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--primary-blue);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: 4rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  letter-spacing: -0.03em;
}

.hero-line {
  display: block;
}

.hero-line.accent {
  background: linear-gradient(135deg, var(--primary-blue), var(--accent-gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--muted-gray);
  line-height: 1.7;
  margin-bottom: 2rem;
  font-weight: 400;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-block;
  padding: 0.85rem 2rem;
  background: linear-gradient(135deg, var(--primary-blue), #3a7bc8);
  color: var(--warm-white);
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 15px rgba(74, 144, 217, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(74, 144, 217, 0.4);
}

.btn-secondary {
  display: inline-block;
  padding: 0.85rem 2rem;
  background: transparent;
  color: var(--warm-white);
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid rgba(245, 240, 232, 0.2);
  transition: border-color 0.3s ease, background 0.3s ease;
}

.btn-secondary:hover {
  border-color: var(--accent-gold);
  background: rgba(232, 184, 75, 0.08);
}

.hero-illustration {
  position: relative;
  z-index: 1;
}

.hero-fish {
  animation: fishFloat 6s ease-in-out infinite;
}

@keyframes fishFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-15px) rotate(2deg); }
  75% { transform: translateY(10px) rotate(-1deg); }
}

.hero-scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted-gray);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  animation: fadeInUp 1s ease 1.5s both;
}

.scroll-arrow {
  width: 20px;
  height: 20px;
  border-right: 2px solid var(--primary-blue);
  border-bottom: 2px solid var(--primary-blue);
  transform: rotate(45deg);
  animation: scrollBounce 2s ease-in-out infinite;
}

@keyframes scrollBounce {
  0%, 100% { transform: rotate(45deg) translateY(0); opacity: 1; }
  50% { transform: rotate(45deg) translateY(8px); opacity: 0.5; }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateX(-50%) translateY(20px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* Sections Common */
section {
  position: relative;
  z-index: 1;
  padding: 6rem 2rem;
}

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 4rem;
}

.section-icon {
  margin-bottom: 1rem;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
  color: var(--warm-white);
}

.section-description {
  font-size: 1.05rem;
  color: var(--muted-gray);
  line-height: 1.7;
}

/* Modules Grid */
#modules {
  background: linear-gradient(180deg, var(--dark-surface) 0%, rgba(26, 26, 46, 0.5) 50%, var(--dark-surface) 100%);
}

.modules-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.module-card {
  position: relative;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 2rem;
  transition: transform 0.4s ease, border-color 0.4s ease;
  overflow: hidden;
}

.module-card:hover {
  transform: translateY(-4px);
  border-color: rgba(74, 144, 217, 0.4);
}

.card-glow {
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at center, rgba(74, 144, 217, 0.08) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.module-card:hover .card-glow {
  opacity: 1;
}

.card-icon {
  margin-bottom: 1.25rem;
}

.card-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--warm-white);
}

.card-text {
  font-size: 0.9rem;
  color: var(--muted-gray);
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.card-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.tag {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  background: rgba(74, 144, 217, 0.1);
  border: 1px solid rgba(74, 144, 217, 0.2);
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--primary-blue);
}

/* Reveal Animation */
.reveal-card {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* About */
#about {
  background: var(--dark-surface);
}

.about-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.about-illustration {
  display: flex;
  justify-content: center;
}

.about-scene {
  animation: sceneFloat 8s ease-in-out infinite;
}

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

.jellyfish-float {
  animation: jellyfishPulse 4s ease-in-out infinite;
}

@keyframes jellyfishPulse {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-8px) scale(1.02); }
}

.about-paragraph {
  font-size: 1.05rem;
  color: var(--muted-gray);
  line-height: 1.8;
  margin-bottom: 1.5rem;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.stat {
  text-align: center;
  padding: 1.5rem 1rem;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 12px;
}

.stat-number {
  display: block;
  font-size: 2rem;
  font-weight: 800;
  color: var(--accent-gold);
  margin-bottom: 0.25rem;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--muted-gray);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Features */
#features {
  background: linear-gradient(180deg, var(--dark-surface) 0%, rgba(26, 26, 46, 0.3) 100%);
}

.features-list {
  max-width: 800px;
  margin: 0 auto;
}

.feature-item {
  display: flex;
  align-items: flex-start;
  gap: 2rem;
  padding: 2rem 0;
  position: relative;
}

.feature-number {
  font-size: 3rem;
  font-weight: 800;
  color: rgba(74, 144, 217, 0.2);
  line-height: 1;
  min-width: 80px;
}

.feature-content h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--warm-white);
  margin-bottom: 0.5rem;
}

.feature-content p {
  font-size: 0.95rem;
  color: var(--muted-gray);
  line-height: 1.7;
}

.feature-line {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--card-border), transparent);
}

/* Contact */
#contact {
  background: var(--dark-surface);
  text-align: center;
  padding: 8rem 2rem;
}

.contact-container {
  max-width: 600px;
  margin: 0 auto;
}

.contact-fish {
  margin-bottom: 1.5rem;
  opacity: 0.6;
}

.contact-text {
  font-size: 1.1rem;
  color: var(--muted-gray);
  margin-bottom: 2rem;
  line-height: 1.7;
}

.contact-form {
  margin-bottom: 1rem;
}

.form-row {
  display: flex;
  gap: 0.75rem;
  max-width: 480px;
  margin: 0 auto;
}

.form-input {
  flex: 1;
  padding: 0.85rem 1.25rem;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  color: var(--warm-white);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.3s ease;
}

.form-input::placeholder {
  color: var(--muted-gray);
}

.form-input:focus {
  border-color: var(--primary-blue);
}

.form-message {
  font-size: 0.85rem;
  margin-top: 0.75rem;
  min-height: 1.2em;
}

.form-message.success {
  color: var(--accent-gold);
}

.form-message.error {
  color: #e85454;
}

/* Footer */
#footer {
  position: relative;
  z-index: 1;
  padding: 3rem 2rem;
  border-top: 1px solid rgba(74, 144, 217, 0.1);
  background: var(--dark-surface);
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--warm-white);
  font-size: 0.95rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  color: var(--muted-gray);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--warm-white);
}

.footer-copy {
  color: var(--muted-gray);
  font-size: 0.8rem;
  width: 100%;
  text-align: center;
  margin-top: 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(74, 144, 217, 0.08);
}

/* Responsive */
@media (max-width: 1024px) {
  .modules-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-title {
    font-size: 3rem;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .nav-toggle {
    display: flex;
  }
  .mobile-nav {
    display: flex;
  }
  #hero {
    flex-direction: column;
    text-align: center;
    padding-top: 8rem;
  }
  .hero-actions {
    justify-content: center;
  }
  .hero-title {
    font-size: 2.5rem;
  }
  .hero-illustration {
    margin-top: 2rem;
  }
  .hero-fish {
    width: 280px;
    height: auto;
  }
  .modules-grid {
    grid-template-columns: 1fr;
  }
  .about-container {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .about-stats {
    grid-template-columns: repeat(3, 1fr);
  }
  .section-title {
    font-size: 2rem;
  }
  .feature-item {
    flex-direction: column;
    gap: 0.75rem;
  }
  .feature-number {
    font-size: 2rem;
  }
  .form-row {
    flex-direction: column;
  }
  .footer-inner {
    flex-direction: column;
    text-align: center;
  }
  .footer-links {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2rem;
  }
  .about-stats {
    grid-template-columns: 1fr;
  }
  section {
    padding: 4rem 1.25rem;
  }
}
