/* BlueDeck Technos - design system and layout
   Tokens first; components follow in page order. */
:root {
  --navy-950: #061A27;
  --navy-900: #0C2C40;
  --navy-800: #12405B;
  --blue-700: #0B6377;
  --blue-600: #0E7C94;
  --blue-500: #1B94AE;
  --blue-300: #97C6D4;
  --blue-100: #E3F1F5;
  --blue-50: #F0F8FA;
  --ink: #0b1220;
  --text: #293a45;
  --muted: #526676;
  --line: #dbe5ea;
  --bg: #ffffff;
  --bg-soft: #f3f8fa;
  --ok: #0a7a54;
  --ok-bg: #e5f6ee;
  --warn: #8f5508;
  --warn-bg: #fdf1dc;
  --err: #b32d29;
  --err-bg: #fdeceb;
  --info: #0B6377;
  --info-bg: #E3F1F5;
  --radius: 0;
  --radius-sm: 0;
  --shadow: 0 24px 48px -28px rgba(12, 44, 64, .4);
  --shadow-lg: 0 30px 60px -20px rgba(6, 26, 39, .45), 0 12px 24px -12px rgba(6, 26, 39, .3);
  --font: "Segoe UI Variable", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", "SF Mono", Consolas, monospace;
  --header-h: 68px;
  --surface: #ffffff;
  --surface-2: #f6f8fb;
  --field-border: #b9c7d1;
  --field-hover: #8398a6;
  --err-line: #f2c1be; --err-text: #7d1f1c;
  --ok-line: #b5e3cf; --ok-text: #075a3d;
  --info-text: #08495a;
  --idle-bg: #eef2f4; --idle-text: #4a5a66;
  --edge: #12405B;
  --gloss-a: #ffffff;
  --gloss-b: #eef5f8;
  --gloss-edge: rgba(255,255,255,.95);
  --sheen: rgba(255,255,255,.16);
  --btn: #0E7C94; --btn-top: #12839a; --btn-bot: #0B6A80;
  --btn-h: #0B6377; --btn-h-top: #0e7388; --btn-h-bot: #095568;
  --btn-glow: rgba(14, 124, 148, .85);
  --glow: rgba(77, 184, 208, .3); --glow2: rgba(27, 148, 174, .16);
  --header-bg: rgba(6, 26, 39, .8);
  --tour-bar: #12405B;
  color-scheme: light;
}

