:root, [data-theme="dark"] {
  color-scheme: dark;
  --bg: #0c0d10;
  --surface: #16171c;
  --surface-2: #1d1e24;
  --line: #2a2c34;
  --text: #f3f4f6;
  --muted: #9aa0ab;
  --dim: #6b7180;
  --accent: #e8a838;
  --accent-hover: #f0b84d;
  --accent-ink: #1a1205;
  --accent-soft: rgba(232, 168, 56, 0.14);
  --glow: rgba(232, 168, 56, 0.16);
  --font: "Bricolage Grotesque", system-ui, sans-serif;
  --font-body: "Figtree", system-ui, sans-serif;
  --hero-glow-1: rgba(232, 168, 56, 0.14);
  --hero-glow-2: rgba(232, 168, 56, 0.05);
  --header-bg: rgba(12, 13, 16, 0.86);
  --drawer-bg: rgba(12, 13, 16, 0.97);
  --ghost-border: #f3f4f6;
}

[data-theme="light"] {
  color-scheme: light;
  --bg: #eef0f4;
  --surface: #ffffff;
  --surface-2: #e7e9ef;
  --line: #d5d8e0;
  --text: #14161c;
  --muted: #5c6370;
  --dim: #8a919e;
  --accent: #c4841a;
  --accent-hover: #a86e10;
  --accent-ink: #fff8eb;
  --accent-soft: rgba(196, 132, 26, 0.12);
  --glow: rgba(196, 132, 26, 0.1);
  --hero-glow-1: rgba(196, 132, 26, 0.12);
  --hero-glow-2: rgba(20, 22, 28, 0.04);
  --header-bg: rgba(238, 240, 244, 0.9);
  --drawer-bg: rgba(238, 240, 244, 0.98);
  --ghost-border: #14161c;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  transition: background 0.35s ease, color 0.35s ease;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

.container {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}

.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  transition: background 0.35s, border-color 0.35s;
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 16px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font);
  font-weight: 700;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
}

.logo__mark {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--accent);
  color: var(--accent-ink);
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
}

.nav {
  display: flex;
  gap: 28px;
  list-style: none;
}

.nav a {
  color: var(--muted);
  font-size: 0.95rem;
  transition: color 0.2s;
}

.nav a:hover { color: var(--text); }

.header__actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.95rem;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.2s;
}

.btn:hover { transform: translateY(-1px); }

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

.btn--primary:hover { background: var(--accent-hover); }

.btn--ghost {
  border: 2px solid var(--ghost-border);
  color: var(--text);
}

.btn--ghost:hover { background: var(--surface); }

.btn--theme {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 10px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.btn--theme:hover {
  color: var(--text);
  border-color: var(--accent);
}

.menu-btn {
  display: none;
  width: 40px;
  height: 40px;
  color: var(--muted);
  font-size: 1.2rem;
}

.hero {
  min-height: 100svh;
  display: grid;
  align-content: center;
  padding: 120px 0 80px;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse 70% 55% at 50% -10%, var(--hero-glow-1), transparent 60%),
    radial-gradient(ellipse 50% 40% at 90% 80%, var(--hero-glow-2), transparent),
    var(--bg);
}

.hero__inner { text-align: center; }

.hero__pill {
  display: inline-block;
  margin-bottom: 28px;
  padding: 8px 16px;
  border-radius: 10px;
  background: linear-gradient(90deg, var(--accent-soft), transparent);
  font-size: 0.875rem;
  font-weight: 600;
  opacity: 0;
  animation: rise 0.7s ease forwards 0.1s;
}

.hero__brand {
  font-family: var(--font);
  font-weight: 800;
  font-size: clamp(4.5rem, 16vw, 9.5rem);
  letter-spacing: -0.06em;
  line-height: 0.9;
  margin-bottom: 20px;
  opacity: 0;
  animation: rise 0.8s ease forwards 0.2s;
}

.hero__brand em {
  font-style: normal;
  color: var(--accent);
}

.hero__title {
  font-family: var(--font);
  font-weight: 700;
  font-size: clamp(1.55rem, 3.8vw, 2.6rem);
  letter-spacing: -0.035em;
  line-height: 1.15;
  max-width: 18ch;
  margin: 0 auto 20px;
  opacity: 0;
  animation: rise 0.8s ease forwards 0.35s;
}

