/* =============================================
   MAGENTIZ — Stylesheet
   Near-black surfaces + Magentiz yellow (#FBC03D)
   ============================================= */
/* --- Fonts (self-hosted, variable woff2) --- */
/* Inter — latin-ext */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(../fonts/inter-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Inter — latin */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(../fonts/inter-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Space Grotesk — latin-ext */
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url(../fonts/space-grotesk-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Space Grotesk — latin */
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url(../fonts/space-grotesk-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Inter — vietnamese */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(../fonts/inter-vietnamese.woff2) format('woff2');
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* Space Grotesk — vietnamese */
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url(../fonts/space-grotesk-vietnamese.woff2) format('woff2');
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}

/* --- CSS Variables --- */
:root {
  --bg-primary: #0a0a0b;
  --bg-secondary: #101012;
  --bg-card: #141417;
  --bg-card-hover: #1a1a1e;
  --bg-glass: rgba(20, 20, 23, 0.7);

  /* Magentiz brand yellow (logo) */
  --brand: #fbc03d;
  --accent: #fbc03d;
  --accent-dark: #e5a91f;
  --accent-dim: #c98f0a;
  --accent-glow: rgba(251, 192, 61, 0.12);
  --accent-glow2: rgba(251, 192, 61, 0.06);

  --text-primary: #f5f5f4;
  --text-secondary: #a8a8b0;
  --text-muted: #8a8a93;

  --border: #232328;
  --border-light: #34343b;

  --nav-height: 64px;
  --radius: 8px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --transition: 0.22s ease;
  --shadow-card: 0 4px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 40px rgba(251, 192, 61, 0.12);
}

/* --- Light Mode ---
   Yellow text fails contrast on white, so --accent becomes a deep amber
   for text/borders; primary buttons keep the brand yellow (see .btn-primary). */
html.light {
  --bg-primary: #fafaf9;
  --bg-secondary: #f3f3f1;
  --bg-card: #ffffff;
  --bg-card-hover: #fafaf9;
  --bg-glass: rgba(255, 255, 255, 0.85);
  --accent: #946200;
  --accent-dark: #7a5100;
  --accent-glow: rgba(251, 192, 61, 0.16);
  --accent-glow2: rgba(251, 192, 61, 0.08);
  --text-primary: #18181b;
  --text-secondary: #3f3f46;
  --text-muted: #63636b;
  --border: #e7e5e4;
  --border-light: #d6d3d1;
  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.08);
  --shadow-glow: 0 0 40px rgba(251, 192, 61, 0.12);
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

ul {
  list-style: none;
}

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

/* --- Container --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px;
}

/* =============================================
   NAVBAR
   ============================================= */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 10px 0;
  transition: background var(--transition), backdrop-filter var(--transition), box-shadow var(--transition);
}

.navbar.scrolled {
  background: rgba(10, 10, 11, 0.90);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border);
}

html.light .navbar.scrolled {
  background: rgba(248, 250, 252, 0.93);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-height);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  padding: 7px 13px;
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius);
  transition: color var(--transition), background var(--transition);
  cursor: pointer;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.06);
}

html.light .nav-link:hover,
html.light .nav-link.active {
  background: rgba(0, 0, 0, 0.05);
}

.nav-cta {
  padding: 8px 18px;
  background: var(--accent);
  color: #000;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--radius);
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
  margin-left: 8px;
  cursor: pointer;
}

.nav-cta:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(251, 192, 61, 0.35);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border-light);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition);
  flex-shrink: 0;
  margin-right: 4px;
}

.theme-toggle:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-glow);
}

.theme-toggle svg {
  width: 16px;
  height: 16px;
  pointer-events: none;
}

.theme-toggle .icon-moon {
  display: none;
}

.theme-toggle .icon-sun {
  display: block;
}

html.light .theme-toggle .icon-moon {
  display: block;
}

html.light .theme-toggle .icon-sun {
  display: none;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 34px;
  border-radius: 20px;
  border: 1px solid var(--border-light);
  background: transparent;
  padding: 0 4px;
  flex-shrink: 0;
  margin-right: 4px;
}

.lang-opt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  border-radius: 14px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: all var(--transition);
  cursor: pointer;
  color: var(--text-muted);
}

.lang-opt:hover {
  color: var(--accent);
}

.lang-opt.active {
  color: var(--text-primary);
  font-weight: 800;
  background: var(--border-light);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius);
  background: none;
  border: none;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  transition: transform var(--transition), opacity var(--transition);
  border-radius: 2px;
}

.nav-toggle.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* =============================================
   BUTTONS
   ============================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 28px;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  letter-spacing: -0.01em;
}

.btn-primary {
  background: var(--accent);
  color: #000;
}

.btn-primary:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(251, 192, 61, 0.32);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border-light);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* =============================================
   SECTION LAYOUT
   ============================================= */
.section {
  padding: 100px 0;
}

.section-dark {
  background: var(--bg-secondary);
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

.section-label::before {
  content: '';
  display: inline-block;
  width: 16px;
  height: 1.5px;
  background: var(--accent);
  border-radius: 1px;
}

.section-title {
  font-size: clamp(1.9rem, 3.5vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.12;
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 580px;
  line-height: 1.75;
}

/* =============================================
   CARDS (base)
   ============================================= */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-3px);
  border-color: var(--border-light);
  box-shadow: var(--shadow-card);
}

.card-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.card-text {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Icon Box */

/* =============================================
   GRIDS
   ============================================= */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

/* =============================================
   HERO — HOMEPAGE
   ============================================= */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: calc(var(--nav-height) + 60px);
  padding-bottom: 80px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 30%, rgba(251, 192, 61, 0.07) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 80% 70%, rgba(255, 255, 255, 0.06) 0%, transparent 55%),
    radial-gradient(ellipse 50% 40% at 50% 10%, rgba(251, 192, 61, 0.05) 0%, transparent 50%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(251, 192, 61, 0.09) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 80px;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: var(--accent-glow);
  border: 1px solid rgba(251, 192, 61, 0.3);
  border-radius: 100px;
  font-size: 0.75rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 24px;
  letter-spacing: 0.04em;
}

