/* Cinematic homepage layer: scoped to the product home only. */
.home-shell {
  --home-bg: oklch(0.085 0.014 285);
  --home-sidebar: oklch(0.105 0.016 282);
  --home-surface: oklch(0.145 0.02 282);
  --home-surface-raised: oklch(0.18 0.027 281);
  --home-line: oklch(0.31 0.035 280 / 0.72);
}

.home-main {
  background:
    radial-gradient(circle at 52% -8%, oklch(0.38 0.13 254 / 0.22), transparent 34%),
    radial-gradient(circle at 92% 10%, oklch(0.31 0.14 318 / 0.17), transparent 28%),
    radial-gradient(circle at 16% 48%, oklch(0.26 0.1 290 / 0.12), transparent 32%),
    var(--home-bg);
}

.home-sidebar {
  background:
    radial-gradient(circle at 15% 9%, oklch(0.4 0.14 255 / 0.16), transparent 23%),
    var(--home-sidebar);
}

.home-brand-mark,
.home-new-button,
.home-primary-action {
  background: oklch(0.68 0.17 150);
}

.home-brand-mark {
  box-shadow: 0 0 0 1px oklch(0.82 0.13 150 / 0.18), 0 0 18px oklch(0.67 0.17 150 / 0.24);
}

.home-topbar {
  background: oklch(0.095 0.018 282 / 0.88);
}

.home-content {
  width: min(1440px, calc(100% - 48px));
  padding-top: 22px;
}

.home-hero.home-hero-cinematic {
  isolation: isolate;
  min-height: 650px;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: hidden;
  padding: 26px 30px 22px;
  border-radius: 16px;
  border: 1px solid oklch(0.48 0.08 282 / 0.32);
  background: oklch(0.095 0.018 282 / 0.82);
  box-shadow: none;
}

.home-hero.home-hero-cinematic::before {
  z-index: -2;
  background:
    radial-gradient(circle at 50% -8%, oklch(0.56 0.17 250 / 0.24), transparent 36%),
    radial-gradient(circle at 8% 34%, oklch(0.45 0.17 296 / 0.14), transparent 31%),
    linear-gradient(180deg, oklch(0.16 0.045 282 / 0.74), transparent 64%);
}

.home-hero.home-hero-cinematic::after {
  width: 520px;
  height: 520px;
  right: -130px;
  top: -260px;
  z-index: -1;
  background: oklch(0.56 0.18 322 / 0.12);
  filter: blur(38px);
}

.home-hero-aurora,
.home-hero-aurora i {
  position: absolute;
  pointer-events: none;
}

.home-hero-aurora {
  inset: 0;
  z-index: -1;
}

.home-hero-aurora i {
  border-radius: 50%;
  filter: blur(44px);
  opacity: 0.38;
}

.home-hero-aurora i:nth-child(1) {
  width: 240px;
  height: 180px;
  left: 16%;
  top: 18%;
  background: oklch(0.54 0.17 286 / 0.4);
}

.home-hero-aurora i:nth-child(2) {
  width: 300px;
  height: 220px;
  left: 46%;
  top: -13%;
  background: oklch(0.59 0.16 242 / 0.36);
}

.home-hero-aurora i:nth-child(3) {
  width: 220px;
  height: 180px;
  right: 7%;
  top: 25%;
  background: oklch(0.54 0.17 328 / 0.3);
}

.home-showcase {
  position: relative;
  width: min(1260px, 100%);
  height: 240px;
  perspective: 1200px;
}

.home-showcase-card {
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  --slide-shift: 0%;
  --slide-scale: 0.74;
  --slide-rotate: 0deg;
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(620px, 58%);
  height: 226px;
  overflow: hidden;
  padding: 0;
  border: 0;
  border-radius: 14px;
  color: var(--white);
  text-align: left;
  background-color: oklch(0.12 0.02 282);
  opacity: 0.72;
  translate: -50% -50%;
  transform: translateX(var(--slide-shift)) scale(var(--slide-scale)) rotateX(var(--tilt-x)) rotateY(calc(var(--slide-rotate) + var(--tilt-y)));
  transform-style: preserve-3d;
  transition: transform 520ms cubic-bezier(.16, 1, .3, 1), opacity 360ms ease-out, filter 240ms ease-out;
}

.home-showcase-card video {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: oklch(0.1 0.02 282);
}

.home-showcase-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(circle at var(--spot-x, 50%) var(--spot-y, 50%), oklch(0.9 0.06 260 / 0.18), transparent 26%),
    linear-gradient(180deg, oklch(0.05 0.02 280 / 0.04) 30%, oklch(0.04 0.02 280 / 0.92) 100%);
}

.home-showcase-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  z-index: 4;
  box-shadow: inset 0 0 0 1px oklch(0.78 0.06 275 / 0.3);
  pointer-events: none;
}

.home-showcase-card.left {
  --slide-shift: -78%;
  --slide-scale: 0.74;
  --slide-rotate: 7deg;
  z-index: 1;
  filter: saturate(0.88) brightness(0.74);
}

