:root {
  --ink: #10233f;
  --muted: #5f6f82;
  --blue: #0057a8;
  --navy: #002d62;
  --sky: #edf6ff;
  --line: #dbe5ef;
  --canvas: #f5f8fb;
  --card: #ffffff;
  --success: #087a49;
  --danger: #b42318;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--canvas);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--canvas); }
button, input, textarea { font: inherit; }
a { color: inherit; }
button { cursor: pointer; }

.site-header {
  height: 72px;
  padding: 0 max(24px, calc((100vw - 1180px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  color: #fff;
  background: linear-gradient(110deg, #002b5c 0%, #0057a8 100%);
  box-shadow: 0 2px 12px rgb(0 35 75 / 20%);
}
.brand { display: inline-flex; align-items: center; gap: 12px; color: #fff; font-weight: 700; text-decoration: none; letter-spacing: -.02em; }
.brand-mark { padding: 5px 9px; border: 2px solid #fff; font-size: 16px; font-weight: 900; letter-spacing: .04em; line-height: 1; }
.header-link { color: #dceeff; font-size: 14px; text-decoration: none; }
.header-link:hover { color: #fff; text-decoration: underline; }

.page-shell { max-width: 1180px; margin: 0 auto; padding: 52px 24px 72px; }
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, .65fr); gap: 28px; align-items: end; padding: 44px; border-radius: 24px; color: #fff; background: radial-gradient(circle at 85% 10%, #2a8dde 0, transparent 30%), linear-gradient(120deg, #002d62, #0057a8); box-shadow: 0 20px 50px rgb(0 45 98 / 18%); }
.eyebrow { margin: 0 0 10px; color: #67c3ff; font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
h1 { max-width: 710px; margin: 0; font-size: clamp(32px, 5vw, 53px); line-height: 1.08; letter-spacing: -.045em; }
.hero p:not(.eyebrow) { max-width: 620px; margin: 18px 0 0; color: #dceeff; font-size: 17px; line-height: 1.65; }
.hero-metric { padding: 24px; border: 1px solid rgb(255 255 255 / 27%); border-radius: 18px; background: rgb(255 255 255 / 9%); backdrop-filter: blur(12px); }
.hero-metric strong { display: block; font-size: 40px; letter-spacing: -.06em; }
.hero-metric span { color: #dceeff; font-size: 14px; }

.catalog-controls { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; margin: 34px 0 22px; }
.search { display: flex; align-items: center; gap: 11px; min-height: 52px; padding: 0 17px; border: 1px solid var(--line); border-radius: 14px; background: #fff; box-shadow: 0 4px 14px rgb(17 55 91 / 5%); }
.search svg { width: 19px; fill: none; stroke: var(--muted); stroke-width: 2; }
.search input { width: 100%; border: 0; outline: 0; color: var(--ink); background: transparent; }
.search input::placeholder { color: #8b9aad; }
.filter-label { color: var(--muted); font-size: 14px; white-space: nowrap; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 8px 12px; border: 1px solid var(--line); border-radius: 999px; color: #4b6078; background: #fff; font-size: 13px; font-weight: 700; }
.chip:hover, .chip.active { border-color: #9bc9ef; color: #004f99; background: #e9f5ff; }

.catalog-meta { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 24px 0 14px; color: var(--muted); font-size: 14px; }
.catalog-meta strong { color: var(--ink); }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.product-card { display: flex; min-width: 0; flex-direction: column; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: var(--card); box-shadow: 0 6px 20px rgb(28 61 95 / 5%); transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.product-card:hover { transform: translateY(-4px); border-color: #a8d0ee; box-shadow: 0 16px 35px rgb(28 61 95 / 13%); }
.product-image { position: relative; display: grid; height: 205px; place-items: center; overflow: hidden; background: linear-gradient(135deg, #f0f5f9, #fff); }
.product-image img { width: 100%; height: 100%; object-fit: contain; padding: 18px; }
.product-image .image-placeholder { font-weight: 800; color: #94a5b7; }
.category-badge { position: absolute; top: 14px; left: 14px; max-width: calc(100% - 28px); padding: 5px 9px; overflow: hidden; border: 1px solid rgb(255 255 255 / 80%); border-radius: 999px; color: #31506e; background: rgb(255 255 255 / 88%); font-size: 11px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; backdrop-filter: blur(6px); }
.product-body { display: flex; flex: 1; flex-direction: column; padding: 21px; }
.product-body h2 { margin: 0; font-size: 20px; line-height: 1.22; letter-spacing: -.025em; }
.product-body .subtitle { min-height: 20px; margin: 5px 0 0; color: var(--blue); font-size: 13px; font-weight: 700; }
.product-description { display: -webkit-box; min-height: 66px; margin: 12px 0 0; overflow: hidden; color: var(--muted); font-size: 14px; line-height: 1.55; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.card-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 18px; }
.document-count { color: #607b95; font-size: 12px; font-weight: 700; }
.text-link { border: 0; color: var(--blue); background: transparent; font-size: 14px; font-weight: 800; }
.text-link:hover { color: var(--navy); text-decoration: underline; }

.empty { padding: 50px 24px; border: 1px dashed #b9cadb; border-radius: 18px; color: var(--muted); text-align: center; background: #fff; }
.loading-shell { display: grid; min-height: 60vh; place-content: center; gap: 12px; color: var(--muted); text-align: center; }
.spinner { width: 32px; height: 32px; margin: auto; border: 3px solid #bfdbef; border-top-color: var(--blue); border-radius: 50%; animation: rotate .75s linear infinite; }
@keyframes rotate { to { transform: rotate(360deg); } }

.detail-back { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 24px; border: 0; color: var(--blue); background: transparent; font-weight: 800; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(300px, .95fr); gap: 42px; align-items: start; }
.gallery { overflow: hidden; border: 1px solid var(--line); border-radius: 20px; background: #fff; }
.gallery-main { display: grid; min-height: 410px; place-items: center; background: linear-gradient(135deg, #f1f7fa, #fff); }
.gallery-main img { width: 100%; height: 410px; object-fit: contain; padding: 28px; }
.gallery-thumbs { display: flex; gap: 9px; padding: 13px; overflow-x: auto; border-top: 1px solid var(--line); }
.gallery-thumb { width: 62px; height: 52px; flex: 0 0 auto; padding: 4px; border: 2px solid transparent; border-radius: 8px; background: #fff; }
.gallery-thumb.active { border-color: var(--blue); }
.gallery-thumb img { width: 100%; height: 100%; object-fit: contain; }
.detail-copy h1 { font-size: clamp(31px, 4vw, 44px); color: var(--navy); }
.detail-copy .lead { margin: 17px 0; color: var(--muted); line-height: 1.7; white-space: pre-line; }
.detail-copy .category { display: inline-block; margin-bottom: 12px; padding: 6px 10px; border-radius: 999px; color: #075aa3; background: #e7f4ff; font-size: 12px; font-weight: 800; }
.detail-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 24px 0; }
.button { display: inline-flex; min-height: 43px; align-items: center; justify-content: center; padding: 10px 16px; border: 1px solid transparent; border-radius: 10px; font-weight: 800; text-decoration: none; transition: transform .15s ease, background .15s ease; }
.button:hover { transform: translateY(-1px); }
.button.primary { color: #fff; background: var(--blue); }
.button.primary:hover { background: var(--navy); }
.button.secondary { border-color: #b8ccde; color: #214866; background: #fff; }
.button.secondary:hover { border-color: #7597b5; }
.document-panel { margin-top: 30px; padding: 21px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.document-panel h2 { margin: 0; font-size: 20px; }
.document-panel > p { margin: 7px 0 15px; color: var(--muted); font-size: 14px; }
.document-list { margin: 0; padding: 0; list-style: none; }
.document-list li { display: flex; align-items: center; gap: 11px; padding: 11px 0; border-top: 1px solid #edf1f5; }
.document-list label { display: flex; flex: 1; align-items: center; gap: 10px; min-width: 0; color: #294964; font-size: 14px; }
.document-list label span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.document-list a { color: var(--blue); font-size: 13px; font-weight: 800; }
.select-all { margin-top: 15px; }

.inquiry-dialog { width: min(680px, calc(100vw - 32px)); max-height: min(760px, calc(100vh - 32px)); padding: 0; overflow: auto; border: 0; border-radius: 18px; color: var(--ink); box-shadow: 0 24px 90px rgb(0 26 55 / 35%); }
.inquiry-dialog::backdrop { background: rgb(0 27 57 / 58%); backdrop-filter: blur(3px); }
.inquiry-dialog form { padding: 26px; }
.dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.dialog-heading h2 { margin: 0; font-size: 25px; letter-spacing: -.03em; }
.dialog-heading .eyebrow { margin-bottom: 5px; color: var(--blue); }
.icon-button { width: 35px; height: 35px; border: 1px solid var(--line); border-radius: 50%; color: #52697f; background: #fff; font-size: 25px; line-height: 1; }
.dialog-product { margin: 13px 0 22px; padding: 10px 12px; border-radius: 9px; color: #075aa3; background: #edf7ff; font-weight: 800; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid label { display: grid; gap: 7px; color: #3b536b; font-size: 13px; font-weight: 800; }
.form-grid .full { grid-column: 1 / -1; }
.form-grid input, .form-grid textarea { width: 100%; padding: 10px 11px; border: 1px solid #bed0e1; border-radius: 9px; color: var(--ink); background: #fff; outline: none; font-weight: 500; }
.form-grid input:focus, .form-grid textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgb(0 87 168 / 12%); }
.consent { display: flex; gap: 9px; margin-top: 17px; color: #4f657b; font-size: 13px; line-height: 1.4; }
.consent input { margin-top: 2px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }
.form-message { min-height: 20px; margin: 13px 0 0; color: var(--muted); font-size: 13px; }
.form-message.error { color: var(--danger); }
.form-message.success { color: var(--success); }
.honeypot { position: absolute; left: -10000px; width: 1px; height: 1px; opacity: 0; }

@media (max-width: 840px) {
  .hero, .detail-grid { grid-template-columns: 1fr; }
  .hero { padding: 31px; }
  .hero-metric { max-width: 220px; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .site-header { height: 64px; padding: 0 16px; }
  .header-link { display: none; }
  .page-shell { padding: 25px 16px 50px; }
  .hero { padding: 26px; border-radius: 18px; }
  .catalog-controls { grid-template-columns: 1fr; }
  .catalog-meta { align-items: flex-start; flex-direction: column; }
  .product-grid { grid-template-columns: 1fr; }
  .gallery-main, .gallery-main img { height: 300px; min-height: 300px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .full { grid-column: auto; }
  .inquiry-dialog form { padding: 20px; }
}