.hero-badge .dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent);
  animation: pulseDot 2.2s ease-in-out infinite;
}

@keyframes pulseDot {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.4;
    transform: scale(0.7);
  }
}

.hero-title {
  font-size: clamp(2.6rem, 5vw, 4.2rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.06;
  margin-bottom: 24px;
}

.hero-title .highlight {
  color: var(--accent);
  text-shadow: 0 0 50px rgba(251, 192, 61, 0.3);
}

.hero-desc {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 40px;
  max-width: 540px;
}

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

.hero-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.hero-tag {
  padding: 5px 14px;
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Hero Visual — 2×2 bento grid */

/* =============================================
   STATS BAR
   ============================================= */
.stats-bar {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 52px 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.stat-item {
  text-align: center;
  padding: 0 24px;
  border-right: 1px solid var(--border);
}

.stat-item:last-child {
  border-right: none;
}

.stat-number {
  font-size: 3rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.05em;
  line-height: 1;
  margin-bottom: 8px;
  display: block;
}

.stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  font-weight: 500;
}

/* =============================================
   SERVICE CARDS (homepage)
   ============================================= */

/* =============================================
   CAPABILITY CARDS
   ============================================= */

/* =============================================
   CLIENTS STRIP
   ============================================= */

/* =============================================
   CTA SECTION
   ============================================= */
.cta-section {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 120px 0;
}

.cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 80% at 50% 50%, rgba(251, 192, 61, 0.07) 0%, transparent 65%),
    var(--bg-secondary);
  z-index: 0;
}

.cta-section .container {
  position: relative;
  z-index: 1;
}

.cta-section .section-title {
  max-width: 620px;
  margin: 0 auto 16px;
}

.cta-section .section-subtitle {
  margin: 0 auto 44px;
}

.cta-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* =============================================
   PAGE HERO (inner pages)
   ============================================= */
.page-hero {
  padding: calc(var(--nav-height) + 80px) 0 80px;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--bg-secondary);
  background-image: radial-gradient(rgba(251, 192, 61, 0.07) 1px, transparent 1px);
  background-size: 32px 32px;
  z-index: 0;
}

.page-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(170deg, transparent 35%, var(--bg-secondary) 90%),
    radial-gradient(ellipse 55% 65% at 80% 25%, rgba(251, 192, 61, 0.08) 0%, transparent 60%);
  z-index: 0;
}

.page-hero .container {
  position: relative;
  z-index: 1;
}

.page-hero-title {
  font-size: clamp(2.2rem, 4.5vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  margin-bottom: 20px;
  line-height: 1.08;
}

.page-hero-desc {
  font-size: 1.08rem;
  color: var(--text-secondary);
  max-width: 580px;
  line-height: 1.78;
}

/* =============================================
   BREADCRUMB
   ============================================= */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.breadcrumb a {
  color: var(--text-muted);
  transition: color var(--transition);
}

.breadcrumb a:hover {
  color: var(--accent);
}

.breadcrumb span {
  color: var(--text-secondary);
}

/* =============================================
   MARKET BADGES
   ============================================= */

/* =============================================
   TECH CARDS (technology page)
   ============================================= */

.tech-tag {
  padding: 4px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  transition: all var(--transition);
}

.tech-tag:hover {
  background: var(--accent-glow);
  color: var(--accent);
  border-color: rgba(251, 192, 61, 0.3);
}

html.light .tech-tag {
  background: rgba(0, 0, 0, 0.03);
}

/* =============================================
   ABOUT — APPROACH / ENGAGEMENT
   ============================================= */

/* =============================================
   SERVICES PAGE
   ============================================= */
.service-section {
  padding: 80px 0;
}

.service-section+.service-section {
  border-top: 1px solid var(--border);
}

.service-number {
  font-size: 5rem;
  font-weight: 900;
  color: rgba(251, 192, 61, 0.09);
  letter-spacing: -0.06em;
  line-height: 1;
  margin-bottom: -12px;
  display: block;
}

.service-feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.service-feature-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
  transition: border-color var(--transition), transform var(--transition);
}

.service-feature-item:hover {
  border-color: var(--border-light);
  transform: translateY(-2px);
}

.service-feature-title {
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
}

.sficon {
  width: 28px;
  height: 28px;
  background: var(--accent-glow);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}

.sficon svg {
  width: 14px;
  height: 14px;
}

.ai-feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}

.ai-feature-list li:last-child {
  border-bottom: none;
}

.ai-feature-icon {
  width: 36px;
  height: 36px;
  background: var(--accent-glow);
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 2px;
}

.ai-feature-icon svg {
  width: 18px;
  height: 18px;
}

/* =============================================
   CONTACT PAGE
   ============================================= */
.contact-info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
}

.contact-info-item {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  align-items: flex-start;
}

.contact-info-item:last-child {
  border-bottom: none;
}

.contact-info-icon {
  width: 38px;
  height: 38px;
  background: var(--accent-glow);
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}

.contact-info-icon svg {
  width: 18px;
  height: 18px;
}

.contact-info-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
}

.contact-info-value {
  font-size: 0.9rem;
  color: var(--text-primary);
}

.contact-info-value a:hover {
  color: var(--accent);
}

.process-step {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}

.process-step:last-child {
  border-bottom: none;
}

.process-step-num {
  width: 28px;
  height: 28px;
  background: var(--accent-glow);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 2px;
}

.process-step-text {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  padding: 72px 0 36px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 56px;
  margin-bottom: 56px;
}

.footer-brand p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.75;
  max-width: 260px;
  margin-top: 16px;
}

.footer-col-title {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 18px;
}

.footer-links li {
  padding: 5px 0;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--text-secondary);
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}

.footer-copy {
  font-size: 0.78rem;
  color: var(--text-muted);
}

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

