/* SMB on Autopilot: home page. Brushed steel, white, graphite; one signal colour for "on". */
@font-face {
  font-family: 'Instrument Sans';
  src: url(../assets/fonts/instrument-sans-latin.woff2) format('woff2');
  font-weight: 400 700; font-stretch: 75% 100%; font-display: swap;
}
:root {
  --white: #ffffff;
  --paper: #f3f4f4;        /* cool steel white, never cream */
  --steel-1: #e2e4e5;
  --steel-2: #b7babd;
  --steel-3: #73777c;
  --graphite: #191919;
  --signal: #1f9d61;       /* only for things that are switched on */
  --signal-glow: rgba(46, 210, 128, .55);
  --text: #191919;
  --muted: #5d6166;
  --brushed: repeating-linear-gradient(0deg, transparent 0 2px, rgba(255,255,255,.28) 2px 3px, rgba(0,0,0,.02) 3px 5px),
             linear-gradient(180deg, #f6f7f7 0%, #d9dcde 48%, #c4c8cb 52%, #eceeef 100%);
  --wrap: 1180px;
  --gut: clamp(16px, 4vw, 40px);
  --ease: cubic-bezier(.2, .7, .1, 1);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--white); color: var(--text);
  font: 400 17px/1.6 'Instrument Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-stretch: 100%;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -.01em; line-height: 1.1; }
h2 { font-size: clamp(30px, 4.2vw, 52px); font-stretch: 80%; font-weight: 600; letter-spacing: -.015em; max-width: 20ch; }
h3 { font-size: 19px; line-height: 1.3; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }
.skip { position: absolute; left: 12px; top: -60px; background: var(--graphite); color: #fff; padding: 10px 14px; border-radius: 8px; z-index: 50; }
.skip:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--graphite); outline-offset: 3px; border-radius: 6px; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 26px;
  border-radius: 999px; background: var(--graphite); color: #fff; text-decoration: none; font-weight: 600; font-size: 16px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 1px 2px rgba(0,0,0,.25), 0 8px 22px -10px rgba(0,0,0,.55);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.btn:hover { transform: translateY(-1px); box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 2px 4px rgba(0,0,0,.2), 0 14px 28px -12px rgba(0,0,0,.6); }
.btn:active { transform: translateY(1px); }
.link { font-weight: 600; text-decoration: underline; text-decoration-color: var(--steel-2); text-underline-offset: 5px; text-decoration-thickness: 2px; }
.link:hover { text-decoration-color: var(--graphite); }

/* header */
.hdr { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,.9); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid transparent; transition: border-color .3s; }
.hdr.is-scrolled { border-bottom-color: var(--steel-1); }
.hdr__in { display: flex; align-items: center; justify-content: space-between; height: 84px; }
.hdr__brand { display: flex; align-items: center; gap: 14px; text-decoration: none; }
.hdr__logo { width: 150px; height: auto; }
.hdr__name { font-weight: 600; font-size: 17px; letter-spacing: -.005em; color: var(--graphite); padding-left: 14px; border-left: 1px solid var(--steel-1); line-height: 1.2; }
.hdr__nav { display: flex; gap: clamp(16px, 3vw, 36px); }
.hdr__nav a { text-decoration: none; font-weight: 500; font-size: 15px; color: var(--muted); padding: 8px 0; }
.hdr__nav a:hover { color: var(--graphite); }

