/* Project site of Software-EKG.

   Colours: the petrol and the two curves of the logo (docs/images/logo.png),
   plus the red, green and amber with which the display of the collector shows
   the state of a job. The structure follows the S202 site
   (software-architektur.com), so that the sites fit together.

   No third-party fonts, no third-party scripts: the page loads nothing from
   others. Only the download buttons ask GitHub for the latest release
   (site.js). */

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

:root {
  color-scheme: dark;
  --bg: #05131a;
  --bg-alt: #081c26;
  --bg-card: #0c2530;
  --bg-card-hover: #103140;
  --border: #173a48;
  --border-light: #25586c;
  --text: #e4f0f4;
  --text-muted: #9ab3bd;
  --text-dim: #66848f;
  --accent: #22c8f0;
  --accent-light: #a8f0ff;
  --accent-deep: #0d5c80;
  --accent-glow: rgba(34, 200, 240, 0.14);
  --red: #ff6b6b;
  --green: #4cd08a;
  --amber: #f0b64a;
  --font: Inter, -apple-system, "Segoe UI Variable Text", "Segoe UI", Roboto,
          "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", "Cascadia Mono", Menlo,
          Consolas, "DejaVu Sans Mono", monospace;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow-lg: 0 12px 48px rgba(0, 0, 0, 0.55);
  --transition: 0.25s ease;
  --page: 1120px;
}

