/* ==========================================================
   ENAVIO — Industrial AI Assistant (product page + home teaser)
   Loaded after style.css; uses its variables.
   ========================================================== */

.as-page section { padding: clamp(80px, 9vw, 136px) 0; }

/* ---------- Hero ---------- */
.as-hero { padding: clamp(136px, 15vw, 184px) 0 clamp(64px, 7vw, 104px) !important; border-bottom: 1px solid var(--border); }
.as-hero-copy { max-width: 880px; }
.as-lockup { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; margin-bottom: 30px; }
.as-lockup-mark {
  width: 40px; height: 40px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center;
  background: var(--surface-2); border: 1px solid var(--border-strong);
}
.as-lockup-mark img { width: 18px; height: auto; }
.as-lockup-name { font-size: 1rem; font-weight: 600; color: var(--text); letter-spacing: -0.005em; }
.as-hero h1 { font-size: clamp(2.5rem, 5.4vw, 4.4rem); line-height: 1.04; letter-spacing: -0.03em; max-width: 19ch; }
.as-hero .page-lede { margin-top: 24px; font-size: clamp(1.08rem, 1.6vw, 1.28rem); line-height: 1.55; max-width: 56ch; }
.as-hero .hero-actions { margin-top: 36px; }
.as-facts { display: flex; flex-wrap: wrap; gap: 10px 28px; margin-top: 32px; }
.as-facts li { position: relative; padding-left: 22px; font-size: 0.92rem; color: var(--text-muted); }
.as-facts li::before {
  content: ""; position: absolute; left: 0; top: 0.42em; width: 12px; height: 7px;
  border-left: 1.5px solid var(--accent); border-bottom: 1.5px solid var(--accent); transform: rotate(-45deg);
}
.as-hero-media { margin-top: clamp(56px, 6vw, 88px); }
.as-hero-media .as-frame { box-shadow: 0 40px 100px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.04); }

/* ---------- In-page navigation ---------- */
.as-page .as-subnav { border-bottom: 1px solid var(--border); background: var(--bg); }
.as-subnav .container { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 32px; min-height: 60px; padding-top: 12px; padding-bottom: 12px; }
.as-subnav a { font-size: 0.88rem; color: var(--text-muted); transition: color var(--t-fast); line-height: 2; }
.as-subnav a:hover { color: var(--text); }
.as-subnav .as-subnav-cta { margin-left: auto; color: var(--accent); }
@media (max-width: 767px) { .as-subnav .as-subnav-cta { margin-left: 0; } }

/* ---------- Section heads ---------- */
.as-head { max-width: 760px; margin-bottom: 56px; }
.as-head h2 { font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.025em; }
.as-head p { margin-top: 18px; font-size: 1.08rem; line-height: 1.6; max-width: 60ch; }
.as-head--flush { margin-bottom: 0; }
.as-eyebrow { display: inline-block; font-size: 0.82rem; color: var(--accent); letter-spacing: 0.06em; margin-bottom: 18px; }

