/* ============================================================
   Cabral Djassi - Sections, Mobile menu, Tweaks, Responsive
   ============================================================ */

/* ---- generic card ---- */
.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 28px;
  transition: transform var(--dur-base) var(--ease-out), border-color var(--dur-base),
              background var(--dur-base), box-shadow var(--dur-base);
  overflow: hidden;
}
.card:hover { border-color: var(--border-strong); }
.card .card-glow {
  position: absolute;
  width: 320px; height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--glow), transparent 65%);
  filter: blur(20px);
  opacity: 0;
  transform: translate(-50%, -50%);
  pointer-events: none;
  transition: opacity var(--dur-base);
  z-index: 0;
}
.card:hover .card-glow { opacity: 0.5; }
.card > * { position: relative; z-index: 1; }

/* ============================================================
   SERVICES
   ============================================================ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.service-card { min-height: 260px; display: flex; flex-direction: column; }
.service-card .ico {
  width: 52px; height: 52px;
  border-radius: var(--r-sm);
  display: grid; place-items: center;
  background: var(--grad-brand-soft);
  border: 1px solid var(--border);
  color: var(--primary);
  margin-bottom: 22px;
  transition: transform var(--dur-base) var(--ease-spring);
}
.service-card:hover .ico { transform: translateY(-3px) rotate(-4deg); }
.service-card .ico svg { width: 26px; height: 26px; }
.service-card h3 { font-size: var(--fs-h4); }
.service-card p { margin-top: 10px; color: var(--text-2); font-size: 0.98rem; flex: 1; }
.service-card .tags {
  display: flex; flex-wrap: wrap; gap: 7px; margin-top: 20px;
}
.service-card .tags span {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  padding: 4px 9px;
  border-radius: var(--r-xs);
  border: 1px solid var(--border);
}
.service-card .idx {
  position: absolute; top: 22px; right: 24px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ============================================================
   PROJECTS
   ============================================================ */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}
.project {
  grid-column: span 1;
  border-radius: var(--r-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
  transition: transform var(--dur-base) var(--ease-out), border-color var(--dur-base), box-shadow var(--dur-base);
}
.project.wide { grid-column: span 2; }
.project:hover { transform: translateY(-5px); border-color: var(--border-strong); box-shadow: var(--shadow-lg); }
.project .thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--surface-2);
}
.project.wide .thumb { aspect-ratio: 21 / 9; }
.project-mark {
  width: clamp(84px, 10vw, 112px);
  height: clamp(84px, 10vw, 112px);
  border-radius: 28px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent-a), var(--accent-b));
  box-shadow:
    0 18px 42px rgba(6, 18, 37, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  color: white;
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 1rem + 1vw, 1.7rem);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.project .thumb::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.5), transparent 55%);
  opacity: 0;
  transition: opacity var(--dur-base);
  pointer-events: none;
}
.project:hover .thumb::after { opacity: 1; }
.project .meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px;
}
.project .meta > div { flex: 1; min-width: 0; }
.project .meta h3 { font-size: var(--fs-h4); }
.project .meta .cat {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.project .meta .copy {
  margin-top: 10px;
  color: var(--text-2);
  font-size: 0.94rem;
  line-height: 1.55;
  max-width: 42ch;
}
.project .meta .yr { font-family: var(--font-mono); font-size: 0.8rem; color: var(--text-muted); }
.project .tags-row { display: flex; gap: 7px; flex-wrap: wrap; padding: 0 24px 22px; }
.project .tags-row span {
  font-size: 0.74rem; color: var(--text-2);
  padding: 4px 10px; border-radius: var(--r-pill);
  border: 1px solid var(--border);
}
.project-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 24px 22px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--primary);
  text-decoration: none;
}
.project-link svg { width: 14px; height: 14px; }
.project-link:hover { text-decoration: underline; }

/* ============================================================
   PROCESS
   ============================================================ */