/* =============================================
   DIVIDER & MISC
   ============================================= */

/* =============================================
   SCROLL REVEAL
   ============================================= */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 {
  transition-delay: 0.08s;
}

.reveal-delay-2 {
  transition-delay: 0.16s;
}

.reveal-delay-3 {
  transition-delay: 0.24s;
}

.reveal-delay-4 {
  transition-delay: 0.32s;
}

.reveal-delay-5 {
  transition-delay: 0.40s;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1024px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 56px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stat-item:nth-child(2) {
    border-right: none;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 72px 0;
  }

  .grid-2,
  .service-feature-grid {
    grid-template-columns: 1fr;
  }

  .hero-title {
    font-size: 2.4rem;
  }

  .page-hero-title {
    font-size: 2rem;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .service-number {
    font-size: 3.2rem;
  }

  .nav-menu {
    display: none;
    position: fixed;
    top: calc(var(--nav-height) + 12px);
    left: 12px;
    right: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    flex-direction: column;
    padding: 16px;
    gap: 4px;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.5);
  }

  .nav-menu.open {
    display: flex;
  }

  .nav-link {
    width: 100%;
    padding: 12px 16px;
  }

  .nav-cta {
    width: 100%;
    text-align: center;
    margin-left: 0;
  }

  .nav-toggle {
    display: flex;
  }

  html.light .nav-menu {
    background: var(--bg-card);
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

  .cta-actions {
    flex-direction: column;
    align-items: center;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stat-item {
    padding: 16px;
  }

  .stat-item:nth-child(2) {
    border-right: none;
  }

  .stat-item:nth-child(3) {
    border-right: 1px solid var(--border);
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 18px;
  }

  .stat-number {
    font-size: 2.2rem;
  }
}

/* prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  .reveal {
    transition: none;
  }

  .hero-badge .dot {
    animation: none;
  }
}

/* =============================================
   SPACE GROTESK — Display Font for Headings
   Gives headings distinctive character vs. Inter body
   ============================================= */
:root {
  --font-display: 'Space Grotesk', system-ui, sans-serif;
}

h1,
h2,
h3,
.hero-title,
.page-hero-title,
.section-title,
.stat-number,
.card-title {
  font-family: var(--font-display);
}

/* =============================================
   EYEBROW — understated alternative to section-label
   ============================================= */

/* =============================================
   FEATURE ROWS — horizontal service list
   Replaces uniform 3-card grid on homepage
   ============================================= */
.feature-rows {
  border-top: 1px solid var(--border);
}

.feature-row-item {
  display: grid;
  grid-template-columns: 48px 1fr 1.5fr;
  gap: 44px;
  padding: 44px 0;
  border-bottom: 1px solid var(--border);
  cursor: default;
}

.feature-row-item:hover .feature-row-title {
  color: var(--accent);
}

.feature-row-num {
  font-size: 0.63rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding-top: 4px;
  font-family: var(--font-display);
}

.feature-row-title {
  font-size: 1.22rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 12px;
  font-family: var(--font-display);
  transition: color var(--transition);
}

.feature-row-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.78;
}

.feature-row-list {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.feature-row-list li {
  font-size: 0.8rem;
  color: var(--text-secondary);
  padding: 5px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  display: flex;
  align-items: center;
  gap: 8px;
}

.feature-row-list li::before {
  content: '';
  width: 3px;
  height: 3px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}

.feature-row-list li:last-child {
  border-bottom: none;
}

.feature-row-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 14px;
}

/* =============================================
   NUMBERED LIST — 2-col capability layout
   Replaces uniform cap-card grids
   ============================================= */
.num-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--border);
}

.num-list-item {
  padding: 32px 0;
  border-bottom: 1px solid var(--border);
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 18px;
  align-items: start;
}

.num-list-item:nth-child(odd) {
  padding-right: 52px;
  border-right: 1px solid var(--border);
}

.num-list-item:nth-child(even) {
  padding-left: 52px;
}

.num-list-item:nth-last-child(1),
.num-list-item:nth-last-child(2) {
  border-bottom: none;
}

.num-list-num {
  font-size: 1rem;
  font-weight: 800;
  color: var(--accent);
  font-family: var(--font-display);
  line-height: 1.15;
}

.num-list-title {
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 7px;
  letter-spacing: -0.01em;
  font-family: var(--font-display);
}

.num-list-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* =============================================
   ABOUT HERO — editorial split layout
   Left: giant stat. Right: mission + stats strip.
   ============================================= */

/* =============================================
   TECHNOLOGY MATRIX — dense reference layout
   ============================================= */

/* =============================================
   CONTACT BOLD HERO
   ============================================= */
.contact-hero-bold {
  padding: calc(var(--nav-height) + 80px) 0 72px;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.contact-hero-bold::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--bg-secondary);
  background-image: radial-gradient(rgba(251, 192, 61, 0.07) 1px, transparent 1px);
  background-size: 32px 32px;
  z-index: 0;
}

.contact-hero-bold::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 75% 55% at 50% 55%, rgba(251, 192, 61, 0.06) 0%, transparent 65%);
  z-index: 0;
}

.contact-hero-bold .container {
  position: relative;
  z-index: 1;
}

