:root {
  --ink: #14191f;
  --muted: #64707c;
  --line: #dbe2e8;
  --soft: #f4f7f9;
  --panel: #fff;
  --brand: #1683bd;
  --brand-deep: #0c5f8d;
  --accent: #ef7d23;
  --ok: #16824b;
  --warn: #b47500;
  --wait: #a93232;
  --radius: 18px;
  --shadow: 0 12px 35px rgba(20, 25, 31, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  background: #fff;
}
button, input, select { font: inherit; }
.shell { width: min(1180px, calc(100% - 32px)); margin: auto; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  height: 72px;
  border-bottom: 1px solid rgba(255, 255, 255, .14);
  background: #10161c;
  color: #fff;
}
.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.brandmark {
  display: flex;
  align-items: center;
  color: #fff;
  text-decoration: none;
}
.brandmark img {
  display: block;
  width: 154px;
  max-height: 64px;
  object-fit: contain;
}
.pdf-link {
  color: #fff;
  text-decoration: none;
  border: 1px solid #52616d;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 13px;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 58px 0 28px;
  color: #fff;
  background: linear-gradient(135deg, #111820 0%, #182631 58%, #0d5b84 100%);
}
.hero::after {
  content: "K'SPEC";
  position: absolute;
  right: -20px;
  top: 0;
  color: rgba(255, 255, 255, .035);
  font-size: 150px;
  font-weight: 900;
  letter-spacing: -.05em;
  pointer-events: none;
}
.eyebrow, .section-label {
  margin: 0 0 10px;
  color: #76c4ed;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .2em;
}
.hero h1 {
  margin: 0 0 14px;
  font-size: clamp(30px, 4.8vw, 54px);
  letter-spacing: -.04em;
}
.lead {
  margin: 0 0 28px;
  color: #d1dde5;
  font-size: 16px;
  line-height: 1.8;
}

.search-panel {
  position: relative;
  z-index: 1;
  padding: 18px;
  color: var(--ink);
  background: #fff;
  border-radius: 22px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, .25);
}
.method-head {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 5px 12px;
  margin: 0 0 10px;
}
.method-label {
  margin: 0;
  color: #3e4b56;
  font-size: 14px;
  font-weight: 900;
}
.method-description {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}
.search-box {
  display: grid;
  grid-template-columns: 1fr auto;
  overflow: hidden;
  background: #fff;
  border: 2px solid #cdd7df;
  border-radius: 15px;
}
.search-box:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(22, 131, 189, .13);
}
.search-box input {
  min-width: 0;
  padding: 18px;
  border: 0;
  outline: 0;
  font-size: 18px;
}
.search-box button {
  padding: 0 28px;
  color: #fff;
  background: var(--brand);
  border: 0;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}
.search-hint {
  margin: 8px 2px 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}
.drilldown-search {
  padding-top: 15px;
  margin-top: 14px;
  border-top: 1px solid var(--line);
}
.filters {
  display: grid;
  grid-template-columns: 1.05fr 1.05fr 1.15fr .8fr auto;
  gap: 10px;
}
.filters label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}
.filters select {
  width: 100%;
  min-height: 44px;
  padding: 0 34px 0 12px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
}
.filters select:disabled {
  color: #9aa5ad;
  background: #f3f5f6;
}
.filter-actions {
  align-self: end;
  display: flex;
  gap: 8px;
}
.filter-search-btn,
.clear-btn {
  height: 44px;
  padding: 0 16px;
  border-radius: 10px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}
