/* ============================================
   古物商許可ナビ — shared stylesheet
   Palette: 深紺(ink-navy) / 真鍮(brass) / 紙(paper) / 朱(stamp-red)
   Motif: 古物商標識の八角形（法定プレートの形）
   ============================================ */

:root{
  --ink-navy: #14213d;
  --ink-navy-deep: #0d1628;
  --paper: #f5f6f4;
  --paper-raised: #ffffff;
  --charcoal: #292722;
  --charcoal-soft: #56534a;
  --brass: #b08d57;
  --brass-light: #d7b787;
  --brass-tint: #f6efe1;
  --stamp-red: #a23b32;
  --line: #e5e3dd;
  --line-on-navy: rgba(247,243,233,0.18);
  --shadow-card: 0 4px 18px rgba(20,33,61,0.08);
  --shadow-card-hover: 0 10px 28px rgba(20,33,61,0.14);

  --font-display: "Shippori Mincho", serif;
  --font-body: "Zen Kaku Gothic New", "Hiragino Sans", sans-serif;
  --font-mono: "Roboto Mono", monospace;

  --radius-s: 3px;
  --radius-m: 8px;
  --maxw: 1120px;
}

@media (prefers-reduced-motion: reduce){
  *{ animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

*{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin:0;
  background: var(--paper);
  color: var(--charcoal);
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
}
img{ max-width:100%; display:block; }
a{ color: inherit; }
:focus-visible{ outline: 2.5px solid var(--stamp-red); outline-offset: 3px; }

.wrap{ max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }

h1,h2,h3,h4{
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ink-navy);
  line-height: 1.4;
  margin: 0 0 0.6em;
  letter-spacing: 0.01em;
}
p{ margin: 0 0 1.2em; }

.eyebrow{
  display:inline-flex; align-items:center; gap:8px;
  font-family: var(--font-mono);
  font-size: 12.5px; letter-spacing: 0.14em;
  color: var(--brass); text-transform: uppercase;
  margin-bottom: 14px;
}

/* ---------- octagon motif ---------- */
.octagon{ clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%); }
.octagon-mark{
  display:inline-block; width: 9px; height: 9px;
  background: var(--brass);
  clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%);
  flex: none;
}

/* ---------- header / nav ---------- */
.site-header{ background: var(--ink-navy); color: var(--paper); border-bottom: 1px solid var(--line-on-navy); position: sticky; top:0; z-index: 50; }
.site-header .wrap{ display:flex; align-items:center; justify-content:space-between; height: 76px; }
.brand{ display:flex; align-items:center; gap:12px; font-family: var(--font-display); font-size: 20px; font-weight:700; text-decoration:none; color: var(--paper); }
.brand .octagon{
  width: 30px; height: 30px; background: var(--brass);
  display:flex; align-items:center; justify-content:center;
  color: var(--ink-navy-deep); font-family: var(--font-display); font-size: 15px; font-weight:700;
}
nav.main-nav{ display:flex; gap: 26px; font-size: 14.5px; }
nav.main-nav a{ text-decoration:none; color: var(--paper); opacity: 0.82; padding: 6px 0; border-bottom: 1px solid transparent; }
nav.main-nav a:hover{ opacity:1; border-color: var(--brass); }

/* ---------- hero ---------- */
.hero{ background: linear-gradient(180deg, var(--ink-navy) 0%, var(--ink-navy-deep) 100%); color: var(--paper); padding: 78px 0 90px; position: relative; overflow: hidden; }
.hero .wrap{ display:grid; grid-template-columns: 1.15fr 0.85fr; gap: 56px; align-items:center; }
.hero h1{ color: var(--paper); font-size: clamp(30px, 4.2vw, 46px); margin-bottom: 0.5em; }
.hero h1 em{ font-style: normal; color: var(--brass-light); }
.hero p.lead{ font-size: 17.5px; color: rgba(247,243,233,0.82); max-width: 46ch; }
.hero-actions{ display:flex; gap:16px; margin-top: 30px; flex-wrap: wrap; }