.process-wrap { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: clamp(28px, 5vw, 72px); align-items: start; }
.process-sticky { position: sticky; top: 120px; }
.process-steps { display: flex; flex-direction: column; gap: 16px; }
.step {
  position: relative;
  padding: 26px 28px 26px 78px;
  border-radius: var(--r-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  transition: border-color var(--dur-base), background var(--dur-base), transform var(--dur-base);
}
.step:hover { transform: translateX(5px); border-color: var(--border-strong); }
.step .n {
  position: absolute;
  left: 24px; top: 26px;
  width: 38px; height: 38px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--primary);
  border: 1px solid var(--border-strong);
  background: var(--grad-brand-soft);
}
.step h3 { font-size: var(--fs-h4); }
.step p { margin-top: 8px; color: var(--text-2); font-size: 0.96rem; }
.process-aside h2 { font-size: var(--fs-h2); }
.process-aside .num-big {
  font-family: var(--font-display);
  font-size: clamp(4rem, 10vw, 8rem);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 0.9;
  background: var(--grad-text);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ============================================================
   TECH STACK
   ============================================================ */
.stack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 14px;
}
.stack-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 26px 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  background: var(--surface);
  text-align: center;
  transition: transform var(--dur-base) var(--ease-out), border-color var(--dur-base), background var(--dur-base);
}
.stack-item:hover { transform: translateY(-4px); border-color: var(--border-strong); background: var(--surface-2); }
.stack-item svg { width: 34px; height: 34px; }
.stack-item span { font-size: var(--fs-small); font-weight: 600; color: var(--text-2); }
.stack-cats { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }

/* ============================================================
   STATS
   ============================================================ */
.stats-band {
  border-radius: var(--r-xl);
  border: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
  position: relative;
}
.stats-band::before {
  content: ""; position: absolute; inset: 0;
  background: var(--grad-brand-soft);
  opacity: 0.6; pointer-events: none;
}
.stats-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(max-content, 1.35fr) repeat(3, minmax(0, 1fr));
}
.stat-cell {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: clamp(28px, 4vw, 48px);
  border-right: 1px solid var(--border);
}
.stat-cell:last-child { border-right: none; }
.stat-cell .v {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 0.9rem + 1.5vw, 2.5rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.12;
  padding-bottom: 0.08em;
  background: var(--grad-text);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}
.stat-cell--name .v {
  font-size: clamp(2.4rem, 1.5rem + 3vw, 4rem);
  white-space: nowrap;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}
.stat-cell .k {
  margin-top: auto;
  padding-top: 12px;
  color: var(--text-2);
  font-size: 0.98rem;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}

/* ============================================================
   HOME SNAPSHOT
   ============================================================ */
.home-snapshot .section-head { max-width: 760px; }
.snapshot-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 18px;
}
.snapshot-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 100%;
}
.snapshot-card h3 { font-size: var(--fs-h3); }
.snapshot-card p { color: var(--text-2); }
.snapshot-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.snapshot-list { display: flex; flex-direction: column; gap: 16px; }
.snapshot-item {
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.snapshot-item:first-child {
  padding-top: 0;
  border-top: none;
}
.snapshot-item h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: var(--tracking-tight);
}
.snapshot-item p {
  margin-top: 6px;
  color: var(--text-2);
  font-size: 0.94rem;
}
.snapshot-card .link-arrow { margin-top: auto; }

/* ============================================================
   TEAM
   ============================================================ */
.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.member { text-align: left; }
.member .ph {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface-2);
  margin-bottom: 16px;
}
.member .ph image-slot { width: 100%; height: 100%; }
.member .ph .role-tag {
  position: absolute; left: 12px; bottom: 12px;
  font-family: var(--font-mono); font-size: 0.72rem;
  padding: 5px 10px; border-radius: var(--r-pill);
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--border-strong);
}
.member h3 { font-size: 1.12rem; }
.member p { color: var(--text-2); font-size: 0.92rem; margin-top: 3px; }