html { scroll-behavior: smooth; scroll-padding-top: 76px; font-size: 16px; }
body {
  font-family: var(--font); background: var(--bg); color: var(--text);
  line-height: 1.7; -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4 { text-wrap: balance; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
.mono, code { font-family: var(--mono); font-size: 0.88em; }
code { color: var(--accent-light); background: rgba(34, 200, 240, 0.08); padding: 1px 6px; border-radius: 5px; white-space: nowrap; }
.container { max-width: var(--page); margin: 0 auto; padding: 0 24px; }
.textlink { color: var(--accent); border-bottom: 1px solid rgba(34, 200, 240, 0.35); transition: color var(--transition), border-color var(--transition); }
.textlink:hover { color: var(--accent-light); border-bottom-color: var(--accent-light); }

/* ── Header line ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(5, 19, 26, 0.86); backdrop-filter: blur(18px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.nav.scrolled { border-bottom-color: var(--border); box-shadow: 0 2px 20px rgba(0, 0, 0, 0.4); }
.nav-inner {
  max-width: var(--page); margin: 0 auto; padding: 0 24px; height: 64px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.1rem; letter-spacing: -0.02em; white-space: nowrap; }
.badge-mark {
  width: 32px; height: 32px; border-radius: 8px; flex-shrink: 0;
  background: linear-gradient(160deg, #0d252c, var(--accent-deep));
  border: 1px solid var(--border-light);
  display: flex; align-items: center; justify-content: center;
}
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-link { padding: 6px 11px; border-radius: 8px; font-size: 0.9rem; color: var(--text-muted); white-space: nowrap; transition: color var(--transition), background var(--transition); }
.nav-link:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.lang-switcher { display: flex; gap: 4px; margin: 0 8px; }
.lang-btn {
  background: none; border: 1px solid var(--border); color: var(--text-muted);
  padding: 4px 9px; border-radius: 6px; font-size: 0.78rem; font-weight: 600;
  cursor: pointer; font-family: var(--font); transition: all var(--transition);
}
.lang-btn:hover { border-color: var(--accent); color: var(--text); }
.lang-btn[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #032029; }
.nav-cta {
  padding: 8px 16px; border-radius: 8px; font-size: 0.875rem; font-weight: 650;
  background: var(--accent); color: #032029; display: flex; align-items: center; gap: 6px;
  transition: background var(--transition), transform var(--transition);
}
.nav-cta:hover { background: var(--accent-light); transform: translateY(-1px); }

/* ── Hero ── */
.hero {
  padding: 118px 0 72px; position: relative; overflow: hidden; text-align: center;
  background:
    radial-gradient(ellipse 90% 55% at 50% 108%, rgba(13, 92, 128, 0.55) 0%, transparent 70%),
    radial-gradient(ellipse 70% 40% at 50% -10%, rgba(34, 200, 240, 0.10) 0%, transparent 70%);
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 26px;
  background: rgba(34, 200, 240, 0.08); border: 1px solid rgba(34, 200, 240, 0.28);
  padding: 6px 16px; border-radius: 100px; font-size: 0.8rem; font-weight: 500; color: var(--accent-light);
}
.hero-badge .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.55; transform: scale(1.35); } }
.hero h1 {
  font-size: clamp(2.1rem, 5vw, 3.5rem); font-weight: 800; line-height: 1.12;
  letter-spacing: -0.035em; margin-bottom: 22px; color: #f2fafc;
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(120deg, var(--accent) 10%, var(--accent-light) 90%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-sub { font-size: clamp(1rem, 2vw, 1.18rem); color: var(--text-muted); max-width: 760px; margin: 0 auto 36px; }
.hero-sub strong { color: var(--text); font-weight: 600; }
.hero-ctas { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 18px; }
.hero-fine { color: var(--text-dim); font-size: 0.85rem; margin-bottom: 48px; }

.btn-primary, .btn-secondary {
  display: inline-flex; align-items: center; gap: 8px; padding: 13px 26px;
  border-radius: 12px; font-size: 1rem; font-weight: 650; cursor: pointer;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}
.btn-primary { background: var(--accent); color: #032029; box-shadow: 0 4px 22px rgba(34, 200, 240, 0.3); }
.btn-primary:hover { background: var(--accent-light); transform: translateY(-2px); box-shadow: 0 8px 32px rgba(34, 200, 240, 0.42); }
.btn-secondary { background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border-light); color: var(--text); }
.btn-secondary:hover { background: rgba(255, 255, 255, 0.1); border-color: var(--accent); transform: translateY(-2px); }
.btn-small { padding: 9px 16px; font-size: 0.88rem; border-radius: 10px; }

/* The recorder in the hero: an illustration, not measured data. Ten curves
   of one week, one of them above the others. The curves are in
   hero-series.svg; here they are uncovered from left to right. */
.recorder {
  max-width: 980px; margin: 0 auto; text-align: left;
  background: linear-gradient(180deg, #0a202a, #071820);
  border: 1px solid var(--border-light); border-radius: var(--radius-lg);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6), 0 0 70px rgba(34, 200, 240, 0.08);
  overflow: hidden;
}
.rec-head {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 14px 18px; border-bottom: 1px solid var(--border);
  font-family: var(--mono); font-size: 0.74rem; color: var(--text-dim);
}
.rec-chip { border: 1px solid var(--border); border-radius: 6px; padding: 2px 9px; background: rgba(255, 255, 255, 0.02); white-space: nowrap; }
.rec-chip b { color: var(--accent-light); font-weight: 500; }
.rec-count { margin-left: auto; white-space: nowrap; }
.rec-plot { position: relative; margin: 18px 18px 0 46px; aspect-ratio: 1000 / 340; }
.rec-grid { position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, rgba(148, 190, 205, 0.11) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(148, 190, 205, 0.09) 1px, transparent 1px);
  background-size: calc(100% / 7) 100%, 100% 25%;
  border-right: 1px solid rgba(148, 190, 205, 0.11); border-bottom: 1px solid rgba(148, 190, 205, 0.22);
}
.rec-y { position: absolute; right: 100%; top: 0; bottom: 0; width: 38px; font-family: var(--mono); font-size: 0.66rem; color: var(--text-dim); }
.rec-y span { position: absolute; right: 8px; transform: translateY(-50%); }
.rec-series { position: absolute; inset: 0; }
.rec-series img { width: 100%; height: 100%; }
.rec-pen { position: absolute; top: 0; bottom: 0; left: 100%; width: 1px; background: var(--accent-light); opacity: 0; }
.rec-label {
  position: absolute; left: 35.7%; top: 0; transform: translate(14px, -4px);
  font-family: var(--mono); font-size: 0.72rem; line-height: 1.35; color: var(--red);
  background: rgba(5, 19, 26, 0.88); border: 1px solid rgba(255, 107, 107, 0.45);
  border-radius: 8px; padding: 5px 10px; white-space: nowrap;
}
.rec-label small { display: block; color: var(--text-muted); font-size: 0.68rem; }
.rec-x { display: grid; grid-template-columns: repeat(7, 1fr); margin: 6px 18px 0 46px; font-family: var(--mono); font-size: 0.68rem; color: var(--text-dim); }
.rec-x span { padding-left: 4px; }
.rec-caption { padding: 14px 18px 16px; font-size: 0.82rem; color: var(--text-dim); }
.rec-caption a { color: var(--text-muted); border-bottom: 1px solid var(--border-light); }
.rec-caption a:hover { color: var(--accent-light); }

@media (prefers-reduced-motion: no-preference) {
  .rec-series { clip-path: inset(0 100% 0 0); animation: sweep 2.8s 0.35s cubic-bezier(0.45, 0.05, 0.3, 1) forwards; }
  .rec-pen { animation: pen 2.8s 0.35s cubic-bezier(0.45, 0.05, 0.3, 1) forwards; }
  .rec-label { opacity: 0; animation: appear 0.6s 3.1s ease forwards; }
}
@keyframes sweep { to { clip-path: inset(0 0 0 0); } }
@keyframes pen { 0% { left: 0; opacity: 0.7; } 92% { opacity: 0.7; } 100% { left: 100%; opacity: 0; } }
@keyframes appear { to { opacity: 1; } }

/* ── Positioning ── */
.positioning {
  padding: 82px 0 72px; background: var(--bg-alt);
  border-top: 1px solid var(--border);   /* the line below is the one of the stats bar */
}
.positioning-intro { max-width: 850px; margin-bottom: 38px; }
.positioning-intro .section-title { font-size: clamp(1.7rem, 3.2vw, 2.6rem); }
.positioning-intro .section-sub { max-width: 760px; }
.position-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.position-card {
  padding: 28px 30px; border: 1px solid var(--border); border-radius: var(--radius-lg);
  background: rgba(12, 37, 48, 0.72);
}
.position-card.ekg-card { border-color: var(--accent-deep); background: linear-gradient(145deg, rgba(13, 92, 128, 0.22), rgba(12, 37, 48, 0.88)); }
.position-kicker { display: block; color: var(--text-dim); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 8px; }
.ekg-card .position-kicker { color: var(--accent); }
.position-card h3 { font-size: 1.18rem; line-height: 1.4; margin-bottom: 16px; }
.position-card ul { list-style: none; display: grid; gap: 9px; }
.position-card li { color: var(--text-muted); font-size: 0.94rem; padding-left: 20px; position: relative; }
.position-card li::before { content: ''; position: absolute; left: 1px; top: 0.72em; width: 7px; height: 1px; background: var(--text-dim); }
.ekg-card li::before { background: var(--accent); }
.position-note { margin-top: 26px; color: var(--text-muted); font-size: 0.92rem; }

/* ── Core differences ── */
.stats-bar { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 30px 0; }
.stats-grid { display: flex; align-items: flex-start; justify-content: center; flex-wrap: wrap; }
.stat { text-align: center; padding: 10px 34px; position: relative; max-width: 270px; }
.stat + .stat::before { content: ''; position: absolute; left: 0; top: 14px; height: 40px; width: 1px; background: var(--border); }
.stat-num { font-size: 1.65rem; font-weight: 800; color: var(--accent-light); line-height: 1.2; letter-spacing: -0.02em; }
.stat-label { font-size: 0.82rem; color: var(--text-dim); margin-top: 4px; line-height: 1.45; }

/* ── Sections ── */
section { padding: 96px 0; }
.alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-label { font-size: 0.78rem; font-weight: 650; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }
.section-title { font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 750; line-height: 1.22; letter-spacing: -0.025em; margin-bottom: 16px; }
.section-sub { font-size: 1.05rem; color: var(--text-muted); max-width: 640px; }
.section-header { margin-bottom: 52px; }
.text-center { text-align: center; }
.text-center .section-sub { margin: 0 auto; }

/* ── The questions ── */
.question-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.question {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 26px 28px; display: flex; gap: 18px; align-items: flex-start;
  transition: border-color var(--transition), background var(--transition), transform var(--transition);
}
.question:hover { border-color: var(--border-light); background: var(--bg-card-hover); transform: translateY(-3px); }
.question svg { flex-shrink: 0; width: 64px; height: 40px; margin-top: 4px; }
.question p { font-size: 1.08rem; font-weight: 550; line-height: 1.45; }
.question p span { display: block; font-size: 0.86rem; font-weight: 400; color: var(--text-muted); margin-top: 6px; line-height: 1.55; }
.after-grid {
  max-width: 800px; margin: 48px auto 0; text-align: center; font-size: 1.12rem; line-height: 1.65;
  border-top: 1px solid var(--border); padding-top: 34px;
}
.after-grid span { color: var(--text-muted); }

/* ── Across organisational boundaries ──
   Every party reports OK, the customer has the problem. The bar and the
   state in words are those of the collector's display. */
.boundary-section {
  border-top: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(34, 200, 240, 0.05) 0%, rgba(13, 92, 128, 0.14) 100%);
}
.boundary-section .section-sub { max-width: 760px; }
.voices { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 40px; }
.voice {
  position: relative; padding: 18px 20px 20px 34px; border-radius: var(--radius);
  background: var(--bg-card); border: 1px solid var(--border);
}
.voice::before { content: ''; position: absolute; left: 16px; top: 18px; bottom: 20px; width: 4px; border-radius: 4px; background: var(--green); }
.voice .who {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px;
  font-size: 0.76rem; font-weight: 650; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim);
}
.voice .state { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0; text-transform: none; color: var(--green); background: rgba(76, 208, 138, 0.1); padding: 2px 9px; border-radius: 100px; }
.voice p { font-size: 1.02rem; font-weight: 550; line-height: 1.45; }
.voice.customer { border-color: rgba(255, 107, 107, 0.45); }
.voice.customer::before { background: var(--red); }
.voice.customer .state { color: var(--red); background: rgba(255, 107, 107, 0.12); }
.boundary-after { max-width: 860px; color: var(--text-muted); font-size: 1.02rem; }
.boundary-after strong { color: var(--text); font-weight: 600; }

