/* ============================================================
   Mujay Rachmat Saputra — portfolio
   Dark dashboard theme. Mobile-first.
   ============================================================ */

:root {
  --bg: #0B1120;
  --surface: #151E32;
  --border: #1E293B;
  --text: #E2E8F0;
  --muted: #94A3B8;
  --accent: #2DD4BF;
  --accent-dim: rgba(45, 212, 191, 0.12);
  --max-w: 1240px;
}

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

html {
  scroll-behavior: smooth;
  /* anchor targets land below the sticky nav */
  scroll-padding-top: 80px;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.25rem;
}

h1, h2, h3 { line-height: 1.2; font-weight: 700; }
h2 { font-size: clamp(1.6rem, 4vw, 2.2rem); margin-bottom: 1.5rem; }
h3 { font-size: 1.15rem; margin-bottom: 0.75rem; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

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

/* ============ Nav ============ */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 17, 32, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0.9rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--text);
  letter-spacing: -0.02em;
}
.nav-logo:hover { text-decoration: none; }

.nav-links {
  display: flex;
  gap: 1.75rem;
  align-items: center;
}

.nav-links a {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); text-decoration: none; }

.nav-cta {
  color: var(--accent) !important;
  border: 1px solid var(--accent);
  border-radius: 8px;
  padding: 0.35rem 0.9rem;
}
.nav-cta:hover { background: var(--accent-dim); }

/* Hamburger — hidden on desktop */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  transition: transform 0.25s, opacity 0.25s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ============ Hero ============ */
.hero {
  position: relative;
  overflow: hidden;
  padding: 6rem 0 5rem;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.5;
}

.hero-grid line {
  stroke: var(--border);
  stroke-width: 1;
  opacity: 0.4;
}

.hero-line {
  stroke: var(--accent);
  stroke-width: 2;
  opacity: 0.35;
  stroke-dasharray: 2400;
  stroke-dashoffset: 2400;
  animation: draw-line 6s ease-out forwards;
}
.hero-line-2 {
  stroke: var(--muted);
  opacity: 0.18;
  animation-delay: 0.8s;
  animation-duration: 7s;
}

@keyframes draw-line {
  to { stroke-dashoffset: 0; }
}

.hero-content { position: relative; }

.eyebrow {
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.hero h1 {
  font-size: clamp(1.8rem, 5vw, 3.15rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  max-width: 960px;
}

.hero-sub {
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.15rem);
  max-width: 720px;
  margin: 1.5rem 0 2.25rem;
}

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

.hero h1 em { font-style: normal; color: var(--muted); }

/* Stat counters */
.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem 2rem;
  margin-top: 3rem;
  max-width: 900px;
}
.stat dt {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.02em;
}
.stat dd { color: var(--muted); font-size: 0.85rem; }

/* ============ Buttons ============ */
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.15s, box-shadow 0.15s, background 0.2s;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }

.btn-primary {
  background: var(--accent);
  color: #042F2E;
}
.btn-primary:hover { box-shadow: 0 6px 24px rgba(45, 212, 191, 0.35); }

.btn-ghost {
  border: 1px solid var(--border);
  color: var(--text);
  background: var(--surface);
}
.btn-ghost:hover { border-color: var(--accent); }

/* ============ Sections ============ */
.section { padding: 5rem 0; }
.section-alt { background: rgba(21, 30, 50, 0.45); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }

.section-intro { color: var(--muted); margin: -0.75rem 0 2rem; }

/* Fade-in on scroll */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: none; }

/* ============ Case study cards ============ */
.card-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.75rem;
  transition: border-color 0.25s, transform 0.25s;
}
.card:hover { border-color: var(--accent); transform: translateY(-4px); }

.card-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-dim);
  border-radius: 999px;
  padding: 0.2rem 0.7rem;
  margin-bottom: 1rem;
}

.card p {
  color: var(--muted);
  font-size: 0.92rem;
  margin-bottom: 0.6rem;
}
.card p strong { font-weight: 600; }

