:root {
  color-scheme: light;
  --bg: #ffffff;
  --surface: #f7faf9;
  --surface-strong: #eef7f6;
  --text: #152022;
  --muted: #5b676b;
  --line: #dbe6e5;
  --line-strong: #b9ccca;
  --teal: #d71920;
  --teal-2: #ef3e42;
  --amber: #d88412;
  --green: #2f8f4e;
  --coral: #aa1f2a;
  --ink: #0f1a1d;
  --shadow: 0 18px 46px rgba(12, 38, 39, 0.11);
  --radius: 8px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #101718;
  --surface: #162224;
  --surface-strong: #1c3032;
  --text: #eaf2f1;
  --muted: #a8b8b6;
  --line: #2e4547;
  --line-strong: #456467;
  --teal: #ff6b6f;
  --teal-2: #ff8f7e;
  --amber: #ffc066;
  --green: #b3d385;
  --coral: #ff8f87;
  --ink: #071012;
  --shadow: 0 18px 46px rgba(0, 0, 0, 0.25);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  --sidebar-width: 320px;
  --topbar-offset: 67px;
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.55;
}

body.nav-collapsed {
  --sidebar-width: 0px;
}

body.searching .guide-section[hidden] {
  display: none;
}

a {
  color: var(--teal);
}

img {
  max-width: 100%;
  display: block;
}

code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.92em;
  color: var(--teal);
}

svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.skip-link {
  position: absolute;
  top: -80px;
  left: 16px;
  z-index: 20;
  padding: 10px 14px;
  color: #fff;
  background: var(--teal);
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 16px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(240px, 620px) auto;
  gap: 18px;
  align-items: center;
  padding: 12px 24px;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

html[data-theme="dark"] .topbar {
  background: rgba(16, 23, 24, 0.92);
}

.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  min-width: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  color: #fff;
  font-weight: 800;
  background: var(--teal);
  border-radius: 8px;
}