.profile-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 100%;
}
.profile-card h3 { font-size: var(--fs-h4); }
.profile-card p { color: var(--text-2); font-size: 0.96rem; margin-top: auto; }
.about-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
  gap: 18px;
  margin-top: 18px;
  margin-bottom: 18px;
}
.about-story-card,
.personal-info-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.about-story-card h3 {
  font-size: var(--fs-h3);
  max-width: 18ch;
}
.about-story-card p {
  color: var(--text-2);
  max-width: 68ch;
}
.about-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: auto;
}
.personal-info-list {
  display: grid;
  gap: 14px;
}
.personal-info-list div {
  display: grid;
  gap: 4px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.personal-info-list div:last-child {
  padding-bottom: 0;
  border-bottom: none;
}
.personal-info-list dt {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.personal-info-list dd {
  color: var(--text);
  font-size: 0.98rem;
}
.personal-info-list a {
  color: var(--primary);
  overflow-wrap: anywhere;
}
.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 0;
}
.profile-card .link-arrow { margin-top: 0; }

/* ============================================================
   PRICING
   ============================================================ */
.price-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: start;
}
.price-card { display: flex; flex-direction: column; padding: 30px; }
.price-card.featured {
  border-color: transparent;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    var(--grad-brand) border-box;
  border: 1.5px solid transparent;
  box-shadow: var(--shadow-glow);
}
.price-card .tier { font-family: var(--font-mono); font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-2); }
.price-card .badge {
  float: right;
  font-size: 0.72rem; font-weight: 600;
  padding: 4px 11px; border-radius: var(--r-pill);
  background: var(--grad-brand); color: #fff;
}
.price-card .amt { margin-top: 18px; display: flex; align-items: baseline; gap: 6px; }
.price-card .amt .n { font-family: var(--font-display); font-size: clamp(2.2rem,1.6rem+2vw,3rem); font-weight: 600; letter-spacing: -0.02em; }
.price-card .amt .per { color: var(--text-muted); font-size: 0.9rem; }
.price-card .desc { color: var(--text-2); margin-top: 12px; font-size: 0.95rem; }
.price-card ul.feats { margin-top: 22px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.price-card .feats li { display: flex; gap: 11px; align-items: flex-start; font-size: 0.94rem; color: var(--text); }
.price-card .feats svg { width: 18px; height: 18px; color: var(--primary); flex: none; margin-top: 1px; }
.price-card .btn { margin-top: 26px; }

.price-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  background: var(--surface);
  margin-top: 22px;
}
.price-toggle button {
  padding: 9px 18px; border-radius: var(--r-pill);
  font-size: 0.9rem; font-weight: 600; color: var(--text-2);
  transition: color var(--dur-fast), background var(--dur-fast);
}
.price-toggle button.active { background: var(--grad-brand); color: #fff; }

/* ============================================================
   CTA
   ============================================================ */
.cta {
  position: relative;
  border-radius: var(--r-xl);
  border: 1px solid var(--border);
  background: var(--surface);
  padding: clamp(40px, 7vw, 96px) clamp(24px, 5vw, 72px);
  overflow: hidden;
  text-align: center;
}
.cta::before {
  content: ""; position: absolute; inset: 0;
  background: var(--hero-veil); opacity: 0.9; pointer-events: none;
}
.cta-inner { position: relative; z-index: 1; max-width: 700px; margin-inline: auto; }
.cta h2 { font-size: var(--fs-h1); }
.cta p { margin-top: 18px; color: var(--text-2); font-size: var(--fs-lead); }
.cta .hero-cta { justify-content: center; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer { border-top: 1px solid var(--border); padding-block: clamp(48px, 7vw, 88px) 36px; position: relative; z-index: var(--z-content); }
.footer-top { display: grid; grid-template-columns: minmax(0, 1.2fr) repeat(3, minmax(0, 0.78fr)); gap: 36px; align-items: start; }
.footer-brand .brand { margin-bottom: 18px; }
.footer-brand p { color: var(--text-2); max-width: 34ch; font-size: 0.96rem; }
.footer-col h4 { font-family: var(--font-mono); font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 16px; font-weight: 500; }
.footer-col a { display: block; color: var(--text-2); padding: 6px 0; font-size: 0.96rem; transition: color var(--dur-fast); }
.footer-col a:hover { color: var(--text); }
.newsletter { margin-top: 24px; display: flex; gap: 8px; max-width: 360px; }
.newsletter input {
  flex: 1; padding: 12px 16px; border-radius: var(--r-pill);
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text); font: inherit; font-size: 0.92rem;
}
.newsletter input::placeholder { color: var(--text-muted); }
.newsletter input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--focus); }
.footer-bottom {
  display: flex; align-items: center; justify-content: space-between;
  gap: 18px; flex-wrap: wrap;
  margin-top: clamp(40px, 6vw, 72px); padding-top: 28px;
  border-top: 1px solid var(--border);
  color: var(--text-muted); font-size: 0.88rem;
}
.footer-socials { display: flex; gap: 8px; }
.footer-socials a {
  width: 40px; height: 40px; border-radius: var(--r-pill);
  border: 1px solid var(--border); display: grid; place-items: center;
  color: var(--text-2); transition: color var(--dur-fast), border-color var(--dur-fast), transform var(--dur-fast);
}
.footer-socials a:hover { color: var(--text); border-color: var(--border-strong); transform: translateY(-2px); }
.footer-socials svg { width: 18px; height: 18px; }
.footer-mega {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(3rem, 14vw, 13rem);
  line-height: 1;
  letter-spacing: -0.04em;
  text-align: center;
  margin-top: clamp(40px, 8vw, 90px);
  padding-bottom: 0.12em;
  background: linear-gradient(180deg, var(--text) -20%, transparent 120%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  opacity: 0.16;
  user-select: none;
}

/* ============================================================
   MOBILE MENU
   ============================================================ */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: var(--z-menu);
  background: var(--bg);
  display: flex;
  flex-direction: column;
  padding: 90px var(--gutter) 40px;
  transform: translateY(-100%);
  transition: transform var(--dur-menu) var(--ease-in-out);
  visibility: hidden;
}
.mobile-menu.open { transform: translateY(0); visibility: visible; }
.mobile-menu::before {
  content: ""; position: absolute; inset: 0; background: var(--hero-veil); opacity: 0.6; pointer-events: none;
}
.mobile-menu nav { position: relative; display: flex; flex-direction: column; gap: 4px; }
.mobile-menu nav a {
  font-family: var(--font-display);
  font-size: clamp(2rem, 9vw, 2.8rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out), color var(--dur-fast);
}
.mobile-menu.open nav a { opacity: 1; transform: none; }
.mobile-menu nav a:hover { color: var(--primary); }
.mobile-menu .mm-foot { position: relative; margin-top: auto; display: flex; flex-direction: column; gap: 16px; }
.mobile-menu .mm-foot .btn { width: 100%; }
.mobile-menu .mm-contact { color: var(--text-2); font-size: 0.95rem; }
body.menu-open { overflow: hidden; }
body.menu-open .nav-burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.menu-open .nav-burger span:nth-child(2) { opacity: 0; }
body.menu-open .nav-burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ============================================================
   TWEAKS PANEL
   ============================================================ */
