/* Content from data/*.json: product models on the product pages, and "Our projects" on home. */

/* product models */
.detail-catalog[hidden] { display: none; }
.detail-catalog { margin: 40px 0 56px; }
.detail-catalog > h2 { margin: 0 0 22px; }
.pc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.pc-card { display: flex; flex-direction: column; border: 1px solid #e6eaf1; border-radius: 16px; background: #fff; overflow: hidden; }
.pc-img { aspect-ratio: 4 / 3; background: #f3f6fa; }
.pc-img img { width: 100%; height: 100%; object-fit: contain; padding: 18px; }
.pc-body { padding: 20px 22px 24px; }
.pc-brand { margin: 0 0 6px; font-size: 12px; font-weight: 600; letter-spacing: 0.04em; color: #2b5fe3; }
.pc-body h3 { margin: 0; font-size: 19px; font-weight: 500; line-height: 1.4; color: #0a1730; }
.pc-model { margin: 4px 0 0; font-size: 13px; color: #6a7a96; }
.pc-sum { margin: 12px 0 0; font-size: 14px; line-height: 1.75; color: #4a5872; }
.pc-specs { margin: 16px 0 0; display: grid; gap: 0; border-top: 1px solid #edf0f5; }
.pc-specs div { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-bottom: 1px solid #edf0f5; font-size: 13px; }
.pc-specs dt { color: #6a7a96; }
.pc-specs dd { margin: 0; color: #0a1730; font-weight: 500; text-align: right; }

/* our projects */
.rp[hidden] { display: none; }
.rp-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.rp-card { min-width: 0; }
.rp-img { position: relative; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: #eef2f8; }
.rp-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1); }
.rp-card:hover .rp-img img { transform: scale(1.03); }
.rp-tag { position: absolute; left: 16px; bottom: 14px; padding: 5px 10px; border-radius: 4px; background: rgba(255, 255, 255, 0.94); font-size: 10px; letter-spacing: 0.08em; color: #0a1730; }
.rp-copy { padding: 20px 0 0; }
.rp-copy h3 { margin: 0; font-size: 21px; font-weight: 500; line-height: 1.5; color: #0a1730; }
.rp-meta { margin: 8px 0 0; display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; color: #6a7a96; }
.rp-sum { margin: 10px 0 0; font-size: 14px; line-height: 1.8; color: #4a5872; }
@media (max-width: 900px) { .rp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .rp-grid { grid-template-columns: minmax(0, 1fr); } .pc-grid { grid-template-columns: minmax(0, 1fr); } }

/* squeeze carousel (squeeze.js) — articles on the home page */
.sq { container-type: inline-size; display: flex; flex-direction: column; width: 100%;
  --sq-slat: 8px; --sq-slat-gap: 8px; --sq-gap: 16px; --sq-radius: 8px; --sq-ms: 1000ms; --sq-ease: cubic-bezier(0.16, 1, 0.3, 1);
  --sq-fill: #2b5fe3; --sq-on-fill: #fff; }
.sq-controls { display: flex; justify-content: flex-end; gap: 8px; margin-bottom: 16px; }
.sq-arrow { width: 38px; height: 38px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 8px; background: var(--sq-fill); color: var(--sq-on-fill); cursor: pointer; transition: opacity 0.2s; }
.sq-arrow:hover { opacity: 0.85; }
.sq-arrow:focus-visible, .sq-card:focus-visible, .sq-action:focus-visible { outline: 2px solid var(--sq-fill); outline-offset: 3px; }
.sq-view { width: 100%; overflow: hidden;
  --sq-h: clamp(180px, 32cqi, 340px); --sq-hero: calc(var(--sq-h) * 16 / 9);
  --sq-room: calc(100cqi - var(--sq-hero) - var(--sq-slats) * var(--sq-slat-gap) - 3 * var(--sq-gap) - var(--sq-slats) * var(--sq-slat));
  height: var(--sq-h); }
.sq-strip { display: flex; height: 100%; width: max-content; transition: transform var(--sq-ms) var(--sq-ease); }
.sq-card { position: relative; isolation: isolate; flex: none; height: 100%; padding: 0; border: 0; overflow: hidden; background: #e6ebf3; cursor: pointer;
  transition: width var(--sq-ms) var(--sq-ease), margin-left var(--sq-ms) var(--sq-ease), border-radius var(--sq-ms) var(--sq-ease); }
/* each picture is drawn at one 16:9 block and centred, so narrowing a card only crops it */
.sq-card img, .sq-fill { position: absolute; top: 0; left: 50%; height: 100%; width: var(--sq-hero); min-width: 100%; max-width: none; transform: translateX(-50%); object-fit: cover; }
.sq-fill { background: linear-gradient(135deg, #13254a, #2b5fe3); }
.sq-overlay { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: flex-end; padding: 56px 20px 18px; pointer-events: none;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.55), transparent); color: #fff; font-size: 11.5px; font-weight: 600; letter-spacing: 0.1em;
  opacity: 0; transition: opacity var(--sq-ms) var(--sq-ease); }
.sq-card.is-front .sq-overlay { opacity: 1; }
.sq-panel { display: grid; margin-top: 24px; }
.sq-item { grid-area: 1 / 1; display: flex; flex-direction: column; gap: 16px; opacity: 0; visibility: hidden; pointer-events: none; transform: translateY(6px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0s 0.2s; }
/* the old copy clears quickly; the new one follows straight after, while the row is still sliding */
.sq-item.is-on { opacity: 1; visibility: visible; pointer-events: auto; transform: none;
  transition: opacity 0.45s ease 0.12s, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.12s, visibility 0s; }
.sq-item p { margin: 0; max-width: 46rem; font-size: 15px; line-height: 1.65; text-wrap: balance; }
.sq-title { color: var(--ink, #0a1730); font-weight: 500; }
.sq-desc { color: var(--ink-soft, #6a7a96); }
.sq-action { align-self: flex-start; flex: none; display: inline-flex; align-items: center; gap: 8px; padding: 11px 16px; border-radius: 8px; background: var(--sq-fill); color: var(--sq-on-fill); font-size: 14px; font-weight: 500; white-space: nowrap; transition: opacity 0.2s; }
.sq-action:hover { opacity: 0.85; text-decoration: none; }
.sq-action svg { transition: transform 0.2s; }
.sq-action:hover svg { transform: translateX(2px); }
@container (min-width: 36rem) {
  .sq-item { flex-direction: row; align-items: flex-start; justify-content: space-between; gap: 40px; }
  .sq-item p { font-size: 17px; }
  .sq-panel { margin-top: 28px; }
}
/* narrow screens: the open panel keeps most of the width, the rest stay readable as slivers */
@container (max-width: 40rem) {
  .sq-view { --sq-gap: 8px; --sq-hero: calc(100cqi - 72px); --sq-h: calc(var(--sq-hero) * 0.66); }
}
/* a still layout: the strip is tidied up and nothing may be seen to move */
.sq.is-still .sq-strip, .sq.is-still .sq-card, .sq.is-still .sq-overlay, .sq.is-still .sq-item { transition: none !important; }
body.motion-enabled .sq:not(.is-still) .sq-strip { transition: transform var(--sq-ms) var(--sq-ease) !important; }
body.motion-enabled .sq:not(.is-still) .sq-card { transition: width var(--sq-ms) var(--sq-ease), margin-left var(--sq-ms) var(--sq-ease), border-radius var(--sq-ms) var(--sq-ease) !important; }
body.motion-enabled .sq:not(.is-still) .sq-overlay { transition: opacity var(--sq-ms) var(--sq-ease) !important; }
body.motion-enabled .sq:not(.is-still) .sq-item { transition: opacity 0.2s ease, transform 0.2s ease, visibility 0s 0.2s !important; }
body.motion-enabled .sq:not(.is-still) .sq-item.is-on { transition: opacity 0.45s ease 0.12s, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.12s, visibility 0s !important; }