.contact-display-title {
  font-size: clamp(2.2rem, 5vw, 4.2rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.06;
  font-family: var(--font-display);
  margin-bottom: 20px;
}

.contact-email-link {
  font-size: clamp(1.3rem, 3vw, 2.6rem);
  font-weight: 700;
  font-family: var(--font-display);
  color: var(--accent);
  letter-spacing: -0.03em;
  text-decoration: none;
  border-bottom: 2px solid rgba(251, 192, 61, 0.3);
  padding-bottom: 4px;
  transition: border-color var(--transition);
  display: inline-block;
}

.contact-email-link:hover {
  border-color: var(--accent);
}

.contact-hero-meta {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-top: 36px;
  flex-wrap: wrap;
}

.contact-meta-item {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.contact-meta-item svg {
  width: 14px;
  height: 14px;
  color: var(--accent);
  flex-shrink: 0;
}

/* =============================================
   SERVICES — full-width AI section layout
   ============================================= */

.ai-full-grid {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 80px;
  align-items: start;
}

/* =============================================
   RESPONSIVE — new components
   ============================================= */
@media (max-width: 1024px) {

  .ai-full-grid {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  /* AI Service page */
}

@media (max-width: 768px) {
  .feature-row-item {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 32px 0;
  }

  .feature-row-num {
    display: none;
  }

  .num-list {
    grid-template-columns: 1fr;
  }

  .num-list-item:nth-child(odd) {
    padding-right: 0;
    border-right: none;
  }

  .num-list-item:nth-child(even) {
    padding-left: 0;
  }

  .num-list-item:nth-last-child(2) {
    border-bottom: 1px solid var(--border);
  }

  /* AI Service page */
}

/* =============================================

/* =============================================
   MAGENTIZ — Brand & new components
   ============================================= */

/* --- Accessibility helpers --- */
.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 2000;
  padding: 10px 16px;
  background: var(--brand);
  color: #000;
  font-weight: 600;
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 12px;
}

/* --- Logo: icon + wordmark, swaps with theme --- */
.nav-logo .logo-mark {
  width: 40px;
  height: 40px;
}

.logo-on-light,
html.light .logo-on-dark {
  display: none;
}

html.light .logo-on-light {
  display: block;
}

.logo-word {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text-primary);
}

/* --- Light mode: primary actions keep the brand yellow --- */
html.light .btn-primary,
html.light .nav-cta {
  background: var(--brand);
  color: #000;
}

html.light .btn-primary:hover,
html.light .nav-cta:hover {
  background: #f0b21f;
}

/* --- Section header row (title left, action right) --- */
.section-head-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 32px;
  flex-wrap: wrap;
  margin-bottom: 52px;
}

.section-head-row .section-title {
  margin-bottom: 0;
}

.section-head-row .btn {
  flex-shrink: 0;
}

.feature-row-title a {
  color: inherit;
}

.feature-row-title a:hover {
  color: var(--accent);
}

/* --- Hero: stack health panel --- */
.stack-panel {
  position: relative;
  z-index: 1;
  margin: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card), var(--shadow-glow);
  overflow: hidden;
  font-size: 0.8rem;
}

.stack-panel-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-secondary);
}

.stack-panel-dots {
  display: inline-flex;
  gap: 6px;
}

.stack-panel-dots i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--border-light);
}

.stack-panel-title {
  flex: 1;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.74rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stack-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  color: #4ade80;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

html.light .stack-live {
  color: #15803d;
}

.stack-live .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  animation: pulseDot 2.2s ease-in-out infinite;
}

.stack-rows {
  padding: 8px 18px;
}

.stack-rows li {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "name val"
    "role role"
    "bar bar";
  column-gap: 12px;
  row-gap: 4px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--border);
}

.stack-rows li:last-child {
  border-bottom: none;
}

.stack-name {
  grid-area: name;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text-primary);
}

.stack-role {
  grid-area: role;
  color: var(--text-muted);
  font-size: 0.74rem;
}

.stack-val {
  grid-area: val;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.76rem;
  color: var(--accent);
}

.stack-bar {
  grid-area: bar;
  height: 4px;
  border-radius: 4px;
  background: var(--border);
  overflow: hidden;
  margin-top: 4px;
}

.stack-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent-dim), var(--brand));
}

.stack-checks {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--border);
}

.stack-check {
  padding: 12px 14px;
  border-right: 1px solid var(--border);
}

.stack-check:last-child {
  border-right: none;
}

.stack-check-label {
  display: block;
  font-size: 0.68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}

.stack-check-val {
  font-weight: 600;
  font-size: 0.78rem;
  color: var(--text-primary);
}

.stack-check-val.ok {
  color: #4ade80;
}

html.light .stack-check-val.ok {
  color: #15803d;
}

.stack-caption {
  padding: 10px 18px 14px;
  font-size: 0.7rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
}

/* --- Homepage: grouped stack --- */
.stack-groups {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.stack-group {
  background: var(--bg-secondary);
  padding: 28px;
}

.stack-group-title {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.stack-group-list li {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  line-height: 1.7;
}

/* --- Inner page hero: jump links --- */
.page-jump {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  margin-top: 32px;
}

.page-jump a {
  font-size: 0.82rem;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
  transition: color var(--transition);
}

.page-jump a span {
  color: var(--accent);
  margin-right: 6px;
  font-variant-numeric: tabular-nums;
}

.page-jump a:hover {
  color: var(--text-primary);
}

/* --- Services page --- */
.service-grid {
  gap: 72px;
  align-items: start;
}

.service-lead {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 24px;
  font-size: 1rem;
  max-width: 68ch;
}

.tag-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.tag-row .tech-tag {
  font-size: 0.8rem;
  padding: 6px 14px;
}

.service-feature-item .card-text {
  font-size: 0.85rem;
}

.service-feature-item.span-2 {
  grid-column: 1 / -1;
}

.service-head {
  max-width: 820px;
  margin-bottom: 48px;
}

.lifecycle {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  list-style: none;
}

.lifecycle-step {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  transition: border-color var(--transition), transform var(--transition);
}

.lifecycle-step:hover {
  border-color: rgba(251, 192, 61, 0.45);
  transform: translateY(-3px);
}

.lifecycle-num {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 18px;
}

.lifecycle-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}

.lifecycle-desc {
  font-size: 0.84rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 18px;
  flex: 1;
}

.lifecycle-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.service-cta-row {
  margin-top: 40px;
}

.ai-feature-title {
  display: block;
  margin-bottom: 4px;
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: var(--font-display);
}

.ai-feature-text {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* --- Technology page --- */
.tool-layer {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 48px;
  padding: 48px 0;
  border-bottom: 1px solid var(--border);
  scroll-margin-top: calc(var(--nav-height) + 24px);
}

.tool-layer:first-child {
  padding-top: 0;
}

.tool-layer-num {
  display: block;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 10px;
}

.tool-layer-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 8px;
}

.tool-layer-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}

.tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
  transition: border-color var(--transition), transform var(--transition);
}

.tool-card:hover {
  border-color: rgba(251, 192, 61, 0.45);
  transform: translateY(-2px);
}

.tool-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.tool-role {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.tool-text {
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

.trademark-note {
  margin-top: 32px;
  font-size: 0.76rem;
  color: var(--text-muted);
  max-width: 70ch;
}

/* --- About page --- */
.about-split {
  gap: 72px;
  align-items: start;
}

.prose p {
  color: var(--text-secondary);
  line-height: 1.85;
  font-size: 1.02rem;
  margin-bottom: 20px;
  max-width: 68ch;
}

.engage-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.engage-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 2px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 28px;
}

.engage-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}

.engage-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* --- Contact page --- */
.contact-display-title {
  margin-bottom: 0;
}

.contact-side {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.contact-next {
  border-top: 2px solid var(--accent);
}

.contact-next .card-title {
  margin-bottom: 20px;
}

/* --- Simple pages (404, thanks) --- */
.simple-page {
  min-height: 72vh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-height) + 80px) 0 80px;
}

.simple-page .page-hero-desc {
  margin-bottom: 36px;
}

.simple-page .cta-actions {
  justify-content: flex-start;
}

/* --- Responsive: Magentiz components --- */
@media (max-width: 1024px) {
  .stack-panel {
    max-width: 520px;
  }

  .lifecycle {
    grid-template-columns: repeat(2, 1fr);
  }

  .stack-groups {
    grid-template-columns: repeat(2, 1fr);
  }

  .tool-layer {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

@media (max-width: 768px) {
  .service-grid,
  .about-split {
    gap: 32px;
  }

  .engage-grid {
    grid-template-columns: 1fr;
  }

  .ai-full-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .logo-word {
    font-size: 1.15rem;
  }
}

@media (max-width: 560px) {
  .lifecycle,
  .stack-groups,
  .service-feature-grid {
    grid-template-columns: 1fr;
  }

  .stack-checks {
    grid-template-columns: 1fr;
  }

  .stack-check {
    border-right: none;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: baseline;
  }

  .stack-check:last-child {
    border-bottom: none;
  }

  .stack-check-label {
    margin-bottom: 0;
  }

  .container {
    padding: 0 16px;
  }
}

/* Hero title sized so "Magento that stays fast" holds one line on desktop */
.hero-title {
  font-size: clamp(2.4rem, 4.3vw, 3.6rem);
}

.ai-full-grid {
  grid-template-columns: 420px 1fr;
  gap: 64px;
}

@media (max-width: 1024px) {
  .ai-full-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 768px) {
  .hero-title br {
    display: none;
  }

  .theme-toggle {
    margin-left: auto;
    margin-right: 8px;
  }
}

/* Decorative section numbers: rendered via CSS so they are not read as content */
.service-number::before {
  content: attr(data-num);
}

/* Navbar: menu, theme toggle and language switch grouped on the right */
.nav-inner {
  justify-content: flex-start;
  gap: 8px;
}

.nav-menu {
  margin-left: auto;
}

.theme-toggle {
  margin-left: 16px;
}

.lang-switch {
  margin-right: 0;
}

@media (max-width: 768px) {
  .theme-toggle {
    margin-left: auto;
    margin-right: 0;
  }
}

/* Form rows: fields already carry their own bottom margin */

/* --- Case study (homepage) --- */

/* --- Inline text links --- */

/* =============================================
   NAV — collapsed menu (tablet & mobile, ≤ 960px)
   ============================================= */
@media (max-width: 960px) {
  .nav-menu {
    display: none;
    position: fixed;
    top: calc(var(--nav-height) + 20px);
    left: 12px;
    right: 12px;
    margin: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 10px;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
    max-height: calc(100dvh - var(--nav-height) - 40px);
    overflow-y: auto;
  }

  .nav-menu.open {
    display: flex;
    animation: menuIn 0.18s ease-out;
  }

  .nav-menu li {
    width: 100%;
  }

  .nav-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 14px 16px;
    font-size: 1rem;
  }

  .nav-link::after {
    content: '→';
    color: var(--text-muted);
    font-size: 0.9rem;
  }

  .nav-link.active::after {
    color: var(--accent);
  }

  .nav-cta {
    display: block;
    width: 100%;
    margin: 8px 0 0;
    padding: 14px 16px;
    text-align: center;
    font-size: 1rem;
  }

  .nav-toggle {
    display: flex;
  }

  .theme-toggle {
    margin-left: auto;
  }

  /* Dim the page behind the open menu */
  .navbar.menu-open {
    background: var(--bg-primary);
    box-shadow: 0 1px 0 var(--border);
  }

  .navbar.menu-open::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
  }
}

@keyframes menuIn {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .nav-menu.open { animation: none; }
}

/* =============================================
   POLISH — v2
   ============================================= */

/* Service numbers on the homepage: readable, on-brand */
.feature-row-num {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--accent);
  line-height: 1;
  padding-top: 2px;
}

.feature-row-item {
  grid-template-columns: 64px 1fr 1.5fr;
}

/* Stack groups: icon + title */
.stack-group-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.stack-group-icon {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--accent-glow);
  color: var(--accent);
  flex-shrink: 0;
}

.stack-group-icon svg {
  width: 17px;
  height: 17px;
}

.stack-group {
  transition: background var(--transition);
}

.stack-group:hover {
  background: var(--bg-card);
}

/* CTA: brand-yellow card */
.cta-section {
  padding: 96px 0;
}

.cta-section::before,
.cta-section::after {
  display: none;
}