.home-showcase-card.featured {
  --slide-shift: 0%;
  --slide-scale: 1;
  --slide-rotate: 0deg;
  z-index: 3;
  opacity: 1;
  filter: saturate(1.08) brightness(0.92);
}

.home-showcase-card.right {
  --slide-shift: 78%;
  --slide-scale: 0.74;
  --slide-rotate: -7deg;
  z-index: 1;
  filter: saturate(0.86) brightness(0.7);
}

.home-showcase-card:hover,
.home-showcase-card:focus-visible {
  opacity: 1;
  filter: saturate(1.08) brightness(1.02);
}

.home-showcase-card.featured:hover,
.home-showcase-card.featured:focus-visible {
  --slide-scale: 1.015;
}

.home-showcase-control {
  position: absolute;
  top: 50%;
  z-index: 6;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: oklch(0.93 0.02 282);
  background: oklch(0.12 0.025 282 / 0.82);
  box-shadow: inset 0 0 0 1px oklch(0.65 0.06 282 / 0.35);
  translate: 0 -50%;
  transition: background 160ms ease-out, transform 160ms cubic-bezier(.22, 1, .36, 1);
}

.home-showcase-control:hover,
.home-showcase-control:focus-visible {
  background: oklch(0.24 0.075 282 / 0.94);
  transform: scale(1.06);
}

.home-showcase-control.previous {
  left: 3%;
}

.home-showcase-control.next {
  right: 3%;
}

.home-showcase-control svg {
  width: 16px;
  height: 16px;
}

.home-showcase-control.previous svg {
  rotate: 180deg;
}

.home-showcase-badge,
.home-showcase-meta,
.home-showcase-open {
  position: absolute;
  z-index: 3;
}

.home-showcase-badge {
  top: 14px;
  left: 14px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 27px;
  padding: 0 9px;
  border-radius: 999px;
  color: oklch(0.93 0.02 275);
  background: oklch(0.1 0.025 280 / 0.78);
  font-size: 10px;
  font-weight: 750;
  backdrop-filter: blur(8px);
}

.home-showcase-badge svg {
  width: 13px;
  height: 13px;
  color: oklch(0.76 0.14 275);
}

.home-showcase-meta {
  left: 17px;
  right: 17px;
  bottom: 15px;
  display: grid;
  gap: 3px;
  transform: translateZ(18px);
}

.home-showcase-meta strong {
  color: var(--white);
  font-size: 14px;
}

.home-showcase-meta small {
  color: oklch(0.82 0.02 280);
  font-size: 9px;
}

.home-showcase-open {
  right: 17px;
  bottom: 17px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: oklch(0.91 0.02 280);
  font-size: 10px;
  font-weight: 700;
  opacity: 0;
  transform: translateX(-5px);
  transition: opacity 160ms ease-out, transform 160ms ease-out;
}

.home-showcase-open svg {
  width: 12px;
  height: 12px;
}

.home-showcase-card.featured .home-showcase-meta {
  right: 110px;
}

.home-showcase-card.featured:hover .home-showcase-open,
.home-showcase-card.featured:focus-visible .home-showcase-open {
  opacity: 1;
  transform: translateX(0);
}

.home-hero.home-hero-cinematic .home-hero-copy {
  z-index: 4;
  width: min(920px, 100%);
  align-self: center;
  padding: 18px 20px 14px;
  text-align: center;
}

.home-hero.home-hero-cinematic .home-hero-tag {
  min-height: 28px;
  color: oklch(0.88 0.09 281);
  background: oklch(0.2 0.06 282 / 0.62);
  box-shadow: inset 0 0 0 1px oklch(0.66 0.13 282 / 0.2);
}

.home-glitch-title {
  --mx: 50%;
  --my: 50%;
  position: relative;
  width: fit-content;
  max-width: 100%;
  margin: 13px auto 11px !important;
  color: oklch(0.96 0.01 280);
  font-size: 48px !important;
  line-height: 1.08 !important;
  letter-spacing: -0.035em !important;
  cursor: crosshair;
  text-wrap: balance;
}

.home-title-text {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  opacity: 1;
  transition: opacity 120ms ease-out;
}

.home-title-text > span {
  color: oklch(0.78 0.15 295);
}

.home-title-text strong {
  color: oklch(0.92 0.065 36);
  font-weight: 820;
}

.home-glitch-title::before,
.home-glitch-title::after {
  display: none;
}

.home-title-canvas {
  position: absolute;
  z-index: 3;
  display: block;
  max-width: none;
  opacity: 0;
  pointer-events: none;
  contain: strict;
  transition: opacity 100ms ease-out;
}

.home-glitch-title.canvas-ready .home-title-text {
  opacity: 1;
}

.home-glitch-title.canvas-ready.is-dissolving .home-title-text {
  opacity: 0.34;
}

.home-glitch-title.canvas-ready.is-dissolving .home-title-canvas {
  opacity: 1;
}

.home-glitch-title.is-dissolving .home-title-canvas {
  will-change: contents;
}

.home-showcase-dots {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 18px;
}

