/* ============================================================
   TheQuest — studio site
   Single stylesheet, no build step. Edit freely.
   ============================================================ */

:root {
  --bg: #07070c;
  --bg-soft: #0e0e17;
  --surface: #14141f;
  --surface-2: #1b1b2a;
  --border: #262636;
  --text: #ededf2;
  --muted: #9a9ab0;
  --accent: #7c5cff;
  --accent-2: #00d4ff;
  --accent-grad: linear-gradient(120deg, #7c5cff 0%, #00d4ff 100%);
  --radius: 16px;
  --maxw: 1100px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: "Space Grotesk", system-ui, sans-serif; line-height: 1.1; margin: 0; }

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

.muted { color: var(--muted); }

code {
  font-family: ui-monospace, "SFMono-Regular", Menlo, monospace;
  font-size: 0.85em;
  background: var(--surface-2);
  padding: 1px 6px;
  border-radius: 6px;
}

/* ============================ NAV ============================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px clamp(20px, 5vw, 48px);
  background: rgba(7, 7, 12, 0.7);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.brand { display: flex; align-items: center; gap: 11px; font-weight: 700; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border-radius: 9px;
  background: var(--accent-grad);
  color: #07070c;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -0.5px;
}
.brand-name { font-family: "Space Grotesk", sans-serif; font-size: 18px; letter-spacing: -0.3px; }

.nav-links { display: flex; align-items: center; gap: clamp(14px, 3vw, 30px); font-size: 15px; }
.nav-links a { color: var(--muted); transition: color 0.2s; }
.nav-links a:hover { color: var(--text); }
.nav-cta {
  color: var(--text) !important;
  border: 1px solid var(--border);
  padding: 7px 16px;
  border-radius: 999px;
  transition: border-color 0.2s, background 0.2s;
}
.nav-cta:hover { border-color: var(--accent); background: rgba(124, 92, 255, 0.12); }

/* ============================ HERO ============================ */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(72px, 14vw, 150px) clamp(20px, 5vw, 48px) clamp(60px, 10vw, 110px);
  max-width: var(--maxw);
  margin: 0 auto;
}
.hero-glow {
  position: absolute;
  top: -20%; left: 50%;
  width: 900px; height: 900px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(124, 92, 255, 0.28) 0%, rgba(0, 212, 255, 0.10) 35%, transparent 65%);
  filter: blur(20px);
  pointer-events: none;
  animation: float 14s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(28px); }
}
.hero-inner { position: relative; max-width: 760px; }

.eyebrow {
  font-family: "Space Grotesk", sans-serif;
  font-size: 13px;
  letter-spacing: 2.5px;
  color: var(--accent-2);
  margin: 0 0 18px;
  font-weight: 600;
}
.hero-title {
  font-size: clamp(56px, 13vw, 120px);
  font-weight: 700;
  letter-spacing: -3px;
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 22px;
}
.hero-sub { font-size: clamp(17px, 2.4vw, 22px); color: var(--muted); max-width: 620px; margin: 0 0 34px; }
.hero-sub strong { color: var(--text); font-weight: 600; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 30px; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  transition: transform 0.2s var(--ease), box-shadow 0.25s, background 0.2s, border-color 0.2s;
  cursor: pointer;
  border: 1px solid transparent;
}
.btn-primary { background: var(--accent-grad); color: #07070c; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 30px -8px rgba(124, 92, 255, 0.6); }
.btn-ghost { border-color: var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); background: rgba(124, 92, 255, 0.1); transform: translateY(-2px); }

.hero-meta { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); }
.dot { width: 9px; height: 9px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.18); }

/* ============================ SECTIONS ============================ */
.section { max-width: var(--maxw); margin: 0 auto; padding: clamp(50px, 8vw, 90px) clamp(20px, 5vw, 48px); }
.section-head { margin-bottom: 38px; }
.section-head h2, .about h2, .contact-card h2 { font-size: clamp(28px, 5vw, 40px); letter-spacing: -1px; }
.section-sub { color: var(--muted); margin: 10px 0 0; font-size: 16px; }

/* ============================ PROJECT GRID ============================ */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 20px;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  overflow: hidden;
  transition: transform 0.3s var(--ease), border-color 0.3s, box-shadow 0.3s;
}
.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(124, 92, 255, 0.12), transparent 55%);
  opacity: 0;
  transition: opacity 0.3s;
}
.card:hover { transform: translateY(-4px); border-color: rgba(124, 92, 255, 0.55); box-shadow: 0 18px 40px -18px rgba(124, 92, 255, 0.45); }
.card:hover::before { opacity: 1; }

.card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; position: relative; }
.card-emoji {
  display: grid; place-items: center;
  width: 46px; height: 46px;
  border-radius: 12px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  font-size: 22px;
}
.card-status {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted);
}
.card-status.live { color: #34d399; border-color: rgba(52, 211, 153, 0.4); }
.card-status.wip { color: #fbbf24; border-color: rgba(251, 191, 36, 0.4); }

.card h3 { font-size: 20px; margin-bottom: 8px; position: relative; }
.card-desc { color: var(--muted); font-size: 15px; flex: 1; position: relative; }

.card-tags { display: flex; flex-wrap: wrap; gap: 7px; margin: 16px 0 18px; position: relative; }
.tag {
  font-size: 12px;
  color: var(--accent-2);
  background: rgba(0, 212, 255, 0.08);
  border: 1px solid rgba(0, 212, 255, 0.18);
  padding: 3px 10px;
  border-radius: 999px;
}

.card-links { display: flex; flex-wrap: wrap; gap: 14px; position: relative; }
.card-link { font-size: 14px; font-weight: 600; color: var(--text); display: inline-flex; align-items: center; gap: 5px; transition: color 0.2s; }
.card-link:hover { color: var(--accent-2); }
.card-link .arrow { transition: transform 0.2s; }
.card-link:hover .arrow { transform: translate(2px, -2px); }

/* ============================ ABOUT ============================ */
.about-inner { max-width: 720px; }
.about p { color: var(--muted); font-size: 17px; margin: 16px 0 0; }
.about-tags { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 26px 0 0; }
.about-tags li {
  font-size: 14px;
  padding: 8px 16px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
}

/* ============================ GITHUB ============================ */
.github-empty { padding: 30px 0; }
.gh-card .card-top { margin-bottom: 12px; }
.gh-lang { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.gh-lang::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.gh-stars { font-size: 13px; color: var(--muted); }

/* ============================ CONTACT ============================ */
.contact { display: flex; justify-content: center; }
.contact-card {
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: clamp(40px, 7vw, 70px) clamp(24px, 6vw, 80px);
  max-width: 640px;
  width: 100%;
  position: relative;
  overflow: hidden;
}
.contact-card::before {
  content: "";
  position: absolute;
  top: -50%; left: 50%;
  width: 500px; height: 500px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(124, 92, 255, 0.18), transparent 60%);
  pointer-events: none;
}
.contact-card h2 { position: relative; }
.contact-card p { color: var(--muted); margin: 12px 0 26px; position: relative; }
.contact-card .btn { position: relative; }
.contact-note { font-size: 12px; margin-top: 20px !important; }

/* ============================ FOOTER ============================ */
.footer {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 30px clamp(20px, 5vw, 48px) 50px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 14px;
  color: var(--muted);
}

/* ============================ REVEAL ANIM ============================ */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .hero-glow { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

@media (max-width: 560px) {
  .nav-links a:not(.nav-cta) { display: none; }
}
