/* ============================================================================
 * sections.css — page section layouts for the marketing narrative:
 * hero (parallax), logo strip, featured four, capabilities, live widgets,
 * feature illustrations, productivity loop, dashboards, Lumina climax,
 * trust, plays heroes, and CTA bands. Depends on tokens/base/components.
 * ==========================================================================*/

/* ---------------------------------------------------------------------------
 * Section tones
 * ------------------------------------------------------------------------- */
/* Grid/flex items default to min-width:auto, which lets an intrinsically wide
   child (e.g. an SVG with a 1200px viewBox) blow past the viewport. Reset it. */
.hero-grid > *, .split > *, .lumina-climax-grid > *, .loop > *,
.featured-grid > *, .trust-grid > *, .illus-grid > *, .capgrid > *,
.mascot-states > *, .module-row > *, .btn-row > * { min-width: 0; }
.hero-visual, .split-media, .split-copy, .dash-wrap, .browser { min-width: 0; max-width: 100%; }

.section.alt { background: var(--surface-2); }
.section.ink { background: var(--grad-deep); color: rgba(255,255,255,0.82); }
.section.ink h1, .section.ink h2, .section.ink h3 { color: #fff; }
.section.ink .lead { color: rgba(255,255,255,0.78); }

/* faint top spectrum hairline for a section (edge use of band-of-light) */
.band-top { position: relative; }
.band-top::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: var(--band); opacity: 0.9; }

/* ---------------------------------------------------------------------------
 * HERO
 * ------------------------------------------------------------------------- */
.hero {
  position: relative; overflow: hidden;
  padding-top: clamp(48px, 7vw, 96px);
  padding-bottom: clamp(56px, 8vw, 120px);
  background:
    radial-gradient(1200px 620px at 8% -20%, rgba(24,104,219,0.10), transparent 60%),
    radial-gradient(900px 560px at 108% 4%, rgba(73,178,182,0.09), transparent 60%),
    var(--surface);
}
.hero .constellation { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; opacity: 0.7; }
.hero-grid {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr; gap: clamp(40px, 5vw, 72px); align-items: center;
}
.hero-copy { max-width: 620px; }
.hero-copy .eyebrow-pill { margin-bottom: var(--s5); }
.hero-copy .honeycomb { margin-bottom: var(--s4); }
.hero h1 { font-size: var(--fs-display); line-height: 1.0; letter-spacing: -0.03em; margin-bottom: var(--s5); }
.hero h1 .hl { color: var(--blue); }
.hero .lead { font-size: var(--fs-lead); color: var(--ink-soft); max-width: 46ch; margin-bottom: var(--s6); }
.hero .btn-row { margin-bottom: var(--s3); }
.hero .trial { font-size: var(--fs-xs); color: var(--ink-mute); font-weight: 600; }

/* hero product visual + floating chips (parallax layers) */
.hero-visual { position: relative; }
.hero-visual .browser { position: relative; z-index: 2; }
.float-chip {
  position: absolute; z-index: 3;
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow-bento); padding: 12px 14px;
  display: flex; align-items: center; gap: 10px;
}
.float-chip .fc-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.float-chip .fc-ic svg { width: 18px; height: 18px; stroke: #fff; fill: none; }
.float-chip b { font-family: var(--font-display); font-size: 1.0625rem; font-weight: 700; display: block; line-height: 1; }
.float-chip small { font-size: 11px; color: var(--ink-mute); font-weight: 600; }
.float-chip.chip-a { top: -18px; right: 8px; }
.float-chip.chip-b { bottom: -18px; left: 8px; }
.float-chip .lumina-orb { width: 30px; height: 30px; }
@media (min-width: 640px) {
  .float-chip.chip-a { right: -12px; }
  .float-chip.chip-b { left: -16px; }
}
@media (max-width: 440px) {
  .float-chip { padding: 9px 11px; }
  .float-chip small { display: none; }
}

.hero-logos { position: relative; z-index: 1; margin-top: clamp(40px, 5vw, 64px); }
.hero-logos .trusted-label { margin-bottom: var(--s4); }

@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: 1.02fr 1.1fr; }
}

/* ---------------------------------------------------------------------------
 * FEATURED FOUR
 * ------------------------------------------------------------------------- */
.featured-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: var(--s5); }

/* ---------------------------------------------------------------------------
 * LIVE WIDGET (tabbed, skeleton -> content)
 * ------------------------------------------------------------------------- */