.cta-section > .container {
  position: relative;
  overflow: hidden;
  width: min(1144px, calc(100% - 32px));
  padding: 80px 48px;
  border-radius: 28px;
  background:
    radial-gradient(rgba(0, 0, 0, 0.09) 1.2px, transparent 1.2px) 0 0 / 22px 22px,
    radial-gradient(ellipse 60% 90% at 85% 0%, rgba(255, 255, 255, 0.35), transparent 60%),
    var(--brand);
  color: #111;
}

.cta-section .container .section-label,
.cta-section .container .section-title {
  color: #111;
}

.cta-section .container .section-label::before {
  background: #111;
}

.cta-section .container .section-subtitle {
  color: rgba(17, 17, 17, 0.78);
  margin-left: auto;
  margin-right: auto;
}

.cta-section .container .btn-primary {
  background: #111;
  color: #fff;
}

.cta-section .container .btn-primary:hover {
  background: #000;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
}

.cta-section .container .btn-outline {
  color: #111;
  border-color: rgba(17, 17, 17, 0.35);
}

.cta-section .container .btn-outline:hover {
  color: #111;
  border-color: #111;
  background: rgba(0, 0, 0, 0.06);
}

.cta-section .container :focus-visible {
  outline-color: #111;
}

/* About hero: facts card on the right */
.page-hero-split {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 64px;
  align-items: end;
}

.hero-facts {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 8px 24px;
  box-shadow: var(--shadow-card);
}

.hero-facts li {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 4px 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}

.hero-facts li:last-child {
  border-bottom: none;
}

.hero-fact-icon {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--accent-glow);
  color: var(--accent);
}

.hero-fact-icon svg {
  width: 18px;
  height: 18px;
}

.hero-fact-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-primary);
}

.hero-fact-text {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* FAQ (native <details>, no JS needed) */
.faq-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 64px;
  align-items: start;
}

.faq-list {
  border-top: 1px solid var(--border);
}

.faq-item {
  border-bottom: 1px solid var(--border);
}

.faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 22px 0;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: '+';
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--border-light);
  color: var(--accent);
  font-family: 'Inter', sans-serif;
  font-size: 1.1rem;
  transition: transform var(--transition), background var(--transition);
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
  background: var(--accent-glow);
}

.faq-item summary:hover {
  color: var(--accent);
}

.faq-answer {
  padding: 0 54px 24px 0;
  color: var(--text-secondary);
  line-height: 1.8;
  font-size: 0.95rem;
}

/* Contact form status message */

@media (max-width: 1024px) {
  .page-hero-split,
  .faq-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 768px) {
  .feature-row-num {
    font-size: 1.3rem;
  }

  .cta-section {
    padding: 64px 0;
  }

  .cta-section > .container {
    padding: 56px 24px;
    border-radius: 22px;
  }

  .faq-answer {
    padding-right: 0;
  }
}

/* Balanced line breaks for headings (avoids one-word last lines) */
h1, h2, h3,
.hero-title,
.page-hero-title,
.section-title {
  text-wrap: balance;
}

/* =============================================================
   LAYOUT — MOBILE-FIRST (final layer)
   Base rules = phones. Then enhance at:
     sm ≥ 640px  ·  md ≥ 768px  ·  lg ≥ 1025px
   Supersedes the older desktop-first overrides above.
   ============================================================= */

:root {
  --gutter: 16px;
  --section-y: 64px;
}

.container {
  padding: 0 var(--gutter);
}

.section,
.service-section {
  padding: var(--section-y) 0;
}

/* ---- Typography scale ---- */
.hero-title {
  font-size: clamp(2.1rem, 1.25rem + 3.4vw, 3.6rem);
  margin-bottom: 18px;
}

.page-hero-title,
.contact-display-title {
  font-size: clamp(2rem, 1.3rem + 2.9vw, 3.5rem);
}

.section-title {
  font-size: clamp(1.65rem, 1.2rem + 2vw, 2.75rem);
}

.hero-desc,
.page-hero-desc {
  font-size: 1rem;
  line-height: 1.7;
}

.section-label,
.stack-group-title,
.tool-role {
  font-size: 0.75rem;
}

.btn {
  width: auto;
  justify-content: center;
  min-height: 48px;
}

/* ---- Navbar controls: 44px tap targets ---- */
.theme-toggle {
  width: 40px;
  height: 40px;
}

.lang-switch {
  height: 40px;
  padding: 0 4px;
}

.lang-opt {
  min-width: 34px;
  min-height: 32px;
  padding: 0 8px;
  font-size: 0.75rem;
}

.nav-toggle {
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
}

.nav-inner {
  gap: 6px;
}

/* ---- Hero ---- */
.hero {
  min-height: 0;
  padding-top: calc(var(--nav-height) + 36px);
  padding-bottom: 48px;
}

.hero-inner {
  grid-template-columns: 1fr;
  gap: 40px;
}

.hero-badge {
  margin-bottom: 18px;
}

.hero-desc {
  margin-bottom: 28px;
}

.hero-actions {
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}

.hero-actions .btn {
  width: 100%;
}

/* Tags: one swipeable row on phones */
.hero-tags {
  flex-wrap: nowrap;
  overflow-x: auto;
  margin: 0 calc(var(--gutter) * -1);
  padding: 2px var(--gutter);
  scrollbar-width: none;
  -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent);
  mask-image: linear-gradient(90deg, #000 85%, transparent);
}

.hero-tags::-webkit-scrollbar {
  display: none;
}

.hero-tag {
  flex-shrink: 0;
}

.stack-panel {
  max-width: none;
  width: 100%;
}

/* ---- Stats bar: 2 × 2 on phones ---- */
.stats-bar {
  padding: 8px 0;
}

.stats-grid {
  grid-template-columns: 1fr 1fr;
}

.stat-item,
.stat-item:nth-child(3) {
  padding: 22px 8px;
  border-right: 1px solid var(--border);
}

.stat-item:nth-child(2n) {
  border-right: none;
}

.stat-item:nth-child(n + 3) {
  border-top: 1px solid var(--border);
}

.stat-number {
  font-size: 2.1rem;
  margin-bottom: 6px;
}