.tweaks-panel {
  position: fixed;
  right: 18px; bottom: 18px;
  z-index: var(--z-tweaks);
  width: 312px;
  max-width: calc(100vw - 36px);
  border-radius: var(--r-lg);
  border: 1px solid var(--border-strong);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: var(--shadow-lg);
  padding: 18px;
  display: none;
  animation: tweakIn var(--dur-base) var(--ease-out);
}
.tweaks-panel.show { display: block; }
@keyframes tweakIn { from { opacity: 0; transform: translateY(14px) scale(0.98); } }
.tweaks-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.tweaks-head h4 { font-family: var(--font-display); font-size: 1rem; }
.tweaks-head button { color: var(--text-2); width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; }
.tweaks-head button:hover { color: var(--text); background: var(--surface-2); }
.tweak-group { margin-bottom: 16px; }
.tweak-group > label { display: block; font-size: var(--fs-micro); text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 8px; font-family: var(--font-mono); }
.tweak-seg { display: flex; gap: 6px; flex-wrap: wrap; }
.tweak-seg button {
  flex: 1; min-width: 64px;
  padding: 9px 6px; border-radius: var(--r-xs);
  border: 1px solid var(--border); background: var(--surface);
  font-size: 0.8rem; font-weight: 600; color: var(--text-2);
  transition: all var(--dur-fast);
}
.tweak-seg button.active { border-color: var(--primary); color: var(--text); background: var(--grad-brand-soft); }
.tweak-swatches { display: flex; gap: 8px; }
.tweak-swatches button {
  width: 34px; height: 34px; border-radius: 50%;
  border: 2px solid transparent; outline: 1px solid var(--border);
  transition: transform var(--dur-fast);
}
.tweak-swatches button.active { border-color: var(--text); transform: scale(1.08); }