/* ── Two-column sections with a picture ── */
.story-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.story-grid > * { min-width: 0; }   /* a wide code block must not widen its column */
.story-grid.top { align-items: start; }
.story-grid.wide-left { grid-template-columns: 1.25fr 1fr; gap: 48px; }
.story-text p { color: var(--text-muted); margin-bottom: 16px; font-size: 0.98rem; }
.story-text p strong { color: var(--text); font-weight: 600; }
.finding-list { list-style: none; margin: 22px 0; display: flex; flex-direction: column; gap: 10px; }
.finding-list li {
  display: flex; align-items: flex-start; gap: 12px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 14px; font-size: 0.9rem; color: var(--text-muted);
}
.alt .finding-list li { background: rgba(255, 255, 255, 0.025); }
.finding-list li strong { color: var(--text); font-weight: 600; }
.finding-num {
  font-family: var(--mono); font-size: 0.72rem; color: var(--accent);
  background: rgba(34, 200, 240, 0.1); padding: 3px 8px; border-radius: 5px;
  flex-shrink: 0; margin-top: 2px; white-space: nowrap;
}
.finding-list.stacked li { flex-direction: column; gap: 7px; }
.finding-list.stacked .finding-num { margin-top: 0; }
.finding-num.red { color: var(--red); background: rgba(255, 107, 107, 0.1); }
.finding-num.green { color: var(--green); background: rgba(76, 208, 138, 0.1); }
.shot {
  display: block; border-radius: var(--radius-lg); overflow: hidden; cursor: zoom-in;
  border: 1px solid var(--border-light); box-shadow: var(--shadow-lg); background: #fff;
  transition: border-color var(--transition), transform var(--transition);
}
.shot:hover { border-color: var(--accent); transform: translateY(-3px); }
.shot img { width: 100%; }
figure.sticky { position: sticky; top: 92px; }
.shot-caption { font-size: 0.82rem; color: var(--text-dim); margin-top: 12px; }
.resolution {
  margin-top: 22px; padding: 16px 18px; border-radius: var(--radius);
  border: 1px solid rgba(76, 208, 138, 0.35); background: rgba(76, 208, 138, 0.06);
}
.resolution p { margin: 0; color: var(--text); }
.resolution .section-label { color: var(--green); margin-bottom: 6px; }

