/* ============================================
   Oppovision — Studio-Grade Design System
   ============================================ */

:root {
  --bg: #050508;
  --bg-elevated: #0a0b10;
  --bg-card: #0e0f17;
  --text: #e8e8ed;
  --text-secondary: #8b8b96;
  --text-tertiary: #5c5c66;
  --accent: #3385ff;
  --accent-dim: rgba(51,133,255,0.15);
  --border: rgba(255,255,255,0.06);
  --border-strong: rgba(255,255,255,0.10);
  --radius: 16px;
  --radius-sm: 10px;
  --max-width: 1120px;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  background: var(--bg);
  color: var(--text);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  font-weight: 400;
  letter-spacing: -0.011em;
  overflow-x: hidden;
}

/* Canvas */
#particles {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.6;
}

/* Header */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 32px;
  height: 56px;
  background: rgba(5,5,8,0.78);
  backdrop-filter: saturate(180%) blur(24px);
  -webkit-backdrop-filter: saturate(180%) blur(24px);
  border-bottom: 1px solid var(--border);
}
.header.hidden { transform: translateY(-100%); }

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.02em;
  text-decoration: none;
}
.logo:hover { opacity: 0.8; }

.nav { display: flex; gap: 28px; }
.nav a {
  font-size: 14px;
  font-weight: 450;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
  letter-spacing: -0.01em;
}
.nav a:hover { color: var(--text); }

/* Sections */
section {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 120px 32px;
}

.section-header { margin-bottom: 64px; }
.section-kicker {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 16px;
}
.section-title {
  font-size: clamp(40px, 7vw, 64px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--text);
}

/* Hero */
.hero {
  padding-top: 200px;
  padding-bottom: 160px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.hero-kicker {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-tertiary);
  margin-bottom: 24px;
}
.hero-title {
  font-size: clamp(56px, 9vw, 88px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.04;
  margin-bottom: 32px;
}
.hero-title-outline {
  color: transparent;
  -webkit-text-stroke: 1px rgba(255,255,255,0.35);
}
.hero-desc {
  font-size: clamp(18px, 2.5vw, 22px);
  color: var(--text-secondary);
  max-width: 560px;
  line-height: 1.5;
  margin-bottom: 64px;
  letter-spacing: -0.01em;
}
.hero-stats {
  display: flex;
  gap: 48px;
}
.stat { display: flex; flex-direction: column; gap: 4px; }
.stat-number {
  font-size: 36px;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--text);
}
.stat-label {
  font-size: 13px;
  color: var(--text-tertiary);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* Games */
.games-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.game-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.3s, transform 0.3s cubic-bezier(0.16,1,0.3,1);
}
.game-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
}

