/* ============================================================
   AchievePro — site-wide design system
   ============================================================ */

:root {
  --bg: #0a0e1a;
  --bg-soft: #0e1322;
  --surface: #121829;
  --surface-2: #181f33;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text: #e9edf6;
  --text-muted: #9aa4ba;
  --text-faint: #6b7488;
  --accent: #6366f1;
  --accent-2: #22d3ee;
  --accent-grad: linear-gradient(110deg, #6366f1 0%, #22d3ee 100%);
  --radius: 16px;
  --radius-lg: 24px;
  --maxw: 1160px;
  --font-display: "Sora", "Segoe UI", sans-serif;
  --font-body: "Inter", "Segoe UI", sans-serif;

  /* Per-project accents */
  --lumina: #f5a524;
  --tadabbur: #2dd4a8;
  --softdiamond: #fb7185;
  --kinzy: #d9b36c;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  font-size: 16.5px;
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; display: block; }

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.02em;
}

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

section { padding: 88px 0; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-2);
  margin-bottom: 16px;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--accent-grad);
  border-radius: 2px;
}

.section-head { max-width: 680px; margin-bottom: 52px; }
.section-head h2 { font-size: clamp(28px, 4vw, 40px); margin-bottom: 14px; }
.section-head p { color: var(--text-muted); font-size: 17.5px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center .eyebrow { justify-content: center; }

.text-grad {
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 14, 26, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 19px;
  letter-spacing: -0.01em;
}
.brand .mark {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--accent-grad);
  display: grid;
  place-items: center;
  flex: none;
}
.brand .mark svg { width: 18px; height: 18px; }
.brand span em { font-style: normal; color: var(--accent-2); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 34px;
  list-style: none;
}
.nav-links a {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 12px 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.18s, box-shadow 0.18s, background 0.18s, border-color 0.18s;
}
.btn-primary {
  background: var(--accent-grad);
  color: #fff;
  box-shadow: 0 8px 28px rgba(99, 102, 241, 0.35);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 34px rgba(99, 102, 241, 0.45); }
.btn-ghost {
  border-color: var(--border-strong);
  color: var(--text);
  background: transparent;
}
.btn-ghost:hover { border-color: var(--accent-2); color: var(--accent-2); }
.btn-sm { padding: 9px 18px; font-size: 14px; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  width: 42px;
  height: 42px;
  cursor: pointer;
  color: var(--text);
  font-size: 18px;
  line-height: 1;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 110px 0 96px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(700px 420px at 18% -10%, rgba(99, 102, 241, 0.22), transparent 65%),
    radial-gradient(640px 400px at 85% 8%, rgba(34, 211, 238, 0.13), transparent 65%);
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(900px 540px at 50% 0%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(900px 540px at 50% 0%, #000 30%, transparent 75%);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }
.hero h1 {
  font-size: clamp(36px, 5.6vw, 62px);
  max-width: 820px;
  margin-bottom: 22px;
}
.hero .lead {
  font-size: clamp(17px, 2vw, 20px);
  color: var(--text-muted);
  max-width: 640px;
  margin-bottom: 36px;
}
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 56px; }

.hero-chips { display: flex; flex-wrap: wrap; gap: 12px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 17px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.03);
}
.chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-grad); }

/* ---------- Cards / grids ---------- */
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 28px;
  transition: transform 0.2s, border-color 0.2s, background 0.2s;
}
.card:hover { transform: translateY(-4px); border-color: var(--border-strong); background: var(--surface-2); }
.card h3 { font-size: 19px; margin: 18px 0 10px; }
.card p { color: var(--text-muted); font-size: 15.5px; }

.icon-tile {
  width: 48px;
  height: 48px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: rgba(99, 102, 241, 0.14);
  border: 1px solid rgba(99, 102, 241, 0.25);
  color: var(--accent-2);
  font-size: 21px;
}
.icon-tile svg { width: 23px; height: 23px; }

/* ---------- Work / portfolio rows ---------- */
.work-row {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
  padding: 56px 0;
  border-bottom: 1px solid var(--border);
}
.work-row:last-of-type { border-bottom: 0; }
.work-row.flip .work-visual { order: 2; }

.work-visual {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  background: var(--surface);
  transition: transform 0.25s, border-color 0.25s;
}
a:hover .work-visual, .work-visual:hover { transform: translateY(-5px); border-color: var(--border-strong); }

.work-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.work-tag .dot { width: 8px; height: 8px; border-radius: 50%; }

.work-info h3 { font-size: clamp(24px, 3vw, 32px); margin-bottom: 14px; }
.work-info p { color: var(--text-muted); margin-bottom: 22px; }
.work-meta { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 26px; }
.work-meta .chip { font-size: 13px; padding: 7px 14px; }

.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 15.5px;
  color: var(--accent-2);
}
.arrow-link svg { width: 17px; height: 17px; transition: transform 0.2s; }
.arrow-link:hover svg { transform: translateX(5px); }