/* ---------- Screenshot frames ---------- */
.as-page figure, .as-fig { margin: 0; }
.as-frame {
  border: 1px solid var(--border-strong); border-radius: 10px; overflow: hidden; background: var(--surface);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4);
  transition: border-color var(--t-fast);
}
.as-frame:hover { border-color: rgba(255, 255, 255, 0.28); }
.as-frame-bar { display: flex; align-items: center; gap: 6px; height: 26px; padding: 0 12px; background: var(--surface-2); border-bottom: 1px solid var(--border); }
.as-frame-bar span { width: 8px; height: 8px; border-radius: 50%; background: rgba(255, 255, 255, 0.14); }
.as-shot { display: block; width: 100%; padding: 0; margin: 0; border: 0; background: #F8FAFC; cursor: zoom-in; position: relative; }
.as-shot img { width: 100%; height: auto; }
.as-shot:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.as-zoom {
  position: absolute; right: 10px; bottom: 10px; display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 10px; border-radius: 6px; background: rgba(10, 10, 12, 0.85); color: var(--text);
  font-size: 0.78rem; font-weight: 500; opacity: 0; transform: translateY(4px);
  transition: opacity var(--t-fast), transform var(--t-fast); pointer-events: none;
}
.as-zoom svg { width: 14px; height: 14px; }
.as-shot:hover .as-zoom, .as-shot:focus-visible .as-zoom { opacity: 1; transform: none; }
@media (hover: none) { .as-zoom { opacity: 1; transform: none; } }
.as-frame--crop .as-shot { aspect-ratio: 16 / 10; overflow: hidden; }
.as-frame--crop .as-shot img { height: 100%; object-fit: cover; object-position: top left; }
.as-fig figcaption, .as-page figcaption { margin-top: 12px; font-size: 0.86rem; line-height: 1.5; color: var(--text-faint); }
.as-fig figcaption strong { color: var(--text-muted); font-weight: 500; margin-right: 4px; }

/* ---------- Cards ---------- */
.as-grid-3 { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); }
@media (min-width: 768px) { .as-grid-3 { grid-template-columns: repeat(3, 1fr); } }
.as-card { background: var(--bg); padding: 32px; }
.as-card h3 { font-size: 1.15rem; margin-top: 20px; line-height: 1.3; }
.as-card p { margin-top: 10px; font-size: 0.98rem; line-height: 1.6; }
.as-icon {
  display: inline-flex; align-items: center; justify-content: center; flex: none; width: 42px; height: 42px;
  border-radius: 8px; background: var(--accent-soft); color: var(--accent);
}
.as-icon svg { width: 21px; height: 21px; }
.as-quote { color: var(--text); }

.as-band {
  margin-top: 32px; padding: 32px; border: 1px solid var(--border-strong); border-radius: 8px; background: var(--surface);
  display: flex; flex-direction: column; gap: 16px; align-items: flex-start;
}
@media (min-width: 768px) { .as-band { flex-direction: row; align-items: center; gap: 24px; padding: 40px 48px; } }
.as-band p { font-size: clamp(1.2rem, 2.4vw, 1.75rem); font-weight: 600; color: var(--text); letter-spacing: -0.015em; line-height: 1.3; }
.as-band p span { color: var(--text-muted); font-weight: 500; }

/* ---------- How it works: connected flow ---------- */
.as-flow { display: grid; gap: 48px; }
@media (min-width: 900px) { .as-flow { grid-template-columns: repeat(3, 1fr); gap: 32px; } }
.as-flow-step { position: relative; }
.as-flow-node { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; position: relative; }
.as-flow-node .as-icon { width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(79, 209, 232, 0.35); position: relative; z-index: 1; order: 1; }
.as-flow-num { font-size: 0.82rem; color: var(--text-faint); letter-spacing: 0.06em; order: 2; position: relative; z-index: 1; }
@media (min-width: 900px) {
  .as-flow-step:not(:last-child) .as-flow-node::after {
    content: ""; position: absolute; left: 62px; right: -32px; top: 50%; height: 1px; background: var(--border-strong);
  }
  .as-flow-num { background: var(--bg); padding-right: 12px; }
}
.as-flow-step h3 { font-size: 1.2rem; line-height: 1.3; }
.as-flow-step p { margin-top: 10px; font-size: 0.98rem; line-height: 1.6; max-width: 38ch; }
.as-flow-who { display: inline-block; margin-top: 18px; font-size: 0.8rem; color: var(--text-muted); border-top: 1px solid var(--border); padding-top: 12px; }

/* ---------- Features ---------- */
.as-overview { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); margin-bottom: clamp(72px, 8vw, 112px); }
@media (min-width: 768px) { .as-overview { grid-template-columns: repeat(3, 1fr); } }
.as-overview-col { background: var(--bg); padding: 28px 32px 32px; display: block; transition: background var(--t-fast); }
.as-overview-col:hover { background: var(--surface); }
.as-overview-col strong { display: block; margin-top: 10px; font-size: 1.15rem; font-weight: 600; color: var(--text); }
.as-overview-col ul { margin-top: 16px; display: grid; gap: 8px; }
.as-overview-col li { font-size: 0.92rem; color: var(--text-muted); padding-left: 16px; position: relative; }
.as-overview-col li::before { content: ""; position: absolute; left: 0; top: 0.75em; width: 6px; height: 1px; background: var(--accent); }
.as-chapter-num { font-size: 0.8rem; color: var(--accent); letter-spacing: 0.06em; }