/* Game Art */
.game-art {
  height: 200px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.game-art-label {
  position: absolute;
  bottom: 16px;
  left: 20px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: rgba(255,255,255,0.9);
  text-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

/* Block Cascade art */
.game-art--block {
  background: linear-gradient(160deg, #1a0a2e 0%, #16213e 40%, #0f3460 100%);
}
.game-art-grid {
  display: grid;
  grid-template-columns: repeat(3, 40px);
  grid-template-rows: repeat(3, 40px);
  gap: 4px;
  opacity: 0.85;
}
.gem {
  border-radius: 8px;
  animation: gem-glow 3s ease-in-out infinite;
}
.gem--a { background: #ff3b6e; animation-delay: 0s; }
.gem--b { background: #ff6b5e; animation-delay: 0.3s; }
.gem--c { background: #ff9f0a; animation-delay: 0.6s; }
.gem--d { background: #30d158; animation-delay: 0.9s; }
.gem--e { background: #5e5ce6; animation-delay: 1.2s; }
.gem--f { background: #64d2ff; animation-delay: 1.5s; }
@keyframes gem-glow {
  0%,100% { filter: brightness(1); }
  50% { filter: brightness(1.25); }
}

/* Sky Drift art */
.game-art--sky {
  background: linear-gradient(170deg, #0b0b1e 0%, #15103a 50%, #2d1240 100%);
}
.game-art-sky {
  width: 100%; height: 100%;
  position: relative;
}
.star {
  position: absolute;
  width: 2px; height: 2px;
  background: #fff;
  border-radius: 50%;
  animation: star-pulse 2s ease-in-out infinite;
}
.s1 { top:20%; left:25%; animation-delay:0s; }
.s2 { top:35%; left:55%; animation-delay:0.4s; }
.s3 { top:50%; left:40%; animation-delay:0.8s; }
.s4 { top:25%; left:70%; animation-delay:1.2s; }
.s5 { top:60%; left:65%; animation-delay:1.6s; }
@keyframes star-pulse {
  0%,100% { opacity:0.3; transform:scale(1); }
  50% { opacity:1; transform:scale(1.5); }
}
.ship-silhouette {
  position: absolute;
  bottom: 25%;
  left: 30%;
  width: 48px; height: 20px;
  background: linear-gradient(135deg, rgba(100,210,255,0.7), rgba(94,92,230,0.5));
  clip-path: polygon(50% 0%, 100% 50%, 85% 100%, 15% 100%, 0% 50%);
  animation: ship-glide 5s ease-in-out infinite;
}
@keyframes ship-glide {
  0%,100% { transform:translate(0,0) rotate(-3deg); }
  25% { transform:translate(40px,-15px) rotate(0deg); }
  50% { transform:translate(70px,8px) rotate(3deg); }
  75% { transform:translate(30px,-20px) rotate(0deg); }
}

/* Merge Haven art */
.game-art--merge {
  background: linear-gradient(150deg, #1a0a20 0%, #221540 50%, #0f2a30 100%);
}
.game-art-merge {
  position: relative;
  width: 160px; height: 120px;
}
.orb {
  position: absolute;
  border-radius: 50%;
  animation: orb-float 6s ease-in-out infinite;
}
.o1 { width:50px;height:50px; background:radial-gradient(circle at 35% 35%,#ff3b6e,#9b1b3a); top:0;left:10px; animation-delay:0s; }
.o2 { width:44px;height:44px; background:radial-gradient(circle at 35% 35%,#30d158,#1a6b2e); top:15px;left:55px; animation-delay:0.8s; }
.o3 { width:54px;height:54px; background:radial-gradient(circle at 35% 35%,#5e5ce6,#2d2a80); top:40px;left:25px; animation-delay:1.6s; }
.o4 { width:38px;height:38px; background:radial-gradient(circle at 35% 35%,#ff9f0a,#9b5a00); top:5px;left:105px; animation-delay:2.4s; }
.o5 { width:34px;height:34px; background:radial-gradient(circle at 35% 35%,#64d2ff,#256b8a); top:45px;left:95px; animation-delay:3.2s; }
@keyframes orb-float {
  0%,100% { transform:translateY(0) scale(1); }
  50% { transform:translateY(-12px) scale(1.06); }
}

/* Game Body */
.game-body { padding: 24px 20px; }
.game-genre {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: rgba(255,255,255,0.05);
  color: var(--text-tertiary);
  margin-bottom: 12px;
  border: 1px solid var(--border);
}
.game-body h3 {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
  color: var(--text);
}
.game-body p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 16px;
}
.game-meta {
  display: flex;
  gap: 16px;
  font-size: 12px;
  color: var(--text-tertiary);
  letter-spacing: 0.02em;
}

/* About */
.about { padding-top: 80px; }
.about-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.about-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 28px;
  transition: border-color 0.3s;
}
.about-card:hover { border-color: var(--border-strong); }
.about-icon {
  width: 48px; height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--accent-dim);
  color: var(--accent);
  margin-bottom: 24px;
}
.about-card h3 {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}
.about-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Contact */
.contact {
  text-align: center;
  padding-bottom: 160px;
}
.contact-text {
  font-size: 18px;
  color: var(--text-secondary);
  margin-bottom: 40px;
  line-height: 1.7;
}
.btn {
  display: inline-flex;
  align-items: center;
  padding: 13px 28px;
  border-radius: 24px;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.01em;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  transition: background 0.25s, transform 0.25s;
}
.btn:hover { background: #4d94ff; transform: scale(1.03); }

/* Footer */
.footer {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px 40px;
  border-top: 1px solid var(--border);
  padding-top: 32px;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
}
.footer-brand { display: flex; flex-direction: column; gap: 8px; }
.footer-legal {
  font-size: 12px;
  color: var(--text-tertiary);
}
.footer-links { display: flex; gap: 24px; }
.footer-links a {
  font-size: 13px;
  color: var(--text-tertiary);
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--text-secondary); }
.footer-copy {
  font-size: 12px;
  color: var(--text-tertiary);
}

/* Reveal animations */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(0.16,1,0.3,1),
              transform 0.7s cubic-bezier(0.16,1,0.3,1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* Responsive */
@media (max-width: 860px) {
  .games-grid, .about-grid { grid-template-columns: 1fr; }
  .hero-stats { gap: 32px; }
  .stat-number { font-size: 28px; }
  .footer-inner { flex-direction: column; gap: 16px; }
}

@media (max-width: 500px) {
  section { padding: 80px 20px; }
  .hero { padding-top: 140px; padding-bottom: 100px; }
  .hero-stats { flex-wrap: wrap; gap: 24px; }
}

/* Ripple effect */
.ripple {
  position: fixed;
  border-radius: 50%;
  border: 1px solid rgba(51,133,255,0.5);
  background: rgba(51,133,255,0.08);
  pointer-events: none;
  z-index: 9999;
  animation: ripple-expand 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes ripple-expand {
  0% { width: 0; height: 0; opacity: 0.6; transform: translate(-50%, -50%) scale(0); }
  100% { width: 240px; height: 240px; opacity: 0; transform: translate(-50%, -50%) scale(1); }
}
