/* =========================================================
   GTECH ASIA SDN BHD — Master Solution Page Template (v2)
   Technical reading page / engineering microsite, NOT a marketing
   landing page. Shared stylesheet for every /solutions/*.html page.
   Extends css/style.css — reuse its tokens, don't duplicate them.
   ========================================================= */

/* ---- Long-form reading measure ----
   Everything that is running prose (not a figure, not a spec grid)
   is capped to a comfortable reading width and centered inside the
   wider .container, the way a technical article or datasheet reads. */
.tech-prose { max-width: 760px; }

/* ---- 1. Masthead ----
   A compact technical title block, not a big glossy marketing hero:
   light background, a single accent rule, no gradient banner. */
.tech-masthead { padding: 40px 0 0; border-bottom: 1px solid var(--grey-100); }
.tech-masthead .breadcrumb { color: var(--grey-600); margin-bottom: 16px; }
.tech-masthead .breadcrumb a { color: var(--blue-600); }
.tech-masthead .tag-pill {
  display: inline-block; background: rgba(26,86,219,0.08); color: var(--blue-600);
  padding: 5px 14px; border-radius: 999px; font-size: 0.72rem; font-weight: 800;
  letter-spacing: 0.07em; text-transform: uppercase; margin-bottom: 16px;
}
.tech-masthead h1 { font-size: 2.35rem; max-width: 900px; margin-bottom: 14px; }
.tech-masthead .tech-dek { font-size: 1.05rem; color: var(--grey-700); max-width: 760px; margin-bottom: 28px; line-height: 1.6; }

/* Spec strip — datasheet-style facts, not sales claims */
.tech-spec-strip { display: grid; grid-template-columns: repeat(5, 1fr); border-top: 1px solid var(--grey-100); }
.tech-spec-strip .tech-spec-item { padding: 18px 20px 20px 0; }
.tech-spec-strip .tech-spec-label { display: block; font-size: 0.66rem; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase; color: var(--grey-500); margin-bottom: 5px; }
.tech-spec-strip .tech-spec-value { font-size: 0.86rem; font-weight: 700; color: var(--ink-900); line-height: 1.4; }
@media (max-width: 980px) { .tech-spec-strip { grid-template-columns: repeat(2, 1fr); } .tech-spec-strip .tech-spec-item { padding-right: 20px; } }
@media (max-width: 600px) { .tech-spec-strip { grid-template-columns: 1fr; } }
@media (max-width: 700px) { .tech-masthead h1 { font-size: 1.8rem; } }

/* ---- 2. Table of contents ---- */
.tech-toc-wrap { background: var(--grey-50); border-bottom: 1px solid var(--grey-100); padding: 18px 0; }
.tech-toc { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; }
.tech-toc-label { font-size: 0.72rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--grey-500); margin-right: 6px; }
.tech-toc a {
  font-size: 0.82rem; font-weight: 700; color: var(--blue-600); background: var(--white);
  border: 1px solid var(--grey-100); border-radius: 999px; padding: 6px 14px; white-space: nowrap;
}
.tech-toc a:hover { background: rgba(26,86,219,0.06); }

/* ---- 3. Section rhythm ---- */
.tech-section { padding: 64px 0; }
.tech-section.bg-light { background: var(--grey-50); }
.tech-section + .tech-section { border-top: 1px solid var(--grey-100); }
.tech-section-head { margin-bottom: 32px; }
.tech-section-head .eyebrow { display: block; }
.tech-section-head h2 { font-size: 1.7rem; margin-bottom: 10px; }
.tech-section-head p { font-size: 0.98rem; max-width: 760px; }

/* ---- Figures (image + caption), used throughout ---- */
.tech-figure { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--grey-100); background: var(--white); box-shadow: var(--shadow-sm); }
.tech-figure .tech-figure-frame { display: flex; align-items: center; justify-content: center; background: var(--white); padding: 14px; }
.tech-figure img { width: 100%; height: auto; max-height: 320px; object-fit: contain; display: block; }
.tech-figure figcaption { padding: 11px 15px; font-size: 0.78rem; color: var(--grey-600); line-height: 1.5; background: var(--grey-50); border-top: 1px solid var(--grey-100); }

