:root {
  --bg: light-dark(#fbfafc, #151219);
  --surface: light-dark(#fff, #1d1822);
  --fg: light-dark(#21172a, #f6eff8);
  --muted: light-dark(#645e6d, #b8adbf);
  --border: light-dark(#dedbe2, #413647);
  --accent: light-dark(#5c2662, #e5ade8);
  --accent-soft: light-dark(#eee6f0, #38253b);
  --mono: ui-monospace, Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 2rem; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 1.125rem/1.55 'Source Sans 3', system-ui, sans-serif; }
h1, h2, h3, p, figure, blockquote, ul { margin: 0; }
h1, h2, h3 { line-height: 1.06; letter-spacing: -.042em; }
h1 { font-size: clamp(3.2rem, 7vw, 5.4rem); }
h2 { font-size: clamp(2.3rem, 4.4vw, 3.5rem); }
h3 { font-size: 1.55rem; }
img { display: block; max-width: 100%; }
a { color: var(--accent); text-underline-offset: .19em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.wrap { width: min(72rem, 100% - 3rem); margin-inline: auto; }
.mast, footer { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.mast { display: grid; grid-template-columns: 1fr auto auto; padding-block: 1.25rem; border-bottom: 1px solid var(--border); font-size: 1rem; }
.mast a { color: inherit; text-decoration: none; }
.mast a:hover { text-decoration: underline; }
.identity { display: inline-flex; align-items: center; gap: .6rem; font-weight: 700; }
.mast nav { display: flex; gap: 1.4rem; }
.mast nav a[aria-current] { text-decoration: underline; text-underline-offset: .35em; }
footer { border-top: 1px solid var(--border); margin-top: 5rem; padding-block: 1.75rem 2.5rem; font-size: 1rem; color: var(--muted); }
.lead { max-width: 35em; color: var(--muted); font-size: clamp(1.16rem, 2vw, 1.4rem); line-height: 1.45; }
.page-intro { padding-block: clamp(3rem, 8vw, 6rem) 2.6rem; }
.page-intro p { margin-top: 1rem; }
.product-title { display: flex; align-items: center; gap: .8rem; }
.product-title img { width: 2.6rem; height: 2.6rem; }
.project-card { display: grid; grid-template-columns: 1fr 1.3fr; background: var(--surface); border: 1px solid var(--border); border-radius: 1.1rem; overflow: hidden; text-decoration: none; color: var(--fg); }
.project-card:hover { border-color: var(--accent); }
.project-copy { align-self: center; padding: clamp(1.6rem, 4vw, 3.4rem); }
.project-copy p { color: var(--muted); margin: 1rem 0 1.7rem; }
.text-link { font-size: 1rem; font-weight: 700; color: var(--accent); text-decoration: underline; text-underline-offset: .22em; }
.hero { display: grid; grid-template-columns: .83fr 1.3fr; align-items: center; gap: clamp(1.5rem, 5vw, 5rem); padding-block: clamp(2.75rem, 7vw, 5.75rem); }
.hero h1 { font-size: clamp(4.6rem, 8.8vw, 7rem); line-height: .96; margin: 1.15rem 0 1.25rem; }
.hero-icon { width: 3.15rem; height: 3.15rem; }
.hero .lead { color: var(--fg); font-size: clamp(1.3rem, 2.2vw, 1.68rem); line-height: 1.32; letter-spacing: -.018em; }
.hero-copy > p + p { color: var(--muted); margin-top: .85rem; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.4rem; margin-top: 1.65rem; }
.button { display: inline-flex; align-items: center; font-size: 1rem; font-weight: 700; padding: .6rem 1.1rem; border-radius: .5rem; background: var(--accent); color: var(--bg); text-decoration: none; }
.button:hover { box-shadow: 0 3px 0 var(--fg); }
.stage {
  background-color: light-dark(#c9addb, #4c3b59);
  background-image: radial-gradient(#69467b44 .8px, transparent 1px), linear-gradient(120deg, light-dark(#eedff3, #4c3756), light-dark(#cdaedd, #392c48) 62%, light-dark(#a799c9, #302e45));
  background-size: 7px 7px, 100% 100%;
  display: grid; align-items: center; overflow: hidden; padding: clamp(1.5rem, 4vw, 3rem) 0 clamp(1.5rem, 4vw, 3rem) clamp(1.35rem, 3vw, 2.5rem);
}
.hero .stage { border-radius: 1.15rem; }
.stage img { width: 112%; max-width: none; height: auto; border-radius: .5rem; box-shadow: 0 15px 28px #351b4970; }
.section { padding-block: clamp(2.5rem, 6vw, 4.75rem); border-top: 1px solid var(--border); }

.demo p, .demo-intro { color: var(--muted); }
.demo-intro { margin: .85rem 0 2rem; }
.demo { display: grid; align-items: center; grid-template-columns: 1.55fr 1fr; gap: clamp(1.5rem, 5vw, 4rem); }
.demo + .demo { margin-top: 2.5rem; }
.demo p { margin: .6rem 0 1rem; }
.demo > a { border: 1px solid var(--border); border-radius: .7rem; overflow: hidden; }
.demo img { width: 100%; height: auto; }
.demo button { line-height: 1.3; font-family: inherit; font-size: 1rem; font-weight: 600; background: var(--surface); color: var(--accent); border: 1px solid var(--border); border-radius: .4rem; padding: .4rem .8rem; cursor: pointer; }
.demo button:hover { border-color: var(--accent); }

@media(max-width: 760px) {
  .wrap { width: min(100% - 2rem, 39rem); }
  .hero, .project-card, .demo { grid-template-columns: 1fr; }
  .hero { gap: 2rem; }
  .stage { padding-block: 1.5rem; }
  .stage img { width: 106%; }

  .demo { gap: 1rem; }
  .demo + .demo { margin-top: 2.1rem; }
}
@media(max-width: 500px) {
  .mast { gap: .6rem; }
  .mast nav { gap: .75rem; }
  footer { margin-top: 3rem; }
}

@media (max-width: 23rem) {
  .mast nav { grid-column: 1 / -1; grid-row: 2; }
  .mast .theme-toggle { grid-column: 3; grid-row: 1; }
}