.stat-label {
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  line-height: 1.45;
}

/* ---- Section header row ---- */
.section-head-row {
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 32px;
}

/* ---- Services list (homepage) ---- */
.feature-row-item {
  grid-template-columns: 1fr;
  gap: 14px;
  padding: 28px 0;
}

.feature-row-num {
  display: block;
  font-size: 1.15rem;
}

.feature-row-list li {
  font-size: 0.86rem;
  line-height: 1.55;
  align-items: flex-start;
}

/* ---- Case study ---- */

/* ---- Stack groups: 2 columns on phones ---- */
.stack-groups {
  grid-template-columns: 1fr 1fr;
}

.stack-group {
  padding: 18px 16px;
}

.stack-group-title {
  align-items: flex-start;
  flex-direction: column;
  gap: 10px;
  letter-spacing: 0.1em;
}

.stack-group-list li {
  font-size: 1rem;
  line-height: 1.65;
}

/* ---- Numbered lists (process, principles) ---- */
.num-list {
  grid-template-columns: 1fr;
}

.num-list-item,
.num-list-item:nth-child(odd),
.num-list-item:nth-child(even) {
  padding: 22px 0;
  border-right: none;
  grid-template-columns: 36px 1fr;
  gap: 12px;
}

.num-list-item:nth-last-child(2) {
  border-bottom: 1px solid var(--border);
}

.num-list-title {
  font-size: 1.05rem;
}

.num-list-desc {
  font-size: 0.9rem;
}

/* ---- Inner page heroes ---- */
.page-hero,
.contact-hero-bold {
  padding: calc(var(--nav-height) + 36px) 0 44px;
}

.page-hero-split {
  grid-template-columns: 1fr;
  gap: 32px;
}

.page-jump {
  gap: 10px 20px;
  margin-top: 24px;
}

.contact-email-link {
  font-size: clamp(1.25rem, 0.9rem + 2vw, 2.6rem);
  word-break: break-word;
}

.contact-hero-meta {
  flex-direction: column;
  gap: 10px;
}

/* ---- Services page ---- */
.service-number {
  font-size: 3rem;
}

.grid-2,
.service-grid,
.about-split,
.ai-full-grid,
.faq-layout {
  grid-template-columns: 1fr;
  gap: 32px;
}

.service-feature-grid {
  grid-template-columns: 1fr;
}

.service-feature-item.span-2 {
  grid-column: auto;
}

.service-grid .btn,
.service-cta-row .btn,
.ai-full-grid .btn {
  width: 100%;
}

/* Lifecycle: swipeable cards on phones */
.lifecycle {
  grid-template-columns: none;
  grid-auto-flow: column;
  grid-auto-columns: 82%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  margin: 0 calc(var(--gutter) * -1);
  padding: 4px var(--gutter) 12px;
  scroll-padding-left: var(--gutter);
  scrollbar-width: thin;
}

.lifecycle-step {
  scroll-snap-align: start;
}

/* ---- Technology page ---- */
.tool-layer {
  grid-template-columns: 1fr;
  gap: 20px;
  padding: 36px 0;
}

.tool-grid {
  grid-template-columns: 1fr;
}

/* ---- FAQ ---- */
.faq-item summary {
  font-size: 1rem;
  padding: 18px 0;
  gap: 16px;
}

.faq-answer {
  padding: 0 0 20px;
  font-size: 0.92rem;
}

/* ---- About ---- */
.engage-grid {
  grid-template-columns: 1fr;
}

/* ---- Contact ---- */

/* ---- CTA card ---- */
.cta-section {
  padding: 56px 0;
}

.cta-section > .container {
  width: calc(100% - var(--gutter) * 2);
  padding: 44px 20px;
  border-radius: 22px;
}

.cta-actions {
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
}

/* ---- Footer ---- */
.footer {
  padding: 48px 0 28px;
}

.footer-grid {
  grid-template-columns: 1fr 1fr;
  gap: 32px 20px;
  margin-bottom: 36px;
}

.footer-brand {
  grid-column: 1 / -1;
}

.footer-links a {
  display: inline-block;
  padding: 6px 0;
}

.footer-bottom {
  flex-direction: column;
  gap: 10px;
  text-align: center;
}

/* =================== sm ≥ 640px =================== */
@media (min-width: 640px) {
  :root {
    --gutter: 24px;
    --section-y: 80px;
  }

  .hero-desc,
  .page-hero-desc {
    font-size: 1.08rem;
  }

  .hero-actions,
  .cta-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .cta-actions {
    justify-content: center;
    align-items: center;
  }

  .hero-actions .btn,
  .service-grid .btn,
  .service-cta-row .btn,
  .ai-full-grid .btn {
    width: auto;
  }

  .hero-tags {
    flex-wrap: wrap;
    overflow: visible;
    margin: 0;
    padding: 0;
    -webkit-mask-image: none;
    mask-image: none;
  }

  .stack-panel {
    max-width: 560px;
  }

  .stack-groups {
    grid-template-columns: repeat(3, 1fr);
  }

  .stack-group {
    padding: 24px;
  }

  .stack-group-title {
    flex-direction: row;
    align-items: center;
  }

  .service-feature-grid,
  .tool-grid {
    grid-template-columns: 1fr 1fr;
  }

  .service-feature-item.span-2 {
    grid-column: 1 / -1;
  }

  .lifecycle {
    grid-auto-columns: 46%;
  }

  .contact-hero-meta {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 12px 28px;
  }

  .cta-section > .container {
    padding: 64px 40px;
  }

  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
  }

  .footer-brand {
    grid-column: auto;
  }

  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

