/* Shared layout system — loaded after page-specific styles on every HTML file. */
:root {
  --maxw: 1180px;
  --pad: clamp(20px, 4vw, 48px);
  --space-section: clamp(72px, 9vw, 128px);
  --space-stack: 24px;
  --ui-border: #e1e4df;
  --ui-surface: #fff;
  --ui-ink: #142622;
  --ui-muted: #67736f;
  --ui-action: #eb6948;
}

body { color: var(--ui-ink); background: #f6f6f2; }
.container { max-width: var(--maxw); padding-left: var(--pad); padding-right: var(--pad); }
.section { padding-top: var(--space-section); padding-bottom: var(--space-section); }
.section-sm { padding-top: 56px; padding-bottom: 56px; }
.section-head { align-items: flex-start; gap: 28px; margin-bottom: 46px; }
.section-head > * { margin-top: 0; }
.section-head .desc { max-width: 420px; color: var(--ui-muted); line-height: 1.78; }

/* One button rhythm: all calls-to-action have the same height, alignment and contrast. */
.btn, .cta-start { min-height: 46px; box-sizing: border-box; border-radius: 0; display: inline-flex; align-items: center; justify-content: center; font: 600 13px/1 var(--font-sans); letter-spacing: 0; }
.btn { padding: 0 20px; }
.cta-start { padding: 0 17px; background: var(--ui-action); color: #fff; }
.btn-primary { background: var(--ui-action); color: #fff; }
.btn-secondary { border-color: var(--ui-ink); color: var(--ui-ink); background: transparent; }
.nav-links > li > a { font-size: 11px; letter-spacing: .04em; }
.lang-switcher .lang-btn { min-height: 38px; font-size: 11px; }

/* A limited set of intentional gaps replaces per-page spacing tweaks. */
.card-grid, .cap-grid, .cat-grid, .prod-grid, .innov-grid, .case-grid { gap: 16px; }
.card, .cap-card, .cat-card, .prod-card, .innov-card, .case-card { border-radius: 0; box-shadow: none; }
.card:hover, .cap-card:hover, .cat-card:hover, .prod-card:hover, .innov-card:hover, .case-card:hover { transform: none; box-shadow: none; }
.card, .innov-card, .case-card, .prod-card { border-color: var(--ui-border); }
.home-rebuild .case-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; }
.home-rebuild .case-card, .home-rebuild .case-card.featured { grid-column: auto; grid-row: auto; display: flex; flex-direction: column; }
.home-rebuild .case-card .thumb { height: 205px; flex: 0 0 205px; overflow: hidden; }
.home-rebuild .case-card .thumb img { height: 100%; width: 100%; object-fit: cover; }
.home-rebuild .case-card .body { flex: 1; padding: 22px; }
.home-rebuild .stat { min-height: 0; padding: 22px 14px; }
.home-rebuild .stat .num { font-size: clamp(42px, 4vw, 54px); line-height: 1; }
.home-rebuild .stat .label { margin-top: 10px; }
.home-rebuild .card-grid[style*="repeat(4"] { gap: 16px !important; }

/* Homepage application categories use the same generated visual language as the product overview. */
.home-rebuild .cat-grid {
  gap: 16px;
  background: transparent;
  border: 0;
}
.home-rebuild .cat-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-height: 0;
  overflow: hidden;
  background: var(--ui-surface);
  border: 1px solid var(--ui-border);
}
.home-rebuild .cat-card .thumb {
  display: block;
  height: 176px;
  flex: 0 0 176px;
  overflow: hidden;
  background: #e7eae5;
  border-bottom: 1px solid var(--ui-border);
}
.home-rebuild .cat-card .thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.84) contrast(1.02);
}
.home-rebuild .cat-card .body { display: flex; flex: 1; flex-direction: column; padding: 20px 20px 22px; }
.home-rebuild .cat-card h3 { margin: 18px 0 9px; font-size: 22px; line-height: 1.22; }
.home-rebuild .cat-card .desc { min-height: 44px; margin: 0 0 20px; }
.home-rebuild .cat-card .more { margin-top: auto; }

