/* Cuper homepage — mobile-first, outcome before explanation */

:root {
  --home-divider-blue: rgba(10, 132, 255, 0.42);
  --home-divider-fade: rgba(10, 132, 255, 0.12);
  --home-section-pad: clamp(72px, 11vh, 112px);
}

.home-section {
  position: relative;
  isolation: isolate;
  contain: layout style;
  padding: var(--home-section-pad) 0;
  border-top: none;
  scroll-margin-top: calc(64px + env(safe-area-inset-top, 0px));
}

/* Blue-accent chapter divider — centered pill + soft hairline */
.home-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 3px;
  border-radius: 999px;
  background: var(--cuper-blue);
  opacity: 0.72;
  box-shadow: 0 0 20px rgba(10, 132, 255, 0.22);
  pointer-events: none;
}

.home-section::after {
  content: "";
  position: absolute;
  top: 1px;
  left: 50%;
  transform: translateX(-50%);
  width: min(92%, 920px);
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--home-divider-fade) 18%,
    var(--border) 50%,
    var(--home-divider-fade) 82%,
    transparent 100%
  );
  pointer-events: none;
}

/* Alternate canvas so each scroll chapter reads clearly */
.home-see,
.home-file-protect,
.home-section#real-project {
  background: var(--bg-elev);
}

.home-pillars,
.home-why {
  background: var(--bg);
}

.home-section .container {
  max-width: 680px;
}

.home-sec-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  margin-bottom: 14px;
}

.home-sec-label::before,
.home-sec-label::after {
  content: "";
  flex: 0 0 28px;
  height: 1px;
  border-radius: 999px;
}

.home-sec-label::before {
  background: linear-gradient(90deg, transparent, var(--home-divider-blue));
}

.home-sec-label::after {
  background: linear-gradient(90deg, var(--home-divider-blue), transparent);
}

.home-sec-title {
  font-size: clamp(1.5rem, 5vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  text-align: center;
  color: var(--text);
  margin-bottom: 40px;
  line-height: 1.15;
}

/* ── Floating nav (homepage) — no pill container ── */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  padding: calc(12px + env(safe-area-inset-top, 0px)) 24px 0;
  background: transparent;
  border: none;
}

.site-nav-panel {
  max-width: 1160px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 56px;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.site-nav-panel .logo {
  font-size: 1.05rem;
  line-height: 1;
  flex-shrink: 0;
  padding-left: 2px;
}

@media (max-width: 640px) {
  .site-nav {
    padding-left: 20px;
    padding-right: 20px;
  }

  .site-nav-panel {
    min-height: 54px;
    gap: 14px;
  }

  .site-nav-panel .logo {
    font-size: 0.96rem;
    padding-left: 0;
  }

  .nav-actions {
    gap: 12px;
  }
}

/* ── Section 1: Hook (100vh) ── */
.home-hook {
  position: relative;
  isolation: isolate;
  contain: layout style;
  overflow: hidden;
  min-height: 100dvh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(72px + env(safe-area-inset-top, 0px)) 20px 36px;
  text-align: center;
  gap: 22px;
  border-top: none;
  background: var(--bg);
}

/* Hero → first section handoff */
.home-hook::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(92%, 920px);
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--home-divider-fade) 20%,
    var(--home-divider-blue) 50%,
    var(--home-divider-fade) 80%,
    transparent 100%
  );
  pointer-events: none;
}

/* Hero intro — clipped headline rotator */
.home-hook-intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: min(36ch, 92vw);
  margin-bottom: 2px;
  flex-shrink: 0;
  contain: layout style;
}

.home-hook-sub {
  margin: 10px 0 0;
  max-width: min(52ch, 94vw);
  font-size: clamp(0.8125rem, 2.2vw, 0.9375rem);
  line-height: 1.5;
  color: var(--text-sec);
  text-align: center;
}

#homeFeatureBadges {
  margin: 10px auto 6px;
  padding: 0 8px;
}

.home-hook-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  width: 100%;
  max-width: min(440px, 94vw);
  overflow: hidden;
  contain: layout style paint;
}

