:root {
  --ink: #18212b;
  --muted: #5b6672;
  --bg: #f8f7f4;
  --bg-alt: #eef0ec;
  --card: #ffffff;
  --line: #e2e4df;
  --brand: #2b4c7e;
  --brand-dark: #1d3559;
  --accent: #e2725b;
  --on-accent: #ffffff;
  --btn-bg: #2b4c7e;
  --btn-bg-hover: #1d3559;
  --cta-bg: #1d3559;
  --cta-soft: #d3dceb;
  --cta-btn: #c4563f;
  --cta-btn-hover: #ad4835;
  --header-bg: rgba(248, 247, 244, 0.95);
  --dash: #c9cdc6;
  --badge-bg: #fde8e3;
  --badge-ink: #9c3d29;
  --badge-live-bg: #e3ecf8;
  --badge-live-ink: #1d3559;
  --radius: 14px;
  --heading: "Bricolage Grotesque", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light dark;
}

/* Follows the visitor's device setting automatically. */
@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e6e9ee;
    --muted: #9ba6b2;
    --bg: #11161d;
    --bg-alt: #171e28;
    --card: #1c2430;
    --line: #2b3544;
    --brand: #8fb4f0;
    --brand-dark: #b5cdf5;
    --accent: #ee8d77;
    --on-accent: #1d120f;
    --btn-bg: #3f6aab;
    --btn-bg-hover: #4d7abd;
    --cta-bg: #1f2f4a;
    --cta-soft: #c4d0e3;
    --cta-btn: #ee8d77;
    --cta-btn-hover: #f3a491;
    --header-bg: rgba(17, 22, 29, 0.92);
    --dash: #3b4656;
    --badge-bg: #3b231d;
    --badge-ink: #f4ab96;
    --badge-live-bg: #1e2c44;
    --badge-live-ink: #a9c6f5;
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
  margin: 0;
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
}

h1, h2, h3 { font-family: var(--heading); line-height: 1.15; margin: 0 0 0.5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 5.5vw, 3.5rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.2rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
a { color: var(--brand); }

.wrap { max-width: 1100px; margin: 0 auto; padding: 0 16px; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--header-bg);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
}
.logo {
  font-family: var(--heading);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--ink);
  text-decoration: none;
}
.logo span { color: var(--accent); }
.site-nav { display: flex; gap: 20px; }
.site-nav a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 500;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] { color: var(--brand); }
.site-nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 6px; }
@media (max-width: 480px) {
  .site-nav { gap: 14px; font-size: 0.95rem; }
  .site-nav .nav-extra { display: none; }
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
}
.btn-primary { background: var(--btn-bg); color: #fff; }
.btn-primary:hover { background: var(--btn-bg-hover); }
.btn-secondary { border: 2px solid var(--brand); color: var(--brand); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* Page sections */
.hero { padding: 64px 0 56px; }
.hero .lead { font-size: 1.2rem; color: var(--muted); max-width: 36em; }
.eyebrow {
  color: var(--accent);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8125rem;
  margin-bottom: 0.75em;
}
.section { padding: 64px 0; }
.section-alt { background: var(--bg-alt); }
.section-lead { color: var(--muted); max-width: 42em; margin-bottom: 32px; }

.grid { display: grid; gap: 16px; }
@media (min-width: 640px) { .grid-2, .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.card p:last-child { margin-bottom: 0; }
a.card { display: block; color: inherit; text-decoration: none; transition: border-color 0.15s, transform 0.15s; }
a.card:hover { border-color: var(--brand); transform: translateY(-2px); }
.card .more { color: var(--brand); font-weight: 600; }

.steps { counter-reset: step; }
.steps .card h3::before {
  counter-increment: step;
  content: counter(step);
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  margin-right: 10px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 0.95rem;
}

/* Portfolio */
.project {
  display: grid;
  gap: 32px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
}
@media (min-width: 900px) { .project { grid-template-columns: 1fr 1.1fr; align-items: start; } }
.project-shot {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #0f1420;
  aspect-ratio: 16 / 10;
}
.project-shot img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.tag {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--bg-alt);
  color: var(--muted);
  margin: 0 6px 6px 0;
}
.check-list { list-style: none; margin: 0 0 1.2em; padding: 0; }
.check-list li { position: relative; padding-left: 28px; margin-bottom: 0.7em; }
.check-list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.45em;
  width: 14px;
  height: 8px;
  border-left: 3px solid var(--accent);
  border-bottom: 3px solid var(--accent);
  transform: rotate(-45deg);
}
.check-list strong { display: block; }

/* Features */
.feature-group { margin-bottom: 48px; }
.feature-group > h2 { font-size: clamp(1.3rem, 2.6vw, 1.7rem); }
.feature-group > p { color: var(--muted); margin-bottom: 20px; }
.feature h3 { margin-bottom: 0.35em; }
.feature .badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 2px 9px;
  border-radius: 999px;
  margin-bottom: 10px;
  background: var(--badge-bg);
  color: var(--badge-ink);
}
.feature .badge.live { background: var(--badge-live-bg); color: var(--badge-live-ink); }
.feature-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.feature-nav a {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
}
.feature-nav a:hover { border-color: var(--brand); color: var(--brand); }