/* ── Workflow ── */
.steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; position: relative; counter-reset: step; }
.step { padding: 0 18px 0 0; position: relative; }
.step-num {
  width: 34px; height: 34px; border-radius: 50%; position: relative; z-index: 1;
  background: var(--bg-alt); border: 1.5px solid var(--accent); color: var(--accent-light);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--mono); font-size: 0.85rem; font-weight: 600; margin-bottom: 18px;
}
.step::before { content: ''; position: absolute; top: 17px; left: 34px; right: 0; height: 1.5px; background: linear-gradient(to right, var(--accent), var(--border-light)); }
.step:last-child::before { display: none; }
.step h3 { font-size: 1.05rem; font-weight: 650; margin-bottom: 8px; }
.step p { font-size: 0.88rem; color: var(--text-muted); line-height: 1.6; }
.steps-after { margin-top: 44px; color: var(--text-muted); max-width: 760px; font-size: 0.98rem; }
.steps-after strong { color: var(--text); font-weight: 600; }

/* ── Quote ── */
.quote-section {
  padding: 68px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(34, 200, 240, 0.06) 0%, rgba(13, 92, 128, 0.16) 100%);
}
.quote-inner { max-width: 780px; margin: 0 auto; text-align: center; }
.quote-mark { font-size: 4rem; line-height: 1; color: var(--accent); opacity: 0.4; margin-bottom: -8px; }
blockquote { font-size: clamp(1.15rem, 2.2vw, 1.5rem); font-weight: 500; line-height: 1.55; margin: 0 0 18px; }
blockquote em { font-style: normal; color: var(--accent-light); }
.quote-source { font-size: 0.85rem; color: var(--text-muted); }