.home-hook-rotator {
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  font-size: clamp(1.65rem, 6.5vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.12;
  color: var(--text);
  text-align: center;
}

.home-hook-rotator__viewport {
  display: block;
  overflow: hidden;
  width: 100%;
  height: 3.25em;
  min-height: 3.25em;
}

.home-hook-rotator__line {
  display: block;
  width: 100%;
  margin: 0;
  font: inherit;
  line-height: inherit;
  letter-spacing: inherit;
  transform: translate3d(0, 0, 0);
  opacity: 1;
  transition: transform 0.34s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.34s ease;
}

.home-hook-rotator__line.is-hide {
  transform: translate3d(0, -14px, 0);
  opacity: 0;
}

.home-hook-rotator__line.is-prep {
  transition: none;
  transform: translate3d(0, 14px, 0);
  opacity: 0;
}

.home-hook-rotator__line.is-show {
  transform: translate3d(0, 0, 0);
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .home-hook-rotator__line {
    transition: none;
  }
}

/* Phone ↔ Mac visual — live HTML product mockup (see cuper-hero-visual.css) */
.home-connect {
  width: 100%;
  margin: 0;
  contain: layout style paint;
}

.home-hero-interactive {
  contain: layout style paint;
}

.home-hook-stage .home-trust-chips {
  max-width: 100%;
  margin: 0;
}

.home-hook-stage .home-hook-cta {
  width: 100%;
  margin-top: 2px;
}

/* Agent logo rail — auto-sliding strip under headline */
.home-agent-rail {
  width: 100vw;
  max-width: 100vw;
  margin: 4px calc(50% - 50vw) 8px;
  overflow: hidden;
  contain: layout style paint;
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}

.home-agent-rail__track {
  display: flex;
  align-items: center;
  gap: 10px;
  width: max-content;
  padding: 2px 0 6px;
  animation: home-agent-rail 52s linear infinite;
  will-change: transform;
}

.home-agent-rail__item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px 7px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-sec);
  white-space: nowrap;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

.home-agent-rail__item img {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  object-fit: contain;
  flex-shrink: 0;
}

@keyframes home-agent-rail {
  to { transform: translateX(-50%); }
}

.home-hook-stage .home-hook-cta .btn-lg {
  flex: 1 1 auto;
  min-width: min(168px, 46vw);
  max-width: 100%;
}

@keyframes home-line-pulse {
  0%, 100% { opacity: 0.45; }
  50% { opacity: 1; }
}

.home-connect-tags {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 12px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.home-connect-tags span.is-on {
  color: var(--text-sec);
}

/* Trust chips — compact row, not a wall of pills */
.home-trust-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  max-width: min(520px, 100%);
  margin: 0 auto;
}

.home-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-sec);
  background: var(--surface);
  border: 1px solid var(--border);
}

.home-chip img {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  object-fit: contain;
}

.home-chip--check::before {
  content: "✓";
  color: var(--cuper-blue);
  font-weight: 800;
}

.home-hook-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 8px;
}

/* Capability marquee */
.home-marquee-wrap {
  width: 100%;
  height: 2.25rem;
  overflow: hidden;
  contain: layout style paint;
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  margin-top: 16px;
}

.home-marquee {
  display: flex;
  gap: 12px;
  width: max-content;
  animation: home-marquee 40s linear infinite;
}

.home-marquee-item {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--muted);
  white-space: nowrap;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
}

@keyframes home-marquee {
  to { transform: translateX(-50%); }
}

/* Compat fact strip */
.home-compat {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
  min-height: 1.5em;
  margin-top: 4px;
}

.home-compat strong {
  color: var(--text-sec);
  font-weight: 700;
}

/* ── Section 2: See it — streaming multi-agent chat ── */
.home-see {
  contain: layout style;
}

.see-demo {
  max-width: 480px;
  margin: 0 auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  contain: layout style paint;
}

.see-agents {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-elev);
  justify-content: center;
}

.see-agent-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: transparent;
  font-family: inherit;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--muted);
  opacity: 0.45;
  transition: opacity 0.3s, border-color 0.3s, color 0.3s, background 0.3s;
  cursor: default;
}

.see-agent-chip img {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  object-fit: contain;
}

.see-agent-chip.is-active {
  opacity: 1;
  color: var(--text);
  border-color: rgba(10, 132, 255, 0.38);
  background: rgba(10, 132, 255, 0.08);
}

.see-thread {
  padding: 18px 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  height: 248px;
  min-height: 248px;
  max-height: 248px;
  overflow: hidden;
}

.see-bubble {
  border-radius: 14px;
  padding: 12px 14px;
  text-align: left;
}

.see-bubble-user {
  align-self: flex-end;
  max-width: 92%;
  background: rgba(59, 130, 246, 0.16);
  border: 1px solid rgba(96, 165, 250, 0.22);
}

.see-bubble-agent {
  align-self: flex-start;
  max-width: 96%;
  background: var(--silver);
  border: 1px solid var(--border);
}

.see-bubble-label {
  display: block;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}

.see-bubble-agent-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.see-bubble-agent-head img {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  object-fit: contain;
}

