/* ナレッジデスク sales site. Tokens are the product's (.interface-design/system.md): binder paper, ink, one diazo
   blue, the marker only on quoted text, the red pencil only for what is missing or open. */
:root {
  --paper: #f3f0e6;
  --sheet: #fffefa;
  --ink: #1e2229;
  --graphite: #50555d;
  --faint: #6a6f77;
  --rule: rgba(30, 34, 41, 0.14);
  --rule-strong: rgba(30, 34, 41, 0.55);
  --field-line: #85898f;
  --diazo: #22356b;
  --diazo-deep: #1a2955;
  --diazo-wash: rgba(34, 53, 107, 0.07);
  --marker: #fbe27a;
  --redpencil: #b8321f;
  --sans: "BIZ UDPGothic", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Meiryo", sans-serif;
  --serif: "BIZ UDMincho", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --wrap: 1120px;
  --gutter: 32px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.85;
  word-break: auto-phrase;
  line-break: strict;
  overflow-wrap: break-word;
  font-variant-numeric: tabular-nums;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--diazo); text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--diazo); outline-offset: 2px; border-radius: 2px; }
h1, h2, h3 { line-height: 1.35; letter-spacing: 0.02em; text-wrap: balance; margin: 0; }
p { margin: 0; }
p + p { margin-top: 0.9em; }
small { font-size: 0.5em; font-weight: 400; margin-left: 2px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--sheet); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }

/* masthead */
.masthead { border-bottom: 1px solid var(--rule); background: var(--paper); }
.masthead-row { display: flex; align-items: center; gap: 32px; min-height: 68px; }
.brand { display: flex; flex-direction: column; line-height: 1.25; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 19px; letter-spacing: 0.04em; }
.brand-sub { font-size: 11px; font-weight: 400; color: var(--graphite); letter-spacing: 0.02em; }
.nav { list-style: none; display: flex; gap: 24px; margin: 0; padding: 0; font-size: 14px; }
.nav a { color: var(--ink); text-decoration: none; padding: 6px 0; }
.nav a:hover { color: var(--diazo); text-decoration: underline; }
.masthead-cta { margin-left: auto; display: flex; align-items: center; gap: 20px; font-size: 14px; }
.link-quiet { color: var(--ink); }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 10px 22px; border-radius: 4px;
  font: inherit; font-weight: 700; font-size: 15px; line-height: 1.3; text-decoration: none; cursor: pointer;
  border: 1px solid transparent;
}
.btn-primary { background: var(--diazo); color: var(--sheet); }
.btn-primary:hover { background: var(--diazo-deep); text-decoration: none; }
.btn-secondary { background: var(--sheet); color: var(--ink); border-color: var(--rule-strong); }
.btn-secondary:hover { border-color: var(--ink); text-decoration: none; }
.btn-small { min-height: 40px; padding: 6px 16px; font-size: 14px; }
.btn-large { min-height: 56px; padding: 12px 28px; font-size: 16px; }
.btn:disabled { opacity: 0.55; cursor: progress; }

