/* home2.html: highway scene, then the production-line scene. Builds on css/automated-driving.css. */

/* the first scene shares the first screen with the 94px header */
.h2-first .ad-stage { height: calc(100vh - 94px); height: calc(100svh - 94px); }
.h2-first .ad-panels { margin-top: calc(94px - 100vh); margin-top: calc(94px - 100svh); }
.h2-first .ad-panel { min-height: calc(100vh - 94px); min-height: calc(100svh - 94px); padding-top: 48px; padding-bottom: 48px; }
.pl-story { scroll-margin-top: 0; }
/* a story with one text panel is exactly one screen tall */
.h2-single .ad-panel { min-height: 100vh; min-height: 100svh; }
.pl-stage { background: radial-gradient(900px 520px at 55% 55%, rgba(60, 110, 200, .22), transparent 70%), #04060c; }
.ad-bad { color: var(--sw-fail); }
.ad-card li.ad-red { border-color: var(--sw-fail); color: #ff8fa5; }
.ad-card-link { margin-top: 22px !important; }

/* this label hangs below its point so it does not sit on top of the HMI label */
.ad-callout-low p { bottom: auto; top: 26px; }
.ad-callout-low p::before { bottom: auto; top: -22px; transform: rotate(38deg); }

/* products */
.h2-products { background: var(--sw-bg); }
.h2-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 52px; }
.h2-product { display: flex; flex-direction: column; padding: 28px 28px 30px; border: 1px solid var(--sw-line); border-radius: 14px; background: linear-gradient(160deg, rgba(47, 123, 255, .1), rgba(5, 10, 28, .5) 55%); color: #fff; text-decoration: none; transition: transform .25s, border-color .25s, box-shadow .25s; }
.h2-product:hover { transform: translateY(-6px); border-color: rgba(111, 191, 228, .6); box-shadow: 0 24px 60px rgba(0, 20, 80, .55); }
.h2-shot { display: grid; place-items: center; height: 220px; margin-bottom: 22px; border-radius: 10px; background: radial-gradient(closest-side, rgba(111, 191, 228, .16), transparent); }
.h2-shot img { max-width: 100%; max-height: 200px; width: auto; height: auto; object-fit: contain; transition: transform .35s; }
.h2-product:hover .h2-shot img { transform: scale(1.05); }
.h2-product h3 { font-size: 22px; }
.h2-product p { flex: 1; margin: 12px 0 20px; font-size: 15.5px; line-height: 1.6; color: var(--sw-text); }

@media (max-width: 900px) {
  .h2-grid { grid-template-columns: 1fr; }
  .h2-shot { height: 180px; }
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

/* Automotive products: two cards, centred under the machine vision row */
.h2-products-auto { padding-top: 0; }
.h2-grid-2 { grid-template-columns: repeat(2, 1fr); max-width: 820px; }
@media (max-width: 860px) { .h2-grid-2 { grid-template-columns: 1fr; } }

/* Home hero: three bullets under the headline, each a link */
.ad-card .h2-bullets { display: block; list-style: none; margin: 22px 0 6px; padding: 0; }
.ad-card .h2-bullets li { display: block; margin: 0; padding: 0; border: 0; border-radius: 0; background: none; }
.ad-card .h2-bullets li + li { margin-top: 4px; }
.ad-card .h2-bullets a { display: inline-flex; align-items: center; gap: 14px; padding: 7px 0; font: 600 clamp(19px, 2vw, 24px)/1.25 var(--f-head, inherit); letter-spacing: .3px; color: inherit; text-decoration: none; }
.ad-card .h2-bullets a::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 50%; background: #2bb3ff; box-shadow: 0 0 0 4px rgba(43, 179, 255, .22); }
.ad-card .h2-bullets a span { opacity: 0; transform: translateX(-6px); transition: opacity .2s, transform .2s; color: #1b6fb5; }
.ad-card .h2-bullets a:hover span, .ad-card .h2-bullets a:focus-visible span { opacity: 1; transform: none; }
.ad-card .h2-bullets a:hover { color: #1b6fb5; }
html[data-theme="lite"] .ad-card .h2-bullets li { background: none; color: #0e1821; }
html[data-theme="dark"] .ad-card .h2-bullets a { color: #fff; text-shadow: 0 2px 20px rgba(2, 3, 15, 1); }
html[data-theme="dark"] .ad-card .h2-bullets a:hover, html[data-theme="dark"] .ad-card .h2-bullets a span { color: #8fd4f5; }

/* Home hero: headline block sits in the upper part of the view, not the middle */
.h2-first .ad-panel-hero { align-items: flex-start; padding-top: clamp(64px, 10vh, 110px); }
@media (max-width: 900px) { .h2-first .ad-panel-hero { padding-top: 110px; } }

/* Talent Partner scene */
.tp-stage { background: radial-gradient(900px 520px at 60% 55%, rgba(43, 179, 255, .18), transparent 70%), #04060c; }
html[data-theme="lite"] .tp-stage { background: #e4e9f0; }
.tp-story .ad-card .h2-bullets a { font-size: clamp(17px, 1.5vw, 20px); }

/* Talent Partner cards use photos, which fill the picture area */
.h2-shot-photo { background: none; overflow: hidden; }
.h2-shot-photo img, html[data-theme="lite"] .h2-shot-photo img { width: 100%; height: 100%; max-height: none; object-fit: cover; border-radius: 10px; }

/* "Explore visualization" link under the hero bullets */
.h2-explore { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 18px 0 0; pointer-events: auto; }
.h2-explore a { display: inline-flex; align-items: center; gap: 10px; padding: 10px 20px 10px 14px; border-radius: 999px; background: #1c63d8; color: #fff !important; font: 700 15px/1 var(--f-head, inherit); letter-spacing: .3px; text-decoration: none; box-shadow: 0 6px 18px rgba(28, 99, 216, .35); transition: transform .2s, box-shadow .2s; }
.h2-explore a:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(28, 99, 216, .45); }
.h2-explore a i { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: rgba(255, 255, 255, .22); font-style: normal; font-size: 10px; padding-left: 2px; }
.h2-explore span { font-size: 13px; color: var(--sw-text, #5a6677); }
html[data-theme="dark"] .h2-explore span { color: #c9d6ea; }

/* Home headline: "AI Vision Systems" stays on one line, "& Talent Partner" on the next */
.h2-first .ad-card-hero { width: min(700px, 100%); }
.h2-first .ad-card-hero h1 { white-space: nowrap; font-size: clamp(34px, 3.9vw, 58px); }
@media (max-width: 900px) { .h2-first .ad-card-hero h1 { font-size: min(7vw, 40px); } }

/* Production-line card on the home page: large and simple */
.ad-card.h2-big-card { width: min(760px, 100%); padding: 40px 44px 42px; }
.ad-card.h2-big-card .ad-step { font-size: 15px; letter-spacing: 3px; }
.ad-card.h2-big-card h2 { margin-top: 14px; font-size: clamp(30px, 3.6vw, 54px); line-height: 1.06; letter-spacing: -.02em; }
.ad-card.h2-big-card h2 span { display: block; white-space: nowrap; }
.ad-card.h2-big-card .ad-card-link { margin-top: 30px; pointer-events: auto; }
.ad-card.h2-big-card .sw-btn { height: 56px; padding: 0 28px; font-size: 17px; }
@media (max-width: 900px) { .ad-card.h2-big-card { padding: 26px 22px 28px; } .ad-card.h2-big-card h2 { font-size: min(7vw, 40px); } }
.h2-grid.h2-grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1100px) { .h2-grid.h2-grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .h2-grid.h2-grid-4 { grid-template-columns: 1fr; } }

/* cards that are not links (Sample Applications) */
.h2-product.h2-static { cursor: default; }
.h2-product.h2-static:hover { transform: none; }
.h2-product.h2-static:hover .h2-shot img { transform: none; }