.see-bubble-agent-head span {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}

.see-bubble-text {
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text-sec);
  margin: 0;
  min-height: 1.5em;
}

.see-bubble-user .see-bubble-text {
  color: var(--text);
}

.see-stream-cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: var(--cuper-blue);
  margin-left: 1px;
  vertical-align: text-bottom;
  animation: see-blink 1s step-end infinite;
}

@keyframes see-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .see-stream-cursor {
    animation: none;
  }
}

@media (max-width: 520px) {
  .see-agent-chip span {
    display: none;
  }

  .see-agent-chip {
    padding: 7px 9px;
  }

  .see-agent-chip.is-active span {
    display: inline;
  }
}

/* ── Section 3: Six pillars (Chat · Build · Protect · Control · Extend · Remember) ── */
.home-pillars {
  padding: var(--home-section-pad) 0;
  contain: layout style;
}

.home-pillars-container {
  max-width: 900px;
}

.home-pillars-title {
  margin-bottom: 36px;
}

@media (max-width: 640px) {
  .home-pillars-title {
    margin-bottom: 24px;
    font-size: clamp(1.35rem, 5vw, 1.75rem);
  }
}

.home-pillars-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  border: none;
}

.home-pillar {
  padding: 24px 18px 26px;
  text-align: left;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
}

.home-pillar:last-child {
  border-right: 1px solid var(--border);
}

.home-pillar-icon {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 32px;
  height: 32px;
  margin-bottom: 18px;
}

.home-pillar-icon svg {
  width: 28px;
  height: 28px;
}

.home-pillar-icon--chat { color: var(--cuper-blue); }
.home-pillar-icon--build { color: #22c55e; }
.home-pillar-icon--protect { color: #f97316; }
.home-pillar-icon--control { color: #a855f7; }
.home-pillar-icon--extend { color: #eab308; }
.home-pillar-icon--remember { color: var(--cuper-blue); }

.home-pillar h3 {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0 0 10px;
}

.home-pillar p {
  font-size: 0.82rem;
  line-height: 1.45;
  font-weight: 500;
  color: var(--muted);
  margin: 0;
}

@media (max-width: 640px) {
  .home-pillars-container {
    max-width: 100%;
  }

  .home-pillars-row {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .home-pillar {
    padding: 14px 12px 16px;
    border-radius: 12px;
  }

  .home-pillar-icon {
    width: 26px;
    height: 26px;
    margin-bottom: 10px;
  }

  .home-pillar-icon svg {
    width: 22px;
    height: 22px;
  }

  .home-pillar h3 {
    font-size: 0.88rem;
    margin-bottom: 6px;
  }

  .home-pillar p {
    font-size: 0.68rem;
    line-height: 1.35;
  }
}

/* ── Section 4: Why Cuper (side-by-side compare) ── */
.home-why-container {
  max-width: 960px;
  contain: layout style;
}

.home-why-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.home-why-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 0 auto;
}

.home-why-card {
  padding: 22px 20px 24px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  text-align: left;
}

.home-why-card.is-cuper {
  border-color: rgba(59, 130, 246, 0.55);
  box-shadow: 0 0 0 1px rgba(59, 130, 246, 0.12);
}

.home-why-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.home-why-card h3 {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0;
}

.home-why-shield {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.home-why-shield svg {
  width: 24px;
  height: 24px;
}

.home-why-shield--dim {
  color: var(--muted);
  opacity: 0.55;
}

.home-why-shield--on {
  color: var(--cuper-blue);
}

.home-why-card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 0;
  padding: 0;
}

.home-why-card li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.82rem;
  line-height: 1.4;
  font-weight: 500;
  color: var(--muted);
}

.home-why-card.is-cuper li {
  color: var(--text);
}

.home-why-mark {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}

.home-why-mark svg {
  width: 11px;
  height: 11px;
}

.home-why-mark--no {
  background: rgba(148, 163, 184, 0.12);
  color: var(--muted);
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.home-why-mark--yes {
  background: rgba(59, 130, 246, 0.18);
  color: var(--cuper-blue);
  border: 1px solid rgba(59, 130, 246, 0.35);
}

.home-why-trust h3 {
  font-size: clamp(0.92rem, 3.2vw, 1.05rem);
  line-height: 1.25;
  max-width: 20ch;
}

.home-why-trust-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid rgba(59, 130, 246, 0.2);
}

.home-why-trust-cta .btn {
  width: 100%;
  max-width: 320px;
  justify-content: center;
  padding: 12px 18px;
  font-size: 0.82rem;
}

.home-why-cta-note {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--muted);
}

@media (min-width: 720px) {
  .home-why-trust {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto auto;
    column-gap: 24px;
    align-items: start;
  }

  .home-why-trust .home-why-card-head {
    grid-column: 1;
    grid-row: 1;
    margin-bottom: 0;
  }

  .home-why-trust ul {
    grid-column: 1;
    grid-row: 2;
    margin-top: 16px;
  }

  .home-why-trust-cta {
    grid-column: 2;
    grid-row: 1 / span 2;
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    align-self: center;
    min-width: 200px;
  }

  .home-why-trust h3 {
    max-width: none;
  }
}

@media (max-width: 640px) {
  .home-why-compare {
    gap: 10px;
  }

  .home-why-card {
    padding: 16px 12px 18px;
  }

  .home-why-card h3 {
    font-size: 0.88rem;
  }

  .home-why-shield {
    width: 22px;
    height: 22px;
  }

  .home-why-shield svg {
    width: 18px;
    height: 18px;
  }

  .home-why-card ul {
    gap: 10px;
  }

  .home-why-card li {
    font-size: 0.68rem;
    gap: 8px;
  }

  .home-why-mark {
    width: 16px;
    height: 16px;
  }

  .home-why-mark svg {
    width: 9px;
    height: 9px;
  }

  .home-why-trust h3 {
    font-size: 0.82rem;
  }

  .home-why-trust-cta .btn {
    font-size: 0.76rem;
    padding: 11px 14px;
  }
}

/* ── Section 5: Real project ── */
.home-project-card {
  max-width: 360px;
  margin: 0 auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
}

.home-project-head {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.home-project-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.home-project-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  font-size: 0.82rem;
}

.home-project-row span:first-child {
  color: var(--muted);
  font-weight: 600;
}

.home-project-row span:last-child {
  color: var(--text);
  font-weight: 700;
  text-align: right;
}

.home-project-row img {
  width: 16px;
  height: 16px;
  vertical-align: -3px;
  margin-right: 4px;
}

/* ── Section 6: Download ── */
.home-download {
  border-top: none;
  text-align: center;
  padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px));
  background: var(--bg);
}