.fine-print {
  color: var(--muted);
  font-size: 0.8rem;
  margin-top: 1.5rem;
  opacity: 0.8;
}

/* ============ Demos (click-through cards) ============ */
.demo-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}
@media (min-width: 700px) {
  .demo-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1080px) {
  .demo-grid { grid-template-columns: repeat(3, 1fr); }
}

.demo-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  color: var(--text);
  transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}
.demo-card:hover {
  text-decoration: none;
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

/* Thumbnail: shows a screenshot if one is set via background-image,
   otherwise a clean branded placeholder with a mini chart. */
.demo-thumb {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 16 / 9;
  background-color: var(--bg);
  background-image: linear-gradient(135deg, #0e1730, #18233f);
  background-size: cover;
  background-position: center top;
  border-bottom: 1px solid var(--border);
}
.demo-thumb svg {
  width: 45%;
  height: auto;
  opacity: 0.7;
}
.demo-thumb svg polyline { stroke: var(--accent); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.demo-thumb svg circle { fill: var(--accent); }
.demo-thumb::after {
  content: attr(data-type);
  position: absolute;
  top: 0.6rem;
  left: 0.6rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(11, 17, 32, 0.75);
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 0.18rem 0.6rem;
}

.demo-card-body { padding: 1.4rem 1.5rem 1.6rem; display: flex; flex-direction: column; flex: 1; }
.demo-card-body .card-tag { margin-bottom: 0.8rem; }
.demo-card-body h3 { font-size: 1.08rem; margin-bottom: 0.5rem; }
.demo-card-body p { color: var(--muted); font-size: 0.9rem; margin-bottom: 1.1rem; flex: 1; }
.demo-open { color: var(--accent); font-weight: 600; font-size: 0.9rem; }

/* ============ Playground (interactive mini dashboard) ============ */
.playground {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.5rem;
}

.pg-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  margin-bottom: 1.5rem;
}

.pg-group { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.pg-btn {
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--muted);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.4rem 0.95rem;
  border-radius: 999px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.pg-btn:hover { color: var(--text); border-color: var(--accent); }
.pg-btn.active {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}

.pg-kpis {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}
@media (min-width: 600px) {
  .pg-kpis { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 900px) {
  .pg-kpis { grid-template-columns: repeat(4, 1fr); }
}
.pg-kpi {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.pg-kpi-label {
  color: var(--muted);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.pg-kpi-value { font-size: 1.25rem; font-weight: 700; }

.pg-chart-wrap {
  position: relative;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.75rem;
}
#pg-chart { display: block; width: 100%; height: auto; }

.pg-legend {
  display: flex;
  gap: 1.25rem;
  padding: 0.25rem 0.5rem 0.5rem;
}
.pg-leg-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--muted);
  font-size: 0.78rem;
}
.pg-leg-swatch { width: 18px; height: 3px; border-radius: 2px; display: inline-block; }
.pg-leg-swatch.this-yr { background: var(--accent); }
.pg-leg-swatch.last-yr {
  background: repeating-linear-gradient(90deg, var(--muted) 0 4px, transparent 4px 7px);
}

.pg-grid { stroke: var(--border); stroke-width: 1; opacity: 0.6; }
.pg-axis { fill: var(--muted); font-size: 10px; font-family: "Inter", system-ui, sans-serif; }

.pg-line-now {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.pg-line-prior {
  fill: none;
  stroke: var(--muted);
  stroke-width: 1.5;
  stroke-dasharray: 5 5;
  opacity: 0.55;
}
.pg-dot { fill: var(--bg); stroke: var(--accent); stroke-width: 2; }
#pg-hover-dot { fill: var(--accent); stroke: var(--bg); stroke-width: 2; pointer-events: none; }

.pg-tooltip {
  position: absolute;
  transform: translate(-50%, -100%);
  background: var(--surface);
  border: 1px solid var(--accent);
  border-radius: 8px;
  padding: 0.35rem 0.6rem;
  font-size: 0.8rem;
  white-space: nowrap;
  pointer-events: none;
  z-index: 5;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
}
.pg-tooltip strong { margin-right: 0.35rem; }
.pg-tooltip .up { color: var(--accent); margin-left: 0.45rem; }
.pg-tooltip .down { color: #F87171; margin-left: 0.45rem; }

/* Share-by-market bars */
.pg-breakdown { display: grid; gap: 0.5rem; margin-top: 1.25rem; }
.pg-bk-row {
  display: grid;
  grid-template-columns: 90px 1fr auto;
  align-items: center;
  gap: 0.75rem;
  transition: opacity 0.25s;
}
.pg-bk-row.dim { opacity: 0.35; }
.pg-bk-name { color: var(--muted); font-size: 0.82rem; }
.pg-bk-track {
  height: 8px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
}
.pg-bk-fill {
  display: block;
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.5s ease;
}
.pg-bk-val { color: var(--text); font-size: 0.8rem; font-weight: 600; min-width: 110px; text-align: right; }

/* Auto-written analysis callout */
.pg-insight {
  margin-top: 1.25rem;
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  border-radius: 12px;
  padding: 1.1rem 1.25rem;
}
.pg-insight-tag {
  display: inline-block;
  color: var(--accent);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.2rem;
}
.pg-insight p {
  color: var(--text);
  font-size: 0.92rem;
  margin-bottom: 0.85rem;
}
.pg-insight p:last-child { margin-bottom: 0; }

/* ============ Services tabs ============ */
.tab-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.tab-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 500;
  padding: 0.55rem 1.1rem;
  border-radius: 10px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.tab-btn:hover { color: var(--text); border-color: var(--accent); }
.tab-btn.active {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}

.tab-panel {
  display: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.75rem;
}
.tab-panel.active { display: block; animation: panel-in 0.3s ease; }

@keyframes panel-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.tab-panel h3 { font-size: 1.05rem; margin-bottom: 1rem; }
.tab-panel ul { list-style: none; }
.tab-panel li {
  color: var(--muted);
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}
.tab-panel li:last-child { border-bottom: none; }
.tab-panel li::before { content: "▸ "; color: var(--accent); }

/* ============ About ============ */
.about-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
  align-items: start;
  justify-items: center;
  text-align: center;
}

.about-photo {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--border);
  background: var(--surface);
}

.about-grid p { color: var(--muted); max-width: 620px; margin-bottom: 1rem; }

.about-promise {
  color: var(--text) !important;
  font-weight: 600;
  border-left: 3px solid var(--accent);
  padding-left: 1rem;
  text-align: left;
}

/* ============ What I fix (pain → fix) ============ */
.fix-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .fix-grid { grid-template-columns: repeat(2, 1fr); }
}
.fix-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 14px;
  padding: 1.5rem 1.6rem;
  transition: border-color 0.25s, transform 0.25s;
}
.fix-card:hover { border-color: var(--accent); transform: translateY(-3px); }
.fix-card .pain {
  color: var(--text);
  font-size: 1.02rem;
  font-weight: 600;
  margin-bottom: 0.8rem;
}
.fix-card .fix {
  color: var(--muted);
  font-size: 0.92rem;
  margin-bottom: 0;
}

/* ============ Trust strip ============ */
.trust-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .trust-grid { grid-template-columns: repeat(3, 1fr); }
}
.trust-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.6rem;
}
.trust-card h3 { font-size: 1.05rem; }
.trust-card p { color: var(--muted); font-size: 0.92rem; margin-bottom: 0; }