.as-chapter { scroll-margin-top: 96px; }
.as-chapter + .as-chapter { margin-top: clamp(96px, 10vw, 144px); }
.as-chapter-head { display: flex; align-items: baseline; gap: 16px; padding-bottom: 20px; margin-bottom: 56px; border-bottom: 1px solid var(--border); }
.as-chapter-head h3 { font-size: 0.95rem; font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-muted); }

.as-feature { display: grid; gap: 36px; align-items: center; }
.as-feature + .as-feature { margin-top: 96px; }
@media (min-width: 1024px) {
  .as-feature { grid-template-columns: 5fr 7fr; gap: 64px; }
  .as-feature--flip { grid-template-columns: 7fr 5fr; }
  .as-feature--flip .as-copy { order: 2; }
  .as-feature--wide { grid-template-columns: 1fr; gap: 44px; }
  .as-feature--wide .as-copy { display: grid; grid-template-columns: 5fr 6fr; gap: 64px; align-items: start; }
  .as-feature--wide .as-checks { margin-top: 6px; }
  .as-feature--wide .as-copy > p { margin-top: 0; }
  .as-feature + .as-feature { margin-top: 120px; }
}
.as-copy h4 { font-size: clamp(1.6rem, 2.8vw, 2.1rem); font-weight: 600; line-height: 1.15; letter-spacing: -0.02em; }
.as-copy p { margin-top: 16px; font-size: 1.05rem; line-height: 1.6; }
.as-checks { margin-top: 24px; display: grid; gap: 12px; }
.as-checks li { position: relative; padding-left: 30px; color: var(--text); font-size: 1rem; line-height: 1.5; }
.as-checks li::before {
  content: ""; position: absolute; left: 0; top: 0.18em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234FD1E8' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 11px no-repeat;
}
.as-media { display: grid; gap: 28px; min-width: 0; }
.as-pair { display: grid; gap: 24px; }
@media (min-width: 600px) { .as-pair { grid-template-columns: 1fr 1fr; } }

/* ---------- Security ---------- */
.as-page .as-security { background: var(--surface); }
.as-security .as-frame { background: var(--bg); }
.as-sec-layout { display: grid; gap: 48px; align-items: start; }
@media (min-width: 1024px) { .as-sec-layout { grid-template-columns: 5fr 7fr; gap: 64px; } }
.as-controls { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border-strong); border-radius: 8px; overflow: hidden; }
.as-controls li { display: grid; grid-template-columns: 42px 1fr; gap: 18px; padding: 24px; background: var(--bg); }
.as-controls h3 { font-size: 1.02rem; line-height: 1.3; }
.as-controls p { margin-top: 6px; font-size: 0.94rem; line-height: 1.55; }

/* ---------- Industries ---------- */
.as-who { display: grid; gap: 40px; }
@media (min-width: 1024px) { .as-who { grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; } .as-who .as-head { margin-bottom: 0; } }
.as-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.as-chips li { padding: 10px 18px; border: 1px solid var(--border-strong); border-radius: 999px; font-size: 0.95rem; color: var(--text); }

/* ---------- Pilot ---------- */
.as-pilot-panel {
  display: grid; gap: 48px; padding: clamp(28px, 5vw, 64px);
  border: 1px solid var(--border-strong); border-radius: 12px; background: var(--surface);
}
@media (min-width: 1024px) { .as-pilot-panel { grid-template-columns: 7fr 5fr; gap: 64px; align-items: start; } }
.as-pilot-copy h2 { font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.025em; }
.as-pilot-copy > p { margin-top: 18px; font-size: 1.08rem; line-height: 1.6; max-width: 56ch; }
.as-pilot-steps { margin-top: 36px; display: grid; gap: 22px; }
.as-pilot-steps li { display: grid; grid-template-columns: 36px 1fr; gap: 16px; }
.as-pilot-steps .n {
  width: 32px; height: 32px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--border-strong); color: var(--accent); font-size: 0.85rem; font-weight: 600;
}
.as-pilot-steps h3 { font-size: 1.02rem; line-height: 1.3; padding-top: 5px; }
.as-pilot-steps p { margin-top: 6px; font-size: 0.95rem; line-height: 1.55; }
.as-pilot-cta { padding: 32px; border: 1px solid var(--border-strong); border-radius: 10px; background: var(--bg); }
.as-pilot-cta h3 { font-size: 1.35rem; }
.as-pilot-cta > p { margin-top: 12px; font-size: 0.96rem; line-height: 1.6; }
.as-pilot-btn { margin-top: 26px; width: 100%; justify-content: center; }
.as-pilot-cta .as-pilot-alt { margin-top: 14px; font-size: 0.88rem; text-align: center; color: var(--text-faint); }
.as-pilot-alt a { color: var(--accent); }