.hero__lead {
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  max-width: 38rem;
  margin: 0 auto 36px;
  opacity: 0;
  animation: rise 0.8s ease forwards 0.5s;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  opacity: 0;
  animation: rise 0.8s ease forwards 0.65s;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

.section { padding: 96px 0; }
.section--tight { padding: 64px 0; }

.section__head {
  text-align: center;
  margin-bottom: 56px;
}

.section__head h2 {
  font-family: var(--font);
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 3.4rem);
  letter-spacing: -0.04em;
  margin-bottom: 14px;
}

.section__head p {
  color: var(--muted);
  font-size: 1.125rem;
  max-width: 36rem;
  margin: 0 auto;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}

.stat__value {
  font-family: var(--font);
  font-weight: 800;
  font-size: clamp(2rem, 5vw, 3.5rem);
  color: var(--accent);
  letter-spacing: -0.04em;
  margin-bottom: 6px;
}

.stat__label { color: var(--text); font-size: 1.05rem; }

.tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 36px;
}

.tab {
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-weight: 600;
  transition: all 0.2s;
}

.tab.is-active,
.tab:hover {
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  color: var(--accent);
  background: var(--accent-soft);
}

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

.product {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 260px;
  transition: border-color 0.25s, transform 0.25s, background 0.35s;
  opacity: 0;
  transform: translateY(16px);
}

.product.is-in {
  opacity: 1;
  transform: none;
  transition: opacity 0.5s ease, transform 0.5s ease, border-color 0.25s, transform 0.25s;
}

.product:hover {
  border-color: color-mix(in srgb, var(--accent) 50%, transparent);
  transform: translateY(-4px);
}

.product.is-hidden { display: none; }

.product__status {
  align-self: flex-start;
  padding: 4px 10px;
  border-radius: 8px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.product__status--beta {
  background: #5b8fd9;
  color: #081018;
}

.product__status--lab,
.product__status--labs {
  background: #7a8499;
  color: #0c0d10;
}

.product__status--case {
  background: #c4841a;
  color: #fff8eb;
}

[data-theme="light"] .product__status--beta {
  background: #3d6fb8;
  color: #fff;
}

[data-theme="light"] .product__status--lab,
[data-theme="light"] .product__status--labs {
  background: #6a7385;
  color: #fff;
}

[data-theme="light"] .product__status--case {
  background: #c4841a;
  color: #fff;
}

.product h3 {
  font-family: var(--font);
  font-size: 1.55rem;
  letter-spacing: -0.03em;
}

.product p { color: var(--muted); flex: 1; }

.product__links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  align-items: center;
  margin-top: auto;
}

.product__link {
  color: var(--accent);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

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

.product__link--ext {
  color: var(--muted);
  font-weight: 600;
}

.product__link--ext:hover { color: var(--accent); }

.products-more {
  margin-top: 28px;
  text-align: center;
}

#products {
  scroll-margin-top: 80px;
}

.studio {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 28px;
  align-items: stretch;
}

.studio__main {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 40px;
  background:
    radial-gradient(ellipse 80% 60% at 0% 0%, var(--glow), transparent 55%),
    var(--surface);
}

.studio__main h2 {
  font-family: var(--font);
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.04em;
  margin-bottom: 14px;
}

.studio__main p {
  color: var(--muted);
  font-size: 1.1rem;
  margin-bottom: 28px;
  max-width: 36ch;
}

.svc-list { display: grid; gap: 14px; }

.svc {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px;
  transition: border-color 0.2s, background 0.35s;
}

.svc:hover { border-color: color-mix(in srgb, var(--accent) 45%, transparent); }

.svc__top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.svc h3 { font-family: var(--font); font-size: 1.2rem; }
.svc__price { color: var(--accent); font-weight: 700; white-space: nowrap; }
.svc p { color: var(--muted); font-size: 0.95rem; }

.jobs { display: grid; gap: 12px; max-width: 820px; margin: 0 auto; }

.job {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 22px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: border-color 0.2s;
}