.filter-search-btn {
  color: #fff;
  background: var(--brand);
  border: 1px solid var(--brand);
}
.filter-search-btn:hover { background: var(--brand-deep); border-color: var(--brand-deep); }
.clear-btn {
  color: var(--muted);
  background: #f7f9fa;
  border: 1px solid var(--line);
}
.status-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
  padding: 14px 2px 0;
  color: #d4e0e8;
  font-size: 12px;
}
.status-strip strong { color: #fff; }
.status-strip .ok {
  padding: 4px 8px;
  color: #fff;
  background: #197448;
  border-radius: 999px;
}
.status-strip .warn, .status-error {
  padding: 4px 8px;
  color: #fff;
  background: #7c2f2f;
  border-radius: 999px;
}

.results-section {
  min-height: 430px;
  scroll-margin-top: 16px;
  padding: 42px 0 64px;
  background: var(--soft);
}
.results-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
  margin-bottom: 20px;
}
.section-label { color: var(--brand-deep); }
.results-head h2 { margin: 0; font-size: 26px; }
.result-count { color: var(--muted); font-size: 15px; font-weight: 800; }
.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.product-card {
  padding: 20px;
  background: var(--panel);
  border: 1px solid #e2e8ed;
  border-radius: var(--radius);
  box-shadow: 0 6px 20px rgba(20, 25, 31, .035);
}
.card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}
.brand-tag {
  display: inline-block;
  padding: 5px 9px;
  color: var(--brand-deep);
  background: #e7f3f9;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 900;
}
.category-tag {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}
.stock {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border-radius: 10px;
  white-space: nowrap;
}
.stock span { font-size: 22px; line-height: 1; }
.stock strong { font-size: 12px; }
.stock.ready { color: var(--ok); background: #e7f6ee; }
.stock.confirm { color: var(--warn); background: #fff4da; }
.stock.wait { color: var(--wait); background: #fae9e9; }
.stock.order {
  min-height: 38px;
  color: #704708;
  background: #fff4d8;
  border: 1px solid #e9c979;
}
.stock.order strong { font-size: 13px; }
.product-card h3 {
  margin: 18px 0 8px;
  font-size: 17px;
  line-height: 1.55;
}
.product-flags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 0 0 10px;
}
.made-to-order-tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  color: #704708;
  background: #fff4d8;
  border: 1px solid #e9c979;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}
.catalog-note {
  margin: 0 0 14px;
  color: #704708;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.55;
}
.price {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 16px;
}
.price-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.price-value {
  font-size: 20px;
  font-weight: 900;
}
.meta {
  display: grid;
  gap: 7px;
  padding-top: 12px;
  margin: 0;
  border-top: 1px solid var(--line);
}
.meta div {
  display: grid;
  grid-template-columns: 94px 1fr;
  gap: 10px;
  font-size: 12px;
}
.meta dt { color: var(--muted); }
.meta dd { margin: 0; overflow-wrap: anywhere; }
.meta .arrival dd { color: var(--wait); font-weight: 800; }
.meta .made-to-order-lead-time { margin-top: 3px; padding: 9px 10px; background: #fff7e8; border: 1px solid #efd39b; border-radius: 8px; }
.meta .made-to-order-lead-time dt { color: #76500b; font-weight: 900; }
.meta .made-to-order-lead-time dd { color: #5d3c00; font-weight: 800; line-height: 1.6; white-space: pre-line; }
.empty, .loading {
  padding: 36px;
  color: var(--muted);
  text-align: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.empty strong {
  display: block;
  margin-bottom: 10px;
  color: var(--ink);
  font-size: 18px;
}
.empty a { color: var(--brand-deep); }
.examples {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 16px 0;
}
.examples button {
  padding: 8px 12px;
  color: var(--brand-deep);
  background: #f3f9fc;
  border: 1px solid #bed4e0;
  border-radius: 999px;
  cursor: pointer;
}
.loading span {
  display: inline-block;
  width: 18px;
  height: 18px;
  margin-right: 8px;
  vertical-align: -4px;
  border: 2px solid #ccd6dd;
  border-top-color: var(--brand);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-top: 24px;
}
.pager button {
  padding: 11px 18px;
  color: #fff;
  background: #17212a;
  border: 0;
  border-radius: 10px;
  font-weight: 800;
  cursor: pointer;
}
.pager span { color: var(--muted); font-size: 13px; }

.guide { padding: 54px 0; background: #fff; }
.guide-grid {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  align-items: start;
  gap: 50px;
}
.guide h2 { margin-top: 0; font-size: 26px; }
.guide p { color: var(--muted); line-height: 1.9; }
.guide .order-guide {
  padding: 12px 14px;
  color: #704708;
  background: #fff8e7;
  border: 1px solid #ead7a3;
  border-radius: 12px;
  font-size: 12px;
  line-height: 1.75;
}
.guide dl {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 0;
}
.guide dl div {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 15px;
}
.guide dt { font-size: 30px; font-weight: 900; }
.guide dd { margin: 4px 0 0; }
.guide dd strong, .guide dd span { display: block; }
.guide dd span { margin-top: 5px; color: var(--muted); font-size: 11px; }

footer { padding: 26px 0; color: #9faab3; background: #10161c; }
footer .shell {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
footer p { margin: 0; color: #fff; font-weight: 800; }
footer a { color: #b8c7d1; font-size: 12px; }

@media (max-width: 920px) {
  .filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filter-actions { grid-column: 1 / -1; justify-content: flex-end; }
}

@media (max-width: 760px) {
  .shell { width: min(100% - 24px, 1180px); }
  .site-header { height: 64px; }
  .brandmark img { width: 126px; max-height: 56px; }
  .pdf-link { padding: 8px 10px; font-size: 11px; }
  .hero { padding: 38px 0 20px; }
  .hero::after { right: -40px; font-size: 80px; }
  .hero h1 { font-size: clamp(27px, 8vw, 38px); line-height: 1.25; }
  .lead { margin-bottom: 22px; font-size: 14px; }
  .search-panel { padding: 12px; border-radius: 17px; }
  .search-box input { padding: 15px 13px; font-size: 16px; }
  .search-box button { padding: 0 18px; }
  .status-strip { gap: 7px 12px; font-size: 11px; }
  .results-section { padding: 30px 0 48px; }
  .results-head h2 { font-size: 21px; }
  .grid { grid-template-columns: 1fr; }
  .product-card { padding: 17px; }
  .product-card h3 { font-size: 16px; }
  .stock { padding: 6px 8px; }
  .guide { padding: 40px 0; }
  .guide-grid { grid-template-columns: 1fr; gap: 20px; }
  .guide dl { grid-template-columns: 1fr; }
  .guide dl div {
    display: grid;
    grid-template-columns: 42px 1fr;
    align-items: center;
    gap: 8px;
  }
  .guide dt { font-size: 24px; }
  .guide dd { margin: 0; }
  footer .shell { display: grid; justify-items: center; text-align: center; }
  .meta div { grid-template-columns: 88px 1fr; }
}

@media (max-width: 430px) {
  .filters { grid-template-columns: 1fr; }
  .filter-actions { grid-column: auto; display: grid; grid-template-columns: 1fr; }
  .filter-search-btn, .clear-btn { width: 100%; }
  .search-box button { padding: 0 14px; }
  .result-count { font-size: 12px; }
  .card-top { align-items: flex-start; }
  .stock strong { display: none; }
  .stock.order strong { display: inline; }
}

/* v0.4.0 search suggestions */
.search-autocomplete { position: relative; }
.suggestions {
  position: absolute;
  z-index: 30;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: min(420px, 58vh);
  overflow: auto;
  padding: 6px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 18px 45px rgba(16, 35, 50, .18);
}
.suggestions[hidden] { display: none; }
.suggestion-item {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 11px 12px;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-radius: 10px;
  text-align: left;
  cursor: pointer;
}
.suggestion-item:hover,
.suggestion-item.active { background: #eef7fb; }
.suggestion-label { overflow: hidden; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.suggestion-meta { color: var(--muted); font-size: 11px; white-space: nowrap; }
@media (max-width: 600px) {
  .suggestion-item { grid-template-columns: 1fr; gap: 2px; }
  .suggestion-meta { white-space: normal; }
}

.app-version{display:block;margin-top:.55rem;font-size:.72rem;letter-spacing:.08em;opacity:.55}

/* v1.1.4 operator-managed public notice tile */
.public-notice-tile {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  align-items: flex-start;
  margin: 0 0 18px;
  padding: 17px 18px;
  color: #4f3a08;
  background: linear-gradient(135deg, #fff8e6 0%, #fff1c9 100%);
  border: 1px solid rgba(224, 173, 52, .72);
  border-radius: 17px;
  box-shadow: 0 12px 32px rgba(43, 28, 3, .12);
}
.public-notice-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  color: #fff;
  background: #b87700;
  border-radius: 50%;
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
}
.public-notice-label {
  margin: 0 0 4px;
  color: #9a6700;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .18em;
}
.public-notice-tile h2 {
  margin: 0 0 6px;
  color: #4b3503;
  font-size: 17px;
  line-height: 1.4;
}
.public-notice-tile p:last-child {
  margin: 0;
  color: #604b1d;
  font-size: 13px;
  line-height: 1.75;
  overflow-wrap: anywhere;
}
@media (max-width: 600px) {
  .public-notice-tile { grid-template-columns: 34px minmax(0,1fr); gap: 11px; padding: 14px; border-radius: 14px; }
  .public-notice-icon { width: 32px; height: 32px; font-size: 18px; }
  .public-notice-tile h2 { font-size: 15px; }
  .public-notice-tile p:last-child { font-size: 12px; }
}