.home-showcase-dots button {
  width: 22px;
  height: 3px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: oklch(0.53 0.02 282 / 0.65);
  transition: width 220ms cubic-bezier(.22, 1, .36, 1), background 160ms ease-out;
}

.home-showcase-dots button.active {
  width: 38px;
  background: oklch(0.96 0.01 282);
}

.home-showcase-dots button:focus-visible {
  outline: 2px solid oklch(0.72 0.15 285);
  outline-offset: 4px;
}

.home-hero.home-hero-cinematic .home-hero-copy > p {
  max-width: 64ch;
  margin-inline: auto;
  color: oklch(0.82 0.025 282);
}

.home-hero.home-hero-cinematic .home-hero-points,
.home-hero.home-hero-cinematic .home-hero-actions {
  justify-content: center;
}

.home-hero.home-hero-cinematic .home-hero-points span {
  color: oklch(0.86 0.025 282);
}

.home-hero.home-hero-cinematic .home-hero-points svg {
  color: oklch(0.72 0.16 151);
}

.home-hero.home-hero-cinematic .home-secondary-action {
  border-color: oklch(0.48 0.08 282 / 0.7);
  background: oklch(0.16 0.035 282 / 0.72);
}

.home-live-strip {
  width: min(760px, 100%);
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 4px;
  border-radius: 10px;
  color: oklch(0.79 0.02 282);
  background: oklch(0.13 0.025 282 / 0.76);
  box-shadow: inset 0 0 0 1px oklch(0.43 0.055 282 / 0.38);
}

.home-live-strip > span {
  min-width: 0;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 7px;
}

.home-live-strip > span:hover {
  background: oklch(0.2 0.035 282 / 0.78);
}

.home-live-strip i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: oklch(0.7 0.18 150);
  box-shadow: 0 0 9px oklch(0.7 0.18 150 / 0.8);
}

.home-live-strip strong,
.home-live-strip small {
  font-size: 9px;
}

.home-live-strip strong {
  color: oklch(0.9 0.02 282);
}

.home-live-strip .muted i {
  background: oklch(0.56 0.02 282);
  box-shadow: none;
}

.home-live-strip .muted small {
  color: oklch(0.62 0.025 282);
}

.home-start-section,
.home-projects,
.home-agent-starter,
.home-gallery {
  position: relative;
}

.home-create-panel,
.home-feature-list button,
.home-project-item,
.home-gallery-card,
.home-agent-starter {
  background-color: oklch(0.13 0.02 282);
}

.home-create-panel::before,
.home-feature-list button::before,
.home-project-item::before,
.home-gallery-card::before {
  background: radial-gradient(circle at var(--spot-x, 50%) var(--spot-y, 50%), oklch(0.68 0.14 282 / 0.13), transparent 36%);
}

@media (max-width: 1120px) {
  .home-showcase {
    height: 220px;
  }

  .home-showcase-card {
    width: min(560px, 62%);
    height: 204px;
  }

  .home-showcase-card.left {
    --slide-shift: -72%;
  }

  .home-showcase-card.right {
    --slide-shift: 72%;
  }

  .home-glitch-title {
    font-size: 42px !important;
  }
}

@media (max-width: 860px) {
  .home-content {
    width: min(100% - 28px, 720px);
  }

  .home-hero.home-hero-cinematic {
    min-height: 0;
    padding: 20px 16px;
  }

  .home-showcase {
    height: 200px;
  }

  .home-showcase-card {
    width: min(88%, 520px);
    height: 190px;
  }

  .home-showcase-card.left,
  .home-showcase-card.right {
    opacity: 0;
    pointer-events: none;
  }

  .home-showcase-control.previous {
    left: 1.5%;
  }

  .home-showcase-control.next {
    right: 1.5%;
  }

  .home-glitch-title {
    font-size: 36px !important;
  }

  .home-live-strip {
    flex-wrap: wrap;
  }

  .home-live-strip > span {
    flex: 1 1 42%;
  }
}

@media (max-width: 560px) {
  .home-content {
    width: calc(100% - 20px);
    padding-top: 10px;
  }

  .home-hero.home-hero-cinematic {
    border-radius: 12px;
    padding-inline: 10px;
  }

  .home-showcase {
    height: 176px;
  }

  .home-showcase-card {
    width: 94%;
    height: 166px;
  }

  .home-showcase-control {
    width: 34px;
    height: 34px;
  }

  .home-hero.home-hero-cinematic .home-hero-copy {
    padding-inline: 4px;
  }

  .home-glitch-title {
    font-size: 31px !important;
    line-height: 1.15 !important;
  }

  .home-title-text {
    gap: 14px;
  }

  .home-glitch-title::before,
  .home-glitch-title::after,
  .home-title-canvas {
    display: none;
  }

  .home-glitch-title.canvas-ready .home-title-text {
    opacity: 1;
  }
}

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

  .home-showcase-card video {
    transition: none;
  }

  .home-title-canvas {
    display: none;
  }

  .home-glitch-title.canvas-ready .home-title-text {
    opacity: 1;
  }
}
