/* Neutral, conventional EC demo UI. */
:root {
  color-scheme: light;
  --page: #f6f7f9;
  --surface: #ffffff;
  --surface-muted: #f8fafc;
  --text: #1f2937;
  --text-muted: #667085;
  --line: #d9dee7;
  --line-strong: #b8c0cc;
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --blue-soft: #eff6ff;
  --green: #067647;
  --green-soft: #ecfdf3;
  --amber: #b54708;
  --amber-soft: #fffaeb;
  --gray-soft: #f2f4f7;
  --shadow: 0 4px 16px rgba(15, 23, 42, .08);
  --radius: 8px;
  --sans: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", Meiryo, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { max-width: 100%; scroll-behavior: smooth; }
body {
  min-width: 320px;
  max-width: 100%;
  margin: 0;
  background: var(--page);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
}
a { color: inherit; text-underline-offset: .16em; }
button, input, select { font: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { color: var(--text); line-height: 1.35; }

:focus-visible { outline: 3px solid rgba(37, 99, 235, .45); outline-offset: 2px; }
.skip-link {
  position: fixed;
  z-index: 100;
  top: .75rem;
  left: .75rem;
  transform: translateY(-180%);
  padding: .5rem .75rem;
  border-radius: 6px;
  background: var(--text);
  color: #fff;
  font-weight: 700;
}
.skip-link:focus-visible { transform: translateY(0); }

/* Shared header and footer */
.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .97);
}
.header-inner,
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
}
.header-inner { min-height: 64px; gap: 1rem; }
.site-name,
.sidebar-title {
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
}
.nav { display: flex; align-items: center; gap: 1.25rem; font-size: .9rem; font-weight: 600; }
.nav a { text-decoration: none; }
.nav a:hover,
.text-link:hover { color: var(--blue); }
.nav-cta {
  padding: .45rem .75rem;
  border-radius: 6px;
  background: var(--blue);
  color: #fff !important;
}
.nav-cta:hover { background: var(--blue-dark); }
.footer {
  border-top: 1px solid var(--line);
  background: var(--surface);
  color: var(--text-muted);
  font-size: .84rem;
}
.footer-inner { min-height: 76px; gap: 1rem; }