.btn{
  display:inline-flex; align-items:center; gap:10px;
  padding: 14px 26px; font-family: var(--font-body);
  font-weight: 700; font-size: 15px; text-decoration:none;
  border-radius: var(--radius-s); border: 1px solid transparent; cursor:pointer;
  transition: background .18s ease, border-color .18s ease;
}
.btn-primary{ background: var(--brass); color: var(--ink-navy-deep); }
.btn-primary:hover{ background: var(--brass-light); }
.btn-ghost{ background: transparent; color: var(--paper); border-color: var(--line-on-navy); }
.btn-ghost:hover{ border-color: var(--brass); }
.btn-outline{ background: transparent; color: var(--ink-navy); border-color: var(--ink-navy); }
.btn-outline:hover{ background: var(--ink-navy); color: var(--paper); }

/* plaque illustration */
.plaque-frame{
  aspect-ratio: 1 / 1.05; max-width: 320px; margin-left: auto;
  background: var(--ink-navy-deep); border: 2px solid var(--brass);
  clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%);
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  text-align:center; padding: 30px;
}
.plaque-sub{ display:block; color: var(--brass-light); font-size: 13.5px; line-height:1.7; }

.hero-tiles{ display:grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.hero-tile{
  background: rgba(247,243,233,0.05); border: 1px solid var(--line-on-navy);
  border-radius: var(--radius-s); padding: 14px 8px; text-align:center;
}
.hero-tile .emoji{ display:block; font-size: 22px; line-height:1.4; }
.hero-tile .label{ display:block; font-size: 11.5px; color: rgba(247,243,233,0.7); }

/* ---------- sections ---------- */
section{ padding: 76px 0; }
.section-alt{ background: var(--paper-raised); border-top:1px solid var(--line); border-bottom:1px solid var(--line); }
.section-head{ max-width: 62ch; margin-bottom: 44px; }
.section-head h2{ font-size: clamp(24px, 3vw, 32px); }
.section-head p{ color: var(--charcoal-soft); margin:0; }

.grid-3{ display:grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-2{ display:grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }

.case-card, .card{
  background: var(--paper-raised); border: 1px solid var(--line);
  border-radius: var(--radius-m); padding: 30px 26px;
  box-shadow: var(--shadow-card);
  transition: transform .18s ease, box-shadow .18s ease;
}
.case-card h3, .card h3{ font-size: 18px; }
.case-card p, .card p{ color: var(--charcoal-soft); font-size: 15px; margin:0; }

.icon-badge{
  width: 44px; height: 44px; display:flex; align-items:center; justify-content:center;
  background: var(--brass-tint); border:1px solid var(--brass-light);
  font-size: 20px; margin-bottom: 18px;
  clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%);
}
.icon-badge.navy{ background: var(--brass); border-color: var(--brass); }
.icon-badge.lg{ width: 56px; height: 56px; font-size: 26px; }

/* ---------- self check panel ---------- */
.check-panel{
  background: linear-gradient(160deg, var(--ink-navy) 0%, var(--ink-navy-deep) 100%);
  color: var(--paper); border-radius: var(--radius-m);
  padding: 54px 48px; display:grid; grid-template-columns: 0.9fr 1.1fr; gap: 48px; align-items:center;
}
.check-panel h2{ color: var(--paper); }
.check-list{ list-style:none; margin:0 0 20px; padding:0; }
.check-list li{
  display:flex; gap:14px; align-items:flex-start;
  background: rgba(247,243,233,0.05); border:1px solid var(--line-on-navy);
  border-radius: var(--radius-s); padding: 14px 16px; margin-bottom: 10px;
}
.check-list input{ margin-top: 7px; accent-color: var(--brass); width:17px; height:17px; flex:none; }
.check-list label{ font-size: 14.5px; line-height:1.7; color: rgba(247,243,233,0.9); cursor:pointer; }
.check-result{
  border-left: 3px solid var(--brass); background: rgba(176,141,87,0.12);
  padding: 16px 18px; font-size: 15px; border-radius: 0 var(--radius-s) var(--radius-s) 0;
}
.check-result.is-empty{ color: rgba(247,243,233,0.55); border-left-color: var(--line-on-navy); background: transparent; }
.check-result.is-need{ border-left-color: var(--stamp-red); background: rgba(162,59,50,0.18); }

/* ---------- steps / timeline ---------- */
.steps{ list-style:none; margin:0; padding:0; counter-reset: step; }
.steps li{
  position: relative; padding: 0 0 30px 62px; counter-increment: step;
  border-left: 1px solid var(--line); margin-left: 20px;
}
.steps li:last-child{ border-left-color: transparent; padding-bottom:0; }
.steps li::before{
  content: counter(step,decimal-leading-zero);
  position:absolute; left:-20px; top:-2px;
  width:40px; height:40px; background: var(--ink-navy); color: var(--brass-light);
  font-family: var(--font-mono); font-size: 12px; font-weight:500;
  display:flex; align-items:center; justify-content:center;
  clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%);
}
.steps h3{ margin: 6px 0 6px; font-size: 18px; }
.steps p{ color: var(--charcoal-soft); font-size: 15px; margin:0; }