/* ============================================================
   VIEW / TAB ROUTER
   ============================================================ */
.view { display: none; }
.view.active { display: block; }
.view.active { animation: viewIn 0.55s var(--ease-out) both; }
.view:not([data-view="home"]) { padding-top: clamp(86px, 10vh, 112px); }
.view:not([data-view="home"]) > .section:first-of-type { padding-top: 0; }
@keyframes viewIn {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .view.active { animation: none; }
}

/* tab indicator / active link */
.nav-links a.active { color: var(--text); }
.nav-links a.active::after { transform: scaleX(1); }
.mobile-menu nav a.active { color: var(--primary); }

/* ============================================================
   THEME SWITCH (slider)
   ============================================================ */
.theme-switch {
  position: relative;
  width: 66px; height: 34px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  background: var(--surface-2);
  display: inline-flex;
  align-items: center;
  padding: 0 7px;
  justify-content: space-between;
  transition: border-color var(--dur-fast), background var(--dur-fast);
}
.theme-switch:hover { border-color: var(--border-strong); }
.theme-switch:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--focus); }
.theme-switch .ts-ico { width: 15px; height: 15px; color: var(--text-muted); transition: color var(--dur-fast); z-index: 1; }
.theme-switch .knob {
  position: absolute;
  top: 3px; left: 3px;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--grad-brand);
  box-shadow: 0 4px 12px -3px var(--glow);
  display: grid; place-items: center;
  transform: translateX(0);
  transition: transform var(--dur-base) var(--ease-spring);
}
.theme-switch .knob svg { width: 14px; height: 14px; color: #fff; }
.theme-switch .knob .k-sun { display: none; }
[data-theme="dark"] .theme-switch .knob { transform: translateX(32px); }
[data-theme="dark"] .theme-switch .knob .k-moon { display: block; }
[data-theme="dark"] .theme-switch .knob .k-sun { display: none; }
[data-theme="light"] .theme-switch .knob { transform: translateX(0); }
[data-theme="light"] .theme-switch .knob .k-sun { display: block; }
[data-theme="light"] .theme-switch .knob .k-moon { display: none; }
[data-theme="light"] .theme-switch .ts-sun { color: transparent; }
[data-theme="dark"] .theme-switch .ts-moon { color: transparent; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-stage { order: -1; max-width: 420px; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .snapshot-grid { grid-template-columns: 1fr; }
  .stack-cats { gap: 8px; }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .process-wrap { grid-template-columns: 1fr; }
  .process-sticky { position: static; }
  .footer-top { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  body {
    padding-bottom: calc(118px + env(safe-area-inset-bottom));
  }
  .nav {
    flex-wrap: nowrap;
    align-items: center;
    gap: 10px;
    padding-top: 12px;
    padding-bottom: 12px;
  }
  .nav-links {
    position: fixed;
    left: 50%;
    bottom: calc(12px + env(safe-area-inset-bottom));
    width: min(calc(100vw - 24px), 720px);
    transform: translateX(-50%);
    z-index: calc(var(--z-nav) + 1);
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    align-items: center;
    gap: 4px;
    padding: 8px;
    overflow: hidden;
    border: 1px solid color-mix(in srgb, var(--border-strong) 72%, transparent);
    border-radius: 28px;
    background:
      linear-gradient(180deg,
        color-mix(in srgb, var(--surface) 68%, transparent),
        color-mix(in srgb, var(--surface-2) 54%, transparent));
    backdrop-filter: blur(22px) saturate(180%);
    -webkit-backdrop-filter: blur(22px) saturate(180%);
    box-shadow:
      0 18px 42px -26px rgba(7, 9, 15, 0.48),
      inset 0 1px 0 rgba(255, 255, 255, 0.24);
    scrollbar-width: none;
  }
  .nav-links::-webkit-scrollbar { display: none; }
  .nav-links a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 0;
    min-height: 62px;
    padding: 9px 4px 10px;
    font-size: 0.68rem;
    line-height: 1;
    letter-spacing: 0.01em;
    text-align: center;
    border: 1px solid transparent;
    background: transparent;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.24);
    border-radius: 20px;
    white-space: nowrap;
  }
  .nav-links a::after { display: none; }
  .nav-links .nav-icon {
    display: grid;
    place-items: center;
    width: 22px;
    height: 22px;
    flex: 0 0 auto;
    color: currentColor;
  }
  .nav-links .nav-icon svg {
    width: 20px;
    height: 20px;
  }
  .nav-links .nav-label--desktop { display: none; }
  .nav-links .nav-label--mobile { display: inline; }
  .nav-links a.active {
    background: color-mix(in srgb, var(--surface) 88%, transparent);
    border-color: var(--border-strong);
    color: var(--text);
    box-shadow:
      0 10px 24px -18px var(--glow),
      inset 0 1px 0 rgba(255, 255, 255, 0.28);
  }
  .brand { font-size: 1rem; }
  .brand span.dim { display: none; }
  .nav-right {
    margin-left: auto;
    gap: 8px;
  }
  .nav-right .theme-switch { display: none; }
  .nav-right .btn.desk { display: none; }
  .nav-burger { display: none; }
  .services-grid { grid-template-columns: 1fr; }
  .projects-grid { grid-template-columns: 1fr; }
  .project.wide { grid-column: span 1; }
  .project.wide .thumb { aspect-ratio: 16 / 10; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-cell:nth-child(2) { border-right: none; }
  .stat-cell:nth-child(1), .stat-cell:nth-child(2) { border-bottom: 1px solid var(--border); }
  .about-layout { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .price-grid { grid-template-columns: 1fr; }
  .price-card.featured { order: -1; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-cell:first-child { grid-column: 1 / -1; border-right: none; }
  .stat-cell { padding: 22px 18px; }
  .stat-cell .v { font-size: clamp(1.6rem, 1rem + 2vw, 2.8rem); }
  .stat-cell--name .v { font-size: clamp(2rem, 1.3rem + 3vw, 3rem); }
  .footer-top { grid-template-columns: 1fr; gap: 28px; }
  .hero-meta { gap: 20px; }
  .hero { padding-top: 154px; }
  .view:not([data-view="home"]) { padding-top: 146px; }
}

@media (max-width: 420px) {
  .team-grid { grid-template-columns: 1fr; }
  .float-chip { font-size: 0.78rem; padding: 7px 11px; }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .stat-cell {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .stat-cell:last-child { border-bottom: none; }
}