.home-download .container {
  max-width: 520px;
}

.home-download h2 {
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.home-download .home-sec-label {
  margin-bottom: 16px;
}

.home-download p {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 24px;
  line-height: 1.5;
}

.home-download-note {
  margin-top: 10px;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--muted);
}

.home-download .btn-lg {
  min-width: min(100%, 280px);
}

/* Hide legacy homepage blocks */
.xp-stage,
.xp-ai-wall,
#xp-compare,
.xp-intent-compact,
.xp-legacy-fold,
#pricing,
.fin#download-legacy {
  display: none !important;
}

@media (prefers-reduced-motion: reduce) {
  .home-marquee {
    animation: none !important;
  }

  .home-agent-rail__track {
    animation: none !important;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    padding-bottom: 4px;
  }

  .home-agent-rail {
    mask-image: none;
    -webkit-mask-image: none;
  }
}

@media (max-width: 640px) {
  :root {
    --home-section-pad: clamp(56px, 10vh, 84px);
  }

  .home-section::before {
    width: 32px;
    height: 2px;
  }

  .home-sec-title {
    margin-bottom: 28px;
  }
}

@media (min-width: 900px) {
  .home-hook .container,
  .home-section .container {
    max-width: 960px;
  }

  .home-hook-intro {
    max-width: 24ch;
  }

  .home-hook-rotator__viewport {
    min-height: 2.45em;
  }
}

/* ── File Protection (Protected Files drag-and-drop) ── */
.home-file-protect .container {
  max-width: 980px;
  contain: layout style;
}

.home-file-protect-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(20px, 4vw, 36px);
  align-items: center;
  margin-top: 8px;
}

@media (max-width: 820px) {
  .home-file-protect-split {
    grid-template-columns: 1fr;
  }
}

.home-file-protect-benefits {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-align: left;
}

.home-file-protect-benefits li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 0.86rem;
  color: var(--text-sec);
  line-height: 1.5;
}

.home-file-protect-benefits li svg {
  flex-shrink: 0;
  color: var(--cuper-blue);
  margin-top: 2px;
}

.home-file-protect-benefits strong {
  display: block;
  color: var(--text);
  font-weight: 800;
  font-size: 0.9rem;
  margin-bottom: 2px;
}

.home-fp-demo {
  border-radius: 18px;
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 16px 16px 14px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.22);
  contain: layout style paint;
}

.home-fp-demo-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.home-fp-demo-badge {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(96, 165, 250, 0.22);
  color: var(--cuper-blue);
}