/* Testimonials (used once real quotes are added) */
.quote-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .quote-grid { grid-template-columns: repeat(2, 1fr); }
}
.quote-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 14px;
  padding: 1.6rem;
  margin: 0;
}
.quote-card blockquote {
  margin: 0 0 0.9rem;
  font-size: 1.02rem;
  color: var(--text);
  line-height: 1.6;
}
.quote-card figcaption { color: var(--text); font-size: 0.85rem; font-weight: 600; }
.quote-role { color: var(--muted); font-weight: 400; }

/* ============ How it works (steps) ============ */
.steps {
  list-style: none;
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
  counter-reset: step;
}
@media (min-width: 768px) {
  .steps { grid-template-columns: repeat(3, 1fr); }
}
.step {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.75rem;
  position: relative;
}
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  color: var(--accent);
  font-weight: 800;
  font-size: 1.1rem;
  margin-bottom: 1rem;
}
.step h3 { font-size: 1.1rem; }
.step p { color: var(--muted); font-size: 0.92rem; margin-bottom: 0; }

/* ============ Engagement models ============ */
.engage-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .engage-grid { grid-template-columns: repeat(2, 1fr); }
}
.engage-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.75rem;
  transition: border-color 0.25s, transform 0.25s;
}
.engage-card:hover { border-color: var(--accent); transform: translateY(-3px); }
.engage-card > p { color: var(--muted); font-size: 0.92rem; margin: 0.5rem 0 1rem; }
.engage-list { list-style: none; }
.engage-list li {
  color: var(--muted);
  font-size: 0.9rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--border);
}
.engage-list li:last-child { border-bottom: none; }
.engage-list li::before { content: "✓ "; color: var(--accent); font-weight: 700; }