/* ── Cards ── */
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.features-grid.four { grid-template-columns: repeat(4, 1fr); }
.feature-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 26px;
  transition: border-color var(--transition), background var(--transition), transform var(--transition);
}
.feature-card:hover { border-color: var(--border-light); background: var(--bg-card-hover); transform: translateY(-3px); }
.feature-card h3 { font-size: 1.03rem; font-weight: 650; margin-bottom: 8px; }
.feature-card p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }
.feature-card .kicker { font-family: var(--mono); font-size: 0.74rem; color: var(--accent); margin-bottom: 12px; display: block; }

/* ── Pictures of the workbench ── */
.showcase { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.showcase-item {
  display: block; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border);
  background: var(--bg-card); cursor: zoom-in;
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}
.showcase-item:hover { border-color: var(--accent); transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.showcase-item.span2 { grid-column: span 2; }
.showcase-img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: top left; background: #fff; }
.showcase-item.span2 .showcase-img { aspect-ratio: 21 / 9; }
.showcase-caption { padding: 14px 18px 16px; border-top: 1px solid var(--border); }
.showcase-caption h3 { font-size: 0.95rem; font-weight: 650; margin-bottom: 3px; }
.showcase-caption p { font-size: 0.82rem; color: var(--text-muted); line-height: 1.55; }

/* ── Collector ── */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 22px; }
.chip {
  font-family: var(--mono); font-size: 0.76rem; padding: 4px 11px; border-radius: 7px;
  border: 1px solid var(--border-light); color: var(--accent-light); background: rgba(34, 200, 240, 0.05);
}
.chip.store { color: var(--amber); border-color: rgba(240, 182, 74, 0.35); background: rgba(240, 182, 74, 0.05); }
.chips-label { font-size: 0.78rem; font-weight: 650; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim); }
.code-block {
  background: #030d12; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px 22px; font-family: var(--mono); font-size: 0.8rem; color: #bfe6f2;
  line-height: 1.75; overflow-x: auto; white-space: pre; tab-size: 2;
}
.code-block .c { color: var(--text-dim); }
.code-block .k { color: var(--accent); }
.code-block .s { color: #b9e7a0; }
.code-title { font-family: var(--mono); font-size: 0.74rem; color: var(--text-dim); margin-bottom: 8px; }
.display-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 56px; }
.display-row .shot { background: #0d3142; }
.figure-wide { margin-top: 56px; }
.figure-wide .shot { background: #fff; padding: 12px; }

/* ── What it is not ── */
.not-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 56px; }
.not-card { border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; background: var(--bg-card); }
.not-card h3 { font-size: 0.98rem; font-weight: 650; margin-bottom: 6px; display: flex; gap: 8px; align-items: baseline; }
.not-card h3::before { content: '×'; color: var(--red); font-weight: 700; }
.not-card p { font-size: 0.86rem; color: var(--text-muted); line-height: 1.55; }
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-card); }
table.compare { width: 100%; border-collapse: collapse; font-size: 0.9rem; min-width: 640px; }
.compare th { text-align: left; font-size: 0.74rem; font-weight: 650; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim); padding: 14px 18px; border-bottom: 1px solid var(--border); }
.compare th:last-child { color: var(--accent); }
.compare td { padding: 14px 18px; border-bottom: 1px solid var(--border); vertical-align: top; color: var(--text-muted); line-height: 1.55; }
.compare tr:last-child td { border-bottom: none; }
.compare td:first-child { color: var(--text); font-weight: 600; width: 26%; }
.compare td:last-child { color: var(--text); background: rgba(34, 200, 240, 0.04); width: 38%; }
.table-note { font-size: 0.86rem; color: var(--text-dim); margin-top: 16px; max-width: 760px; }

