:root {
  --bg: #0a0a0f;
  --bg-alt: #0f0f18;
  --surface: #14141f;
  --surface-2: #1b1b2b;
  --border: #262636;
  --text: #eef0f6;
  --text-dim: #a0a3b1;
  --accent: #7c5cff;
  --accent-2: #24d3c4;
  --radius: 16px;
  --maxw: 1120px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, .logo-text {
  font-family: "Space Grotesk", "Inter", sans-serif;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

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

/* HEADER */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 15, 0.7);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.logo-mark {
  display: grid; place-items: center;
  width: 32px; height: 32px; border-radius: 9px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  font-family: "Space Grotesk", sans-serif; font-weight: 700; color: #fff;
}
.logo-text { font-size: 1.15rem; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a { color: var(--text-dim); font-size: 0.95rem; transition: color 0.2s var(--ease); }
.nav a:hover { color: var(--text); }
.nav-cta {
  padding: 8px 16px; border: 1px solid var(--border); border-radius: 999px;
  color: var(--text) !important;
}
.nav-cta:hover { border-color: var(--accent); background: rgba(124, 92, 255, 0.1); }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { width: 22px; height: 2px; background: var(--text); transition: 0.25s var(--ease); }

/* HERO */
.hero { position: relative; padding: 100px 0 90px; overflow: hidden; }
.hero-glow {
  position: absolute; top: -30%; left: 50%; transform: translateX(-50%);
  width: 900px; height: 700px; pointer-events: none;
  background: radial-gradient(circle at 50% 40%, rgba(124, 92, 255, 0.28), transparent 62%),
              radial-gradient(circle at 65% 55%, rgba(36, 211, 196, 0.16), transparent 60%);
  filter: blur(20px);
}
.hero-inner { position: relative; max-width: 780px; }
.eyebrow {
  text-transform: uppercase; letter-spacing: 0.16em; font-size: 0.78rem;
  color: var(--accent-2); font-weight: 600; margin-bottom: 18px;
}
.hero h1 { font-size: clamp(2.1rem, 6vw, 3.6rem); font-weight: 700; }
.hero-sub { margin-top: 22px; font-size: 1.1rem; color: var(--text-dim); max-width: 620px; }
.hero-actions { margin-top: 34px; display: flex; flex-wrap: wrap; gap: 14px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 13px 24px; border-radius: 999px; font-weight: 600; font-size: 0.97rem;
  cursor: pointer; border: 1px solid transparent; transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), background 0.2s var(--ease);
}
.btn-primary {
  background: linear-gradient(135deg, var(--accent), #9b7bff);
  color: #fff; box-shadow: 0 8px 30px rgba(124, 92, 255, 0.35);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 40px rgba(124, 92, 255, 0.5); }
.btn-ghost { border-color: var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); background: rgba(124, 92, 255, 0.08); transform: translateY(-2px); }

.hero-stats { margin-top: 52px; display: flex; flex-wrap: wrap; gap: 40px; }
.hero-stats dt { font-family: "Space Grotesk", sans-serif; font-size: 1.7rem; font-weight: 700; }
.hero-stats dd { color: var(--text-dim); font-size: 0.9rem; }

/* SECTIONS */
.section { padding: 90px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin-top: 10px; }
.section-lead { margin-top: 14px; color: var(--text-dim); }

.grid { display: grid; gap: 22px; }
.cards { grid-template-columns: repeat(3, 1fr); }
.services { grid-template-columns: repeat(4, 1fr); }

/* CARDS */
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; transition: transform 0.28s var(--ease), border-color 0.28s var(--ease), box-shadow 0.28s var(--ease);
}
.card:hover { transform: translateY(-6px); border-color: rgba(124, 92, 255, 0.5); box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45); }
.card-thumb { height: 150px; background: #222; position: relative; }
.thumb-a { background: linear-gradient(135deg, #7c5cff, #3a2a80); }
.thumb-b { background: linear-gradient(135deg, #24d3c4, #16706a); }
.thumb-c { background: linear-gradient(135deg, #ff6b9d, #7a2f52); }
.thumb-d { background: linear-gradient(135deg, #ffb347, #8a5a1a); }
.thumb-e { background: linear-gradient(135deg, #5c8cff, #29407f); }
.thumb-f { background: linear-gradient(135deg, #b06bff, #5a2f85); }
.card-body { padding: 20px; }
.card-body h3 { margin: 12px 0 8px; font-size: 1.2rem; }
.card-body p { color: var(--text-dim); font-size: 0.92rem; }
.tag {
  display: inline-block; padding: 3px 10px; border-radius: 999px;
  font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em;
}
.tag-game { background: rgba(124, 92, 255, 0.15); color: #b7a3ff; }
.tag-app { background: rgba(36, 211, 196, 0.15); color: #7fe9df; }
.store-links { display: flex; gap: 10px; margin-top: 16px; }
.store {
  font-size: 0.82rem; padding: 7px 12px; border: 1px solid var(--border); border-radius: 8px;
  color: var(--text-dim); transition: 0.2s var(--ease);
}
.store:hover { border-color: var(--accent); color: var(--text); }
.portfolio-note { margin-top: 28px; color: var(--text-dim); font-size: 0.88rem; }
.portfolio-note a { color: var(--accent-2); text-underline-offset: 3px; text-decoration: underline; }
.portfolio-note a:hover { color: var(--text); }
a.featured-visual { display: block; }
a.featured-visual:hover .dot { opacity: 1; }
.featured-body h3 a { transition: color 0.2s var(--ease); }
.featured-body h3 a:hover { color: var(--accent-2); }
.store-cta { border-color: var(--accent); color: var(--text); background: rgba(124, 92, 255, 0.12); font-weight: 600; }
.store-cta:hover { background: rgba(124, 92, 255, 0.22); border-color: var(--accent); }
.store-appstore { border-color: var(--accent-2); color: #7fe9df; background: rgba(36, 211, 196, 0.1); font-weight: 600; }
.store-appstore:hover { background: rgba(36, 211, 196, 0.2); border-color: var(--accent-2); color: var(--text); }

/* FEATURED PROJECT */
.featured {
  display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 0;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; transition: border-color 0.28s var(--ease), box-shadow 0.28s var(--ease);
}
.featured:hover { border-color: rgba(124, 92, 255, 0.5); box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45); }
.featured-visual {
  position: relative; min-height: 300px;
  background: radial-gradient(circle at 30% 30%, #2a2350, #0d0d16);
  border-right: 1px solid var(--border);
}
.featured-visual .dot {
  position: absolute; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 40px rgba(124, 92, 255, 0.6);
}
.featured-visual .dot-1 { width: 90px; height: 90px; top: 22%; left: 20%; animation: pulse 3s var(--ease) infinite; }
.featured-visual .dot-2 { width: 54px; height: 54px; top: 55%; left: 52%; animation: pulse 3s var(--ease) infinite 0.6s; }
.featured-visual .dot-3 { width: 30px; height: 30px; top: 30%; left: 66%; animation: pulse 3s var(--ease) infinite 1.2s; }
@keyframes pulse { 0%, 100% { transform: scale(1); opacity: 0.95; } 50% { transform: scale(0.7); opacity: 0.6; } }
.featured-body { padding: 34px 32px; }
.featured-body h3 { font-size: 1.7rem; margin: 12px 0 12px; }
.featured-lead { color: var(--text-dim); }
.featured-points { list-style: none; margin: 18px 0; display: grid; gap: 8px; }
.featured-points li { color: var(--text-dim); font-size: 0.92rem; padding-left: 20px; position: relative; }
.featured-points li::before { content: "▸"; position: absolute; left: 0; color: var(--accent); }
.featured-tech {
  font-size: 0.82rem; color: var(--text-dim); letter-spacing: 0.04em;
  border-top: 1px solid var(--border); padding-top: 14px; margin-bottom: 16px;
}
@media (max-width: 900px) {
  .featured { grid-template-columns: 1fr; }
  .featured-visual { min-height: 200px; border-right: 0; border-bottom: 1px solid var(--border); }
}
@media (prefers-reduced-motion: reduce) {
  .featured-visual .dot { animation: none; }
}

/* SERVICES */
.service {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px 22px; transition: transform 0.28s var(--ease), border-color 0.28s var(--ease);
}
.service:hover { transform: translateY(-5px); border-color: rgba(36, 211, 196, 0.5); }
.service-icon { font-size: 1.8rem; }
.service h3 { margin: 14px 0 8px; font-size: 1.08rem; }
.service p { color: var(--text-dim); font-size: 0.9rem; }
.services-cta { margin-top: 40px; }

/* ABOUT */
.about-inner { display: grid; grid-template-columns: 1.3fr 1fr; gap: 50px; align-items: start; }
.about-inner h2 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin: 10px 0 20px; }
.about-inner p { color: var(--text-dim); margin-bottom: 16px; }
.about-list { list-style: none; display: grid; gap: 14px; }
.about-list li {
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px;
  padding: 16px 18px; font-size: 0.92rem; color: var(--text-dim);
}
.about-list strong { color: var(--text); }

/* CONTACT */
.contact-inner { display: grid; grid-template-columns: 1.3fr 1fr; gap: 50px; align-items: start; }
.contact-inner h2 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin: 10px 0 8px; }
.contact-form { margin-top: 26px; display: grid; gap: 18px; max-width: 520px; }
.field { display: grid; gap: 6px; }
.field label { font-size: 0.85rem; color: var(--text-dim); font-weight: 500; }
.field input, .field select, .field textarea {
  background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 14px; color: var(--text); font: inherit; font-size: 0.95rem;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(124, 92, 255, 0.2);
}
.field textarea { resize: vertical; }
.form-status { font-size: 0.9rem; color: var(--accent-2); min-height: 1.2em; }
.field input:invalid:not(:placeholder-shown) { border-color: #ff6b6b; }

.company-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px 26px;
}
.company-card h3 { font-size: 1.05rem; margin-bottom: 16px; color: var(--text-dim); font-weight: 500; }
.company-name { font-family: "Space Grotesk", sans-serif; font-weight: 700; font-size: 1.15rem; margin-bottom: 6px; }
.company-card address { font-style: normal; color: var(--text-dim); margin-bottom: 20px; }
.company-ids { display: grid; gap: 10px; }
.company-ids > div { display: flex; justify-content: space-between; border-top: 1px solid var(--border); padding-top: 10px; }
.company-ids dt { color: var(--text-dim); font-size: 0.9rem; }
.company-ids dd { font-weight: 600; font-size: 0.9rem; }

/* FOOTER */
.site-footer { border-top: 1px solid var(--border); padding: 28px 0; background: var(--bg-alt); }
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; color: var(--text-dim); font-size: 0.88rem; }
.footer-inner a:hover { color: var(--text); }

/* REVEAL ANIMATION */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

/* RESPONSIVE */
@media (max-width: 900px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .services { grid-template-columns: repeat(2, 1fr); }
  .about-inner, .contact-inner { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 640px) {
  .nav { display: none; }
  .nav.open {
    display: flex; flex-direction: column; align-items: flex-start; gap: 18px;
    position: absolute; top: 68px; left: 0; right: 0;
    background: var(--bg); border-bottom: 1px solid var(--border); padding: 22px 20px;
  }
  .nav-toggle { display: flex; }
  .cards, .services { grid-template-columns: 1fr; }
  .hero { padding: 70px 0 60px; }
  .hero-stats { gap: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