/* ---- 4. Overview (prose + a supporting figure) ---- */
.tech-overview-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: start; }
.tech-overview-grid p { font-size: 0.98rem; }
@media (max-width: 860px) { .tech-overview-grid { grid-template-columns: 1fr; } }

/* ---- 5. Capabilities — the core of the page ----
   Each capability is a full editorial block: numbered heading, prose
   explaining what it does and why it's used, a compact spec list for
   the fast-scan facts, and (where a genuine source figure exists) an
   illustration. Media position alternates left/right for rhythm across
   a long list, and collapses to a single column on narrow screens. */
.tech-capability-list { display: flex; flex-direction: column; gap: 0; }
.tech-capability {
  display: grid; grid-template-columns: 300px 1fr; gap: 36px; align-items: start;
  padding: 40px 0; border-top: 1px solid var(--grey-100);
}
.tech-capability:first-child { border-top: none; padding-top: 0; }
.tech-capability.no-media { grid-template-columns: 1fr; }
.tech-capability.media-right { grid-template-columns: 1fr 300px; }
.tech-capability.media-right .tech-capability-media { order: 2; }
.tech-capability-media .tech-figure { position: sticky; top: 96px; }
.tech-capability-num { display: inline-block; font-size: 0.76rem; font-weight: 800; color: var(--blue-600); letter-spacing: 0.06em; margin-bottom: 6px; }
.tech-capability h3 { font-size: 1.28rem; margin-bottom: 12px; scroll-margin-top: 96px; }
.tech-capability > .tech-capability-body > p { font-size: 0.96rem; }
.tech-specs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px 20px; margin: 22px 0 0; padding: 18px 20px; background: var(--grey-50); border-radius: var(--radius-sm); border: 1px solid var(--grey-100); }
.tech-specs div { margin: 0; }
.tech-specs dt { font-size: 0.66rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--blue-600); margin-bottom: 5px; }
.tech-specs dd { margin: 0; font-size: 0.85rem; color: var(--grey-700); line-height: 1.5; }
@media (max-width: 860px) {
  .tech-capability, .tech-capability.media-right { grid-template-columns: 1fr; }
  .tech-capability.media-right .tech-capability-media { order: 0; }
  .tech-capability-media .tech-figure { position: static; }
  .tech-specs { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) { .tech-specs { grid-template-columns: 1fr; } }

/* ---- 6. Workflow — numbered list with inline figures (reading style,
   not a marketing icon strip) ---- */
.tech-workflow-list { counter-reset: tech-step; display: flex; flex-direction: column; gap: 28px; }
.tech-workflow-step { display: grid; grid-template-columns: 56px 1fr; gap: 20px; }
.tech-workflow-step .tech-step-num {
  counter-increment: tech-step; width: 40px; height: 40px; border-radius: 50%;
  background: var(--grey-100); color: var(--blue-600); font-weight: 800; font-size: 1rem;
  display: flex; align-items: center; justify-content: center;
}
.tech-workflow-step .tech-step-num::before { content: counter(tech-step); }
.tech-workflow-step h4 { font-size: 1rem; margin-bottom: 5px; }
.tech-workflow-step p { font-size: 0.9rem; margin-bottom: 12px; }
.tech-workflow-step .tech-figure { max-width: 480px; }
@media (max-width: 560px) { .tech-workflow-step { grid-template-columns: 1fr; } .tech-workflow-step .tech-step-num { margin-bottom: 4px; } }

/* ---- 7. Applications — grounded, example-driven rows ---- */
.tech-app-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.tech-app-card { display: flex; flex-direction: column; gap: 12px; }
.tech-app-card h4 { font-size: 1rem; margin-bottom: 0; }
.tech-app-card p { font-size: 0.9rem; margin-bottom: 0; }
@media (max-width: 760px) { .tech-app-grid { grid-template-columns: 1fr; } }

/* ---- 8. Interoperability — technical "see also", not sales cards ---- */
.tech-interop-list { display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--grey-100); }
.tech-interop-item { display: grid; grid-template-columns: 160px 1fr; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--grey-100); align-items: baseline; }
.tech-interop-item .tech-interop-name { font-weight: 800; color: var(--ink-900); font-size: 0.92rem; }
.tech-interop-item .tech-interop-name a { color: var(--blue-600); }
.tech-interop-item p { margin: 0; font-size: 0.88rem; }
@media (max-width: 620px) { .tech-interop-item { grid-template-columns: 1fr; gap: 4px; } }