/* ============ Contact ============ */
.contact-block { text-align: center; }
.contact-intro { margin-left: auto; margin-right: auto; max-width: 560px; }

.contact-or {
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  margin-top: 2rem;
  opacity: 0.8;
}

.contact-form {
  max-width: 580px;
  margin: 1rem auto 0;
  text-align: left;
  display: grid;
  gap: 1rem;
}
.cf-row {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}
@media (min-width: 560px) {
  .cf-row { grid-template-columns: 1fr 1fr; }
}
.cf-field { display: flex; flex-direction: column; gap: 0.35rem; }
.cf-field > span {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
}
.cf-field > span em { font-weight: 400; font-style: normal; opacity: 0.7; }
.cf-field input,
.cf-field textarea {
  font: inherit;
  font-size: 0.95rem;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  width: 100%;
  resize: vertical;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.cf-field input:focus,
.cf-field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}
.cf-field input::placeholder,
.cf-field textarea::placeholder { color: var(--muted); opacity: 0.6; }
.contact-form .btn { justify-self: start; cursor: pointer; border: none; }
.cf-note { font-size: 0.88rem; color: var(--accent); margin: 0; min-height: 1.2em; }
.cf-note.error { color: #F87171; }

.contact-alt {
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 2.5rem;
}
.contact-alt > p { margin-bottom: 0.9rem; }

.social-links {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}
.social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.5rem 1rem;
  transition: color 0.2s, border-color 0.2s, transform 0.15s;
}
.social-link svg { width: 18px; height: 18px; display: block; }
.social-link:hover {
  text-decoration: none;
  color: var(--accent);
  border-color: var(--accent);
  transform: translateY(-2px);
}

.contact-ctas {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

/* ============ Footer ============ */
.footer {
  border-top: 1px solid var(--border);
  padding: 2rem 0;
  text-align: center;
}
.footer p { color: var(--muted); font-size: 0.85rem; }

/* ============ Reduced motion ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-line { animation: none; stroke-dashoffset: 0; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .card { transition: none; }
  .pg-bk-fill { transition: none; }
  .tab-panel.active { animation: none; }
}

/* ============ Tablet: 768px+ ============ */
@media (min-width: 768px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(4, 1fr); }
  .playground { padding: 2rem; }
  .about-grid {
    grid-template-columns: auto 1fr;
    text-align: left;
    justify-items: start;
    gap: 3rem;
  }
}

/* ============ Wide: 1024px+ — 5 cards as 2-up + 3-up ============ */
@media (min-width: 1024px) {
  .card-grid { grid-template-columns: repeat(6, 1fr); }
  .card-grid .card { grid-column: span 3; }
  .card-grid .card:nth-child(n+3) { grid-column: span 2; }
}

/* ============ Mobile nav: below 768px ============ */
@media (max-width: 767px) {
  .nav-toggle { display: flex; }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 0.5rem 0 1rem;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 0.75rem 1.25rem; width: 100%; text-align: center; }
  .nav-cta { border: none; }

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