/* ---------- Dark theme (switch in the header; saved in localStorage) ---------- */
:root[data-theme="dark"] {
  --navy-900: #1a4d68;
  --navy-800: #1f5f80;
  --blue-700: #6cc3d8;
  --blue-600: #4db8d0;
  --blue-500: #3aa6c0;
  --blue-300: #97C6D4;
  --blue-100: #15384a;
  --blue-50: #10303d;
  --ink: #eaf3f7;
  --text: #c4d3dc;
  --muted: #9db1be;
  --line: #243b4a;
  --bg: #0a1620;
  --bg-soft: #0e1d29;
  --surface: #12232f;
  --surface-2: #0e1d29;
  --field-border: #4a6272;
  --field-hover: #7d97a8;
  --ok: #5fd3a5; --ok-bg: #0f3a2c; --ok-line: #1f6b52; --ok-text: #9be8c9;
  --warn: #f0b45a; --warn-bg: #3d2d0e;
  --err: #ff9d98; --err-bg: #43201f; --err-line: #7a3a38; --err-text: #ffc9c5;
  --info: #7cd0e3; --info-bg: #12384a; --info-text: #a8dfec;
  --idle-bg: #22343f; --idle-text: #b7c8d2;
  --edge: #8fb4c6;
  --shadow: 0 24px 48px -28px rgba(0, 0, 0, .7);
  --gloss-a: rgba(255,255,255,.075);
  --gloss-b: rgba(255,255,255,0);
  --gloss-edge: rgba(255,255,255,.14);
  --sheen: rgba(255,255,255,.07);
  color-scheme: dark;
}
:root[data-theme="dark"] .req { color: #ff9d98; }
:root[data-theme="dark"] .hb u.warn { background: #e69a1a; }

/* ---------- Blue theme: bright professional corporate blue ---------- */
:root[data-theme="blue"] {
  --navy-950: #06173f;
  --navy-900: #0c3085;
  --navy-800: #1342a8;
  --navy-700: #1a55cc;
  --blue-700: #0f3fb0;
  --blue-600: #1257e8;
  --blue-500: #2f7bff;
  --blue-300: #9fc2ff;
  --blue-100: #cfe0ff;
  --blue-50: #e3edff;
  --ink: #071433;
  --text: #1c2f55;
  --muted: #3d5380;
  --line: #b5caf0;
  --bg: #eaf1ff;
  --bg-soft: #dce8ff;
  --surface: #ffffff;
  --surface-2: #e8f0ff;
  --field-border: #8ea9d8;
  --field-hover: #5f82c4;
  --info: #0f3fb0; --info-bg: #cfe0ff; --info-text: #0c3085;
  --edge: #1342a8;
  --gloss-b: #e3ecff;
  --btn: #1257e8; --btn-top: #1f66f5; --btn-bot: #0f3fb0;
  --btn-h: #0f3fb0; --btn-h-top: #1553d6; --btn-h-bot: #0b2f8a;
  --btn-glow: rgba(18, 87, 232, .85);
  --glow: rgba(70, 140, 255, .5); --glow2: rgba(47, 123, 255, .3);
  --header-bg: rgba(6, 23, 63, .88);
  --tour-bar: #1342a8;
  --shadow: 0 24px 48px -26px rgba(12, 48, 133, .55);
}
:root[data-theme="blue"] .kpi, :root[data-theme="blue"] .panel, :root[data-theme="blue"] .cv, :root[data-theme="blue"] .sol { box-shadow: inset 0 1px 0 var(--gloss-edge), 0 14px 30px -18px rgba(18, 87, 232, .45); }
:root[data-theme="blue"] .section-soft { background-image: linear-gradient(180deg, #e3edff, #d3e2ff); }
:root[data-theme="blue"] .eyebrow:not(.eyebrow-light) { color: var(--blue-600); }
.dash-line { stroke: var(--blue-600); }
#hg stop { stop-color: var(--blue-500); }
#wf-arr path { fill: var(--edge); }
#wf-arr-o path { fill: var(--blue-600); }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 1rem; line-height: 1.6; color: var(--text); background: var(--bg); overflow-x: clip; }
img, svg { max-width: 100%; }
h1, h2, h3, h4 { color: var(--ink); line-height: 1.15; margin: 0; letter-spacing: -.02em; }
p { margin: 0; }
ul, ol, dl, dd { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: var(--blue-700); text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--blue-500); outline-offset: 3px; border-radius: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; background: #fff; color: #0b1220; padding: 10px 16px; border-radius: 0; z-index: 200; font-weight: 600; }
.skip-link:focus { top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.container { width: min(1200px, 100% - 40px); margin-inline: auto; }
.ico { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: 0; border: 1px solid transparent; font-weight: 600; font-size: .95rem; text-decoration: none; line-height: 1.2; transition: background-color .18s, border-color .18s; }
.btn-lg { padding: 13px 24px; font-size: 1rem; }
.btn-block { width: 100%; }
.btn-primary { background: var(--btn); color: #fff; }
.btn-primary:hover { background: var(--btn-h); }
.btn-ghost { color: #fff; border-color: rgba(255,255,255,.35); background: rgba(255,255,255,.04); }
.btn-ghost:hover { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.6); }
.btn .ico { width: 18px; height: 18px; }
.btn[disabled] { opacity: .75; cursor: progress; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 100; background: rgba(6, 26, 39, .96); border-bottom: 1px solid rgba(255,255,255,.08); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: #fff; font-weight: 700; font-size: 1.2rem; letter-spacing: -.02em; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 0; background: #fff; flex: none; }
.brand-mark img { height: 27px; width: auto; display: block; }
.brand-text span { font-weight: 400; color: var(--blue-300); }
.primary-nav { display: flex; align-items: center; gap: 20px; }
.primary-nav ul { display: flex; gap: 4px; }
.primary-nav ul a { display: block; color: rgba(255,255,255,.82); text-decoration: none; font-size: .93rem; font-weight: 500; padding: 9px 12px; border-radius: 0; transition: color .15s, background-color .15s; }
.primary-nav ul a:hover, .primary-nav ul a.active { color: #fff; background: rgba(255,255,255,.1); }
.header-actions { display: flex; align-items: center; gap: 8px; }
.sw-light { background: linear-gradient(135deg, #ffffff 50%, #0E7C94 50%); }
.sw-dark { background: linear-gradient(135deg, #12232f 50%, #4db8d0 50%); }
.sw-auto { background: conic-gradient(#ffffff 0 33%, #12232f 0 66%, #1257e8 0); }
.sw-blue { background: linear-gradient(135deg, #0a2250 50%, #3b82f0 50%); }
.menu-toggle { display: none; width: 44px; height: 44px; border: 1px solid rgba(255,255,255,.3); border-radius: 0; background: transparent; flex-direction: column; align-items: center; justify-content: center; gap: 5px; padding: 0; }
.menu-toggle span { width: 20px; height: 2px; background: #fff; border-radius: 0; transition: transform .2s, opacity .2s; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Typography helpers ---------- */
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--blue-700); margin-bottom: 16px; }
.eyebrow-light { color: var(--blue-300); }
h2 { font-size: clamp(1.8rem, 3.2vw, 2.6rem); font-weight: 700; letter-spacing: -.03em; }
.sub { margin-top: 16px; font-size: 1.06rem; color: var(--muted); max-width: 40rem; }
.sub-light { color: rgba(255,255,255,.78); }

/* ---------- Hero ---------- */
.hero { position: relative; background: var(--navy-950); color: #fff; overflow: hidden; padding: clamp(48px, 7vw, 88px) 0 24px; isolation: isolate; }
.hero-bg { position: absolute; inset: 0; z-index: -1; background:
  radial-gradient(60% 55% at 78% 30%, rgba(27,148,174,.26), transparent 70%),
  linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 56px 56px,
  linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 56px 56px;
  -webkit-mask-image: linear-gradient(#000 55%, transparent); mask-image: linear-gradient(#000 55%, transparent); }
.hero-inner { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 4vw, 60px); align-items: center; }
.hero h1 { color: #fff; font-size: clamp(2.1rem, 4.4vw, 3.7rem); letter-spacing: -.035em; line-height: 1.06; font-weight: 700; }
.lede { margin-top: 20px; font-size: clamp(1.02rem, 1.3vw, 1.14rem); color: rgba(255,255,255,.8); max-width: 34rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-points { margin-top: 26px; display: grid; gap: 8px; color: rgba(255,255,255,.78); font-size: .93rem; }
.hero-points li { display: flex; gap: 10px; align-items: flex-start; }
.hero-points .ico { color: var(--blue-300); width: 18px; height: 18px; margin-top: 3px; }
.hero-disclaimer { margin-top: 28px; font-size: .8rem; color: rgba(255,255,255,.68); }

/* Hero dashboard (illustration; fixed demonstration data) */
.hero-visual { min-width: 0; }
.dash { display: grid; grid-template-columns: 148px minmax(0, 1fr); background: var(--surface); border-radius: 0; overflow: hidden; box-shadow: var(--shadow-lg); border: 1px solid rgba(255,255,255,.14); color: var(--text); font-size: 12px; line-height: 1.4; }
.dash-side { background: var(--navy-900); padding: 14px 10px; color: rgba(255,255,255,.75); }
.dash-logo { display: flex; align-items: center; gap: 8px; color: #fff; padding: 2px 6px 14px; font-size: 13px; }
.dash-logo svg { width: 22px; height: 22px; }
.dash-side li { display: flex; align-items: center; gap: 9px; padding: 8px; border-radius: 0; font-size: 12px; margin-bottom: 2px; }
.dash-side li .ico { width: 15px; height: 15px; }
.dash-side li.on { background: rgba(27,148,174,.28); color: #fff; }
.dash-main { padding: 14px; background: var(--surface-2); min-width: 0; display: grid; gap: 10px; }
.dash-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.dash-top b { display: block; color: var(--ink); font-size: 14px; }
.dash-top small, .dash-card-h small { color: var(--muted); font-size: 11px; }
.demo-tag { font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; background: var(--warn-bg); color: var(--warn); padding: 3px 8px; border-radius: 0; white-space: nowrap; }
.demo-tag-dark { background: rgba(255,255,255,.14); color: #fff; }
.dash-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.dash-kpis > div, .dash-chart, .dash-plants, .dash-table { background: var(--surface); border: 1px solid var(--line); border-radius: 0; padding: 10px; min-width: 0; }
.dash-kpis small { display: block; color: var(--muted); font-size: 10.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dash-kpis b { display: block; font-size: 18px; color: var(--ink); letter-spacing: -.02em; margin: 2px 0; }
.dash-kpis i { font-style: normal; font-size: 10.5px; color: var(--muted); }
.dash-kpis i.warn { color: var(--warn); }
.dash-row { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 8px; }
.dash-card-h { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; margin-bottom: 6px; }
.dash-card-h b { color: var(--ink); font-size: 12px; }
.dash-chart svg { width: 100%; height: 96px; display: block; }
.dash-plants li { display: flex; align-items: center; gap: 7px; padding: 5px 0; border-bottom: 1px solid var(--line); font-size: 11.5px; }
.dash-plants li:last-child { border: 0; }
.dash-plants em { margin-left: auto; font-style: normal; color: var(--muted); font-size: 10.5px; }
.st { width: 8px; height: 8px; border-radius: 0; flex: none; }
.st.ok { background: #22c07f; } .st.warn { background: #e69a1a; } .st.idle { background: #9AAEB8; }
.dash-table table { width: 100%; border-collapse: collapse; }
.dash-table td { padding: 6px 4px; border-top: 1px solid var(--line); font-size: 11.5px; white-space: nowrap; }
.dash-table td:first-child { font-family: var(--mono); color: var(--muted); font-size: 11px; }
.dash-table td:nth-child(2) { overflow: hidden; text-overflow: ellipsis; max-width: 130px; }
.chip { display: inline-block; padding: 2px 8px; border-radius: 0; font-size: 10.5px; font-weight: 600; white-space: nowrap; }
.chip.ok { background: var(--ok-bg); color: var(--ok); } .chip.warn { background: var(--warn-bg); color: var(--warn); } .chip.info { background: var(--info-bg); color: var(--info); } .chip.err { background: var(--err-bg); color: var(--err); } .chip.idle { background: var(--idle-bg); color: var(--idle-text); }

/* ---------- Sections ---------- */
.section { padding: clamp(60px, 8vw, 104px) 0; }
.section-soft { background: var(--bg-soft); border-block: 1px solid var(--line); }
.section-dark { background: var(--navy-950); }
.section-dark h2 { color: #fff; }
.section-head { max-width: 46rem; margin-bottom: clamp(32px, 4.5vw, 52px); }

/* Challenges and value */
.cv { border: 1px solid var(--line); border-radius: 0; overflow: hidden; background: var(--surface); }
.cv-row { display: grid; grid-template-columns: minmax(0, 1fr) 40px minmax(0, 1.15fr); gap: 16px; align-items: center; padding: 20px clamp(16px, 2.4vw, 28px); border-top: 1px solid var(--line); }
.cv-row:first-child { border-top: 0; }
.cv-head { background: var(--bg-soft); font-size: .76rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-block: 12px; }
.cv-row h3 { font-size: 1.05rem; margin-bottom: 4px; letter-spacing: -.01em; }
.cv-row p { color: var(--muted); font-size: .95rem; }
.cv-row .ico { color: var(--blue-600); }
.cv-row .cv-val h3 { color: var(--blue-700); }

/* Solutions */
.sol-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(20px, 3vw, 32px); }
.sol { background: var(--surface); border: 1px solid var(--line); border-radius: 0; overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.sol img { display: block; width: 100%; height: clamp(190px, 20vw, 250px); object-fit: cover; }
.sol img.pos-mixer { object-position: 50% 38%; }
.sol-body { padding: clamp(20px, 2.6vw, 32px); display: flex; flex-direction: column; gap: 14px; flex: 1; }
.sol-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 0; background: var(--navy-900); color: #fff; }
.sol h3 { font-size: clamp(1.4rem, 2.2vw, 1.8rem); }
.sol-body > p { color: var(--muted); }
.ticks { display: grid; gap: 10px; }
.ticks li { display: flex; gap: 12px; align-items: flex-start; }
.ticks .ico { color: var(--blue-600); width: 18px; height: 18px; margin-top: 4px; }
.sol-flow { margin-top: auto; padding-top: 14px; border-top: 1px dashed var(--line); font-size: .88rem; color: var(--muted); }
.sol-flow b { display: block; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink); margin-bottom: 4px; }
.sol-note { margin-top: 24px; max-width: 46rem; color: var(--muted); }
.sol-note strong { color: var(--ink); }

/* ---------- Workflow explorer ---------- */
.wf-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.tab-btn { display: inline-flex; align-items: center; gap: 10px; text-align: left; min-height: 44px; padding: 10px 16px; border: 1px solid var(--line); background: var(--surface); border-radius: 0; color: var(--muted); font-weight: 600; font-size: .93rem; transition: background-color .15s, color .15s, border-color .15s; }
.tab-btn:hover { background: var(--blue-50); color: var(--ink); border-color: var(--blue-300); }
.tab-btn[aria-selected="true"] { background: var(--navy-900); border-color: var(--navy-900); color: #fff; }
.wf-panel { background: var(--surface); border: 1px solid var(--line); border-radius: 0; padding: clamp(18px, 3vw, 32px); box-shadow: var(--shadow); }
.wf-summary { color: var(--text); max-width: 52rem; }
.wf-banner { margin-top: 14px; padding: 10px 14px; border-radius: 0; background: var(--info-bg); color: var(--info-text); font-size: .92rem; font-weight: 500; }
.wf-legend { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 18px 0 14px; font-size: .84rem; color: var(--muted); }
.wf-legend span { display: inline-flex; align-items: center; gap: 8px; }
.wf-legend i { display: inline-block; width: 28px; height: 0; border-top: 2px solid var(--navy-800); position: relative; }
.wf-legend i.dash { border-top-style: dashed; border-color: var(--blue-600); }
.wf-legend i.box { width: 18px; height: 12px; border: 1.5px dashed var(--blue-600); border-radius: 0; background: var(--surface); }
.wf-legend i.box.solid { border-style: solid; border-color: var(--navy-900); background: var(--navy-900); }
.wf-stage { position: relative; }
.wf-edges { display: none; }
.wf-nodes { display: grid; gap: 0; }
.wf-label { display: none; }
.wf-node { position: relative; display: block; margin: 0 0 22px 28px; padding: 12px 14px; border: 1.5px solid var(--navy-900); background: var(--navy-900); color: #fff; border-radius: 0; }
.wf-node:last-child { margin-bottom: 0; }
.wf-node b { display: block; font-size: .98rem; line-height: 1.25; }
.wf-node small { display: block; margin-top: 3px; font-size: .86rem; line-height: 1.4; color: rgba(255,255,255,.82); }
.wf-node.optional { background: var(--surface); border: 1.5px dashed var(--blue-600); color: var(--ink); }
.wf-node.optional small { color: var(--muted); }
.wf-node.support { background: var(--blue-50); border: 1.5px solid var(--blue-300); color: var(--ink); }
.wf-node.support small { color: var(--muted); }
.wf-node .wf-tag { display: inline-block; margin-top: 8px; padding: 2px 8px; border-radius: 0; font-size: .72rem; font-weight: 700; letter-spacing: .02em; background: var(--blue-100); color: var(--info-text); }
.wf-node:not(.optional):not(.support) .wf-tag { background: rgba(255,255,255,.16); color: #fff; }
.wf-links { display: block; margin-top: 8px; font-size: .78rem; color: inherit; opacity: .85; }
.wf-node::before { content: ""; position: absolute; left: -17px; top: 0; bottom: -23px; width: 2px; background: var(--blue-300); }
.wf-node:last-child::before { display: none; }
.wf-node::after { content: ""; position: absolute; left: -22px; top: 18px; width: 12px; height: 12px; border-radius: 0; background: var(--surface); border: 2px solid var(--blue-600); }
.wf-notes { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); display: grid; gap: 8px; color: var(--muted); font-size: .93rem; }
.wf-notes li { display: flex; gap: 10px; align-items: flex-start; }
.wf-notes .ico { color: var(--blue-600); width: 16px; height: 16px; margin-top: 4px; }
@media (min-width: 1000px) {
  .wf-stage { container-type: inline-size; --u: calc(100cqw / 960); margin-top: 6px; aspect-ratio: var(--ar); }
  .wf-edges { display: block; position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
  .wf-edges path.e { fill: none; stroke: var(--edge); stroke-width: 1.8; }
  .wf-edges path.e.opt { stroke: var(--blue-600); stroke-dasharray: 6 5; }
  .wf-nodes { display: block; position: absolute; inset: 0; }
  .wf-node { position: absolute; left: var(--x); top: var(--y); width: var(--w); height: var(--h); margin: 0; padding: calc(var(--u) * 9) calc(var(--u) * 10); font-size: calc(var(--u) * 12.5); overflow: hidden; display: flex; flex-direction: column; justify-content: center; }
  .wf-node b { font-size: 1em; }
  .wf-node small { font-size: .86em; margin-top: calc(var(--u) * 3); line-height: 1.3; }
  .wf-node .wf-tag { font-size: .8em; margin-top: calc(var(--u) * 5); align-self: flex-start; padding: 1px calc(var(--u) * 7); }
  .wf-node::before, .wf-node::after { display: none; }
  .wf-links { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .wf-label { display: block; position: absolute; left: var(--x); top: var(--y); transform: translate(-50%, -50%); background: var(--surface); padding: 1px calc(var(--u) * 6); border-radius: 0; font-size: calc(var(--u) * 10.8); color: var(--info-text); font-weight: 600; white-space: nowrap; line-height: 1.3; }
}

/* ---------- Product tour ---------- */
.tour { background: var(--surface); border-radius: 0; overflow: hidden; box-shadow: var(--shadow-lg); border: 1px solid rgba(255,255,255,.12); }
.tour-bar { display: flex; align-items: center; gap: 12px; padding: 10px 16px; background: var(--tour-bar); color: rgba(255,255,255,.92); font-size: .82rem; }
.tour-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tour-body { display: grid; grid-template-columns: 200px minmax(0, 1fr); min-height: 600px; }
.tour-nav { background: var(--navy-900); padding: 12px 10px; display: flex; flex-direction: column; gap: 2px; align-content: start; }
.tour-nav .tab-btn { background: none; border-color: transparent; color: rgba(255,255,255,.78); padding: 10px 12px; font-size: .9rem; }
.tour-nav .tab-btn:hover { background: rgba(255,255,255,.08); color: #fff; border-color: transparent; }
.tour-nav .tab-btn[aria-selected="true"] { background: rgba(27,148,174,.32); color: #fff; }
.tour-view { padding: clamp(14px, 2.2vw, 24px); background: var(--bg-soft); min-width: 0; }
.tv-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.tv-head h3 { font-size: 1.3rem; } .tv-head p { color: var(--muted); font-size: .88rem; margin-top: 2px; }
.controls { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; margin-bottom: 14px; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 0; }
.ctl { display: flex; align-items: center; gap: 8px; font-size: .85rem; color: var(--muted); font-weight: 600; }
.ctl select { width: auto; min-height: 36px; padding: 6px 30px 6px 10px; font-size: .88rem; border-radius: 0; }
.ctl-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.fchip { min-height: 34px; padding: 5px 12px; border: 1px solid var(--line); border-radius: 0; background: var(--surface); font-size: .82rem; font-weight: 600; color: var(--muted); }
.fchip:hover { border-color: var(--blue-300); color: var(--ink); }
.fchip[aria-pressed="true"] { background: var(--navy-800); border-color: var(--navy-800); color: #fff; }
.ctl-check { display: inline-flex; align-items: center; gap: 8px; font-size: .85rem; font-weight: 600; color: var(--muted); min-height: 36px; }
.ctl-check input { width: 18px; height: 18px; accent-color: var(--blue-600); }
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.kpi, .panel { background: var(--surface); border: 1px solid var(--line); border-radius: 0; padding: 14px 16px; min-width: 0; }
.kpi small { color: var(--muted); font-size: .8rem; display: block; }
.kpi b { display: block; font-size: 1.45rem; color: var(--ink); letter-spacing: -.02em; margin: 2px 0; font-variant-numeric: tabular-nums; }
.kpi span { font-size: .78rem; color: var(--muted); }
.tv-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; margin-bottom: 14px; }
.panel h4 { font-size: .95rem; margin-bottom: 2px; letter-spacing: -.01em; }
.panel .cap { color: var(--muted); font-size: .8rem; margin-bottom: 12px; }
.panel.scroll { overflow-x: auto; }
.hb { display: grid; gap: 10px; }
.hb div { display: grid; grid-template-columns: 96px minmax(0, 1fr) 76px; gap: 10px; align-items: center; font-size: .82rem; color: var(--muted); }
.hb i { height: 10px; background: var(--blue-100); border-radius: 0; overflow: hidden; }
.hb u { display: block; height: 100%; border-radius: 0; background: linear-gradient(90deg, var(--blue-600), var(--blue-500)); }
.hb u.warn { background: #e69a1a; } .hb u.ok { background: #22c07f; }
.hb em { font-style: normal; text-align: right; color: var(--ink); font-variant-numeric: tabular-nums; }
.empty { color: var(--muted); font-size: .9rem; padding: 8px 0; }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600; padding: 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 10px 8px; border-bottom: 1px solid var(--line); font-size: .86rem; color: var(--text); white-space: nowrap; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl td:first-child { font-family: var(--mono); font-size: .8rem; color: var(--muted); }
.tbl .r { text-align: right; font-variant-numeric: tabular-nums; }
.tour-foot { margin-top: 4px; font-size: .78rem; color: var(--muted); }

/* ---------- Features ---------- */
.feat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 28px); align-items: start; }
.feat-col { border-top: 3px solid var(--navy-900); padding-top: 16px; }
.feat-col h3 { font-size: 1.2rem; margin-bottom: 4px; }
.feat-col > p { color: var(--muted); font-size: .93rem; margin-bottom: 8px; }
.feat-col li { padding: 12px 0; border-top: 1px solid var(--line); }
.feat-col li b { display: block; color: var(--ink); font-size: .98rem; }
.feat-col li span { color: var(--muted); font-size: .9rem; }
.confirm-tag { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 0; background: var(--warn-bg); color: var(--warn); font-size: .7rem; font-weight: 700; vertical-align: 2px; }
.feat-note { margin-top: 28px; padding: 14px 18px; background: var(--blue-50); border: 1px solid var(--blue-100); border-radius: 0; color: var(--info-text); font-size: .93rem; max-width: 52rem; }

/* ---------- Process / FAQ ---------- */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.steps li { position: relative; padding-top: 4px; }
.steps li:not(:last-child)::before { content: ""; position: absolute; top: 24px; left: 52px; right: -12px; height: 1px; background: var(--blue-300); }
.step-n { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 0; background: var(--navy-900); color: #fff; font-weight: 700; margin-bottom: 18px; position: relative; z-index: 1; }
.steps h3 { font-size: 1.12rem; margin-bottom: 8px; letter-spacing: -.01em; }
.steps p { color: var(--muted); font-size: .95rem; }
.split { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(28px, 6vw, 88px); align-items: start; }
.faq-item { border-top: 1px solid var(--line); }
.faq-item:last-child { border-bottom: 1px solid var(--line); }
.faq-item h3 { font-size: 1.05rem; letter-spacing: -.01em; }
.faq-item button { width: 100%; min-height: 44px; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 4px; background: none; border: 0; text-align: left; font-weight: 600; color: var(--ink); font-size: 1.05rem; }
.faq-item button:hover { color: var(--blue-700); }
.faq-ico { width: 22px; height: 22px; flex: none; position: relative; border: 1px solid var(--line); border-radius: 0; }
.faq-ico::before, .faq-ico::after { content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 1.5px; background: currentColor; transform: translate(-50%, -50%); }
.faq-ico::after { transform: translate(-50%, -50%) rotate(90deg); }
button[aria-expanded="true"] .faq-ico::after { display: none; }
.faq-a { padding: 0 40px 20px 4px; color: var(--muted); max-width: 44rem; }
.faq-a p + p { margin-top: 10px; }

/* ---------- Contact ---------- */
.contact-section { background: var(--navy-950); background-image: radial-gradient(50% 60% at 15% 20%, var(--glow2), transparent 70%); }
.contact-section h2 { color: #fff; }
.contact-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(28px, 6vw, 88px); align-items: start; }
.contact-points { margin-top: 26px; display: grid; gap: 12px; color: rgba(255,255,255,.88); }
.contact-points li { display: flex; gap: 12px; align-items: flex-start; }
.contact-points .ico { color: var(--blue-300); width: 18px; height: 18px; margin-top: 4px; }
.contact-ph { margin-top: 28px; color: rgba(255,255,255,.8); font-size: .95rem; line-height: 1.9; }
.contact-ph a { color: #fff; font-weight: 600; }
.placeholder { font-family: var(--mono); font-size: .85em; background: rgba(255,255,255,.1); border: 1px dashed rgba(255,255,255,.45); padding: 2px 8px; border-radius: 0; color: #fff; }
.form { background: var(--surface); border-radius: 0; padding: clamp(20px, 3.5vw, 38px); box-shadow: var(--shadow-lg); display: grid; gap: 18px; min-width: 0; }
.form h3 { font-size: 1.5rem; }
.form-note { font-size: .82rem; color: var(--muted); margin-top: -10px; }
.req { color: var(--err); font-weight: 700; }
.field { display: grid; gap: 6px; min-width: 0; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.field label, .fieldset legend { font-weight: 600; font-size: .9rem; color: var(--ink); }
.hint, .hint-inline { font-size: .78rem; color: var(--muted); font-weight: 400; }
input[type=text], input[type=email], input[type=tel], select, textarea { width: 100%; min-height: 44px; padding: 10px 14px; border: 1px solid var(--field-border); border-radius: 0; background: var(--surface); font-size: 1rem; transition: border-color .15s, box-shadow .15s; }
textarea { resize: vertical; min-height: 110px; }
input:hover, select:hover, textarea:hover { border-color: var(--field-hover); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue-500); box-shadow: 0 0 0 4px rgba(27,148,174,.22); }
[aria-invalid="true"] { border-color: var(--err) !important; background: var(--surface)afa; }
.err { color: var(--err); font-size: .84rem; font-weight: 500; }
.fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.fieldset legend { padding: 0; margin-bottom: 8px; }
.checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.check { display: flex; align-items: center; gap: 10px; min-height: 44px; border: 1px solid var(--line); border-radius: 0; padding: 8px 12px; cursor: pointer; font-size: .92rem; font-weight: 500; color: var(--text); transition: background-color .15s, border-color .15s; }
.check:hover { background: var(--bg-soft); }
.check input { width: 18px; height: 18px; accent-color: var(--blue-600); flex: none; }
.check:has(input:checked) { background: var(--blue-50); border-color: var(--blue-300); }
.check:has(input:focus-visible) { outline: 3px solid var(--blue-500); outline-offset: 2px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { padding: 14px 16px; border-radius: 0; font-size: .93rem; border: 1px solid; }
.form-status.error { background: var(--err-bg); border-color: var(--err-line); color: var(--err-text); }
.form-status.success { background: var(--ok-bg); border-color: var(--ok-line); color: var(--ok-text); }
.form-status strong { display: block; margin-bottom: 2px; }
.form-status ul { margin-top: 6px; padding-left: 18px; list-style: disc; }
.spinner { display: none; width: 18px; height: 18px; border-radius: 0; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; animation: spin .7s linear infinite; }
.is-loading .spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.form-fine { font-size: .8rem; color: var(--muted); text-align: center; }
.form-fine.devnote { color: var(--warn); font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-950); color: rgba(255,255,255,.78); border-top: 1px solid rgba(255,255,255,.08); padding-top: 52px; font-size: .92rem; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1.3fr; gap: 40px; padding-bottom: 36px; }
.footer-brand p { margin-top: 16px; max-width: 24rem; }
.site-footer h2 { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: #fff; margin-bottom: 14px; font-weight: 700; }
.site-footer li { margin-bottom: 8px; }
.site-footer a:not(.brand) { color: inherit; text-decoration: none; }
.site-footer a:not(.brand):hover { color: #fff; text-decoration: underline; }
.footer-base { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 18px 0; border-top: 1px solid rgba(255,255,255,.1); font-size: .82rem; }

/* ---------- Motion: restrained, transform/opacity only ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.hero-copy { animation: rise .6s ease both; }
.hero-visual { animation: rise .7s .12s ease both; }
.dash-line { stroke-dasharray: 1; animation: draw 1.4s .5s ease-out both; }
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .5s ease, transform .5s ease; }
.js .reveal.in { opacity: 1; transform: none; }
.fade-in { animation: fade .22s ease both; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .dash { grid-template-columns: 120px minmax(0, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
}
@media (max-width: 999px) {
  .menu-toggle { display: inline-flex; }
  .primary-nav { position: absolute; top: var(--header-h); left: 0; right: 0; background: var(--navy-950); flex-direction: column; align-items: stretch; gap: 12px; padding: 12px 20px 24px; border-bottom: 1px solid rgba(255,255,255,.1); opacity: 0; visibility: hidden; transition: opacity .2s, visibility .2s; }
  .primary-nav.open { opacity: 1; visibility: visible; }
  .primary-nav ul { flex-direction: column; }
  .primary-nav ul a { padding: 14px 12px; font-size: 1.05rem; }
  .hero-inner, .split, .contact-grid { grid-template-columns: minmax(0, 1fr); }
  .wf-panel .wf-stage { max-width: 680px; }
  .tour-body { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .tour-nav { flex-direction: row; overflow-x: auto; padding: 10px; gap: 6px; scrollbar-width: thin; }
  .tour-nav .tab-btn { flex: none; white-space: nowrap; }
  .feat-grid { grid-template-columns: minmax(0, 1fr); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 24px; }
  .steps li::before { display: none; }
  .sol-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tv-grid { grid-template-columns: minmax(0, 1fr); }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .cv-row { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .cv-row > .ico { transform: rotate(90deg); }
  .cv-head { display: none; }
}
@media (max-width: 640px) {
  .container { width: min(1200px, 100% - 32px); }
  .dash { grid-template-columns: minmax(0, 1fr); }
  .dash-side, .dash-plants { display: none; }
  .dash-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-row { grid-template-columns: minmax(0, 1fr); }
  .hide-sm { display: none; }
  .steps { grid-template-columns: minmax(0, 1fr); }
  .checks { grid-template-columns: minmax(0, 1fr); }
  .footer-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .hero-actions .btn { width: 100%; }
  .tour-title { display: none; }
  .tour-bar { justify-content: space-between; }
  .faq-a { padding-right: 4px; }
  .hb div { grid-template-columns: 78px minmax(0, 1fr) 64px; }
  .wf-tabs { display: grid; grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 380px) {
  .kpis { grid-template-columns: minmax(0, 1fr); }
  .brand { font-size: 1.05rem; }
}
@media (min-width: 1700px) {
  .container { width: min(1320px, 100% - 80px); }
  html { font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
  .dash-line { stroke-dasharray: none; }
}

/* Square corners everywhere; only status dots and the loading spinner stay round */
.st, .spinner, .wf-node::after { border-radius: 50%; }

/* Workflow explorer keeps its rounded corners */
.wf-tabs .tab-btn { border-radius: 10px; }
.wf-panel { border-radius: 14px; }
.wf-banner { border-radius: 10px; }
.wf-node { border-radius: 12px; }
.wf-node .wf-tag { border-radius: 99px; }
.wf-label { border-radius: 6px; }
.wf-legend i.box { border-radius: 4px; }
.wf-notes { border-radius: 0; }

/* ---------- Glossy finish (both themes): soft gradients, top-edge highlights, glass on dark bars ---------- */
.kpi, .panel, .sol, .cv, .wf-panel, .form, .controls, .dash-kpis > div, .dash-chart, .dash-plants, .dash-table, .wf-node.optional, .wf-node.support, .check {
  background-image: linear-gradient(180deg, var(--gloss-a), var(--gloss-b));
  box-shadow: inset 0 1px 0 var(--gloss-edge), 0 1px 2px rgba(6, 26, 39, .06);
}
.sol, .wf-panel, .form { box-shadow: inset 0 1px 0 var(--gloss-edge), var(--shadow); }
.form { box-shadow: inset 0 1px 0 var(--gloss-edge), var(--shadow-lg); }
.tour { background-image: linear-gradient(180deg, var(--gloss-a), var(--gloss-b)); box-shadow: inset 0 1px 0 var(--gloss-edge), var(--shadow-lg); }
.wf-node:not(.optional):not(.support), .tab-btn[aria-selected="true"], .sol-icon, .step-n {
  background-image: linear-gradient(180deg, rgba(255,255,255,.2) 0%, rgba(255,255,255,.05) 50%, rgba(255,255,255,0) 51%, rgba(0,0,0,.12) 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.3), 0 6px 14px -8px rgba(6, 26, 39, .6);
}
.btn-primary {
  background-color: var(--btn);
  background-image: linear-gradient(180deg, rgba(255,255,255,.16) 0, rgba(255,255,255,.04) 50%, rgba(255,255,255,0) 51%), linear-gradient(180deg, var(--btn-top), var(--btn-bot));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.4), inset 0 -1px 0 rgba(0,0,0,.2), 0 10px 20px -10px var(--btn-glow);
}
.btn-primary:hover { background-color: var(--btn-h); background-image: linear-gradient(180deg, rgba(255,255,255,.14) 0, rgba(255,255,255,.03) 50%, rgba(255,255,255,0) 51%), linear-gradient(180deg, var(--btn-h-top), var(--btn-h-bot)); }
.btn-ghost { background-image: linear-gradient(180deg, rgba(255,255,255,.14), rgba(255,255,255,.03)); box-shadow: inset 0 1px 0 rgba(255,255,255,.25); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.site-header { background: var(--header-bg); -webkit-backdrop-filter: blur(14px) saturate(1.4); backdrop-filter: blur(14px) saturate(1.4); box-shadow: inset 0 -1px 0 rgba(255,255,255,.08), 0 8px 24px -16px rgba(0,0,0,.6); }
.menu-toggle { background-image: linear-gradient(180deg, rgba(255,255,255,.14), rgba(255,255,255,.02)); box-shadow: inset 0 1px 0 rgba(255,255,255,.25); }
.tour-bar { background-image: linear-gradient(180deg, rgba(255,255,255,.14), rgba(255,255,255,0)); }
.tour-nav, .dash-side { background-image: linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,0) 40%); }
.dash { position: relative; box-shadow: inset 0 1px 0 rgba(255,255,255,.5), var(--shadow-lg); }
.dash::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(115deg, var(--sheen) 0%, rgba(255,255,255,0) 36%); }
.hero-bg { background:
  radial-gradient(45% 50% at 80% 25%, var(--glow), transparent 70%),
  radial-gradient(35% 40% at 10% 90%, var(--glow2), transparent 70%),
  linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 56px 56px,
  linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 56px 56px; }
.section-soft { background-image: linear-gradient(180deg, var(--surface-2), var(--bg-soft)); }
input[type=text], input[type=email], input[type=tel], select, textarea { box-shadow: inset 0 1px 2px rgba(6, 26, 39, .08); }
@media (max-width: 640px) { .site-header, .btn-ghost { -webkit-backdrop-filter: none; backdrop-filter: none; } .site-header { background: var(--navy-950); } }

/* Logo keeps its rounded tile; blue logo copy is shown in the Blue theme */
.brand-mark { border-radius: 10px; }
/* The green and blue logo copies cross-fade continuously (opacity only; static when motion is reduced) */
.brand-mark img { grid-area: 1 / 1; }
.logo-default { animation: logoGreen 8s ease-in-out infinite; }
.logo-blue { opacity: 0; animation: logoBlue 8s ease-in-out infinite; }
@keyframes logoGreen { 0%, 35% { opacity: 1; } 50%, 85% { opacity: 0; } 100% { opacity: 1; } }
@keyframes logoBlue { 0%, 35% { opacity: 0; } 50%, 85% { opacity: 1; } 100% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .logo-default { opacity: 1; } .logo-blue { opacity: 0; } }

/* Site photos (Solutions) */
.site-photos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(12px, 2vw, 24px); margin-top: clamp(28px, 4vw, 44px); }
.site-photos figure { margin: 0; }
.site-photos img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; background: var(--bg-soft); }
.site-photos figcaption { padding-top: 10px; font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
@media (max-width: 720px) { .site-photos { grid-template-columns: minmax(0, 1fr); } }

/* Blue theme: near-black chrome (site header, tour bar and sidebar, hero dashboard sidebar) with blue highlights */
:root[data-theme="blue"] {
  --header-bg: rgba(8, 12, 22, .9);
  --tour-bar: #080c16;
  --chrome: #0a1120;
}
:root[data-theme="blue"] .tour-nav, :root[data-theme="blue"] .dash-side { background-color: var(--chrome); }
:root[data-theme="blue"] .tour-nav .tab-btn[aria-selected="true"] { background: rgba(47, 123, 255, .38); }
:root[data-theme="blue"] .dash-side li.on { background: rgba(47, 123, 255, .38); }
:root[data-theme="blue"] .site-header { border-bottom-color: rgba(47, 123, 255, .35); }
:root[data-theme="blue"] .tour { border-color: rgba(47, 123, 255, .35); }

/* Near-black chrome applied consistently: header, mobile menu, tour bar and sidebar, dashboard sidebar, footer.
   Light and Dark use a blue-black; Blue uses --chrome from its own block above. */
:root { --chrome: #08131b; }
:root[data-theme="dark"] { --chrome: #070f16; }
:root:not([data-theme="blue"]) { --header-bg: rgba(8, 19, 27, .88); --tour-bar: #0b1822; }
:root[data-theme="dark"] { --header-bg: rgba(7, 15, 22, .9); --tour-bar: #0a141c; }
.site-footer { background-color: var(--chrome); }
.primary-nav { background-color: var(--chrome); }
.tour-nav, .dash-side { background-color: var(--chrome); }
@media (max-width: 640px) { .site-header { background: var(--chrome); } }
:root:not([data-theme="blue"]) .tour { border-color: rgba(255,255,255,.14); }
.panel h4 + .tbl { margin-top: 10px; }

/* Logo button + password-protected theme dialog */
.sw { display: inline-block; width: 16px; height: 16px; border: 1px solid rgba(128,128,128,.6); flex: none; }
#theme-dialog { width: min(420px, calc(100% - 32px)); padding: clamp(20px, 4vw, 28px); border: 1px solid var(--line); background: var(--surface); color: var(--text); box-shadow: var(--shadow-lg); }
#theme-dialog::backdrop { background: rgba(4, 10, 20, .65); }
#theme-dialog h2 { font-size: 1.35rem; margin-bottom: 8px; }
#theme-dialog p { color: var(--muted); font-size: .95rem; }
#theme-dialog form { display: grid; gap: 16px; margin-top: 16px; }
.td-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
#td-form .td-actions { margin-top: 0; }
.btn-outline { background: transparent; color: var(--ink); border-color: var(--field-border); }
.btn-outline:hover { background: var(--blue-50); }
.td-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 16px; }
.td-options button { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 8px 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 600; text-align: left; }
.td-options button:hover { border-color: var(--blue-300); background: var(--blue-50); }
.td-options button[aria-pressed="true"] { border-color: var(--blue-600); box-shadow: inset 0 0 0 1px var(--blue-600); }
.td-options button[aria-pressed="true"]::after { content: "\2713"; margin-left: auto; color: var(--blue-600); }

/* Invisible strip at the far left of the header: click it to open the password-protected theme dialog */
.theme-hotspot { position: absolute; z-index: 2; left: 0; top: 0; bottom: 0; width: calc((100% - min(1200px, 100% - 40px)) / 2); min-width: 16px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.theme-hotspot:focus-visible { outline: 3px solid var(--blue-500); outline-offset: -3px; background: rgba(255,255,255,.08); }
@media (max-width: 640px) { .theme-hotspot { width: 16px; } }
@media (min-width: 1700px) { .theme-hotspot { width: calc((100% - min(1320px, 100% - 80px)) / 2); } }