/* Landing page */
.landing-page { background: var(--surface); }
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, .9fr);
  align-items: center;
  gap: clamp(2.5rem, 6vw, 5rem);
  width: min(1120px, calc(100% - 2rem));
  min-height: 520px;
  margin: 0 auto;
  padding: 5rem 0;
}
.kicker,
.breadcrumb,
.error-code {
  margin-bottom: .5rem;
  color: var(--text-muted);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .03em;
}
.hero h1 {
  max-width: 15ch;
  margin-bottom: 1.25rem;
  font-size: clamp(2.25rem, 4.2vw, 3.75rem);
  letter-spacing: -.035em;
}
.hero-copy > p:not(.kicker) { max-width: 42rem; color: var(--text-muted); font-size: 1.05rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.75rem; }
.primary-button,
.secondary-button,
.primary-action,
.presentation-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: .55rem .9rem;
  border: 1px solid transparent;
  border-radius: 6px;
  font-size: .88rem;
  font-weight: 700;
  text-decoration: none;
}
.primary-button,
.primary-action { border-color: var(--blue); background: var(--blue); color: #fff; }
.primary-button:hover,
.primary-action:hover { border-color: var(--blue-dark); background: var(--blue-dark); color: #fff; }
.secondary-button { border-color: var(--line-strong); background: #fff; color: var(--text); }
.secondary-button:hover { border-color: var(--blue); color: var(--blue); }

.hero-preview {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--shadow);
}
.preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.1rem;
  border-bottom: 1px solid var(--line);
}
.preview-header span { color: var(--text-muted); font-size: .82rem; }
.preview-products { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; padding: 1rem; }
.preview-products article { min-width: 0; }
.preview-products article > div { display: grid; gap: .1rem; padding: .65rem 0 .35rem; }
.preview-products strong { font-size: .88rem; }
.preview-products small { color: var(--text-muted); }
.preview-products article > span:last-child { font-size: .9rem; font-weight: 700; }
.image-placeholder,
.product-visual,
.product-detail-visual {
  display: grid;
  place-items: center;
  min-height: 130px;
  border: 1px solid #e1e5eb;
  border-radius: 6px;
  background: var(--gray-soft);
  color: #7a8493;
  font-size: .78rem;
  font-weight: 600;
}

.section { padding: 4.5rem 1rem; }
.section-muted { background: var(--page); }
.section-inner { width: min(1120px, 100%); margin: 0 auto; }
.section-heading { margin-bottom: 1.75rem; }
.section-heading h2,
.demo-intro h2 { margin-bottom: .5rem; font-size: clamp(1.6rem, 2.6vw, 2.25rem); }
.grid,
.scenario-grid,
.metric-grid { display: grid; gap: 1rem; }
.three-up,
.product-grid,
.metric-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.two-up { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card {
  min-width: 0;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.card h3 { margin-bottom: .45rem; font-size: 1.05rem; }
.card p { color: var(--text-muted); font-size: .92rem; }
.card p:last-child { margin-bottom: 0; }
.demo-intro { display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.demo-intro p { margin-bottom: 0; color: var(--text-muted); }

/* Demo index */
.demo-home { width: min(1000px, calc(100% - 2rem)); min-height: calc(100vh - 141px); margin: 0 auto; padding: 3.5rem 0 5rem; }
.page-heading { margin-bottom: 1.25rem; }
.page-heading h1 { margin-bottom: .5rem; font-size: clamp(2rem, 4vw, 3rem); }
.page-heading > p:last-child { margin-bottom: 0; color: var(--text-muted); }
.demo-notice {
  margin: 1rem 0 1.5rem;
  padding: .7rem .85rem;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: var(--blue-soft);
  color: #1e40af;
  font-size: .84rem;
}
.scenario-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.scenario-card {
  display: block;
  padding: 1.4rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
}
.scenario-card:hover { border-color: #93c5fd; box-shadow: 0 3px 12px rgba(15, 23, 42, .08); }
.scenario-card small { color: var(--text-muted); font-size: .78rem; font-weight: 700; }
.scenario-card h2 { margin: .45rem 0; font-size: 1.2rem; }
.scenario-card p { margin-bottom: 0; color: var(--text-muted); font-size: .9rem; }
.scenario-card > span:last-child { display: inline-block; margin-top: 1rem; color: var(--blue); font-size: .86rem; font-weight: 700; }

/* Application-like demo pages */
.app-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  width: min(1240px, calc(100% - 2rem));
  min-height: calc(100vh - 2rem);
  margin: 1rem auto;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.sidebar {
  display: flex;
  flex-direction: column;
  padding: 1.25rem .8rem;
  border-right: 1px solid var(--line);
  background: #fff;
}
.sidebar-title { margin: 0 .55rem 1.5rem; }
.sidebar nav { display: grid; gap: .2rem; }
.sidebar nav a,
.sidebar-back {
  padding: .6rem .7rem;
  border-radius: 6px;
  color: var(--text-muted);
  font-size: .86rem;
  font-weight: 600;
  text-decoration: none;
}
.sidebar nav a:hover,
.sidebar nav a.active { background: var(--blue-soft); color: var(--blue-dark); }
.sidebar-back { margin-top: auto; border-top: 1px solid var(--line); border-radius: 0; }
.sidebar-back:hover { color: var(--blue); }
.app-main { min-width: 0; padding: clamp(1.1rem, 3vw, 2rem); }
.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1.15rem;
  border-bottom: 1px solid var(--line);
}
.topbar h1 { max-width: none; margin: 0; font-size: clamp(1.5rem, 3vw, 2rem); }
.topbar .breadcrumb { margin-bottom: .25rem; }
.text-link { color: var(--blue); font-size: .86rem; font-weight: 600; text-decoration: none; }
.tabs { display: flex; gap: .15rem; margin-top: 1rem; overflow-x: auto; border-bottom: 1px solid var(--line); }
.tab-button {
  flex: 0 0 auto;
  padding: .7rem .9rem;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-size: .88rem;
  font-weight: 650;
}
.tab-button:hover,
.tab-button.active,
.tab-button[aria-selected="true"] { border-bottom-color: var(--blue); color: var(--blue-dark); }
.tab-panel { padding-top: 1.4rem; }
.tab-panel[hidden] { display: none; }
.panel-heading { margin-bottom: 1rem; }
.panel-heading h2 { margin-bottom: .25rem; font-size: 1.25rem; }
.panel-heading p { margin-bottom: 0; color: var(--text-muted); font-size: .86rem; }
.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  margin-bottom: 1rem;
}
.toolbar > * { margin: 0; }
.toolbar h2 { margin-bottom: .15rem; font-size: 1.25rem; }
.toolbar p,
.toolbar label { margin-bottom: 0; color: var(--text-muted); font-size: .84rem; }
.toolbar select { margin-left: .4rem; padding: .4rem .55rem; border: 1px solid var(--line-strong); border-radius: 6px; background: #fff; color: var(--text); }
.toolbar button:not(.primary-action),
.data-table button,
.card button:not(.primary-action),
.request-item button,
.connection-card button:not(.primary-action) {
  padding: .43rem .68rem;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  font-size: .82rem;
  font-weight: 650;
}
.toolbar button:not(.primary-action):hover,
.data-table button:hover,
.card button:not(.primary-action):hover,
.request-item button:hover { border-color: var(--blue); background: var(--blue-soft); color: var(--blue-dark); }

.table-scroll-hint { display: none; margin: 0 0 .4rem; color: var(--text-muted); font-size: .78rem; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.data-table { width: 100%; min-width: 660px; border-collapse: collapse; text-align: left; font-size: .84rem; }
.data-table caption { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.data-table th,
.data-table td { padding: .75rem .85rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.data-table th { background: var(--surface-muted); color: #475467; font-size: .75rem; font-weight: 700; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: #fafcff; }
.data-table small { display: block; margin-top: .1rem; color: var(--text-muted); }

.product-card { display: grid; gap: .65rem; padding: 1rem; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.product-card h3,
.product-card p { margin: 0; }
.product-card p { color: var(--text-muted); font-size: .84rem; }
.product-card strong,
.price { display: block; margin-top: .2rem; font-size: 1rem; }
.product-card button { width: fit-content; padding: .42rem .65rem; border: 1px solid var(--line-strong); border-radius: 6px; background: #fff; color: var(--text); font-size: .8rem; font-weight: 650; }
.product-card button:hover { border-color: var(--blue); color: var(--blue); }
.shop-header { margin-bottom: 1rem; }
.product-detail-visual { min-height: 300px; }

.status {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: .16rem .5rem;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 700;
  line-height: 1.5;
  white-space: nowrap;
}
.status-published,
.status-delivered { background: var(--green-soft); color: var(--green); }
.status-pending { background: var(--amber-soft); color: var(--amber); }
.status-shipped { background: var(--blue-soft); color: var(--blue-dark); }
.status-draft,
.status-disconnected { background: var(--gray-soft); color: #475467; }
.card-heading,
.connection-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.card-heading h3,
.connection-heading h3 { margin-bottom: .25rem; }
.connection-heading p { margin-bottom: 0; color: var(--text-muted); font-size: .86rem; }

.definition-list { margin: 1rem 0; }
.definition-list > div { display: grid; grid-template-columns: 8rem minmax(0, 1fr); gap: .75rem; padding: .55rem 0; border-bottom: 1px solid var(--line); font-size: .87rem; }
.definition-list dt { color: var(--text-muted); }
.definition-list dd { min-width: 0; margin: 0; overflow-wrap: anywhere; }
.quote-options { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.quote-options button { padding: .45rem .7rem; border: 1px solid var(--line-strong); border-radius: 6px; background: #fff; color: var(--text); font-size: .85rem; font-weight: 650; }
.quote-options button:hover,
.quote-options button[aria-pressed="true"] { border-color: var(--blue); background: var(--blue-soft); color: var(--blue-dark); }
.metric-grid article { padding: 1rem; }
.metric-grid span,
.metric-grid small { color: var(--text-muted); font-size: .8rem; }
.metric-grid strong { display: block; margin: .35rem 0; font-size: 1.15rem; }

.timeline { max-width: 720px; margin: 0; padding: 0 0 0 1.25rem; border-left: 2px solid #cbd5e1; list-style: none; }
.timeline li { position: relative; padding: 0 0 1.25rem; }
.timeline li::before { position: absolute; top: .35rem; left: -1.63rem; width: .62rem; height: .62rem; border: 2px solid #fff; border-radius: 50%; background: #98a2b3; box-shadow: 0 0 0 1px #98a2b3; content: ""; }
.timeline li.is-complete::before,
.timeline li.is-current::before { background: var(--blue); box-shadow: 0 0 0 1px var(--blue); }
.timeline strong { display: block; margin-bottom: .15rem; }
.timeline p { margin: 0; color: var(--text-muted); font-size: .88rem; }

.request-list { display: grid; gap: .75rem; }
.request-item {
  display: grid;
  grid-template-columns: auto minmax(140px, 1fr) auto auto;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}
.request-item h3,
.request-item p { margin: 0; }
.request-item p { color: var(--text-muted); font-size: .84rem; }
.shop-avatar { display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 6px; background: var(--gray-soft); color: #475467; font-weight: 700; }
.action-row { display: flex; gap: .4rem; }
.settings-panel,
.connection-card { padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }

.presentation-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin: 2rem auto 0; }
.presentation-nav a { min-height: 38px; border-color: var(--line-strong); background: #fff; color: var(--text); font-size: .82rem; }
.presentation-nav a:hover { border-color: var(--blue); color: var(--blue); }
.noscript-note { margin-top: 1rem; padding: .8rem; border: 1px solid var(--line); border-radius: 6px; background: var(--surface-muted); color: var(--text-muted); font-size: .84rem; }
.toast,
.demo-toast {
  position: fixed;
  z-index: 50;
  right: 1rem;
  bottom: 1rem;
  max-width: min(360px, calc(100vw - 2rem));
  padding: .75rem .9rem;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #fff;
  box-shadow: var(--shadow);
  font-size: .86rem;
  opacity: 0;
  pointer-events: none;
  transform: translateY(.75rem);
  transition: opacity .18s ease, transform .18s ease;
}
.toast.is-visible,
.demo-toast.is-visible { opacity: 1; transform: translateY(0); }

/* Interactive purchase and seller journeys. */
.role-switch { display: flex; gap: .4rem; }
.role-switch a,
.step-nav a { padding: .45rem .7rem; border-radius: 6px; color: var(--text-muted); font-size: .84rem; font-weight: 700; text-decoration: none; }
.role-switch a.is-current,
.role-switch a:hover,
.step-nav a.is-current,
.step-nav a:hover { background: var(--blue-soft); color: var(--blue-dark); }
.journey-page,
.route-card { width: min(960px, calc(100% - 2rem)); min-height: calc(100vh - 65px); margin: 0 auto; padding: 2.5rem 0 4rem; }
.route-card { max-width: 680px; }
.journey-title { margin: 1.5rem 0; }
.journey-title h1,
.entry-choice h1 { max-width: 20ch; margin-bottom: .45rem; font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -.025em; }
.journey-title h1 { font-size: 1.5rem; }
.page-lead,
.quiet-note { color: var(--text-muted); }
.entry-choice { padding: 3rem 0; }
.journey-choice { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
button.scenario-card { width: 100%; text-align: left; cursor: pointer; font: inherit; }
.scenario-card { display: flex; align-items: flex-start; gap: 1rem; border: 1px solid var(--line); }
.scenario-card strong,
.scenario-card em { display: block; }
.scenario-card strong { margin: .35rem 0; font-size: 1.12rem; }
.scenario-card em { color: var(--text-muted); font-size: .88rem; font-style: normal; }
.choice-icon { display: grid; flex: 0 0 2.75rem; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: 6px; background: var(--blue-soft); color: var(--blue-dark); font-weight: 800; }
.step-nav { display: flex; overflow-x: auto; gap: .25rem; margin: 1.25rem 0 1.5rem; border-bottom: 1px solid var(--line); padding-bottom: .5rem; }
.step-nav a { flex: 0 0 auto; }
.journey-screen { padding: 1.25rem; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); box-shadow: 0 2px 9px rgba(15, 23, 42, .04); }
.journey-screen > * { min-width: 0; }
.journey-screen button:not(.primary-action) { padding: .5rem .75rem; border: 1px solid var(--line-strong); border-radius: 6px; background: #fff; color: var(--text); cursor: pointer; }
.journey-screen button:disabled { cursor: default; opacity: .6; }
.screen-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.screen-heading h2 { margin-bottom: .2rem; font-size: 1.35rem; }
.screen-heading p { margin-bottom: 0; color: var(--text-muted); font-size: .9rem; }
.search-field { display: grid; gap: .35rem; max-width: 600px; margin-bottom: 1.5rem; color: var(--text-muted); font-size: .86rem; font-weight: 700; }
.search-field input,
.form-card input,
.form-card select { width: 100%; min-height: 42px; padding: .55rem .65rem; border: 1px solid var(--line-strong); border-radius: 6px; background: #fff; color: var(--text); }
.search-layout { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.search-layout h3 { margin-bottom: .5rem; font-size: .95rem; }
.result-card,
.cart-row,
.order-card,
.published-preview,
.mall-preview { display: block; padding: 1rem; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.result-card > div { min-width: 0; }
.result-card p,
.cart-row p,
.order-card p { margin: .1rem 0 .6rem; color: var(--text-muted); font-size: .84rem; }
.sample-visual,
.product-illustration { display: grid; flex: 0 0 auto; place-items: center; width: 72px; height: 72px; overflow: hidden; border: 1px solid #dbe1e9; border-radius: 6px; background: var(--gray-soft); }
.product-illustration { width: min(100%, 380px); height: 300px; }
.sample-visual::after,
.product-illustration::after { color: #5d6877; font-size: .75rem; font-weight: 750; }
.visual-tote::after { content: "トート"; }
.visual-mug::after { content: "マグ"; }
.visual-notebook::after { content: "ノート"; }
.visual-mall::after { content: "Mall"; }
.visual-coffee::after { content: "商品"; }
.visual-tote { background: linear-gradient(135deg, #eef2f7 0 46%, #dbeafe 46% 100%); }
.visual-mug { background: linear-gradient(135deg, #f3f4f6 0 54%, #e0e7ff 54% 100%); }
.visual-notebook { background: linear-gradient(135deg, #f3f4f6 0 48%, #dbeafe 48% 100%); }
.visual-mall { background: linear-gradient(135deg, #eff6ff 0 52%, #e5e7eb 52% 100%); }
[data-photo="tote"]::after { content: "トート"; }
[data-photo="mug"]::after { content: "マグ"; }
[data-photo="notebook"]::after { content: "ノート"; }
.product-detail-layout { display: grid; grid-template-columns: minmax(220px, .9fr) minmax(0, 1fr); gap: 2rem; align-items: start; }
.product-detail-layout h2 { margin-bottom: .4rem; }
.back-link { display: inline-block; margin-bottom: 1rem; color: var(--blue); font-size: .88rem; }
.compact-list,
.summary-list { margin: 1rem 0; }
.compact-list > div,
.summary-list > div { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--line); }
.compact-list dt,
.summary-list dt { color: var(--text-muted); }
.compact-list dd,
.summary-list dd { margin: 0; font-weight: 700; }
.cart-row { justify-content: flex-start; }
.cart-row > strong { margin-left: auto; }
.form-card { display: grid; gap: 1.1rem; max-width: 680px; }
.form-card > label,
.form-card fieldset { display: grid; gap: .4rem; margin: 0; padding: 0; border: 0; color: var(--text-muted); font-size: .86rem; font-weight: 700; }
.form-card legend { margin-bottom: .45rem; color: var(--text); }
.form-two-up { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.form-two-up label,
.fee-amount { display: grid; gap: .4rem; color: var(--text-muted); font-size: .86rem; font-weight: 700; }
.check-row { display: flex; flex-wrap: wrap; gap: 1rem; color: var(--text); font-weight: 500; }
.check-row label { display: flex; align-items: center; gap: .5rem; }
.check-row input { width: 18px; height: 18px; min-height: 0; margin: 0; padding: 0; }
.field-help { margin: 0; color: var(--text-muted); font-size: .8rem; font-weight: 400; }
.form-error { margin: 0; color: #b42318; font-size: .85rem; font-weight: 700; }
.checkout-total { display: flex; justify-content: space-between; align-items: center; padding-top: .9rem; border-top: 1px solid var(--line); }
.checkout-total strong { font-size: 1.2rem; }
.photo-choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .75rem; }
.photo-choices label { display: grid; gap: .4rem; color: var(--text); font-size: .82rem; font-weight: 600; }
.photo-choices input { position: static; opacity: 1; width: 18px; height: 18px; min-height: 0; padding: 0; margin: 0; }
.photo-choices input:focus-visible + .sample-visual { outline: 3px solid rgba(37, 99, 235, .45); outline-offset: 2px; }
.photo-choices input:checked + .sample-visual { border: 2px solid var(--blue); background: var(--blue-soft); }
.photo-choices .sample-visual { width: 100%; height: 96px; }
.published-preview { align-items: stretch; }
.published-preview > div { display: flex; flex-direction: column; align-items: flex-start; }
.published-preview > div button + button { margin-top: .6rem; }
.order-card { justify-content: space-between; }
.inline-input { display: flex; gap: .5rem; }
.inline-input input { min-width: 0; }
.inline-input button,
.invite-row button,
.dialog-actions button:not(.primary-action) { padding: .5rem .7rem; border: 1px solid var(--line-strong); border-radius: 6px; background: #fff; color: var(--text); font-weight: 700; }
.invite-list { display: grid; gap: .55rem; margin: 0; padding: 0; list-style: none; }
.invite-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: .7rem; padding: .75rem; border: 1px solid var(--line); border-radius: 6px; }
.invite-row strong { min-width: 0; overflow-wrap: anywhere; }
.public-mall-card { margin-top: 1.25rem; padding: 1rem; border: 1px solid #bfdbfe; border-radius: 8px; background: var(--blue-soft); }
.public-mall-card h3 { margin-bottom: .25rem; }
.public-mall-card p { color: #1e40af; font-size: .88rem; }
.public-shop-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; margin: .75rem 0 0; }
.public-shop-card { padding: .75rem; border: 1px solid #bfdbfe; border-radius: 6px; background: #fff; }
.public-shop-card span { display: block; margin-top: .15rem; color: var(--text-muted); font-size: .8rem; }
.complete-card { display: flex; align-items: flex-start; gap: 1rem; max-width: 620px; }
.complete-mark { display: grid; flex: 0 0 2.5rem; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 50%; background: var(--green-soft); color: var(--green); font-weight: 800; }
.journey-message { margin: 1rem 0 0; color: var(--blue-dark); font-weight: 700; }
.demo-dialog { width: min(100% - 2rem, 520px); padding: 1.5rem; border: 1px solid var(--line); border-radius: 10px; color: var(--text); box-shadow: var(--shadow); }
.demo-dialog::backdrop { background: rgba(15, 23, 42, .45); }
.demo-dialog h2 { margin-bottom: .65rem; }
.demo-dialog p { color: var(--text-muted); }
.dialog-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .6rem; margin-top: 1.25rem; }
.qr-placeholder { display: grid; place-items: center; width: 150px; height: 150px; margin: 1rem auto; border: 1px dashed var(--line-strong); background: var(--surface-muted); color: var(--text-muted); font-weight: 800; }
.agreement { display: flex; gap: .5rem; align-items: flex-start; }

/* 404 */
.not-found-page { display: grid; min-height: 100vh; place-items: center; padding: 1rem; }
.not-found { width: min(100%, 620px); padding: clamp(1.5rem, 5vw, 3rem); border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: var(--shadow); }
.not-found h1 { margin-bottom: .75rem; font-size: clamp(1.7rem, 4vw, 2.5rem); }
.not-found > p:not(.error-code) { color: var(--text-muted); }

@media (max-width: 820px) {
  .site-header { position: static; }
  .hero { grid-template-columns: 1fr; min-height: auto; padding: 3.5rem 0; }
  .hero h1 { max-width: 18ch; }
  .three-up,
  .product-grid,
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .app-shell { grid-template-columns: 1fr; width: 100%; min-height: 100vh; margin: 0; border: 0; border-radius: 0; box-shadow: none; }
  .sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
  .sidebar-title { margin-bottom: .75rem; }
  .sidebar nav { display: flex; overflow-x: auto; }
  .sidebar nav a { flex: 0 0 auto; white-space: nowrap; }
  .sidebar-back { display: none; }
}

@media (max-width: 560px) {
  body { font-size: 15px; }
  .header-inner,
  .footer-inner { align-items: flex-start; flex-direction: column; justify-content: center; padding: .8rem 0; }
  .nav { flex-wrap: wrap; gap: .75rem; }
  .hero { padding: 2.75rem 0; }
  .hero h1 { font-size: 2.15rem; }
  .preview-products,
  .three-up,
  .two-up,
  .product-grid,
  .scenario-grid,
  .metric-grid { grid-template-columns: 1fr; }
  .section { padding-block: 3rem; }
  .demo-intro,
  .topbar,
  .toolbar { align-items: flex-start; flex-direction: column; }
  .demo-home { padding-top: 2.5rem; }
  .app-main { padding: 1rem; }
  .table-scroll-hint { display: block; }
  .definition-list > div { grid-template-columns: 1fr; gap: .15rem; }
  .request-item { grid-template-columns: auto 1fr; }
  .request-item .status,
  .request-item .action-row { grid-column: 2; }
  .journey-page,
  .route-card { width: min(100% - 1.25rem, 960px); padding-top: 1.25rem; }
  .role-switch { width: 100%; }
  .role-switch a { flex: 1; text-align: center; }
  .journey-choice,
  .search-layout,
  .product-detail-layout,
  .form-two-up,
  .public-shop-list { grid-template-columns: 1fr; }
  .journey-screen { padding: 1rem; }
  .product-illustration { width: 100%; height: 220px; }
  .result-card,
  .cart-row,
  .published-preview { align-items: flex-start; }
  .inline-input,
  .order-card { align-items: stretch; flex-direction: column; }
  .invite-row { grid-template-columns: 1fr auto; }
  .invite-row button { grid-column: 1 / -1; }
}