/* ── Download ── */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 26px; display: flex; flex-direction: column; gap: 12px;
  transition: border-color var(--transition);
}
.card.yours { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 0 40px var(--accent-glow); }
.card h3 { font-size: 1.2rem; font-weight: 700; }
.card .status { font-size: 0.82rem; color: var(--text-dim); margin-top: -8px; }
.card .btn-primary { justify-content: center; }
.card .second { font-size: 0.86rem; color: var(--text-muted); text-align: center; }
.card ol { list-style: none; counter-reset: li; display: flex; flex-direction: column; gap: 8px; margin-top: 6px; padding-top: 16px; border-top: 1px solid var(--border); }
.card ol li { counter-increment: li; font-size: 0.86rem; color: var(--text-muted); padding-left: 26px; position: relative; line-height: 1.55; }
.card ol li::before { content: counter(li); position: absolute; left: 0; top: 1px; font-family: var(--mono); font-size: 0.74rem; color: var(--accent); }
.card ol code { display: block; width: fit-content; max-width: 100%; margin-top: 4px; white-space: normal; overflow-wrap: anywhere; }
.rel-line { color: var(--text-muted); }
.first-chart { margin-top: 64px; }
.first-chart h3 { font-size: 1.3rem; font-weight: 700; margin-bottom: 14px; letter-spacing: -0.01em; }
.first-chart p { color: var(--text-muted); font-size: 0.96rem; margin-bottom: 14px; }
.first-chart p strong { color: var(--text); font-weight: 600; }
.more-links { display: flex; flex-wrap: wrap; gap: 10px 26px; margin-top: 26px; font-size: 0.9rem; }

/* ── Closing ── */
.cta-section {
  text-align: center; padding: 100px 0;
  background: radial-gradient(ellipse 60% 60% at 50% 50%, rgba(34, 200, 240, 0.09) 0%, transparent 70%);
}
.cta-section .section-title { font-size: clamp(1.8rem, 3.5vw, 2.8rem); }
.cta-section p { color: var(--text-muted); font-size: 1.05rem; max-width: 560px; margin: 0 auto 38px; }
.cta-buttons { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.github-btn {
  display: inline-flex; align-items: center; gap: 10px; padding: 15px 30px; border-radius: 12px;
  font-size: 1rem; font-weight: 700; background: #fff; color: #0d1117;
  transition: transform var(--transition), box-shadow var(--transition); box-shadow: 0 4px 20px rgba(255, 255, 255, 0.1);
}
.github-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(255, 255, 255, 0.2); }
.github-btn svg { width: 22px; height: 22px; }