.brand-title,
.brand-subtitle {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-title {
  font-weight: 800;
}

.brand-subtitle {
  color: var(--muted);
  font-size: 0.78rem;
}

.search-shell {
  position: relative;
  min-width: 0;
}

.search {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-width: 0;
  padding: 10px 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.search input {
  width: 100%;
  min-width: 0;
  color: var(--text);
  font: inherit;
  font-size: 0.95rem;
  background: transparent;
  border: 0;
  outline: 0;
}

.search-results {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  z-index: 35;
  max-height: min(460px, calc(100vh - var(--topbar-offset) - 24px));
  padding: 10px;
  overflow: auto;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.search-results[hidden] {
  display: none;
}

.search-summary {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.search-result-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.search-result {
  display: grid;
  gap: 3px;
  width: 100%;
  padding: 10px;
  color: var(--text);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.search-result:hover,
.search-result:focus-visible {
  border-color: var(--teal);
  outline: 0;
}

.search-result strong {
  font-size: 0.94rem;
}

.search-result span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.search-result p,
.search-no-results p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.search-no-results {
  display: grid;
  gap: 10px;
  padding: 12px;
  color: var(--muted);
  background: var(--surface);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
}

.search-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.search-suggestions button {
  min-height: 32px;
  padding: 6px 10px;
  color: var(--teal);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 850;
  cursor: pointer;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.search-suggestions button:hover,
.search-suggestions button:focus-visible {
  color: #fff;
  background: var(--teal);
  border-color: var(--teal);
  outline: 0;
}

.toolbar {
  display: flex;
  gap: 8px;
}

.tool-button,
.to-top {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: var(--text);
  cursor: pointer;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.tool-button:hover,
.to-top:hover {
  color: var(--teal);
  border-color: var(--line-strong);
}

.nav-toggle[aria-expanded="false"] {
  color: #fff;
  background: var(--teal);
  border-color: var(--teal);
}

.layout {
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  align-items: start;
  min-width: 0;
  transition: grid-template-columns 180ms ease;
}

.sidebar {
  position: sticky;
  top: var(--topbar-offset);
  width: var(--sidebar-width);
  height: calc(100vh - var(--topbar-offset));
  min-width: 0;
  padding: 24px 14px;
  overflow: auto;
  background: var(--surface);
  border-right: 1px solid var(--line);
  transition: width 180ms ease, padding 180ms ease, opacity 140ms ease, visibility 140ms ease;
}

body.nav-collapsed .sidebar {
  width: 0;
  padding-right: 0;
  padding-left: 0;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  border-right: 0;
}

.nav-panel-header {
  display: grid;
  gap: 2px;
  margin-bottom: 14px;
  padding: 0 12px;
}

.nav-panel-header span {
  font-weight: 900;
}

.nav-panel-header small {
  color: var(--muted);
  font-size: 0.78rem;
}

.nav-sort {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 0 0 18px;
  padding: 0 12px;
}

.nav-sort button {
  min-height: 34px;
  color: var(--muted);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 850;
  cursor: pointer;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.nav-sort button.active {
  color: #fff;
  background: var(--teal);
  border-color: var(--teal);
}

.sidebar nav {
  display: grid;
  gap: 16px;
}

.nav-group {
  display: grid;
  gap: 4px;
}

.nav-group h2 {
  margin: 0;
  padding: 0 12px 4px;
  color: var(--teal);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sidebar a {
  display: block;
  padding: 9px 12px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.25;
  text-decoration: none;
  white-space: normal;
  overflow-wrap: anywhere;
  border-radius: var(--radius);
}

.sidebar a:hover,
.sidebar a.active {
  color: var(--teal);
  background: var(--surface-strong);
}

.content {
  width: min(1120px, 100%);
  min-width: 0;
  margin: 0 auto;
  padding: 44px 28px 80px;
}

.guide-section {
  padding: 42px 0;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: calc(var(--topbar-offset) + 28px);
}

.guide-section:first-child {
  padding-top: 0;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  gap: 34px;
  align-items: center;
}

.hero h1 {
  margin: 0;
  max-width: 720px;
  font-size: clamp(2.6rem, 7vw, 5.8rem);
  line-height: 0.95;
  letter-spacing: 0;
}

.lead {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.18rem;
}

.section-label {
  margin: 0 0 10px;
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0;
}

.primary-action,
.secondary-action {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  min-width: 0;
  padding: 10px 16px;
  font-weight: 800;
  text-decoration: none;
  overflow-wrap: anywhere;
  border-radius: var(--radius);
}

.primary-action {
  color: #fff;
  background: var(--teal);
}

.secondary-action {
  color: var(--teal);
  background: var(--surface);
  border: 1px solid var(--line);
}

.notice {
  padding: 14px 16px;
  color: var(--text);
  background: var(--surface-strong);
  border: 1px solid var(--line-strong);
  border-left: 4px solid var(--teal);
  border-radius: var(--radius);
}

.notice.warning {
  border-left-color: var(--coral);
}

.hero-media {
  margin: 0;
}

.hero-media img {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero-media figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.88rem;
}

.workflow-explorer {
  display: grid;
  gap: 18px;
  margin: 0 0 28px;
  padding: 22px;
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.workflow-explorer h3,
.workflow-explorer h4 {
  margin: 0;
}

.workflow-explorer > div:first-child p {
  margin: 6px 0 0;
  color: var(--muted);
}

.workflow-map {
  position: relative;
  display: grid;
  grid-template-columns: repeat(7, minmax(94px, 1fr));
  gap: 10px;
}

.workflow-map::before {
  content: "";
  position: absolute;
  top: 34px;
  right: 6%;
  left: 6%;
  height: 3px;
  background: linear-gradient(90deg, var(--teal), var(--amber), var(--coral));
  opacity: 0.35;
}

.hotspot {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  place-items: center;
  min-height: 90px;
  padding: 12px;
  color: var(--text);
  font: inherit;
  font-weight: 850;
  cursor: pointer;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.hotspot span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  color: #fff;
  background: var(--teal);
  border-radius: 999px;
}

.hotspot.active,
.hotspot:hover {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(0, 109, 112, 0.14);
}

.workflow-detail {
  padding: 18px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-left: 4px solid var(--teal);
  border-radius: var(--radius);
}

.workflow-detail span {
  display: block;
  margin-bottom: 6px;
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.workflow-detail p {
  margin: 8px 0 0;
  color: var(--muted);
}

.interactive-panel {
  display: grid;
  gap: 16px;
  margin: 0 0 28px;
  padding: 20px;
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.interactive-copy h3 {
  margin: 0;
}

.interactive-copy p:last-child {
  margin: 6px 0 0;
  color: var(--muted);
}

.mini-label {
  margin: 0 0 4px !important;
  color: var(--teal) !important;
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tab-buttons,
.status-choice-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tab-buttons button,
.status-choice {
  min-height: 42px;
  padding: 9px 13px;
  color: var(--text);
  font: inherit;
  font-weight: 850;
  cursor: pointer;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.tab-buttons button.active,
.tab-buttons button:hover,
.status-choice.active,
.status-choice:hover {
  color: #fff;
  background: var(--teal);
  border-color: var(--teal);
}

.role-panel,
.image-hotspot-detail,
.status-detail,
.report-tab-panel {
  padding: 18px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-left: 4px solid var(--teal);
  border-radius: var(--radius);
}

.role-panel span,
.image-hotspot-detail span,
.status-detail span,
.report-tab-panel span {
  display: block;
  margin-bottom: 6px;
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.role-panel h4,
.image-hotspot-detail h4,
.status-detail h4,
.report-tab-panel h4 {
  margin: 0 0 8px;
}

.role-panel p,
.image-hotspot-detail p,
.status-detail p,
.report-tab-panel p,
.video-panel p,
.video-panel li {
  color: var(--muted);
}

.role-panel ul,
.report-tab-panel ul,
.video-panel ul {
  display: grid;
  gap: 7px;
  margin-bottom: 0;
  padding-left: 20px;
}

.automation-flow,
.inspection-flow-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.automation-flow article {
  padding: 16px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.automation-flow span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 10px;
  color: #fff;
  font-weight: 900;
  background: var(--teal);
  border-radius: 999px;
}

.automation-flow h4,
.automation-flow p {
  margin: 0;
}

.automation-flow h4 {
  margin-bottom: 8px;
}

.automation-flow p {
  color: var(--muted);
  font-size: 0.92rem;
}

.hotspot-image {
  position: relative;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.hotspot-image img {
  width: 100%;
  aspect-ratio: 16 / 5;
  object-fit: cover;
  object-position: top center;
}

.pin {
  position: absolute;
  left: var(--x);
  top: var(--y);
  min-width: 58px;
  min-height: 36px;
  padding: 7px 10px;
  color: var(--text);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 900;
  cursor: pointer;
  background: #fff;
  border: 2px solid var(--amber);
  border-radius: 999px;
  box-shadow: 0 10px 22px rgba(15, 26, 29, 0.18);
  transform: translate(-50%, -50%);
}

.pin.active,
.pin:hover {
  color: #fff;
  background: var(--teal);
  border-color: var(--teal);
}

.video-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(240px, 0.7fr);
  gap: 16px;
  align-items: start;
  padding: 16px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.video-panel.library-panel {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.video-panel[hidden] {
  display: none;
}

.training-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #000;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.video-card {
  display: grid;
  gap: 10px;
  align-content: start;
}

.video-card h4,
.video-card p {
  margin: 0;
}

.video-card img {
  width: 100%;
  height: auto;
  max-height: 340px;
  object-fit: contain;
  object-position: top center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.status-choice-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.section-art {
  margin: 0 0 24px;
}

.section-art img {
  width: 100%;
  height: auto;
  max-height: min(720px, 76vh);
  object-fit: contain;
  object-position: center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.section-art.screenshot-figure img {
  aspect-ratio: auto;
  object-fit: contain;
  object-position: top center;
  background: transparent;
}

.section-art figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.9rem;
}

.screenshot-slots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 24px;
}

.screenshot-slots article,
.visual-note {
  padding: 16px;
  background: var(--surface);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
}

.screenshot-slots article.screenshot-card {
  padding: 12px;
}

.screenshot-card img {
  width: 100%;
  height: auto;
  max-height: 340px;
  object-fit: contain;
  object-position: top center;
  margin-bottom: 12px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) - 2px);
}

.screenshot-card img.tall-shot {
  aspect-ratio: auto;
}

.screenshot-card img.wide-shot {
  aspect-ratio: auto;
}

.screenshot-card span {
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.clickable-media {
  cursor: zoom-in;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.clickable-media:hover,
.clickable-media:focus-visible {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(215, 25, 32, 0.14), var(--shadow);
  outline: 0;
}

.click-tile {
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.click-tile:hover,
.click-tile:focus-visible {
  border-color: var(--teal);
  box-shadow: 0 12px 28px rgba(12, 38, 39, 0.12);
  outline: 0;
  transform: translateY(-1px);
}

body.modal-open {
  overflow: hidden;
}

.lightbox,
.tile-detail-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(9, 14, 16, 0.76);
  backdrop-filter: blur(8px);
}

.lightbox[hidden],
.tile-detail-modal[hidden] {
  display: none;
}

.lightbox {
  cursor: zoom-out;
}

.lightbox-figure {
  display: grid;
  gap: 12px;
  width: min(1180px, 96vw);
  max-height: 92vh;
  margin: 0;
  cursor: default;
}

.lightbox-figure img {
  width: auto;
  max-width: 100%;
  max-height: 82vh;
  height: auto;
  margin: 0 auto;
  object-fit: contain;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: var(--radius);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

.lightbox-figure figcaption {
  color: #fff;
  font-size: 0.95rem;
  font-weight: 750;
  text-align: center;
}

.lightbox-close,
.tile-detail-close {
  position: absolute;
  top: 18px;
  right: 18px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  color: var(--text);
  cursor: pointer;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow);
}

.lightbox-close:hover,
.lightbox-close:focus-visible,
.tile-detail-close:hover,
.tile-detail-close:focus-visible {
  color: #fff;
  background: var(--teal);
  border-color: var(--teal);
  outline: 0;
}

.tile-detail-card {
  position: relative;
  display: grid;
  gap: 12px;
  width: min(720px, 94vw);
  max-height: 86vh;
  padding: 24px;
  overflow: auto;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
}

.tile-detail-card h3,
.tile-detail-card p {
  margin: 0;
}

.tile-detail-card p {
  color: var(--muted);
}

.tile-detail-card ul {
  display: grid;
  gap: 8px;
  margin: 2px 0 0;
  padding-left: 20px;
}

.tile-detail-card .mini-label {
  padding-right: 46px;
}

.mock-screen {
  display: grid;
  gap: 7px;
  margin-bottom: 14px;
  padding: 10px;
  aspect-ratio: 16 / 10;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 7px;
  box-shadow: inset 0 0 0 1px rgba(0, 109, 112, 0.04);
}

.mock-screen div {
  height: 18px;
  background: linear-gradient(90deg, var(--teal), var(--teal-2));
  border-radius: 5px;
}

.mock-screen b,
.mock-screen i {
  display: block;
  height: 11px;
  background: var(--line);
  border-radius: 999px;
}

.mock-screen b {
  width: 76%;
}

.mock-screen i:nth-of-type(1) {
  width: 92%;
}

.mock-screen i:nth-of-type(2) {
  width: 66%;
}

.mock-screen i:nth-of-type(3) {
  width: 82%;
}

.mock-screen.app-shot {
  align-content: start;
  gap: 8px;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(0, 109, 112, 0.08), transparent 46%),
    var(--bg);
}

.mock-screen.app-shot div {
  height: auto;
  background: transparent;
  border-radius: 0;
}

.shot-window-bar {
  display: flex;
  gap: 5px;
  padding-bottom: 3px;
  border-bottom: 1px solid var(--line);
}

.shot-window-bar span {
  width: 7px;
  height: 7px;
  background: var(--line-strong);
  border-radius: 999px;
}

.shot-window-bar span:first-child {
  background: var(--coral);
}

.shot-window-bar span:nth-child(2) {
  background: var(--amber);
}

.shot-window-bar span:nth-child(3) {
  background: var(--green);
}

.expense-summary,
.supplier-profile {
  display: flex;
  gap: 7px;
  align-items: center;
  min-width: 0;
}

.shot-title {
  min-width: 0;
  overflow: hidden;
  color: var(--text);
  font-size: 0.75rem;
  font-weight: 900;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shot-badge {
  flex: 0 0 auto;
  padding: 3px 6px;
  color: #fff;
  font-size: 0.62rem;
  font-weight: 900;
  line-height: 1;
  background: var(--teal);
  border-radius: 999px;
}

.shot-badge.warning {
  color: #603d00;
  background: #ffe7a3;
}

.expense-line,
.support-route {
  display: grid;
  align-items: center;
  min-width: 0;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 6px;
}

.expense-line {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  padding: 7px 8px;
  font-size: 0.72rem;
}

.expense-line span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.expense-line span:last-child {
  font-weight: 900;
}

.receipt-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.receipt-strip span {
  height: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.6), transparent),
    var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: 5px;
}

.supplier-profile {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
}

.supplier-avatar {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 900;
  background: var(--teal);
  border-radius: 999px;
}

.supplier-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.supplier-fields span {
  min-height: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 5px;
}

.approval-dots {
  position: relative;
  display: flex;
  justify-content: space-between;
  padding: 0 5px;
}

.approval-dots::before {
  position: absolute;
  top: 50%;
  right: 12px;
  left: 12px;
  height: 2px;
  content: "";
  background: var(--line);
}

.approval-dots span {
  position: relative;
  z-index: 1;
  width: 18px;
  height: 18px;
  background: var(--bg);
  border: 5px solid var(--teal);
  border-radius: 999px;
}

.support-shot {
  gap: 7px;
}

.support-route {
  grid-template-columns: minmax(72px, 0.75fr) minmax(0, 1fr);
  gap: 8px;
  padding: 7px 8px;
  border-left: 4px solid var(--line-strong);
}

.support-route.active {
  background: var(--surface-strong);
  border-left-color: var(--teal);
}

.support-route span {
  min-width: 0;
  overflow: hidden;
  font-size: 0.68rem;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-route span:first-child {
  font-weight: 900;
}

.support-route span:last-child {
  color: var(--muted);
}

.screenshot-slots article > span {
  display: block;
  margin-bottom: 8px;
  color: var(--teal);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.screenshot-slots article > strong {
  display: block;
  margin-bottom: 6px;
}

.screenshot-slots p,
.visual-note {
  color: var(--muted);
  font-size: 0.92rem;
}

.screenshot-slots p {
  margin: 0;
}

.visual-note {
  margin-bottom: 24px;
  border-style: solid;
  border-left: 4px solid var(--coral);
}

.visual-note strong {
  color: var(--text);
}

.section-heading {
  max-width: 820px;
  margin-bottom: 24px;
}

.section-heading h2 {
  margin: 0 0 12px;
  font-size: clamp(1.8rem, 3vw, 3rem);
  line-height: 1.08;
  letter-spacing: 0;
}

.section-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

h3 {
  margin: 28px 0 12px;
  font-size: 1.26rem;
  line-height: 1.2;
}

h4 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.quick-grid p,
.callout p,
.decision p,
.approval-actions p,
.expense-grid p,
.principles p,
.glossary p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.quick-grid,
.callout-grid,
.expense-grid,
.principles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.quick-grid article,
.callout,
.decision-grid article,
.approval-actions article,
.expense-grid article,
.principles article,
.glossary article {
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.quick-grid h3,
.callout h3,
.expense-grid h3,
.principles h3,
.glossary h3 {
  margin-top: 0;
}

.checklist,
.plain-list {
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.checklist label {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.checklist input {
  width: 18px;
  height: 18px;
  margin: 3px 0 0;
  accent-color: var(--teal);
}

.two-column,
.approval-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
  background: var(--bg);
}

th,
td {
  padding: 13px 14px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}

th {
  color: var(--text);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--surface);
}

tr:last-child td {
  border-bottom: 0;
}

details {
  margin: 12px 0;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

summary {
  min-height: 50px;
  padding: 14px 18px;
  font-weight: 850;
  cursor: pointer;
}

details > p,
details > .steps,
details > .plain-list {
  padding: 0 18px 18px;
}

.steps {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 22px;
}

.decision {
  padding: 22px;
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.decision h3 {
  margin-top: 0;
}

.decision-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.best-for {
  margin-top: 12px !important;
  color: var(--teal) !important;
  font-weight: 700;
}

.status-grid,
.match-grid,
.glossary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.status-grid article,
.match-grid article {
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.status-visual {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.mock-status-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 10px;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 900;
  border-radius: 999px;
}

.status-visual p {
  margin: 0;
  color: var(--muted);
}

.status-grid article {
  position: relative;
  padding-left: 22px;
}

.status-grid article::before {
  content: "";
  position: absolute;
  top: 18px;
  bottom: 18px;
  left: 0;
  width: 6px;
  border-radius: 0 999px 999px 0;
  background: var(--status-color, var(--line-strong));
}

[data-status="draft"] { --status-color: #2f8f4e; }
[data-status="pending"] { --status-color: #d88700; }
[data-status="action"] { --status-color: #d71920; }
[data-status="buyer"] { --status-color: #6b6ccf; }
[data-status="approved"] { --status-color: #245c7a; }
[data-status="ordered"] { --status-color: #2d75b9; }
[data-status="partial"] { --status-color: #8dbb56; }
[data-status="received"] { --status-color: #4f7f2a; }
[data-status="invoiced"] { --status-color: #4866a8; }
[data-status="withdrawn"] { --status-color: #a66363; }
[data-status="rejected"] { --status-color: #d95b43; }
[data-status="closed"] { --status-color: #354044; }

.status-draft { background: #7b8589; }
.status-pending { background: #d88700; }
.status-buyer { background: #6b6ccf; }
.status-approved { background: #006d70; }
.status-ordered { background: #2d75b9; }
.status-received { background: #4f7f2a; }
.status-invoiced { background: #4866a8; }
.status-closed { background: #354044; }

.status-grid strong,
.status-grid span,
.match-grid strong {
  display: block;
}

.status-grid span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.9rem;
}

.approval-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.match-card {
  padding: 22px;
  background: linear-gradient(135deg, var(--surface-strong), var(--surface));
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.match-card h3 {
  margin-top: 0;
}

.match-infographic {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 18px 0 28px;
}

.match-infographic article {
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.match-infographic h3 {
  margin-top: 0;
}

.match-path {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 0;
}

.match-path span {
  display: grid;
  place-items: center;
  min-width: 88px;
  min-height: 58px;
  padding: 10px;
  color: #fff;
  font-weight: 900;
  background: var(--teal);
  border-radius: var(--radius);
}

.match-path b {
  width: 34px;
  height: 3px;
  background: var(--amber);
  border-radius: 999px;
}

.three-way span:nth-of-type(2) {
  background: var(--green);
}

.three-way span:nth-of-type(3) {
  background: #4866a8;
}

.match-infographic p,
.match-infographic li {
  color: var(--muted);
}

.match-infographic ul {
  display: grid;
  gap: 6px;
  padding-left: 20px;
  margin-bottom: 0;
}

.report-capabilities,
.report-grid,
.supplier-process {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin: 0 0 24px;
}

.report-capabilities article,
.report-grid article,
.supplier-process article {
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.report-capabilities h3,
.supplier-process h3 {
  margin-top: 0;
}

.report-capabilities p,
.report-grid span,
.supplier-process p {
  color: var(--muted);
}

.report-grid strong,
.report-grid span {
  display: block;
}

.report-grid span {
  margin-top: 6px;
}

.supplier-process {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.supplier-process article span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 12px;
  color: #fff;
  font-weight: 900;
  background: var(--teal);
  border-radius: 999px;
}

.source-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.source-list a {
  padding: 12px 14px;
  overflow-wrap: anywhere;
  text-decoration: none;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.source-list a:hover {
  border-color: var(--line-strong);
}

.to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 160ms ease, visibility 160ms ease;
}

.to-top.visible {
  opacity: 1;
  visibility: visible;
}

.footer {
  padding: 28px;
  color: var(--muted);
  text-align: center;
  background: var(--surface);
  border-top: 1px solid var(--line);
}

.footer p {
  margin: 0;
}

.search-empty {
  padding: 26px;
  color: var(--muted);
  text-align: center;
  background: var(--surface);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
}

mark {
  color: var(--ink);
  background: #ffe08a;
  border-radius: 3px;
}

@media (max-width: 1180px) {
  body {
    --topbar-offset: 194px;
  }

  .topbar {
    grid-template-columns: 1fr;
  }

  .content {
    width: min(100%, 1040px);
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .decision-grid,
  .status-grid,
  .match-grid,
  .screenshot-slots,
  .workflow-map,
  .automation-flow,
  .inspection-flow-grid,
  .status-choice-grid,
  .report-capabilities,
  .report-grid,
  .supplier-process {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .video-panel {
    grid-template-columns: 1fr;
  }

  .video-panel.library-panel {
    grid-template-columns: 1fr;
  }

  .match-infographic {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: fixed;
    top: var(--topbar-offset);
    bottom: 0;
    left: 0;
    z-index: 12;
    width: min(320px, 86vw);
    max-width: 100vw;
    height: calc(100vh - var(--topbar-offset));
    padding: 14px;
    overflow: auto;
    border-right: 1px solid var(--line);
    border-bottom: 0;
    box-shadow: var(--shadow);
    transform: translateX(0);
    transition: transform 180ms ease, opacity 140ms ease, visibility 140ms ease;
  }

  body.nav-collapsed .sidebar {
    width: min(320px, 86vw);
    padding: 14px;
    border-right: 1px solid var(--line);
    transform: translateX(-100%);
    opacity: 0;
    visibility: hidden;
  }

  .sidebar nav {
    display: grid;
    gap: 16px;
    max-width: 100%;
    min-width: 0;
    padding-bottom: 4px;
  }

  .sidebar a {
    white-space: normal;
  }
}

@media (max-width: 760px) {
  .topbar {
    padding: 10px 14px;
  }

  .content {
    padding: 28px 16px 70px;
  }

  .guide-section {
    padding: 34px 0;
  }

  .hero h1 {
    font-size: 3rem;
  }

  .quick-grid,
  .callout-grid,
  .two-column,
  .approval-panel,
  .decision-grid,
  .status-grid,
  .match-grid,
  .expense-grid,
  .principles,
  .glossary,
  .source-list,
  .screenshot-slots,
  .workflow-map,
  .automation-flow,
  .inspection-flow-grid,
  .status-choice-grid,
  .report-capabilities,
  .report-grid,
  .supplier-process {
    grid-template-columns: 1fr;
  }

  .hotspot-image img {
    aspect-ratio: 16 / 8;
  }

  .pin {
    min-width: 42px;
    min-height: 32px;
    padding: 6px 8px;
    font-size: 0.68rem;
  }

  .workflow-map::before {
    display: none;
  }

  .match-path {
    align-items: stretch;
    flex-direction: column;
  }

  .match-path b {
    width: 3px;
    height: 24px;
    margin-left: 42px;
  }

  .approval-actions {
    grid-template-columns: 1fr;
  }

  .hero-actions {
    flex-direction: column;
  }

  .primary-action,
  .secondary-action {
    justify-content: center;
    width: 100%;
    white-space: normal;
    text-align: center;
  }
}

@media print {
  .topbar,
  .sidebar,
  .to-top,
  .footer,
  .hero-actions {
    display: none !important;
  }

  body {
    color: #000;
    background: #fff;
  }

  .layout {
    display: block;
  }

  .content {
    width: 100%;
    padding: 0;
  }

  .guide-section {
    break-inside: avoid;
    border-bottom: 1px solid #ddd;
  }

  details {
    break-inside: avoid;
  }

  details:not([open]) > *:not(summary) {
    display: block;
  }

  a {
    color: #000;
  }
}
