/* ScottiCAD website. Palette taken from the app's logo. */
:root {
  --navy: #0e2a47;
  --navy-2: #163d63;
  --blue-dark: #1b558c;
  --blue: #2e86c8;
  --blue-light: #6cc4f0;
  --green: #2fbf5f;
  --ink: #13263b;
  --muted: #55667a;
  --line: #dfe7ef;
  --tint: #f3f8fc;
  --bg: #ffffff;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(14, 42, 71, .06), 0 12px 32px rgba(14, 42, 71, .10);
  --shadow-lg: 0 2px 4px rgba(14, 42, 71, .08), 0 30px 80px rgba(14, 42, 71, .22);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--blue-dark); }
h1, h2, h3, h4 { line-height: 1.15; letter-spacing: -.02em; margin: 0 0 .5em; color: var(--navy); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); font-weight: 800; }
h3 { font-size: 1.4rem; font-weight: 700; }
h4 { font-size: 1.05rem; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
code { font-family: var(--mono); font-size: .88em; background: #eaf2f9; color: var(--navy); padding: .1em .35em; border-radius: 5px; }
kbd {
  font-family: var(--font); font-size: .8em; font-weight: 600;
  display: inline-block; min-width: 1.6em; padding: .1em .45em; text-align: center;
  color: var(--navy); background: #fff; border: 1px solid #c9d6e2; border-bottom-width: 2px; border-radius: 6px;
}

.wrap { width: min(1180px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(820px, 100% - 32px); }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: #fff; padding: 8px 12px; border-radius: 8px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .55em;
  font-weight: 600; text-decoration: none; border-radius: 999px;
  padding: .7em 1.25em; border: 1.5px solid transparent;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn svg { width: 1.2em; height: 1.2em; }
.btn:hover { transform: translateY(-1px); }
.btn--sm { padding: .45em 1em; font-size: .92rem; }
.btn--lg { padding: .85em 1.6em; font-size: 1.05rem; }
.btn--primary { background: var(--blue); color: #fff; box-shadow: 0 6px 18px rgba(46, 134, 200, .35); }
.btn--primary:hover { background: var(--blue-dark); color: #fff; }
.btn--ghost { color: var(--navy); border-color: #c4d5e5; background: #fff; }
.btn--ghost:hover { border-color: var(--blue); color: var(--blue-dark); }
.btn--ghost-light { color: #fff; border-color: rgba(255,255,255,.4); }
.btn--ghost-light:hover { color: #fff; border-color: #fff; }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.nav.is-scrolled { border-bottom-color: var(--line); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.2rem; color: var(--navy); text-decoration: none; letter-spacing: -.02em; }
.brand:hover { color: var(--navy); }
.nav__links { display: flex; align-items: center; gap: 26px; }
.nav__links a:not(.btn) { color: var(--ink); text-decoration: none; font-weight: 500; font-size: .95rem; }
.nav__links a:not(.btn):hover { color: var(--blue); }
.nav__toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.nav__toggle span { display: block; width: 22px; height: 2px; background: var(--navy); margin: 5px 0; border-radius: 2px; transition: transform .2s, opacity .2s; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  padding: 72px 0 40px;
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(108, 196, 240, .28), transparent 60%),
    radial-gradient(900px 400px at 0% 10%, rgba(46, 134, 200, .12), transparent 60%),
    linear-gradient(#fff, #f5f9fd);
  overflow: hidden;
}
.hero::before { /* faint workplane grid */
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(46, 134, 200, .07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(46, 134, 200, .07) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: linear-gradient(to bottom, #000 0%, transparent 70%);
  pointer-events: none;
}
.hero__copy { position: relative; text-align: center; max-width: 880px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .88rem; font-weight: 600; color: var(--blue-dark);
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px;
  box-shadow: 0 2px 8px rgba(14, 42, 71, .05);
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(47, 191, 95, .18); }
.hero h1 { font-size: clamp(2.3rem, 6vw, 4.1rem); font-weight: 800; letter-spacing: -.035em; margin: 22px 0 18px; }
.grad { background: linear-gradient(92deg, var(--blue-dark), var(--blue) 45%, #3fb0e8); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lede { font-size: clamp(1.05rem, 1.6vw, 1.2rem); color: var(--muted); max-width: 720px; margin: 0 auto 28px; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.ticks { list-style: none; padding: 0; margin: 22px 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; color: var(--muted); font-size: .93rem; }
.ticks li::before { content: "✓"; color: var(--green); font-weight: 800; margin-right: 6px; }

.hero__media { position: relative; margin-top: 52px; max-width: 1080px; }
.window { margin: 0; border-radius: var(--radius); overflow: hidden; background: #fff; box-shadow: var(--shadow); border: 1px solid var(--line); }
.window--hero { box-shadow: var(--shadow-lg); border-color: #cfdbe7; }
.window__bar { display: flex; align-items: center; gap: 7px; height: 34px; padding: 0 14px; background: #eef3f8; border-bottom: 1px solid var(--line); }
.window__bar span { width: 11px; height: 11px; border-radius: 50%; background: #cdd8e3; }
.window__bar em { font-style: normal; font-size: .8rem; font-weight: 600; color: var(--muted); margin-left: auto; margin-right: auto; transform: translateX(-24px); }
.window--hero img { width: 100%; }
.caption { text-align: center; color: var(--muted); font-size: .9rem; margin-top: 14px; }

/* ---------- strip ---------- */
.strip { background: var(--navy); color: #cfe3f3; }
.strip__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; padding: 34px 0; }
.stat { display: flex; align-items: baseline; gap: 14px; }
.stat b { font-size: 2.6rem; font-weight: 800; color: #fff; letter-spacing: -.03em; line-height: 1; }

.stat span { font-size: .93rem; line-height: 1.4; }

/* ---------- sections ---------- */
.section { padding: 96px 0; }
.section--tint { background: var(--tint); }
.section--dark { background: radial-gradient(900px 400px at 100% 0%, rgba(46, 134, 200, .35), transparent 60%), var(--navy); color: #c9dcec; }
.section--dark h2 { color: #fff; }
.section--dark code { background: rgba(255,255,255,.1); color: #fff; }
.section__head { text-align: center; max-width: 760px; margin: 0 auto 56px; }
.sub { color: var(--muted); font-size: 1.1rem; }
.kicker { text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; font-weight: 700; color: var(--blue); margin-bottom: 10px; }
.kicker--light { color: var(--blue-light); }

#why h2 { margin-bottom: .7em; }
#why .narrow > p { font-size: 1.08rem; color: #334a60; }
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 44px; }
.pillars article { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.pillars h3 { font-size: 1.12rem; margin-top: 14px; }
.pillars p { color: var(--muted); font-size: .95rem; margin: 0; }
.icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: linear-gradient(135deg, #e3f3fc, #cfe7f8); }
.icon svg { width: 24px; height: 24px; fill: none; stroke: var(--blue-dark); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- features ---------- */
.feature { display: grid; grid-template-columns: 1fr 1.25fr; gap: 56px; align-items: center; margin-bottom: 104px; }
.feature--flip .feature__text { order: 2; }
.feature__text p { color: #3b5166; }
.feature__text h3 { font-size: clamp(1.45rem, 2.4vw, 1.85rem); font-weight: 800; }
.feature__media { margin: 0; }
.feature__media.window { box-shadow: var(--shadow-lg); }
.hint { font-size: .9rem; color: var(--blue-dark); font-weight: 500; }
.hint::before { content: "↔ "; }

.checks, .partlist { list-style: none; padding: 0; margin: 18px 0 0; }
.checks li, .partlist li { position: relative; padding-left: 28px; margin: 8px 0; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: .38em; width: 18px; height: 18px; border-radius: 50%;
  background: rgba(47, 191, 95, .15) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%232fbf5f' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/12px no-repeat;
}
.checks--light li { color: #dbe9f5; }
.partlist li::before { content: ""; position: absolute; left: 4px; top: .6em; width: 10px; height: 10px; border-radius: 3px; background: var(--blue-light); transform: rotate(45deg); }
.partlist li { color: #3b5166; }
.partlist b { color: var(--navy); }

/* before/after slider */
.compare { position: relative; aspect-ratio: 700 / 490; box-shadow: var(--shadow-lg); user-select: none; }
.compare img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.compare__top { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.compare__line { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 3px; margin-left: -1.5px; background: #fff; box-shadow: 0 0 0 1px rgba(14,42,71,.2); pointer-events: none; }
.compare__line::after {
  content: "‹ ›"; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 42px; height: 42px; border-radius: 50%; background: #fff; color: var(--navy);
  display: grid; place-items: center; font-weight: 800; letter-spacing: 2px; box-shadow: var(--shadow);
}
.compare input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; margin: 0; }
.compare input:focus-visible ~ .compare__line::after, .compare:focus-within .compare__line::after { outline: 3px solid var(--blue-light); }
.compare__label { position: absolute; top: 14px; font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; background: rgba(14, 42, 71, .82); color: #fff; padding: 4px 10px; border-radius: 999px; pointer-events: none; }
.compare__label--l { left: 14px; }
.compare__label--r { right: 14px; }

/* cards */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 24px 20px; transition: box-shadow .2s, transform .2s; }
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.card p { color: var(--muted); font-size: .95rem; margin: 0; }
.card h4::before { content: ""; display: block; width: 26px; height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--blue), var(--blue-light)); margin-bottom: 14px; }
.card--line { background: transparent; }

/* ---------- steps ---------- */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; counter-reset: step; }
.steps li { position: relative; background: var(--tint); border-radius: var(--radius); padding: 22px; counter-increment: step; }
.steps li::before {
  content: counter(step); position: absolute; top: 16px; left: 16px;
  width: 30px; height: 30px; border-radius: 50%; background: var(--navy); color: #fff;
  display: grid; place-items: center; font-weight: 700; font-size: .9rem;
}
.steps__art { height: 120px; display: grid; place-items: center; margin-bottom: 8px; }
.steps__art svg { width: 100%; max-width: 190px; height: 100%; }
.steps__art .plane { fill: #d7ecf9; stroke: #9fcfee; stroke-width: 1; }
.steps__art .dash { fill: none; stroke: #0e2a47; stroke-width: 1.2; stroke-dasharray: 3 3; }
.steps h3 { font-size: 1.1rem; }
.steps p { color: var(--muted); font-size: .95rem; margin: 0; }

/* ---------- automation ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.code { background: #081a2d; border: 1px solid rgba(255,255,255,.08); border-radius: var(--radius); overflow: hidden; box-shadow: 0 30px 80px rgba(0,0,0,.35); }
.code__bar { display: flex; justify-content: space-between; align-items: center; padding: 10px 16px; border-bottom: 1px solid rgba(255,255,255,.08); font-family: var(--mono); font-size: .82rem; color: #8fb3d1; }
.code pre { margin: 0; padding: 20px 22px; overflow-x: auto; font-family: var(--mono); font-size: .88rem; line-height: 1.7; color: #e3eef8; }
.code pre code { background: none; padding: 0; color: inherit; font-size: inherit; }
.code .c { color: #6f8ba4; font-style: italic; }
.code .k { color: #7cc7f2; }
.code .s { color: #9fe0a8; }
.code .n { color: #f6c177; }
.copy { font: 600 .78rem var(--font); color: #cfe3f3; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); border-radius: 6px; padding: 4px 10px; cursor: pointer; }
.copy:hover { background: rgba(255,255,255,.16); }
.copy.is-done { color: #9fe0a8; }

/* ---------- shortcuts ---------- */
.keys { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.keys__col { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.keys dl { display: grid; grid-template-columns: auto 1fr; gap: 10px 14px; margin: 14px 0 0; align-items: center; }
.keys dt { white-space: nowrap; font-size: .9rem; color: var(--muted); }
.keys dd { margin: 0; font-size: .93rem; }

/* ---------- download ---------- */
.download { display: grid; grid-template-columns: 1fr 1.2fr; border-radius: 22px; overflow: hidden; box-shadow: var(--shadow-lg); border: 1px solid var(--line); }
.download__main { background: linear-gradient(160deg, var(--navy), var(--blue-dark)); color: #cfe3f3; padding: 56px 44px; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; }
.download__main h2 { color: #fff; margin-top: 20px; }
.download__main .btn { margin-top: 10px; }
.download__main .small { font-size: .88rem; margin-top: 14px; color: #9fbfda; }
.download__side { padding: 44px; background: #fff; }
.download__side h3 { font-size: 1.1rem; margin-top: 1.4em; }
.download__side h3:first-child { margin-top: 0; }
.download__side ol, .download__side ul { padding-left: 1.2em; color: #3b5166; }
.download__side li { margin: 6px 0; }
.code--inline { display: flex; align-items: center; gap: 10px; padding-right: 12px; box-shadow: none; }
.code--inline pre { padding: 12px 16px; font-size: .82rem; flex: 1; }

/* ---------- FAQ ---------- */
details { background: #fff; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 12px; }
summary { cursor: pointer; list-style: none; padding: 18px 54px 18px 22px; font-weight: 600; color: var(--navy); position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 22px; top: 50%; transform: translateY(-50%); font-size: 1.4rem; font-weight: 400; color: var(--blue); transition: transform .2s; }
details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
details p { padding: 0 22px 18px; margin: 0; color: #3b5166; }

/* ---------- final CTA ---------- */
.final { padding: 96px 0; text-align: center; color: #cfe3f3; background:
  radial-gradient(700px 300px at 50% 120%, rgba(108, 196, 240, .35), transparent 70%), var(--navy); }
.final h2 { color: #fff; }
.final p { font-size: 1.15rem; margin-bottom: 28px; }
.cta--center { justify-content: center; }

/* ---------- footer ---------- */
.footer { background: #08192b; color: #8fa9c1; padding: 40px 0; font-size: .92rem; }
.footer__inner { display: grid; grid-template-columns: auto 1fr; gap: 20px 40px; align-items: center; }
.footer__brand { display: flex; align-items: center; gap: 12px; }
.footer__brand b { display: block; color: #fff; }
.footer__links { display: flex; flex-wrap: wrap; gap: 8px 26px; justify-content: flex-end; }
.footer__links a { color: #cfe3f3; text-decoration: none; }
.footer__links a:hover { color: #fff; text-decoration: underline; }
.footer__legal { grid-column: 1 / -1; margin: 0; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.08); font-size: .85rem; }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .card { transition: none; }
}

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .feature { grid-template-columns: 1fr; gap: 28px; margin-bottom: 72px; }
  .feature--flip .feature__text { order: 0; }
  .grid, .keys { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; }
  .download { grid-template-columns: 1fr; }
  .strip__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 820px) {
  .nav__toggle { display: block; }
  .nav__links {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    padding: 8px 16px 16px; display: none;
  }
  .nav__links.is-open { display: flex; }
  .nav__links a:not(.btn) { padding: 12px 4px; border-bottom: 1px solid var(--line); }
  .nav__links .btn { margin-top: 12px; justify-content: center; }
  .nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .pillars { grid-template-columns: 1fr; }
  .section { padding: 72px 0; }
  .footer__inner { grid-template-columns: 1fr; }
  .footer__links { justify-content: flex-start; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .hero { padding-top: 48px; }
  .eyebrow { font-size: .76rem; padding: 5px 12px; }
  .hide-sm { display: none; }
  .grid, .keys, .steps, .strip__grid { grid-template-columns: 1fr; }
  .window__bar { height: 26px; }
  .window__bar em { display: none; }
  .download__main, .download__side { padding: 32px 22px; }
  .code pre { font-size: .8rem; }
  .code--inline { flex-direction: column; align-items: stretch; padding: 0 0 12px; }
  .code--inline .copy { align-self: flex-end; margin-right: 12px; }
}

/* Let grid/flex children shrink below their content width (long code lines scroll instead). */
.split > *, .download > *, .feature > *, .code--inline pre { min-width: 0; }