/* ---------- tables ---------- */
.doc-table{ width:100%; border-collapse: collapse; margin: 0 0 28px; background: var(--paper-raised); font-size: 15px; }
.doc-table th, .doc-table td{ border: 1px solid var(--line); padding: 13px 16px; text-align:left; vertical-align: top; }
.doc-table th{ background: var(--ink-navy); color: var(--paper); font-family: var(--font-display); font-weight:700; }
.doc-table tbody tr:nth-child(even){ background: #fafaf8; }
.table-scroll{ overflow-x: auto; -webkit-overflow-scrolling: touch; margin-bottom: 28px; }
.table-scroll .doc-table{ min-width: 640px; margin-bottom:0; }

/* ---------- callouts ---------- */
.callout{
  background: var(--brass-tint); border-left: 4px solid var(--brass);
  padding: 18px 22px; margin: 0 0 28px; font-size: 15px; line-height:1.8;
  border-radius: 0 var(--radius-s) var(--radius-s) 0;
}
.callout.warn{ background: #fdf1ef; border-left-color: var(--stamp-red); }
.callout a{ color: var(--stamp-red); font-weight:700; }

/* ---------- FAQ ---------- */
.faq-item{ border-bottom:1px solid var(--line); }
.faq-item summary{
  cursor:pointer; list-style:none; padding: 22px 40px 22px 0; position:relative;
  font-family: var(--font-display); font-weight:700; color: var(--ink-navy); font-size: 17px;
}
.faq-item summary::-webkit-details-marker{ display:none; }
.faq-item summary::after{
  content:"+"; position:absolute; right:6px; top:20px;
  font-family: var(--font-mono); color: var(--brass); font-size: 20px;
}
.faq-item[open] summary::after{ content:"−"; }
.faq-item p{ color: var(--charcoal-soft); font-size: 15px; padding-bottom: 8px; margin:0 0 16px; }

/* ---------- article pages ---------- */
.article-hero{ background: linear-gradient(180deg, var(--ink-navy) 0%, var(--ink-navy-deep) 100%); color: var(--paper); padding: 52px 0 58px; }
.article-hero h1{ color: var(--paper); font-size: clamp(24px, 3.4vw, 34px); }
.breadcrumb{ font-size: 13px; color: rgba(247,243,233,0.6); margin-bottom: 20px; }
.breadcrumb a{ color: var(--brass-light); text-decoration:none; }
.breadcrumb a:hover{ text-decoration:underline; }
.topic-banner{ display:flex; align-items:center; gap:20px; }
.topic-banner .icon-badge{ margin-bottom:0; flex:none; }

.article-body{ max-width: 760px; margin: 0 auto; padding: 60px 28px 80px; }
.article-body h2{ font-size: 24px; margin-top: 2em; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.article-body h2:first-child{ margin-top:0; }
.article-body h3{ font-size: 18.5px; margin-top: 1.8em; }
.article-body ul, .article-body ol{ padding-left: 1.4em; margin: 0 0 1.4em; }
.article-body li{ margin-bottom: 0.5em; }
.article-body a{ color: var(--stamp-red); }

.article-cta{
  background: var(--ink-navy); color: var(--paper);
  padding: 34px 32px; border-radius: var(--radius-m); margin-top: 56px;
  border-left: 4px solid var(--brass);
}
.article-cta h3{ color: var(--paper); margin-top:0; }
.article-cta p{ color: rgba(247,243,233,0.75); font-size: 15px; }

.updated{ font-family: var(--font-mono); font-size: 12px; color: var(--charcoal-soft); letter-spacing: .06em; margin-bottom: 34px; }

/* ---------- article index cards ---------- */
.art-grid{ display:grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.art-card{
  display:flex; flex-direction:column; gap:8px;
  background: var(--paper-raised); border:1px solid var(--line); border-radius: var(--radius-m);
  padding: 26px 24px; text-decoration:none; color: inherit;
  box-shadow: var(--shadow-card);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.art-card:hover{ transform: translateY(-3px); box-shadow: var(--shadow-card-hover); border-color: var(--brass-light); }
.art-card .tag{
  align-self:flex-start; font-family: var(--font-mono); font-size: 11px; letter-spacing:.1em;
  background: var(--brass-tint); color: var(--brass); border:1px solid var(--brass-light);
  padding: 3px 10px; border-radius: 100px;
}
.art-card .tag.biz{ background: rgba(20,33,61,0.06); color: var(--ink-navy); border-color: rgba(20,33,61,0.2); }
.art-card h3{ margin: 4px 0 0; font-size: 17px; }
.art-card p{ color: var(--charcoal-soft); font-size: 14px; margin:0; }

.route-head{ display:flex; align-items:baseline; gap:14px; margin: 60px 0 26px; }
.route-head h2{ margin:0; font-size: 22px; }
.route-head .rule{ flex:1; height:1px; background: var(--line); }

/* ---------- profit simulator ---------- */
.sim{
  background: var(--paper-raised); border:1px solid var(--line); border-radius: var(--radius-m);
  padding: 30px 28px; box-shadow: var(--shadow-card); margin-bottom: 30px;
}
.sim-grid{ display:grid; grid-template-columns: repeat(2, 1fr); gap: 18px 22px; }
.sim-field{ display:flex; flex-direction:column; gap:6px; }
.sim-field label{ font-size: 13.5px; font-weight:700; color: var(--ink-navy); }
.sim-field input, .sim-field select{
  font-family: var(--font-mono); font-size: 15px; padding: 11px 12px;
  border:1px solid var(--line); border-radius: var(--radius-s); background:#fff; color: var(--charcoal);
}
.sim-field small{ color: var(--charcoal-soft); font-size: 12px; }
.sim-out{
  margin-top: 26px; background: var(--ink-navy); color: var(--paper);
  border-radius: var(--radius-m); padding: 26px 24px;
  display:grid; grid-template-columns: repeat(3,1fr); gap: 18px; text-align:center;
}
.sim-out .cell .k{ display:block; font-size: 12px; color: rgba(247,243,233,0.6); letter-spacing:.08em; }
.sim-out .cell .v{ display:block; font-family: var(--font-mono); font-size: 25px; font-weight:500; color: var(--brass-light); margin-top:4px; }
.sim-out .cell .v.neg{ color: #e08b83; }
.sim-note{ font-size: 13.5px; color: var(--charcoal-soft); margin-top: 14px; }
.sim-break{ margin-top: 18px; border-top:1px dashed var(--line); padding-top: 16px; font-size: 14px; color: var(--charcoal-soft); }
.sim-break span{ font-family: var(--font-mono); color: var(--ink-navy); font-weight:500; }

/* ---------- form guide (shorui-sakusei) ---------- */
.tool-shell{ max-width: 860px; margin: 0 auto; padding: 0 28px 80px; }
.guide-section{ margin-top: 54px; }
.step-label{ font-family: var(--font-mono); font-size: 12px; letter-spacing:.12em; color: var(--brass); margin:0 0 6px; }
.step-hint{ color: var(--charcoal-soft); font-size: 15px; }
.form-preview{ position: relative; border:1px solid var(--line); box-shadow: var(--shadow-card); background:#fff; }
.field-band{ position:absolute; left:0; right:0; background: rgba(176,141,87,0.18); border-top:1px solid var(--brass); border-bottom:1px solid var(--brass); }
.field-band .num{
  position:absolute; left:-14px; top:50%; transform: translateY(-50%);
  width: 26px; height:26px; background: var(--stamp-red); color:#fff;
  font-family: var(--font-mono); font-size: 12px;
  display:flex; align-items:center; justify-content:center; border-radius: 50%;
}
.field-legend{ list-style:none; padding:0; margin: 22px 0 0; }
.field-legend li{ display:flex; gap:12px; align-items:flex-start; padding: 10px 0; border-bottom:1px dashed var(--line); font-size: 15px; }
.field-legend .num{
  flex:none; width:24px; height:24px; background: var(--stamp-red); color:#fff;
  font-family: var(--font-mono); font-size: 12px;
  display:flex; align-items:center; justify-content:center; border-radius:50%; margin-top:4px;
}
.toggle-row{ background: var(--paper-raised); border:1px solid var(--line); border-radius: var(--radius-m); padding: 20px 22px; margin-top: 24px; }
.toggle-row > label{ display:block; font-weight:700; color: var(--ink-navy); margin-bottom: 12px; font-size: 15px; }
.radio-pair{ display:flex; gap: 12px; }
.option-card{ border:1px solid var(--line); border-radius: var(--radius-s); padding: 10px 18px; cursor:pointer; font-size: 14.5px; }
.option-card:has(input:checked){ border-color: var(--brass); background: var(--brass-tint); }

/* ---------- footer ---------- */
.site-footer{ background: var(--ink-navy-deep); color: var(--paper); padding: 60px 0 0; }
.site-footer .wrap{ display:grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; padding-bottom: 44px; }
.site-footer h4{ color: var(--brass-light); font-size: 15px; }
.site-footer ul{ list-style:none; padding:0; margin:0; }
.site-footer li{ margin-bottom: 9px; }
.site-footer a{ color: rgba(247,243,233,0.72); text-decoration:none; font-size: 14px; }
.site-footer a:hover{ color: var(--brass-light); }
.footer-note{
  border-top: 1px solid var(--line-on-navy); padding: 20px 28px 40px !important;
  color: rgba(247,243,233,0.5); font-size: 12.5px; display:block !important; max-width: var(--maxw);
}

/* ---------- ad slots (広告枠) ---------- */
.ad-slot{
  max-width: 760px; margin: 40px auto; padding: 0 28px;
}
.ad-slot .inner{
  border: 1px dashed var(--line); border-radius: var(--radius-s);
  min-height: 100px; display:flex; align-items:center; justify-content:center;
  color: #b9b6ae; font-family: var(--font-mono); font-size: 11px; letter-spacing:.1em;
  background: #fbfbf9;
}

/* ---------- responsive ---------- */
@media (max-width: 900px){
  .hero .wrap{ grid-template-columns: 1fr; gap: 40px; }
  .plaque-frame{ margin-left: 0; }
  .check-panel{ grid-template-columns: 1fr; padding: 36px 26px; gap: 30px; }
  .grid-3, .grid-2, .art-grid{ grid-template-columns: 1fr; }
  .site-footer .wrap{ grid-template-columns: 1fr; gap: 30px; }
  .sim-grid{ grid-template-columns: 1fr; }
  .sim-out{ grid-template-columns: 1fr; gap: 16px; }
}
@media (max-width: 720px){
  body{ font-size: 16px; }
  .site-header .wrap{ height: auto; flex-direction: column; gap: 10px; padding: 14px 20px; }
  nav.main-nav{ gap: 16px; flex-wrap: wrap; justify-content:center; font-size: 13.5px; }
  section{ padding: 54px 0; }
  .wrap{ padding: 0 20px; }
  .article-body{ padding: 40px 20px 60px; }
  .hero{ padding: 52px 0 60px; }
  .hero-tiles{ grid-template-columns: repeat(3, 1fr); }
  .site-header{ position: static; }
}