.widget { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-bento); overflow: hidden; }
.widget .wtabs { display: flex; gap: 4px; padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.widget .wtab { font-size: var(--fs-xs); font-weight: 700; color: var(--ink-mute); padding: 8px 14px; border-radius: 8px; cursor: pointer; border: none; background: none; }
.widget .wtab[aria-selected="true"] { background: #fff; color: var(--blue-deep); box-shadow: var(--shadow-sm); }
.widget .wbody { position: relative; padding: 18px; min-height: 280px; }
.widget .wpane { display: none; }
.widget .wpane.is-active { display: block; }
.widget .wskel { position: absolute; inset: 18px; display: flex; flex-direction: column; gap: 12px; }
.widget.is-loaded .wskel { display: none; }
.widget:not(.is-loaded) .wpanes { visibility: hidden; }

/* ---------------------------------------------------------------------------
 * PRODUCTIVITY LOOP
 * ------------------------------------------------------------------------- */
.loop { display: grid; grid-template-columns: 1fr; gap: var(--s5); }
.loop-node { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 26px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 10px; position: relative; }
.loop-node .ln-ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; }
.loop-node .ln-ic svg { width: 24px; height: 24px; stroke: #fff; fill: none; }
.loop-node h3 { font-size: 1.25rem; }
.loop-node p { font-size: var(--fs-sm); color: var(--ink-mute); line-height: 1.55; }
.loop-node.n1 .ln-ic { background: var(--grad-blue); }
.loop-node.n2 .ln-ic { background: linear-gradient(150deg,#922791,#6f1c6e); }
.loop-node.n3 .ln-ic { background: linear-gradient(150deg,#8ac036,#5f8d1d); }
.loop-outcome { margin-top: var(--s6); }
@media (min-width: 860px) { .loop { grid-template-columns: repeat(3, 1fr); } }

/* ---------------------------------------------------------------------------
 * DASHBOARD wrapper (holds the inline SVG bento replica)
 * ------------------------------------------------------------------------- */
.dash-wrap { position: relative; }
.dash-wrap .browser__body { padding: 0; }
.sample-tag { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-size: 10.5px; font-weight: 700; color: var(--ink-faint); letter-spacing: 0.03em; }
.sample-tag::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--ink-faint); }

/* horizontally scrollable frame for dense replicas on small screens */
.scroll-frame { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.scroll-frame > svg { min-width: 680px; }
.scroll-hint { display: none; font-size: var(--fs-xs); color: var(--ink-faint); text-align: center; margin-top: var(--s3); }
@media (max-width: 767.98px) { .scroll-hint { display: block; } }

/* ---------------------------------------------------------------------------
 * LUMINA climax (dark)
 * ------------------------------------------------------------------------- */
.lumina-section { position: relative; overflow: hidden; }
.lumina-section .constellation { opacity: 0.5; }
.lumina-climax-grid { display: grid; grid-template-columns: 1fr; gap: clamp(32px, 5vw, 64px); align-items: center; position: relative; z-index: 1; }
.lumina-climax-grid .checks li { color: rgba(255,255,255,0.9); }
@media (min-width: 1024px) { .lumina-climax-grid { grid-template-columns: 1fr 1fr; } }

/* checklist */
.checks { list-style: none; display: flex; flex-direction: column; gap: 14px; }
.checks li { display: flex; gap: 12px; align-items: flex-start; font-size: var(--fs-body); font-weight: 600; color: var(--ink-soft); line-height: 1.45; }
.checks li::before {
  content: ""; flex: none; width: 24px; height: 24px; border-radius: 7px; margin-top: 1px;
  background: var(--green-tint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%235f8d1d' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 14px no-repeat;
}
.section.ink .checks li::before { background-color: rgba(138,192,54,0.22); }

/* mascot states row */
.mascot-states { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: var(--s4); }
.mstate { display: flex; flex-direction: column; align-items: center; gap: 12px; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 22px 18px; box-shadow: var(--shadow-sm); text-align: center; }
.mstate b { font-size: 0.9375rem; }
.mstate small { font-size: var(--fs-xs); color: var(--ink-mute); font-weight: 500; line-height: 1.4; }

/* ---------------------------------------------------------------------------
 * TRUST
 * ------------------------------------------------------------------------- */
.trust-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: var(--s4); }

/* ---------------------------------------------------------------------------
 * FEATURE ILLUSTRATIONS
 * ------------------------------------------------------------------------- */
.illus-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: var(--s6); }
.illus-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; }
.illus-card .illus-art { aspect-ratio: 4 / 3; background: var(--surface-2); display: grid; place-items: center; overflow: hidden; }
.illus-card .illus-art svg, .illus-card .illus-art img { width: 100%; height: 100%; object-fit: cover; }
.illus-card .illus-body { padding: 22px 24px 26px; }
.illus-card h3 { font-size: 1.25rem; margin-bottom: 8px; }
.illus-card p { font-size: var(--fs-sm); color: var(--ink-mute); line-height: 1.55; }

/* ---------------------------------------------------------------------------
 * PLAYS hero (For QA / product teams / Jira)
 * ------------------------------------------------------------------------- */
.play-hero { position: relative; overflow: hidden; padding-top: clamp(40px, 6vw, 80px); padding-bottom: clamp(48px, 6vw, 88px); }
.play-hero .eyebrow { margin-bottom: var(--s4); }
.play-hero h1 { font-size: var(--fs-h1); margin-bottom: var(--s5); max-width: 18ch; }
.play-hero .lead { margin-bottom: var(--s6); }

/* ---------------------------------------------------------------------------
 * CTA band (a CTA in every section; big closing band)
 * ------------------------------------------------------------------------- */
.cta-band { position: relative; overflow: hidden; text-align: center; }
.cta-band .container { position: relative; z-index: 1; }
.cta-band h2 { font-size: var(--fs-h1); margin-bottom: var(--s5); max-width: 20ch; margin-inline: auto; }
.cta-band .lead { margin-inline: auto; margin-bottom: var(--s7); }
.cta-band .btn-row { justify-content: center; }

.finale { background: var(--grad-deep); color: #fff; }
.finale h2 { color: #fff; }
.finale .band-art { height: 34px; max-width: 156px; margin: 0 auto var(--s8); background: var(--honeycomb) center / contain no-repeat; }
.finale h2 .hl { background: linear-gradient(90deg, #6db0ff, #4fd0d4); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

/* inline CTA row that closes a mid-page section */
.section-cta { margin-top: var(--s8); }
.section-cta.center { display: flex; justify-content: center; }

/* ---------------------------------------------------------------------------
 * Generic two-column split (copy + media)
 * ------------------------------------------------------------------------- */
.split { display: grid; grid-template-columns: 1fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.split .split-media { position: relative; }
@media (min-width: 960px) {
  .split { grid-template-columns: 1fr 1fr; }
  .split.media-left .split-copy { order: 2; }
  .split.wide-media { grid-template-columns: 0.9fr 1.1fr; }
}