/* hero */
.hero { padding: 72px 0 24px; }
.hero-copy { max-width: 800px; }
.hero h1 { font-size: clamp(30px, 4.4vw, 50px); letter-spacing: 0.03em; }
.hero-lead { margin-top: 24px; font-size: 18px; color: var(--graphite); max-width: 36em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.cta-note { margin-top: 12px; font-size: 14px; color: var(--graphite); }
.hero-shot { margin: 56px 0 0; }

/* screenshots */
.shot { margin: 0; }
.shot-frame { position: relative; background: var(--sheet); border: 1px solid var(--rule); border-radius: 8px; overflow: hidden; }
.shot figcaption, .hero-shot figcaption { margin-top: 10px; font-size: 13px; color: var(--graphite); display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; line-height: 1.6; }
.demo-tag {
  display: inline-block; padding: 1px 8px; font-size: 12px; color: var(--diazo); white-space: nowrap;
  background: repeating-linear-gradient(-45deg, var(--paper) 0 6px, #e6e2d5 6px 8px);
  border: 1px solid var(--rule);
}

/* balloons: the product's citation mark (a part balloon on an assembly drawing) */
.balloon {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 26px; height: 26px; border-radius: 50%;
  border: 1.5px solid var(--diazo); color: var(--diazo); background: var(--sheet);
  font-size: 14px; font-weight: 700; line-height: 1;
}
.balloon-on {
  position: absolute; transform: translate(-50%, -50%);
  width: clamp(26px, 3vw, 40px); height: clamp(26px, 3vw, 40px); font-size: clamp(14px, 1.5vw, 20px);
  background: var(--diazo); color: var(--sheet); border: 3px solid var(--sheet);
  box-shadow: 0 0 0 1.5px var(--diazo);
}
.balloon-legend { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 28px; margin: 4px 0 0; padding: 0; font-size: 15px; color: var(--ink); }
.balloon-legend li { display: flex; align-items: center; gap: 8px; }
.hero-shot figcaption { justify-content: space-between; align-items: center; }

/* sections */
.section { padding: 96px 0; }
.section-sheet { background: var(--sheet); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.section h2 { font-size: clamp(24px, 2.8vw, 32px); }
.section-lead { margin-top: 16px; max-width: 40em; color: var(--graphite); }

/* pains: the buyer's words on the left, our answer on the right, ruled like a binder page */
.pains { margin: 48px 0 0; border-top: 1px solid var(--rule-strong); }
.pain { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px; padding: 28px 0; border-bottom: 1px solid var(--rule); }
.pain dt { font-family: var(--serif); font-size: 21px; line-height: 1.6; text-indent: -0.5em; }
.pain dd { margin: 0; color: var(--ink); max-width: 36em; }

/* how it answers */
.how { margin-top: 56px; display: grid; gap: 80px; }
.how-row { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 48px; align-items: start; }
.how-text h3 { font-size: 22px; margin-bottom: 16px; }
.how-text p { color: var(--ink); }
.more-shots { margin-top: 88px; padding-top: 40px; border-top: 1px solid var(--rule); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 0.44fr); gap: 32px; align-items: start; }

/* ledgers (ruled tables) */
.table-scroll { margin-top: 40px; }
.ledger { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.7; }
.ledger th, .ledger td { text-align: left; vertical-align: top; padding: 16px 16px 16px 0; border-bottom: 1px solid var(--rule); }
.ledger thead th { font-size: 13px; font-weight: 400; color: var(--graphite); padding-top: 0; padding-bottom: 10px; border-bottom: 1px solid var(--rule-strong); }
.ledger tbody th { font-weight: 700; }
.ledger .meta { display: block; font-weight: 400; font-size: 13px; color: var(--graphite); }
.templates tbody th { width: 22%; }
.templates td:nth-child(2) { width: 34%; }
.examples { list-style: none; margin: 0; padding: 0; }
.examples li::before { content: "「"; }
.examples li::after { content: "」"; }
.num, .ledger .num, .report-table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* measured: laid out as a test report (試験成績書) */
.report { margin-top: 48px; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 56px; align-items: start; }
.report-table { width: 100%; border-collapse: collapse; border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink); }
.report-table caption, .ledger caption { caption-side: top; text-align: left; font-size: 13px; color: var(--graphite); padding-bottom: 10px; }
.report-table th, .report-table td { padding: 18px 12px 18px 0; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: baseline; }
.report-table thead th { font-size: 13px; font-weight: 400; color: var(--graphite); padding: 10px 12px 10px 0; }
.report-table tbody th { font-weight: 700; font-size: 15px; width: 42%; }
.report-table td.num { font-size: 40px; font-weight: 700; line-height: 1; padding-right: 20px; }
.report-table td:last-child { font-size: 14px; color: var(--graphite); }
.report-table .frac { color: var(--ink); font-weight: 700; }
.report-table tr.is-open td.num { color: var(--redpencil); text-decoration: underline wavy var(--redpencil); text-decoration-thickness: 1.5px; text-underline-offset: 8px; }
.redpencil { color: var(--redpencil); font-weight: 700; margin-right: 4px; }
.ledger.compact { font-size: 14px; }
.ledger.compact th, .ledger.compact td { padding: 10px 12px 10px 0; }
.caveats { margin: 28px 0 0; padding: 0 0 0 1.2em; font-size: 14px; color: var(--graphite); }
.caveats li + li { margin-top: 8px; }

/* spec list (security) */
.spec { margin: 40px 0 0; border-top: 1px solid var(--rule-strong); }
.spec > div { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; padding: 22px 0; border-bottom: 1px solid var(--rule); }
.spec dt { font-weight: 700; }
.spec dd { margin: 0; max-width: 40em; }

/* pricing */
.price-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; margin-top: 24px; }
.price-lead { color: var(--graphite); }
.note-draft { font-size: 13px; color: var(--ink); border: 1px dashed var(--rule-strong); padding: 2px 10px; border-radius: 2px; background: var(--sheet); }
.plans {
  margin-top: 32px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(6, auto); border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule-strong);
}
.plan { grid-row: span 6; display: grid; grid-template-rows: subgrid; row-gap: 0; padding: 24px 20px 28px; border-left: 1px solid var(--rule); }
.plan:first-child { border-left: 0; padding-left: 0; }
.plan-trial { box-shadow: inset 0 3px 0 var(--diazo); }
.plan-name { font-size: 18px; }
.plan-price { padding-top: 12px; }
.price { line-height: 1.2; }
.price-num { font-size: 32px; font-weight: 700; letter-spacing: 0.01em; }
.price-unit { font-size: 13px; margin-left: 4px; color: var(--graphite); }
.price-tax { font-size: 13px; color: var(--graphite); margin-top: 6px; }
.plan-summary { font-size: 14px; padding-top: 16px; }
.plan-limits { margin: 16px 0 0; font-size: 14px; border-top: 1px solid var(--rule); }
.plan-limits > div { display: flex; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px dotted var(--rule-strong); }
.plan-limits dt { color: var(--graphite); }
.plan-limits dd { margin: 0; font-weight: 700; text-align: right; }
.plan-features { margin: 16px 0 0; padding: 0 0 0 1.1em; font-size: 14px; line-height: 1.7; }
.plan-features li + li { margin-top: 4px; }
.plan-cta { padding-top: 20px; align-self: end; }
.plan-cta .btn { width: 100%; }
.more-link { margin-top: 24px; }