/* =================== md ≥ 768px =================== */
@media (min-width: 768px) {
  .section-head-row {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 52px;
  }

  .stats-bar {
    padding: 44px 0;
  }

  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .stat-item,
  .stat-item:nth-child(2n),
  .stat-item:nth-child(3) {
    padding: 0 16px;
    border-right: 1px solid var(--border);
  }

  .stat-item:nth-child(n + 3) {
    border-top: none;
  }

  .stat-item:last-child {
    border-right: none;
  }

  .stat-number {
    font-size: 2.6rem;
  }

  .feature-row-item {
    grid-template-columns: 56px 1fr;
    gap: 20px 28px;
    padding: 40px 0;
  }

  .feature-row-item > div:last-child {
    grid-column: 2;
  }

  .feature-row-num {
    font-size: 1.4rem;
  }

  .num-list {
    grid-template-columns: 1fr 1fr;
  }

  .num-list-item:nth-child(odd) {
    padding: 30px 40px 30px 0;
    border-right: 1px solid var(--border);
  }

  .num-list-item:nth-child(even) {
    padding: 30px 0 30px 40px;
  }

  .num-list-item:nth-last-child(1),
  .num-list-item:nth-last-child(2) {
    border-bottom: none;
  }

  .engage-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .faq-item summary {
    font-size: 1.08rem;
    padding: 22px 0;
  }

  .faq-answer {
    padding-right: 54px;
  }
}

/* =================== lg ≥ 1025px (desktop) =================== */
@media (min-width: 1025px) {
  :root {
    --gutter: 28px;
    --section-y: 100px;
  }

  .hero {
    min-height: 100vh;
    padding-top: calc(var(--nav-height) + 60px);
    padding-bottom: 80px;
  }

  .hero-inner {
    grid-template-columns: 1fr 400px;
    gap: 72px;
  }

  .hero-desc {
    font-size: 1.1rem;
    margin-bottom: 40px;
  }

  .hero-actions {
    margin-bottom: 40px;
  }

  .stack-panel {
    max-width: none;
  }

  .stats-bar {
    padding: 52px 0;
  }

  .stat-item,
  .stat-item:nth-child(2n),
  .stat-item:nth-child(3) {
    padding: 0 24px;
  }

  .stat-item:last-child {
    border-right: none;
  }

  .stat-number {
    font-size: 3rem;
  }

  .feature-row-item {
    grid-template-columns: 64px 1fr 1.5fr;
    gap: 44px;
    padding: 44px 0;
  }

  .feature-row-item > div:last-child {
    grid-column: auto;
  }

  .feature-row-num {
    font-size: 1.6rem;
  }

  .page-hero,
  .contact-hero-bold {
    padding: calc(var(--nav-height) + 80px) 0 80px;
  }

  .page-hero-split {
    grid-template-columns: 1.3fr 1fr;
    gap: 64px;
  }

  .grid-2,
  .about-split {
    grid-template-columns: 1fr 1fr;
    gap: 72px;
  }

  .service-grid {
    grid-template-columns: 1fr 1fr;
    gap: 72px;
  }

  .ai-full-grid {
    grid-template-columns: 420px 1fr;
    gap: 64px;
  }

  .faq-layout {
    grid-template-columns: 340px 1fr;
    gap: 64px;
  }

  .service-number {
    font-size: 5rem;
  }

  .lifecycle {
    grid-auto-flow: row;
    grid-auto-columns: auto;
    grid-template-columns: repeat(5, 1fr);
    overflow: visible;
    margin: 0;
    padding: 0;
  }

  .tool-layer {
    grid-template-columns: 280px 1fr;
    gap: 48px;
    padding: 48px 0;
  }

  .tool-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }

  .cta-section {
    padding: 96px 0;
  }

  .cta-section > .container {
    width: min(1144px, calc(100% - var(--gutter) * 2));
    padding: 80px 48px;
    border-radius: 28px;
  }

  .footer {
    padding: 72px 0 36px;
  }

  .footer-grid {
    gap: 56px;
    margin-bottom: 56px;
  }
}

/* Grid children may shrink below their content (fixes hero overflow on phones) */
.hero-inner > *,
.page-hero-split > *,
.faq-layout > *,
.service-grid > *,
.ai-full-grid > * {
  min-width: 0;
}

/* Manual line breaks in headings only apply on wide screens */
.br-lg {
  display: none;
}

@media (min-width: 768px) {
  .br-lg {
    display: inline;
  }
}

/* CTA label is centred: drop the leading dash so it never strands when wrapping */
.cta-section .container .section-label {
  justify-content: center;
}

.cta-section .container .section-label::before {
  display: none;
}

/* Panel title may wrap instead of being cut on narrow phones */
.stack-panel-title {
  white-space: normal;
  line-height: 1.4;
}

/* =============================================
   CONTACT — information layout (no form)
   ============================================= */
.contact-mail-btn {
  margin-top: 28px;
  gap: 10px;
}

.contact-mail-btn svg {
  width: 18px;
  height: 18px;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  align-items: start;
}

.contact-grid > * {
  min-width: 0;
}

.contact-info-card {
  padding: 24px 20px;
}

.contact-info-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.contact-info-value {
  overflow-wrap: anywhere;
}

.contact-info-value a {
  color: var(--accent);
}

.contact-tips {
  border-top: 2px solid var(--accent);
}

.contact-tips .card-title,
.contact-next .card-title {
  margin-bottom: 16px;
}

.contact-tips-list li {
  position: relative;
  padding: 10px 0 10px 26px;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
}

.contact-tips-list li:last-child {
  border-bottom: none;
}

.contact-tips-list li::before {
  content: '';
  position: absolute;
  left: 2px;
  top: 17px;
  width: 12px;
  height: 7px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}

@media (max-width: 639px) {
  .contact-mail-btn {
    width: 100%;
  }
}

@media (min-width: 640px) {
  .contact-info-card {
    padding: 32px;
  }
}

@media (min-width: 1025px) {
  .contact-grid {
    grid-template-columns: 1.1fr 1fr;
    gap: 24px;
  }
}

.contact-display-title {
  margin-bottom: 16px;
}

.contact-hero-meta {
  align-items: flex-start;
  justify-content: flex-start;
  margin-top: 24px;
}

/* Links inside contact values are underlined, not distinguished by colour alone */
.contact-info-value a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