footer { border-top: 1px solid var(--border); padding: 40px 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 18px; }
.footer-logo { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; }
.footer-links a { font-size: 0.875rem; color: var(--text-muted); transition: color var(--transition); }
.footer-links a:hover { color: var(--text); }
.footer-copy { font-size: 0.8rem; color: var(--text-dim); }

/* ── Large view of a picture ── */
dialog.lightbox {
  border: none; padding: 0; background: transparent; margin: auto;
  max-width: min(96vw, 1920px); max-height: 94vh; overflow: visible;
}
dialog.lightbox::backdrop { background: rgba(0, 0, 0, 0.9); }
dialog.lightbox img { max-width: 96vw; max-height: 86vh; width: auto; border-radius: var(--radius); background: #fff; box-shadow: 0 24px 80px rgba(0, 0, 0, 0.8); }
dialog.lightbox p { color: var(--text-muted); font-size: 0.88rem; text-align: center; margin-top: 12px; }
.lightbox-close {
  position: fixed; top: 18px; right: 22px; width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.12); border: none; color: #fff; font-size: 1.1rem; cursor: pointer;
}
.lightbox-close:hover { background: rgba(255, 255, 255, 0.24); }

/* ── Fade-in while scrolling (only with JavaScript, otherwise everything is there) ── */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s ease, transform 0.6s ease; }
  .js .reveal.visible { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-badge .dot { animation: none; }
}

/* ── Narrow windows ── */
@media (max-width: 1040px) {
  .nav-links .nav-link { display: none; }
  .not-grid, .features-grid.four, .voices { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  section { padding: 72px 0; }
  .story-grid, .story-grid.wide-left, .question-grid, .showcase, .cards, .display-row, .position-grid { grid-template-columns: 1fr; }
  figure.sticky { position: static; }
  .story-grid { gap: 36px; }
  .showcase-item.span2 { grid-column: span 1; }
  .showcase-item.span2 .showcase-img { aspect-ratio: 16 / 9; }
  .steps { grid-template-columns: 1fr; gap: 26px; }
  .step { padding: 0 0 0 52px; }
  .step-num { position: absolute; left: 0; top: 0; margin: 0; }
  .step::before { top: 34px; bottom: -26px; left: 16px; right: auto; width: 1.5px; height: auto; background: linear-gradient(to bottom, var(--accent), var(--border-light)); }
  .stat + .stat::before { display: none; }
  .stat { padding: 10px 18px; }
  .footer-inner { flex-direction: column; text-align: center; }
  .rec-count { display: none; }
}
@media (max-width: 700px) {
  /* The comparison as stacked entries, so that the last column stays in view. */
  table.compare { min-width: 0; }
  .compare thead { display: none; }
  .compare tr { display: block; padding: 10px 0; border-bottom: 1px solid var(--border); }
  .compare tr:last-child { border-bottom: none; }
  .compare td, .compare td:first-child, .compare td:last-child { display: block; width: auto; border: none; padding: 4px 18px; background: none; }
  .compare td:last-child { color: var(--accent-light); }
  .compare td:last-child::before { content: '\2192\00a0'; color: var(--accent); }
}
@media (max-width: 560px) {
  .container, .nav-inner { padding: 0 16px; }
  .hero { padding-top: 108px; }
  .brand > span:not(.badge-mark) { display: none; }
  .nav-cta span { display: none; }
  .nav-cta { padding: 8px 10px; }
  .not-grid, .features-grid.four, .voices { grid-template-columns: 1fr; }
  .question { flex-direction: column; gap: 10px; padding: 22px; }
  .rec-plot { margin-left: 38px; margin-right: 12px; aspect-ratio: 1000 / 520; }
  .rec-x { margin-left: 38px; margin-right: 12px; }
  .rec-y { width: 32px; }
  .rec-label { left: auto; right: 4px; font-size: 0.64rem; transform: translateY(-8px); }
  .rec-chip.opt { display: none; }
}