/* FAQ */
.faq { margin-top: 32px; border-top: 1px solid var(--rule-strong); max-width: 860px; }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary { cursor: pointer; list-style: none; padding: 20px 40px 20px 0; font-weight: 700; font-size: 17px; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 8px; top: 16px; font-size: 24px; color: var(--diazo); font-weight: 400; }
.faq details[open] summary::after { content: "−"; }
.faq details p { padding: 0 0 24px; max-width: 44em; }

/* closing: the one diazo print on the page */
.closing { background: var(--diazo); color: var(--paper); padding: 80px 0; }
.closing-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 48px; align-items: center; }
.closing h2 { font-size: clamp(26px, 3vw, 36px); }
.closing p { margin-top: 16px; max-width: 34em; }
.closing .cta-row { margin-top: 0; justify-content: flex-end; }
.closing .btn-primary { background: var(--paper); color: var(--diazo); }
.closing .btn-primary:hover { background: var(--sheet); }
.closing .btn-secondary { background: transparent; color: var(--paper); border-color: rgba(243, 240, 230, 0.7); }
.closing .btn-secondary:hover { border-color: var(--paper); }
.closing :focus-visible { outline-color: var(--marker); }

/* footer: a drawing title block */
.site-footer { padding: 56px 0 64px; font-size: 13px; }
.titleblock { margin-left: auto; border-collapse: collapse; border: 1.5px solid var(--ink); background: var(--sheet); max-width: 640px; width: 100%; }
.titleblock th, .titleblock td { border: 1px solid var(--rule-strong); padding: 6px 10px; text-align: left; vertical-align: top; line-height: 1.6; }
.titleblock th { font-weight: 400; color: var(--graphite); white-space: nowrap; width: 1%; }
.nobr { white-space: nowrap; }
.footer-links { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 24px; padding: 0; margin: 20px 0 0; justify-content: flex-end; }

/* inner pages */
.page { padding-top: 56px; padding-bottom: 96px; }
.page-title { font-size: clamp(26px, 3vw, 34px); }
.prose { max-width: 46em; margin-top: 48px; }
.prose h2 { font-size: 18px; margin: 40px 0 12px; }
.prose section:first-child h2 { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.4em; margin: 12px 0 0; }
.prose li + li { margin-top: 6px; }
.prose ul + p { margin-top: 20px; }
.legal .page-title { margin-bottom: 8px; }
.revised { margin-top: 48px; font-size: 14px; color: var(--graphite); }
.draft-banner { margin-bottom: 32px; padding: 14px 18px; border-left: 4px solid var(--redpencil); background: var(--sheet); font-size: 14px; max-width: 46em; }
.draft-banner strong { color: var(--redpencil); display: block; font-size: 16px; }
.legal-table { margin-top: 32px; max-width: 860px; }
.legal-table tbody th { width: 30%; font-weight: 700; }