.home-fp-demo-badge svg {
  width: 18px;
  height: 18px;
}

.home-fp-demo-title {
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}

.home-fp-demo-sub {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--muted);
  margin-top: 2px;
}

.home-fp-demo-stage {
  position: relative;
  height: 210px;
  min-height: 210px;
  max-height: 210px;
  overflow: hidden;
  contain: layout style paint;
}

.home-fp-demo-dropzone {
  height: 100%;
  min-height: 100%;
  border-radius: 14px;
  border: 1.5px dashed rgba(148, 163, 184, 0.35);
  background: rgba(15, 23, 42, 0.28);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  padding: 18px 14px 14px;
  overflow: hidden;
  transition: border-color 0.35s, background 0.35s;
  position: relative;
}

.home-fp-demo-drop-hint {
  flex-shrink: 0;
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
}

.home-fp-demo-examples,
.home-fp-demo-vault {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  margin: 0;
}

.home-fp-demo-examples[hidden],
.home-fp-demo-vault[hidden] {
  display: flex !important;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.home-fp-demo.is-active .home-fp-demo-dropzone {
  border-color: rgba(59, 130, 246, 0.55);
  background: rgba(59, 130, 246, 0.06);
}

.home-fp-demo-examples {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.home-fp-demo-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--silver);
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--muted);
}

.home-fp-demo-chip svg {
  width: 14px;
  height: 14px;
  opacity: 0.85;
}

.home-fp-demo-vault {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-content: flex-start;
  gap: 8px;
  width: auto;
  min-height: 0;
  max-height: 9.5rem;
  overflow: hidden;
}

.home-fp-demo-vault[hidden] {
  display: flex !important;
}

.home-fp-demo-capsule {
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid rgba(96, 165, 250, 0.35);
  background: rgba(59, 130, 246, 0.12);
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--cuper-blue);
  animation: home-fp-capsule-in 0.45s ease both;
}

@keyframes home-fp-capsule-in {
  from {
    opacity: 0;
    transform: translateY(6px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.home-fp-demo-drag {
  position: absolute;
  top: 16px;
  right: -2px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #1d232b;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--text);
  pointer-events: none;
  z-index: 2;
}

.home-fp-demo-drag svg {
  width: 16px;
  height: 16px;
  color: var(--cuper-blue);
  flex-shrink: 0;
}

.home-fp-demo:not(.is-reduced) .home-fp-demo-drag {
  animation: home-fp-drag-in 4.5s ease-in-out infinite;
}

@keyframes home-fp-drag-in {
  0%,
  12% {
    opacity: 0;
    transform: translate(48px, -36px) scale(0.92);
  }
  22%,
  38% {
    opacity: 1;
    transform: translate(-12px, 52px) scale(1);
  }
  48%,
  100% {
    opacity: 0;
    transform: translate(-12px, 72px) scale(0.88);
  }
}

.home-fp-demo-caption {
  margin-top: 10px;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  line-height: 1.45;
}

.home-file-protect-approvals {
  position: relative;
  margin-top: clamp(48px, 8vw, 68px);
  padding-top: clamp(44px, 7vw, 60px);
  text-align: center;
}

.home-file-protect-approvals::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(88%, 640px);
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--home-divider-fade) 22%,
    var(--home-divider-blue) 50%,
    var(--home-divider-fade) 78%,
    transparent 100%
  );
  pointer-events: none;
}

.home-file-protect-flow {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px 10px;
  max-width: 720px;
  margin: 20px auto 0;
}

.home-file-protect-step {
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-sec);
}

.home-file-protect-step.is-danger {
  border-color: rgba(239, 68, 68, 0.35);
  color: var(--danger);
}

.home-file-protect-step.is-safe {
  border-color: rgba(59, 130, 246, 0.35);
  color: var(--cuper-blue);
}

.home-file-protect-arrow {
  color: var(--muted);
  font-weight: 900;
  font-size: 0.85rem;
}

@media (prefers-reduced-motion: reduce) {
  .home-fp-demo .home-fp-demo-drag {
    animation: none;
    opacity: 1;
    transform: translate(-12px, 52px);
  }
}

/* Footer — quiet close with blue hairline */
.shell > footer {
  position: relative;
  border-top: none;
  padding: 36px 0 calc(32px + env(safe-area-inset-bottom, 0px));
  background: var(--bg);
}

.shell > footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(92%, 920px);
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--home-divider-fade) 30%,
    var(--border) 50%,
    var(--home-divider-fade) 70%,
    transparent 100%
  );
  pointer-events: none;
}