/* ---------- Contact ---------- */
.as-contact { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); }
@media (min-width: 768px) { .as-contact { grid-template-columns: repeat(2, 1fr); } }
.as-contact .as-card h3 { margin-top: 0; }
.as-contact .as-card p { margin-top: 6px; }
.as-contact dl { margin: 0; }
.as-contact dt { font-size: 0.78rem; color: var(--text-muted); letter-spacing: 0.06em; text-transform: uppercase; }
.as-contact dd { margin: 4px 0 16px; color: var(--accent); overflow-wrap: anywhere; }
.as-contact dd:last-child { margin-bottom: 0; }

/* ---------- Home teaser (index.html) ---------- */
.as-teaser-grid { display: grid; gap: 48px; align-items: center; }
@media (min-width: 1024px) { .as-teaser-grid { grid-template-columns: 5fr 7fr; gap: 64px; } }
.as-teaser h2 { font-size: clamp(2rem, 4vw, 3rem); }
.as-teaser p { margin-top: 18px; font-size: 1.05rem; max-width: 52ch; }
.as-teaser .hero-actions { margin-top: 32px; }
.as-teaser .as-checks { margin-top: 24px; }
.as-teaser .as-eyebrow { display: block; }
.as-teaser-media { margin: 0; }
.as-teaser-link { display: block; }
.as-teaser-link img { width: 100%; height: auto; background: #F8FAFC; }
.as-teaser-link:hover { border-color: var(--accent); }
.as-teaser-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.as-teaser-media figcaption { margin-top: 12px; font-size: 0.86rem; font-weight: 400; color: var(--text-faint); }

/* ---------- Lightbox ---------- */
.as-lightbox {
  border: 0; padding: 0; margin: 0; background: transparent; color: var(--text);
  width: 100vw; height: 100vh; max-width: 100vw; max-height: 100vh; overflow: hidden;
}
.as-lightbox::backdrop { background: rgba(5, 5, 7, 0.95); }
.as-lightbox[open] .as-lightbox-inner { animation: as-fade 0.25s var(--ease); }
@keyframes as-fade { from { opacity: 0; transform: scale(0.985); } to { opacity: 1; transform: none; } }
.as-lightbox-inner { position: relative; width: 100%; height: 100%; display: flex; flex-direction: column; }
.as-lightbox-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 16px; }
.as-lightbox-count { font-size: 0.85rem; color: var(--text-muted); }
.as-lightbox-actions { display: flex; gap: 8px; }
.as-lightbox-btn {
  width: 44px; height: 44px; border-radius: 6px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer; transition: border-color var(--t-fast);
}
.as-lightbox-btn:hover { border-color: var(--accent); }
.as-lightbox-btn svg { width: 22px; height: 22px; }
.as-lightbox-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.as-lightbox-scroll { flex: 1; overflow: auto; display: flex; align-items: flex-start; justify-content: center; padding: 8px 16px 16px; }
.as-lightbox-scroll img { max-width: min(1600px, 100%); height: auto; margin: auto; border-radius: 8px; }
@media (max-width: 767px) {
  .as-lightbox-scroll { justify-content: flex-start; }
  .as-lightbox-scroll img { max-width: none; width: 1100px; }
}
.as-lightbox-caption { color: var(--text-muted); font-size: 0.9rem; padding: 12px 24px 20px; text-align: center; }
@media (prefers-reduced-motion: reduce) { .as-lightbox[open] .as-lightbox-inner { animation: none; } }