/* Inner-page heroes and regular sections use a quiet, predictable rhythm. */
.hero { padding-top: clamp(64px, 8vw, 110px); padding-bottom: clamp(64px, 8vw, 110px); }
.hero-grid { gap: clamp(32px, 6vw, 88px); align-items: center; }
.hero .lead { line-height: 1.8; }
.hero-meta { margin-top: 42px; padding-top: 18px; gap: 20px; }

/* Normalize common inline layout wrappers without changing page content. */
.section [style*="margin-top:32px"] { margin-top: 28px !important; }
.section [style*="margin-top:48px"] { margin-top: 40px !important; }
.section [style*="margin-top:64px"] { margin-top: 48px !important; }
.section [style*="gap:18px"] { gap: 16px !important; }
.section [style*="gap:20px"] { gap: 16px !important; }

/* Product overview: AI art supplies a clear visual entry point for each application. */
.product-overview .cat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  background: transparent;
  border: 0;
}
.product-overview .cat-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-height: 0;
  overflow: hidden;
  background: var(--ui-surface);
  border: 1px solid var(--ui-border);
}
.product-overview .cat-card .thumb {
  display: block;
  height: 176px;
  overflow: hidden;
  background: #e7eae5;
  border-bottom: 1px solid var(--ui-border);
}
.product-overview .cat-card .thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.84) contrast(1.02);
  transition: transform .35s ease, filter .35s ease;
}
.product-overview .cat-card:hover { background: var(--ui-surface); }
.product-overview .cat-card:hover .thumb img { transform: scale(1.035); filter: saturate(.96) contrast(1.02); }
.product-overview .cat-card .body { display: flex; flex: 1; flex-direction: column; padding: 20px 20px 22px; }
.product-overview .cat-card h3 { margin: 18px 0 9px; font-size: 22px; line-height: 1.22; }
.product-overview .cat-card .desc { min-height: 44px; margin: 0 0 20px; }
.product-overview .cat-card .more { margin-top: auto; }

@media (max-width: 760px) {
  .section { padding-top: 64px; padding-bottom: 64px; }
  .section-sm { padding-top: 44px; padding-bottom: 44px; }
  .section-head { display: block; margin-bottom: 30px; }
  .section-head .desc { margin-top: 16px; }
  .btn, .cta-start { min-height: 44px; }
  .hero-grid { gap: 30px; }
  .home-rebuild .cat-grid { gap: 12px; }
  .home-rebuild .cat-card .thumb { height: 150px; flex-basis: 150px; }
  .product-overview .cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 480px) {
  .product-overview .cat-grid { grid-template-columns: 1fr; }
}