/* hero */
.hero { position: relative; overflow: hidden; background: radial-gradient(120% 90% at 75% 40%, #ffffff 0%, #f4f5f5 55%, #e9ebec 100%); }
.hero__in { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); align-items: center; gap: 24px; min-height: min(calc(100svh - 84px), 760px); padding-top: 40px; padding-bottom: 56px; }
.hero__text { position: relative; z-index: 1; grid-column: 1; grid-row: 1; }
.hero__title { font-size: clamp(40px, 4.5vw, 70px); font-stretch: 75%; font-weight: 600; letter-spacing: -.02em; line-height: .98; }
.hero__line { display: block; white-space: nowrap; transition: color .7s var(--ease), opacity .7s var(--ease); }
.hero__line--hate { color: var(--steel-3); }
.hero__line--love { color: var(--graphite); }
.is-off .hero__line--hate { color: var(--graphite); }
.is-off .hero__line--love { color: #7d8186; }
.hero__sub { margin-top: 28px; max-width: 46ch; font-size: 19px; color: var(--muted); }
.hero__cta { margin-top: 34px; display: flex; flex-wrap: wrap; align-items: center; gap: 22px; }

.hero__stage { position: relative; aspect-ratio: 1.25 / 1; width: 100%; grid-column: 2; grid-row: 1; }
.hero__canvas { position: absolute; inset: -12% -14% -8% -14%; width: 128%; height: 120%; display: block; cursor: pointer; touch-action: pan-y; }
.hero__fallback { position: absolute; inset: 0; display: grid; place-items: center; }
.has-3d .hero__fallback { display: none; }
.hero__toggle {
  position: absolute; left: 50%; bottom: 2%; transform: translateX(-50%);
  display: inline-flex; align-items: center; gap: 10px; padding: 9px 16px 9px 12px; border-radius: 999px;
  border: 1px solid var(--steel-1); background: rgba(255,255,255,.75); color: var(--graphite);
  font: 600 14px/1 'Instrument Sans', system-ui, sans-serif; letter-spacing: .02em; cursor: pointer;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.hero__toggle:hover { border-color: var(--steel-2); }

.led { width: 9px; height: 9px; border-radius: 50%; background: #9da1a5; box-shadow: inset 0 1px 1px rgba(0,0,0,.35); flex: none; transition: background .3s, box-shadow .3s; }
[aria-pressed="true"] .led, .led.is-on { background: #2ed280; box-shadow: 0 0 0 3px rgba(46,210,128,.18), 0 0 12px var(--signal-glow); }

/* CSS fallback big switch (no WebGL) */
.is-off .bigswitch__track i { left: 5px; }
.bigswitch { display: flex; align-items: center; gap: 22px; padding: 22px 22px 22px 34px; border-radius: 999px; background: var(--brushed); box-shadow: inset 0 1px 0 #fff, inset 0 -2px 3px rgba(0,0,0,.12), 0 30px 60px -30px rgba(0,0,0,.45); }
.bigswitch__label { font-weight: 600; letter-spacing: .35em; font-size: clamp(14px, 2vw, 22px); color: #3d4044; }
.bigswitch__track { position: relative; width: 120px; height: 62px; border-radius: 999px; background: linear-gradient(180deg, #2a2c2f, #4a4d51); box-shadow: inset 0 3px 6px rgba(0,0,0,.6); }
.bigswitch__track i { position: absolute; top: 5px; left: 63px; transition: left .5s var(--ease); width: 52px; height: 52px; border-radius: 50%; background: conic-gradient(from 0deg, #f4f5f6, #a9adb1, #eef0f1, #9a9ea2, #f4f5f6, #b5b9bc, #f4f5f6); box-shadow: 0 2px 4px rgba(0,0,0,.5); }

/* switches (panel rows) */
.sw {
  position: relative; flex: none; width: 76px; height: 40px; padding: 0; border: 0; border-radius: 999px; cursor: pointer;
  background: linear-gradient(180deg, #2b2d30 0%, #45484c 100%);
  box-shadow: inset 0 2px 5px rgba(0,0,0,.65), 0 1px 0 #fff, 0 0 0 1px rgba(0,0,0,.08);
  transition: background .35s var(--ease);
}
.sw i {
  position: absolute; top: 4px; left: 4px; width: 32px; height: 32px; border-radius: 50%;
  background: conic-gradient(from 20deg, #f6f7f8, #a7abaf 12%, #eff1f2 25%, #9ea2a6 38%, #f6f7f8 50%, #b2b6b9 63%, #f1f2f3 76%, #a3a7ab 88%, #f6f7f8);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.7), 0 2px 3px rgba(0,0,0,.5), 0 6px 10px -4px rgba(0,0,0,.4);
  transition: transform .45s var(--ease);
}
.sw::after { content: ''; position: absolute; top: 50%; right: 13px; width: 7px; height: 7px; margin-top: -3.5px; border-radius: 50%; background: #5b5f63; transition: background .3s, box-shadow .3s, right .45s var(--ease), left .45s var(--ease); }
.sw[aria-checked="true"] { background: linear-gradient(180deg, #14301f 0%, #1d4a31 100%); }
.sw[aria-checked="true"] i { transform: translateX(36px); }
.sw[aria-checked="true"]::after { right: auto; left: 13px; background: #2ed280; box-shadow: 0 0 10px var(--signal-glow); }
.sw:active i { width: 36px; }
.sw--static { cursor: default; opacity: .6; }

/* chores */
.chores { background: var(--paper); padding: clamp(80px, 11vw, 140px) 0; }
.chores__head { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: end; margin-bottom: 48px; }
.chores__head p { color: var(--muted); max-width: 44ch; }
.panel {
  position: relative; border-radius: 28px; padding: 10px;
  background: var(--brushed);
  box-shadow: inset 0 1px 0 #fff, inset 0 -1px 0 rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.08), 0 40px 80px -40px rgba(0,0,0,.35);
}
.panel__status { display: flex; align-items: center; gap: 10px; padding: 14px 22px; font-weight: 600; font-size: 14px; letter-spacing: .02em; color: #3b3e42; }
.panel__rows { list-style: none; margin: 0; padding: 0; border-radius: 20px; background: var(--white); box-shadow: inset 0 1px 3px rgba(0,0,0,.12); overflow: hidden; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 28px; padding: 26px 28px; border-top: 1px solid var(--steel-1); transition: background .4s var(--ease); }
.row:first-child { border-top: 0; }
.row__text { display: grid; flex: 1; max-width: 64ch; }
.row__text h3 { transition: color .4s; }
.row__off, .row__on { grid-area: 2 / 1; margin-top: 6px; max-width: 62ch; transition: opacity .4s var(--ease), transform .4s var(--ease); }
.row__off { color: var(--muted); }
.row__on { color: var(--graphite); opacity: 0; transform: translateY(6px); }
.row.is-on { background: linear-gradient(90deg, rgba(46,210,128,.07), rgba(46,210,128,0) 60%); }
.row.is-on .row__off { opacity: 0; transform: translateY(-6px); }
.row.is-on .row__on { opacity: 1; transform: none; }
.panel__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; padding: 18px 22px 12px; color: #3b3e42; font-size: 15px; }
.panel__foot p { max-width: 70ch; }
.btn--small { min-height: 42px; padding: 0 20px; font-size: 15px; }
.panel [data-all-on] { opacity: 0; transform: translateY(6px); pointer-events: none; transition: opacity .4s var(--ease), transform .4s var(--ease); }
.panel.is-all-on [data-all-on] { opacity: 1; transform: none; pointer-events: auto; }
.panel__foot a { font-weight: 600; text-underline-offset: 4px; }

/* products */
.products { padding: clamp(80px, 11vw, 140px) 0; }
.products h2 { margin-bottom: 56px; }
.product { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.product__visual { display: grid; place-items: center; perspective: 1400px; padding: 64px 0; overflow: hidden; border-radius: 28px; background: radial-gradient(70% 60% at 50% 45%, #ffffff 0%, #eef0f1 60%, #e1e4e6 100%); }
.book { position: relative; width: min(280px, 64%); transform-style: preserve-3d; transform: rotateY(-22deg) rotateX(4deg); transition: transform .6s var(--ease); }
.book img { background: #111; border-radius: 3px 6px 6px 3px; box-shadow: 0 50px 60px -30px rgba(0,0,0,.55), 0 20px 30px -20px rgba(0,0,0,.4); }
.book::before { /* page block */
  content: ''; position: absolute; top: 1.2%; bottom: 1.2%; left: 100%; width: 30px; transform: rotateY(90deg); transform-origin: left;
  background: linear-gradient(90deg, rgba(0,0,0,.18), rgba(0,0,0,0) 40%), repeating-linear-gradient(90deg, #f4f4f2 0 1px, #d6d6d2 1px 2px);
}
.book::after { content: ''; position: absolute; inset: 0; border-radius: 3px 6px 6px 3px; background: linear-gradient(105deg, rgba(255,255,255,.28) 0%, rgba(255,255,255,0) 30%, rgba(0,0,0,0) 70%, rgba(0,0,0,.18) 100%); pointer-events: none; }
.product__kind { font-weight: 600; font-size: 15px; color: var(--steel-3); }
.product__text h3 { margin-top: 10px; font-size: clamp(32px, 4vw, 48px); font-stretch: 80%; letter-spacing: -.015em; }
.product__lead { margin-top: 18px; color: var(--muted); max-width: 52ch; }
.specs { margin: 32px 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--steel-1); border-bottom: 1px solid var(--steel-1); }
.specs div { padding: 18px 12px 18px 0; }
.specs div + div { padding-left: 16px; border-left: 1px solid var(--steel-1); }
.specs dt { font-size: 34px; font-weight: 600; font-stretch: 75%; line-height: 1; }
.specs dd { margin: 8px 0 0; font-size: 14px; line-height: 1.35; color: var(--muted); }
.product__buy { margin-top: 32px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.price { display: flex; align-items: baseline; gap: 12px; }
.price strong { font-size: 40px; font-weight: 600; font-stretch: 80%; }
.price span { color: var(--muted); font-size: 15px; }
.next { margin-top: 56px; display: flex; align-items: center; gap: 14px; padding: 20px 24px; border-radius: 20px; border: 1px solid var(--steel-1); background: var(--paper); color: var(--muted); }
.next .led { background: #c9a227; box-shadow: 0 0 0 3px rgba(201,162,39,.15); }
.next b { color: var(--graphite); font-weight: 600; }

/* rules */
.rules { background: var(--paper); padding: clamp(80px, 10vw, 128px) 0; }
.rules h2 { margin-bottom: 48px; }
.rules__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(24px, 4vw, 56px); }
.rule { padding-top: 22px; border-top: 2px solid var(--graphite); }
.rule p { margin-top: 10px; color: var(--muted); }

/* close */
.close { padding: clamp(96px, 12vw, 160px) 0; background: radial-gradient(90% 120% at 50% 100%, #e7e9ea 0%, #ffffff 70%); text-align: center; }
.close__in { display: grid; justify-items: center; gap: 30px; }
.close h2 { max-width: 18ch; }
.close__contact { color: var(--muted); font-size: 15px; }
.close__contact a { font-weight: 600; text-underline-offset: 4px; }

/* footer */
.ftr { border-top: 1px solid var(--steel-1); padding: 32px 0 40px; }
.ftr__in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 32px; }
.ftr__brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 600; font-size: 15px; }
.ftr__brand img { width: 84px; height: auto; }
.ftr__nav { display: flex; gap: 24px; }
.ftr__nav a, .ftr__copy { font-size: 14px; color: var(--muted); }
.ftr__nav a { text-decoration: none; }
.ftr__nav a:hover { color: var(--graphite); text-decoration: underline; }

/* responsive */
@media (max-width: 960px) {
  .hero__in { grid-template-columns: 1fr; min-height: 0; padding-top: 28px; gap: 36px; }
  .hero__toggle { bottom: -8%; }
  .hero__stage { grid-column: 1; grid-row: auto; max-width: 560px; width: 100%; margin: 0 auto; aspect-ratio: 1.6 / 1; }
  .hero__text { grid-column: 1; grid-row: auto; }
  .hero__canvas { inset: -8% -2% -6% -2%; width: 104%; height: 114%; }
  .chores__head, .product { grid-template-columns: 1fr; }
  .chores__head { gap: 16px; }
  .rules__grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .hdr__in { height: 64px; }
  .hdr__logo { width: 104px; }
  .hdr__name { font-size: 15px; padding-left: 10px; }
  .hdr__brand { gap: 10px; }
  .hdr__nav a:not([href="#products"]) { display: none; }
  .hero__line { white-space: normal; }
  .row { align-items: flex-start; }
  .row .sw { margin-top: 2px; }
  .hero__sub { font-size: 17px; }
  .row { padding: 20px 18px; gap: 16px; }
  .panel { padding: 6px; border-radius: 22px; }
  .panel__rows { border-radius: 17px; }
  .specs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .specs div:nth-child(3) { padding-left: 0; border-left: 0; }
  .specs div:nth-child(n+3) { border-top: 1px solid var(--steel-1); }
  .product__buy .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