/* ---- 9. FAQ (native accordion) ---- */
.tech-faq { max-width: 800px; }
.tech-faq-item { border-bottom: 1px solid var(--grey-100); padding: 4px 0; }
.tech-faq-item summary {
  cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 15px 2px; font-weight: 700; font-size: 0.94rem; color: var(--ink-900);
}
.tech-faq-item summary::-webkit-details-marker { display: none; }
.tech-faq-item summary::after {
  content: '+'; flex-shrink: 0; width: 24px; height: 24px; border-radius: 50%; background: var(--grey-100);
  color: var(--blue-600); font-size: 1.05rem; font-weight: 800; display: flex; align-items: center; justify-content: center;
}
.tech-faq-item[open] summary::after { content: '\2212'; }
.tech-faq-item p { padding: 0 2px 15px; font-size: 0.88rem; margin-bottom: 0; }

/* ---- 10. Technical Resources — flyer/brochure cards. Same figure +
   card language as Applications (section 7), not a separate marketing
   style. Hidden by default in the HTML on every page (revealed by
   product-resources-enhance.js only once a matching flyer exists), so
   a product with no resource never shows an empty section. */
.tech-resource-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 340px)); gap: 28px; }
.tech-resource-card {
  display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--grey-100);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm);
}
.tech-resource-card .tech-figure { border: none; border-radius: 0; box-shadow: none; }
.tech-resource-card .tech-figure-frame { padding: 0; background: var(--grey-50); }
.tech-resource-card .tech-figure img { max-height: 220px; object-fit: cover; object-position: top; }
.tech-resource-thumb-fallback {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  height: 220px; background: var(--grey-100); color: var(--grey-500);
}
.tech-resource-thumb-fallback span { font-size: 1.6rem; font-weight: 800; letter-spacing: 0.04em; color: var(--grey-400); }
.tech-resource-thumb-fallback small { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.tech-resource-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 8px; }
.tech-resource-body h4 { font-size: 1rem; margin: 0; }
.tech-resource-body p { font-size: 0.88rem; margin: 0; color: var(--grey-700); }
.tech-resource-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
@media (max-width: 620px) { .tech-resource-grid { grid-template-columns: 1fr; } }

/* ---- 11. Access & support — a low-key closing note, not a CTA banner ---- */
.tech-access { background: var(--grey-50); border: 1px solid var(--grey-100); border-radius: var(--radius); padding: 28px 32px; display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.tech-access p { margin: 0; font-size: 0.9rem; max-width: 560px; }
.tech-access .tech-access-actions { display: flex; gap: 10px; flex-wrap: wrap; }
@media (max-width: 700px) { .tech-access { flex-direction: column; align-items: flex-start; } }

/* ---- 12. Quick Resource CTA (Phase 5E-3) — a compact shortcut to the
   existing Technical Resources section (#resources), NOT a duplicate
   of the flyer card itself and not a second render of
   ProductResourceCard(). Structural precedent: section 11's
   .tech-access (a single non-grid card, flex row that wraps to a
   column on narrow screens) — kept deliberately plain, matching this
   template's own "technical reading page, not a marketing landing
   page" language at the top of this file. The containing section
   ships hidden by default in the HTML and is revealed only by
   js/quick-resource-cta.js once it confirms a matching, non-empty
   flyer entry exists for this page's solution — same
   hidden-until-confirmed pattern section 10 already uses. */
.quick-resource-cta {
  background: var(--white); border: 1px solid var(--grey-100); border-radius: var(--radius);
  padding: 22px 28px; display: flex; justify-content: space-between; align-items: center;
  gap: 20px; flex-wrap: wrap;
}
.quick-resource-cta-text { display: flex; flex-direction: column; gap: 4px; max-width: 560px; }
.quick-resource-cta-title { margin: 0; font-size: 1rem; font-weight: 700; color: var(--ink-900); }
@media (max-width: 700px) { .quick-resource-cta { flex-direction: column; align-items: flex-start; } }