/* 2026-10-08: one clear process carousel and a compact evidence-led contact area. */
.home-process .process-carousel {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, .85fr);
  min-height: 430px;
  border: 1px solid var(--ui-border);
  background: var(--ui-surface);
}
.process-carousel-visual { position: relative; min-height: 430px; overflow: hidden; background: #dce2df; }
.process-carousel-visual img { display: block; width: 100%; height: 100%; min-height: inherit; object-fit: cover; transition: opacity .22s ease; }
.process-counter { position: absolute; right: 18px; bottom: 18px; padding: 8px 12px; color: #fff; background: rgba(16,35,31,.8); font: 12px/1 var(--font-mono); }
.process-counter b { color: #ff7957; }
.process-carousel-copy { display: flex; flex-direction: column; justify-content: center; padding: clamp(24px, 4vw, 48px); }
.process-carousel-copy h3 { margin: 12px 0; font-size: clamp(26px, 3vw, 38px); line-height: 1.15; }
.process-carousel-copy > p { min-height: 52px; color: var(--ui-muted); line-height: 1.7; }
.process-carousel-copy > .text-link { align-self: flex-start; margin-top: 10px; }
.process-carousel-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 28px; }
.process-carousel-tabs button { display: flex; align-items: center; gap: 10px; min-height: 42px; padding: 8px 10px; border: 1px solid var(--ui-border); background: #fff; color: var(--ui-ink); text-align: left; cursor: pointer; }
.process-carousel-tabs button span:first-child { color: var(--ui-muted); font: 10px/1 var(--font-mono); }
.process-carousel-tabs button[aria-selected="true"] { border-color: var(--ui-ink); background: #f3f5f1; }
.process-carousel-tabs button[aria-selected="true"] span:first-child { color: var(--primary); }
.process-carousel-tabs button:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.process-hub-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.process-hub-card { display: flex; min-width: 0; flex-direction: column; border: 1px solid var(--ui-border); padding: 18px; background: var(--ui-surface); color: var(--ui-ink); }
.process-hub-card.featured { grid-column: span 2; grid-row: span 2; }
.process-hub-card.no-image.featured { justify-content: center; padding: clamp(28px, 5vw, 64px); background: #f0f2ed; }
.process-hub-card img { display: block; width: 100%; height: 190px; object-fit: cover; margin-bottom: 16px; background: #e5e9e5; }
.process-hub-card.featured img { height: 310px; }
.process-hub-card .num { color: var(--primary); font: 11px/1.4 var(--font-mono); }
.process-hub-card h2 { margin: 8px 0; font-size: 21px; }
.process-hub-card p { color: var(--ui-muted); line-height: 1.6; }
.process-hub-card .more { margin-top: auto; padding-top: 14px; color: var(--primary); }
.verified-cert-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.verified-cert-grid article { display: flex; min-height: 126px; flex-direction: column; justify-content: space-between; gap: 10px; padding: 18px; border: 1px solid var(--ui-border); background: var(--ui-surface); }
.verified-cert-grid article b { font-size: 17px; }
.verified-cert-grid article span, .verified-cert-grid article small { color: var(--ui-muted); font-size: 12px; line-height: 1.5; }
.home-quality .verified-cert-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.verified-cert-grid article.verified-doc-card { min-height: 0; justify-content: flex-start; gap: 10px; padding: 14px; }
.verified-doc-card .verified-doc-image { position: relative; display: block; height: 250px; overflow: hidden; border: 1px solid var(--ui-border); background: #f3f2ed; }
.verified-doc-image img { display: block; width: 100%; height: 100%; object-fit: contain; }
.verified-doc-image > span { position: absolute; right: 8px; bottom: 8px; padding: 5px 8px; color: #fff; background: rgba(17, 37, 34, .88); font-size: 10px; }
.verified-doc-card .verified-doc-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.verified-doc-card .verified-doc-pair .verified-doc-image { height: 210px; }
.verified-doc-pdf, .verified-doc-links a { color: var(--primary); font-size: 12px; line-height: 1.5; }
.verified-doc-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: auto; padding-top: 6px; }
.home-quality .verified-doc-card .verified-doc-image { height: 210px; }
.home-quality .verified-doc-card .verified-doc-pair .verified-doc-image { height: 170px; }
#certificate-library, #certificate-documents { scroll-margin-top: 108px; }
.iso-cert-feature { display: grid; grid-template-columns: minmax(210px, .72fr) 1fr; gap: 28px; align-items: center; margin: 26px 0 20px; padding: 22px; border: 1px solid var(--ui-border); background: var(--ui-surface); }
.iso-cert-image { position: relative; display: block; overflow: hidden; background: #f2f1e7; border: 1px solid var(--ui-border); }
.iso-cert-image img { display: block; width: 100%; height: clamp(260px, 34vw, 420px); object-fit: contain; }
.iso-cert-image > span { position: absolute; right: 10px; bottom: 10px; padding: 7px 10px; color: #fff; background: rgba(17, 37, 34, .88); font-size: 12px; }
.iso-cert-copy { max-width: 560px; }
.iso-cert-copy h3 { margin: 10px 0; font-size: clamp(22px, 3vw, 32px); }
.iso-cert-copy p { color: var(--ui-muted); line-height: 1.7; }
.iso-cert-copy dl { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 22px 0; }
.iso-cert-copy dl div { padding: 12px 14px; border-top: 1px solid var(--ui-border); }
.iso-cert-copy dt { color: var(--ui-muted); font-size: 12px; }
.iso-cert-copy dd { margin: 5px 0 0; font-weight: 600; }
.quality-scope-note { margin-top: 16px; color: var(--ui-muted); font-size: 13px; }
.factory-evidence-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 28px; }
.factory-evidence-grid figure { min-width: 0; margin: 0; border: 1px solid var(--ui-border); background: var(--ui-surface); }
.factory-evidence-grid img { display: block; width: 100%; height: 210px; object-fit: cover; }
.factory-evidence-grid figcaption { padding: 12px 14px; color: var(--ui-muted); font-size: 13px; }
.home-quality-cta { display: flex; justify-content: center; gap: 12px; margin-top: 26px; }
.workflow-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.workflow-grid article { min-height: 158px; padding: 22px; border: 1px solid var(--ui-border); background: var(--ui-surface); }
.workflow-grid article > b { color: var(--primary); font: 12px/1 var(--font-mono); }
.workflow-grid article h3 { margin: 16px 0 8px; font-size: 18px; }
.workflow-grid article p, .case-confidentiality { color: var(--ui-muted); line-height: 1.65; }
.case-confidentiality { margin: 22px 0 0; font-size: 13px; }
.contact-options .contact-channel-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.contact-channel { display: flex; min-width: 0; flex-direction: column; align-items: flex-start; padding: 24px; }
.contact-channel h3 { overflow-wrap: anywhere; margin: 12px 0 6px; font-size: 18px; }
.contact-channel p { margin: 0; font-size: 16px; }
.contact-channel p a { color: var(--ui-ink); }
.contact-channel small { margin-top: 8px; color: var(--ui-muted); line-height: 1.5; }
.contact-channel .text-link { margin-top: 14px; }
.channel-label { color: var(--primary); font: 10px/1.4 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; }
.contact-company-block { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; margin-top: 16px; padding: 24px; border: 1px solid var(--ui-border); background: #f6f7f3; }
.contact-company-block h3 { margin: 8px 0; font-size: 20px; }
.contact-company-block p { max-width: 760px; margin: 6px 0 0; color: var(--ui-muted); line-height: 1.65; }
.contact-legal-name { max-width: 260px; color: var(--ui-muted); font-size: 12px; line-height: 1.5; text-align: right; }
.certification-page-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.certification-evidence-grid { margin-top: 24px; }
@media (max-width: 900px) {
  .verified-cert-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .home-quality .verified-cert-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .process-hub-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .iso-cert-feature { grid-template-columns: 1fr; gap: 18px; padding: 16px; }
  .iso-cert-image img { height: min(118vw, 520px); }
  .verified-doc-card .verified-doc-image { height: 220px; }
  .home-process .process-carousel { grid-template-columns: 1fr; }
  .process-carousel-visual { min-height: 300px; }
  .process-carousel-visual img { min-height: 300px; }
  .process-carousel-copy { padding: 24px; }
  .process-hub-card.featured { grid-column: span 2; grid-row: auto; }
  .process-hub-card.featured img { height: 230px; }
  .workflow-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact-options .contact-channel-grid { grid-template-columns: 1fr; }
  .contact-company-block { display: block; }
  .contact-legal-name { margin-top: 14px; text-align: left; }
}
@media (max-width: 560px) {
  .verified-cert-grid, .certification-page-grid, .factory-evidence-grid, .process-hub-grid, .workflow-grid { grid-template-columns: 1fr; }
  .home-quality .verified-cert-grid { grid-template-columns: 1fr; }
  .process-hub-card.featured { grid-column: auto; }
  .process-carousel-tabs { grid-template-columns: 1fr; }
  .factory-evidence-grid img { height: 190px; }
  .home-quality-cta { flex-direction: column; }
}

/* Interactive export routes on the contact page. The map image is the visual plane; SVG stays live for motion and interaction. */
.trade-map {
  position: relative;
  min-height: clamp(310px, 44vw, 535px);
  overflow: hidden;
  isolation: isolate;
  background: #031522;
  border: 1px solid #173444;
}
.trade-map > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .92; }
.trade-map::after { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(90deg, rgba(1,13,23,.16), transparent 35%, transparent 65%, rgba(1,13,23,.22)), linear-gradient(180deg, rgba(1,13,23,.08), rgba(1,13,23,.24)); }
.trade-routes { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; pointer-events: none; }
.trade-routes path { fill: none; stroke: #ff7a54; stroke-width: 2.1; stroke-linecap: round; stroke-dasharray: 6 12; filter: drop-shadow(0 0 5px rgba(255,122,84,.78)); animation: trade-dash 3.8s linear infinite; opacity: .7; }
.trade-routes path.is-active { stroke: #ffd3b9; stroke-width: 3.4; opacity: 1; }
.trade-node { position: absolute; z-index: 3; left: var(--x); top: var(--y); width: 17px; height: 17px; padding: 0; border: 0; border-radius: 50%; transform: translate(-50%, -50%); background: #ff754e; box-shadow: 0 0 0 4px rgba(255,117,78,.2), 0 0 18px rgba(255,117,78,.9); cursor: pointer; }
.trade-node::before { content: ''; position: absolute; inset: -11px; border: 1px solid rgba(255,184,150,.7); border-radius: inherit; animation: trade-pulse 2.35s ease-out infinite; }
.trade-node span { display: block; width: 5px; height: 5px; margin: auto; border-radius: inherit; background: #fff6ee; }
.trade-node:hover, .trade-node:focus-visible, .trade-node.is-active { outline: none; background: #fff0e5; box-shadow: 0 0 0 6px rgba(255,117,78,.32), 0 0 28px rgba(255,117,78,1); }
.trade-node:hover span, .trade-node:focus-visible span, .trade-node.is-active span { background: #ee6846; }
.trade-node.is-origin { width: 23px; height: 23px; background: #fff2e8; box-shadow: 0 0 0 7px rgba(255,117,78,.27), 0 0 30px rgba(255,117,78,.98); }
.trade-node.is-origin span { width: 8px; height: 8px; background: #f06746; }
.trade-map-status { position: absolute; z-index: 4; left: 22px; bottom: 18px; max-width: calc(100% - 44px); padding: 9px 12px; border: 1px solid rgba(184,232,246,.35); background: rgba(2,19,31,.72); color: #e8f7fb; font: 11px/1.3 var(--font-mono); letter-spacing: .04em; backdrop-filter: blur(8px); }
.trade-map-hint { position: absolute; z-index: 4; display: none; margin: 0; padding: 7px 10px; border: 1px solid rgba(255,190,159,.7); background: rgba(13,31,42,.92); color: #fff3ea; font: 11px/1 var(--font-mono); pointer-events: none; transform: translate(-50%, -140%); white-space: nowrap; }
.trade-map-hint.is-visible { display: block; }
@keyframes trade-dash { to { stroke-dashoffset: -72; } }
@keyframes trade-pulse { 0% { transform: scale(.35); opacity: .9; } 100% { transform: scale(1.2); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .trade-routes path, .trade-node::before { animation: none; } }
@media (max-width: 600px) { .trade-map { min-height: 300px; } .trade-map-status { left: 12px; bottom: 12px; font-size: 10px; } .trade-node { width: 14px; height: 14px; } .trade-node.is-origin { width: 19px; height: 19px; } }