.job:hover { border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.job h3 { font-family: var(--font); font-size: 1.25rem; margin-bottom: 4px; }
.job p { color: var(--muted); font-size: 0.95rem; }

.cta {
  text-align: center;
  padding: 80px 40px;
  border-radius: 24px;
  border: 1px solid var(--line);
  background:
    radial-gradient(ellipse 70% 80% at 50% 0%, var(--glow), transparent 60%),
    var(--surface);
}

.cta h2 {
  font-family: var(--font);
  font-size: clamp(2rem, 5vw, 3.25rem);
  letter-spacing: -0.04em;
  margin-bottom: 14px;
}

.cta p { color: var(--muted); font-size: 1.1rem; margin-bottom: 28px; }

.cta__meta {
  margin-top: 28px;
  color: var(--dim);
  font-size: 0.9rem;
  line-height: 1.7;
}

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

.footer {
  border-top: 1px solid var(--line);
  padding: 28px 0 40px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: var(--dim);
  font-size: 0.9rem;
}

.nav-drawer {
  display: none;
  position: fixed;
  inset: 64px 0 0;
  background: var(--drawer-bg);
  padding: 28px;
  z-index: 40;
  flex-direction: column;
  gap: 18px;
}

.nav-drawer.is-open { display: flex; }
.nav-drawer a { font-size: 1.25rem; font-family: var(--font); font-weight: 600; }

/* —— Project shell —— */
body.signal-skin {
  margin: 0;
  min-height: 100vh;
}

body.signal-skin .global-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

body.signal-skin main.signal-main {
  flex: 1;
  padding-top: 64px;
}

body.signal-skin .header {
  width: 100%;
}

.btn--theme svg {
  width: 18px;
  height: 18px;
  display: block;
}

.btn--theme .icon-moon { display: none; }
[data-theme="light"] .btn--theme .icon-sun { display: none; }
[data-theme="light"] .btn--theme .icon-moon { display: block; }

/* Inner pages */
.page-hero {
  padding: 72px 0 48px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(ellipse 70% 55% at 50% -10%, var(--hero-glow-1), transparent 60%),
    var(--bg);
}

.page-hero__kicker {
  color: var(--dim);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.page-hero__title {
  font-family: var(--font);
  font-weight: 800;
  font-size: clamp(2.2rem, 6vw, 4rem);
  letter-spacing: -0.04em;
  line-height: 1.05;
  margin-bottom: 14px;
}

.page-hero__text {
  color: var(--muted);
  font-size: 1.1rem;
  max-width: 40rem;
}

.page-hero__badge {
  display: inline-block;
  margin-bottom: 14px;
}

.page-body {
  padding: 48px 0 80px;
}

.page-body .content {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 46rem;
  line-height: 1.65;
}

.page-body .content p + p { margin-top: 1em; }

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--dim);
  font-size: 0.9rem;
  margin-bottom: 20px;
}

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

.signal-footer {
  border-top: 1px solid var(--line);
  padding: 36px 0 48px;
  margin-top: auto;
}

.signal-footer__grid {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.signal-footer__brand {
  font-family: var(--font);
  font-weight: 700;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
  margin-bottom: 8px;
}

.signal-footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 24px;
}

.signal-footer__nav a {
  color: var(--muted);
  font-size: 0.95rem;
}

.signal-footer__nav a:hover { color: var(--text); }

.signal-footer__legal {
  margin-top: 28px;
  color: var(--dim);
  font-size: 0.88rem;
  line-height: 1.7;
}

.block-html {
  margin-bottom: 40px;
  color: var(--muted);
  max-width: 46rem;
  line-height: 1.65;
}

.block-html h2, .block-html h3 {
  font-family: var(--font);
  color: var(--text);
  margin: 1.2em 0 0.5em;
}

@media (max-width: 900px) {
  .nav { display: none; }
  .menu-btn { display: grid; place-items: center; }
  .stats { grid-template-columns: 1fr 1fr; }
  .product-grid { grid-template-columns: 1fr; }
  .studio { grid-template-columns: 1fr; }
  .job { flex-direction: column; align-items: flex-start; }
  .footer,
  .signal-footer__grid { flex-direction: column; }
}