.demo {
  margin-top: 16px;
  border: 1px dashed var(--dash);
  border-radius: 10px;
  padding: 16px;
  background: var(--bg);
  font-size: 0.95rem;
}
.demo-label { font-size: 0.75rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 8px; }
.demo-banner {
  background: var(--accent);
  color: var(--on-accent);
  padding: 8px 12px;
  border-radius: 6px;
  font-weight: 500;
  margin-bottom: 12px;
}
.demo-banner.is-hidden { background: none; color: var(--muted); border: 1px dashed var(--dash); font-weight: 400; }
.demo input[type="range"] { width: 100%; }
.fine { font-size: 0.875rem; color: var(--muted); }
.demo-status { font-weight: 600; }
.demo-status::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 8px;
  background: #b0453a;
}
.demo-status.is-open::before { background: #2f8a4c; }

.compare {
  position: relative;
  aspect-ratio: 3 / 2;
  border-radius: 8px;
  overflow: hidden;
}
.compare-img {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 72% 30%, #ffe08a 0 7%, transparent 7.5%),
    radial-gradient(ellipse at 30% 100%, #3f7d4a 0 38%, transparent 38.5%),
    radial-gradient(ellipse at 85% 105%, #2f6a3c 0 40%, transparent 40.5%),
    linear-gradient(to bottom, #6fb3e0 0%, #bfe1f2 55%, #4f93b8 56%, #2c6e92 100%);
}
.compare-before {
  filter: sepia(0.75) saturate(0.55) contrast(0.8) brightness(1.12) hue-rotate(-12deg);
  clip-path: inset(0 calc(100% - var(--pos)) 0 0);
}
.compare-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos);
  width: 3px;
  background: #fff;
  transform: translateX(-50%);
  pointer-events: none;
}
.compare input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}

/* Control panel callout */
.panel-callout { display: grid; gap: 32px; align-items: start; }
@media (min-width: 900px) { .panel-callout { grid-template-columns: 1fr 1fr; } }
.panel-callout > div > p { max-width: 34em; }
.panel-form { display: grid; grid-template-columns: 1fr 6.5em; gap: 8px; margin-bottom: 12px; }
.panel-form label { display: grid; gap: 4px; font-size: 0.8125rem; font-weight: 600; color: var(--muted); }
.demo input[type="text"] {
  width: 100%;
  min-width: 0;
  font: inherit;
  font-size: 0.95rem;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--card);
  color: var(--ink);
}
.menu-preview {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--card);
  border: 1px solid var(--line);
  font-weight: 600;
}
.menu-preview #preview-name { overflow-wrap: anywhere; }
.menu-preview .dots { flex: 1; border-bottom: 2px dotted var(--dash); min-width: 12px; }

/* Kind-of-site cards */
.type-card h3 { color: var(--brand); }
.type-card .fine { margin-bottom: 12px; }

/* Store demo */
.cart-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
.qty { display: inline-flex; align-items: center; gap: 6px; }
.qty button {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.qty output { min-width: 1.2em; text-align: center; font-weight: 600; }
.cart-options { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 10px; }
.demo-status-plain { font-weight: 600; margin: 0; }

/* Order lookup demo */
.lookup { display: flex; gap: 8px; margin-bottom: 12px; }
.btn-small { padding: 7px 16px; border: 0; font: inherit; font-weight: 600; cursor: pointer; }
.status-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.status-steps li { position: relative; padding-left: 26px; color: var(--muted); }
.status-steps li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.3em;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--dash);
}
.status-steps li.done { color: var(--ink); }
.status-steps li.done::before { background: var(--brand); border-color: var(--brand); }
.status-steps li.current { color: var(--ink); font-weight: 600; }
.status-steps li.current::before { background: #2f8a4c; border-color: #2f8a4c; }

/* About */
.about { display: grid; gap: 32px; align-items: start; }
@media (min-width: 860px) { .about { grid-template-columns: 1.4fr 1fr; } }
.about p { max-width: 38em; }
.about .check-list { margin-bottom: 1em; }

/* Contact */
.cta {
  background: var(--cta-bg);
  color: #fff;
  border-radius: var(--radius);
  padding: 40px 28px;
  text-align: center;
}
.cta p { color: var(--cta-soft); max-width: 34em; margin-left: auto; margin-right: auto; }
.cta .btn-primary { background: var(--cta-btn); color: var(--on-accent); }
.cta .btn-primary:hover { background: var(--cta-btn-hover); }
.cta .btn-light { border: 2px solid #fff; color: #fff; }
.cta .btn-light:hover { background: rgba(255, 255, 255, 0.1); }
.cta .contact-note { margin-top: 20px; margin-bottom: 0; font-size: 0.95rem; }
.cta .contact-note a { color: #fff; }

.site-footer { padding: 32px 0; color: var(--muted); font-size: 0.9rem; text-align: center; }