/* contact */
.contact { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; align-items: start; }
.contact-intro p { margin-top: 16px; color: var(--graphite); }
.form { background: var(--sheet); border: 1px solid var(--rule); border-radius: 8px; padding: 32px; }
.field + .field { margin-top: 22px; }
.field label { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.req, .opt { font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 2px; }
.req { color: var(--sheet); background: var(--diazo); }
.opt { color: var(--graphite); border: 1px solid var(--rule-strong); font-weight: 400; }
.field input, .field textarea {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: var(--sheet);
  border: 1px solid var(--field-line); border-radius: 2px; padding: 10px 12px; min-height: 48px;
}
.field textarea { resize: vertical; line-height: 1.7; }
.field input:focus-visible, .field textarea:focus-visible { outline: 3px solid var(--diazo); outline-offset: 0; border-color: var(--diazo); }
.field [aria-invalid="true"] { border-color: var(--redpencil); }
.field-error { color: var(--redpencil); font-size: 14px; margin-top: 6px; }
.hint { font-size: 13px; color: var(--graphite); margin-top: 6px; }
.form > .hint { margin-top: 24px; }
.form-actions { margin-top: 20px; }
.form-status { margin-top: 16px; font-size: 15px; }
.form-status:empty { display: none; }
.form-status[data-kind="ok"] { padding: 12px 14px; border-left: 4px solid var(--diazo); background: var(--diazo-wash); }
.form-status[data-kind="error"] { padding: 12px 14px; border-left: 4px solid var(--redpencil); color: var(--redpencil); background: var(--sheet); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* narrow screens */
@media (max-width: 1000px) {
  .nav { gap: 16px; }
  .masthead-cta .link-quiet { display: none; }
  .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(12, auto); }
  .plan:nth-child(3) { border-left: 0; padding-left: 0; }
  .plan:nth-child(n + 3) { border-top: 1px solid var(--rule); }
}
@media (max-width: 860px) {
  :root { --gutter: 20px; }
  .masthead-row { flex-wrap: wrap; gap: 0 16px; padding-top: 10px; }
  .masthead nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; }
  .nav { gap: 14px; padding-bottom: 4px; white-space: nowrap; font-size: 13px; }
  .nav a { display: inline-block; padding: 10px 0; }
  .hero { padding: 40px 0 8px; }
  .hero-lead { font-size: 16px; }
  .hero-shot { margin-top: 36px; }
  .balloon-legend { font-size: 14px; gap: 6px 18px; }
  .section { padding: 64px 0; }
  .pain, .how-row, .report, .closing-grid, .contact { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .pain dt { font-size: 18px; }
  .how { gap: 56px; }
  .how-row { gap: 20px; }
  .more-shots { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); margin-top: 56px; }
  .more-shots .shot-phone { grid-column: 1 / -1; max-width: 220px; }
  .report { gap: 40px; }
  .spec > div { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .closing .cta-row { justify-content: flex-start; margin-top: 8px; }
  .contact { gap: 32px; }
  .form { padding: 22px 18px; }
  .titleblock { margin-left: 0; }
  .footer-links { justify-content: flex-start; }

  /* tables become ruled blocks */
  .templates thead { position: absolute; left: -10000px; }
  .templates, .templates tbody, .templates tr, .templates th, .templates td { display: block; width: auto !important; }
  .templates tr { padding: 20px 0; border-bottom: 1px solid var(--rule); }
  .templates th, .templates td { border: 0; padding: 0; }
  .templates td { margin-top: 10px; }
  .templates td::before { content: attr(data-label); display: block; font-size: 12px; color: var(--graphite); }
  .table-scroll { border-top: 1px solid var(--rule-strong); margin-top: 32px; }
}
@media (max-width: 600px) {
  .more-shots { grid-template-columns: minmax(0, 1fr); }
  .plans { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; }
  .plan { grid-row: auto; display: block; border-left: 0; padding: 24px 0 28px; border-top: 1px solid var(--rule); }
  .plan:first-child { border-top: 0; }
  .plan-trial { box-shadow: none; }
  .report-table thead { position: absolute; left: -10000px; }
  .report-table, .report-table tbody, .report-table caption { display: block; }
  .report-table tr { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--rule); }
  .report-table tr:last-child { border-bottom: 0; }
  .report-table th, .report-table td { border: 0; padding: 0; }
  .report-table tbody th { grid-column: 1 / -1; width: auto; margin-bottom: 8px; }
  .report-table td.num { font-size: 34px; padding-right: 0; align-self: center; }
  .report-table td:last-child { align-self: center; }
  .btn-large { width: 100%; }
  .cta-row { flex-direction: column; }
  .closing .cta-row { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; } }