/* ---------- Process ---------- */
.process { counter-reset: step; }
.process .card { position: relative; }
.step-num {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-2);
  letter-spacing: 0.1em;
}

/* ---------- Stack badges ---------- */
.stack-badges { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.stack-badges .chip { font-size: 14.5px; padding: 11px 20px; }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.stat {
  text-align: center;
  padding: 30px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.stat .num {
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 700;
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat .lbl { color: var(--text-muted); font-size: 14.5px; margin-top: 6px; }

/* ---------- Contact ---------- */
.contact-panel {
  background:
    radial-gradient(540px 280px at 12% 0%, rgba(99, 102, 241, 0.2), transparent 65%),
    radial-gradient(480px 280px at 90% 100%, rgba(34, 211, 238, 0.13), transparent 65%),
    var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: clamp(36px, 6vw, 72px);
  text-align: center;
}
.contact-panel h2 { font-size: clamp(28px, 4vw, 42px); margin-bottom: 16px; }
.contact-panel p { color: var(--text-muted); max-width: 560px; margin: 0 auto 32px; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 56px 0 36px;
  background: var(--bg-soft);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 44px;
}
.footer-grid h4 { font-size: 14px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 16px; }
.footer-grid ul { list-style: none; }
.footer-grid li { margin-bottom: 10px; }
.footer-grid a { color: var(--text-muted); font-size: 15px; transition: color 0.2s; }
.footer-grid a:hover { color: var(--text); }
.footer-grid .about { color: var(--text-muted); font-size: 15px; max-width: 300px; margin-top: 14px; }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 26px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  color: var(--text-faint);
  font-size: 14px;
}

/* ---------- Project detail pages ---------- */
.project-hero {
  position: relative;
  padding: 90px 0 70px;
  overflow: hidden;
}
.project-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(720px 400px at 20% -10%, var(--proj-glow, rgba(99, 102, 241, 0.2)), transparent 65%);
  pointer-events: none;
}
.project-hero .container { position: relative; z-index: 1; }
.breadcrumb { font-size: 14px; color: var(--text-faint); margin-bottom: 26px; }
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--text); }
.project-hero h1 { font-size: clamp(34px, 5vw, 56px); margin-bottom: 18px; }
.project-hero .tagline { font-size: clamp(17px, 2vw, 21px); color: var(--text-muted); max-width: 660px; margin-bottom: 34px; }

.project-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-top: 44px;
}
.fact {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 20px 22px;
}
.fact .k { font-size: 12.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 7px; }
.fact .v { font-weight: 600; font-size: 15.5px; }

.project-visual {
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin: 56px auto 0;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}

.feature-card h3 { display: flex; align-items: center; gap: 12px; margin-top: 0; }
.feature-card .emoji { font-size: 22px; }

.deliverables { list-style: none; display: grid; gap: 14px; }
.deliverables li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 13px;
  padding: 17px 20px;
  color: var(--text-muted);
  font-size: 15.5px;
}
.deliverables li strong { color: var(--text); }
.deliverables .tick {
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(34, 211, 238, 0.14);
  color: var(--accent-2);
  display: grid;
  place-items: center;
  font-size: 12px;
  margin-top: 2px;
}

.next-project {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 34px 38px;
  background: var(--surface);
  transition: border-color 0.2s, transform 0.2s;
}
.next-project:hover { border-color: var(--accent-2); transform: translateY(-3px); }
.next-project .k { font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 6px; }
.next-project .v { font-family: var(--font-display); font-size: 24px; font-weight: 700; }

.store-badges { display: flex; gap: 14px; flex-wrap: wrap; }
.store-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--border-strong);
  border-radius: 13px;
  padding: 11px 20px;
  background: rgba(255, 255, 255, 0.04);
  transition: border-color 0.2s, transform 0.2s;
}
.store-badge:hover { border-color: var(--accent-2); transform: translateY(-2px); }
.store-badge .lines small { display: block; font-size: 11.5px; color: var(--text-faint); line-height: 1.3; }
.store-badge .lines strong { font-size: 16px; }
.store-badge svg { width: 26px; height: 26px; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .project-facts { grid-template-columns: repeat(2, 1fr); }
  .work-row { grid-template-columns: 1fr; gap: 30px; padding: 44px 0; }
  .work-row.flip .work-visual { order: 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  section { padding: 64px 0; }
  .hero { padding: 72px 0 64px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .nav-links {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--bg-soft);
    border-bottom: 1px solid var(--border);
    padding: 10px 24px 18px;
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; }
  .nav-links a:not(.btn) { display: block; padding: 13px 0; font-size: 16px; }
  .nav-links .btn { margin-top: 12px; padding: 12px 24px; }
  .nav-toggle { display: grid; place-items: center; }
  .nav-cta-desktop { display: none; }
  .next-project { flex-direction: column; align-items: flex-start; }
}
