/* MyXavi — 21st-inspired showcases
   Scroll media expansion · Radial orbital · Liquid glass · Animated icons */

/* ——— Scroll media expansion ——— */
.sx-expand {
  position: relative;
  height: 220vh;
  background: #07080c;
}

.sx-expand-sticky {
  position: sticky;
  top: 0;
  height: 100svh;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.sx-expand-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(0.35) saturate(0.85);
  transform: scale(1.08);
}

.sx-expand-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 50% 40%, rgba(199, 154, 58, 0.18), transparent 65%),
    linear-gradient(180deg, rgba(7, 8, 12, 0.2), rgba(7, 8, 12, 0.85));
}

.sx-expand-copy {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 1.25rem;
  max-width: 40rem;
  margin-bottom: min(42vh, 22rem);
  transition: opacity 0.2s linear;
}

.sx-expand-copy h2 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  color: #fff;
  line-height: 1.15;
}

.sx-expand-copy p.sx-lead {
  margin: 0;
  color: rgba(244, 245, 247, 0.78);
  font-size: 1.05rem;
}

.sx-hint {
  margin: 1rem 0 0;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #c79a3a;
  font-weight: 600;
}

.sx-expand-media {
  position: absolute;
  left: 50%;
  top: 52%;
  z-index: 3;
  width: min(42vw, 22rem);
  aspect-ratio: 16 / 10;
  border-radius: 1.35rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow:
    0 0 0 1px rgba(199, 154, 58, 0.12),
    0 40px 80px -30px rgba(0, 0, 0, 0.85);
  transform: translate(-50%, -40%) scale(1);
  will-change: transform, width, border-radius;
}

.sx-expand-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.sx-expand-after {
  position: relative;
  z-index: 1;
  margin-top: -30vh;
  padding: 4rem 0 5rem;
  background: linear-gradient(180deg, transparent, #0a0b10 28%);
}

/* ——— Radial Orbital Timeline ——— */
.orb-section {
  overflow: hidden;
}

.orb-layout {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 960px) {
  .orb-layout {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 3rem;
  }
}

.orb-stage {
  --orb-size: min(88vw, 28rem);
  position: relative;
  width: var(--orb-size);
  height: var(--orb-size);
  margin: 0 auto;
}

.orb-ring {
  position: absolute;
  inset: 12%;
  border-radius: 50%;
  border: 1px dashed rgba(199, 154, 58, 0.35);
  animation: orb-spin 48s linear infinite;
}

.orb-ring-2 {
  inset: 4%;
  border-style: solid;
  border-color: rgba(255, 255, 255, 0.06);
  animation-duration: 72s;
  animation-direction: reverse;
}

@keyframes orb-spin {
  to {
    transform: rotate(360deg);
  }
}

.orb-center {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 5.5rem;
  height: 5.5rem;
  margin: -2.75rem 0 0 -2.75rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: -0.02em;
  color: #0a0b10;
  background: linear-gradient(145deg, #e0b85a, #c79a3a);
  box-shadow: 0 0 40px rgba(199, 154, 58, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.45);
  z-index: 2;
}

.orb-node {
  --a: 0deg;
  position: absolute;
  left: 50%;
  top: 50%;
  width: 3.25rem;
  height: 3.25rem;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  background: rgba(17, 19, 26, 0.92);
  color: #f4f5f7;
  cursor: pointer;
  transform: rotate(var(--a)) translate(calc(var(--orb-size) * 0.38)) rotate(calc(-1 * var(--a)));
  transform-origin: center;
  display: grid;
  place-items: center;
  transition: border-color 0.25s, box-shadow 0.25s, background 0.25s, transform 0.35s var(--ease);
  z-index: 3;
}

.orb-node:hover,
.orb-node.is-active {
  border-color: rgba(199, 154, 58, 0.75);
  background: rgba(199, 154, 58, 0.16);
  box-shadow: 0 0 24px rgba(199, 154, 58, 0.35);
}

.orb-node .ai-icon {
  width: 1.35rem;
  height: 1.35rem;
}

.orb-detail {
  padding: 1.75rem 1.5rem;
  border-radius: 1.35rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  min-height: 14rem;
}

.orb-detail[hidden] {
  display: none;
}

.orb-detail.is-in {
  animation: orb-detail-in 0.45s var(--ease) both;
}

@keyframes orb-detail-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.orb-detail .ax-eyebrow {
  margin-bottom: 0.65rem;
}

.orb-detail h3 {
  margin: 0 0 0.65rem;
  font-size: 1.45rem;
  color: #fff;
}

.orb-detail p {
  margin: 0;
  color: rgba(244, 245, 247, 0.75);
  line-height: 1.65;
}

.orb-status {
  display: inline-flex;
  margin-top: 1.1rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #0a0b10;
  background: #c79a3a;
}

/* ——— Liquid Glass button ——— */
.btn-liquid {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 52px;
  padding: 0.9rem 1.5rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  overflow: hidden;
  isolation: isolate;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none !important;
  color: #0a0b10 !important;
  -webkit-text-fill-color: #0a0b10;
  background: rgba(224, 184, 90, 0.55);
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    inset 0 -10px 24px rgba(199, 154, 58, 0.25),
    0 14px 40px -14px rgba(199, 154, 58, 0.55);
  transition: transform 0.25s var(--ease), box-shadow 0.25s;
}

.btn-liquid:hover {
  transform: translateY(-2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.65),
    inset 0 -10px 28px rgba(199, 154, 58, 0.35),
    0 18px 48px -12px rgba(199, 154, 58, 0.65);
  color: #0a0b10 !important;
  -webkit-text-fill-color: #0a0b10;
}

.btn-liquid .lb-glass {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  border-radius: inherit;
  pointer-events: none;
}

.btn-liquid .lb-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(18px);
  opacity: 0.75;
}

.btn-liquid .lb-blob-a {
  width: 70%;
  height: 120%;
  left: -20%;
  top: -40%;
  background: radial-gradient(circle, #f0d28a, transparent 70%);
  animation: lb-drift-a 7s ease-in-out infinite alternate;
}

.btn-liquid .lb-blob-b {
  width: 60%;
  height: 100%;
  right: -15%;
  bottom: -45%;
  background: radial-gradient(circle, #c79a3a, transparent 70%);
  animation: lb-drift-b 8s ease-in-out infinite alternate;
}

.btn-liquid .lb-spec {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0.45), transparent 42%, transparent 58%, rgba(255, 255, 255, 0.12));
  opacity: 0.55;
}

.btn-liquid > span:not(.lb-glass) {
  position: relative;
  z-index: 1;
}

.ax-price .btn-liquid {
  width: 100%;
}

@keyframes lb-drift-a {
  from {
    transform: translate(0, 0) scale(1);
  }
  to {
    transform: translate(18px, 12px) scale(1.12);
  }
}

@keyframes lb-drift-b {
  from {
    transform: translate(0, 0) scale(1);
  }
  to {
    transform: translate(-14px, -10px) scale(1.08);
  }
}

/* ——— Animated icons ——— */
.ai-icon {
  display: inline-block;
  width: 1.5rem;
  height: 1.5rem;
  color: #e0b85a;
}

.ai-icon svg {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}

.ai-icon--pulse {
  animation: ai-pulse 2.4s ease-in-out infinite;
}

.ai-icon--spin-slow svg {
  animation: ai-spin 10s linear infinite;
  transform-origin: center;
}

.ai-icon--draw .ai-stroke {
  stroke-dasharray: 64;
  stroke-dashoffset: 64;
  animation: ai-draw 2.8s ease forwards infinite;
}

.ai-icon--bounce {
  animation: ai-bounce 2.2s ease-in-out infinite;
}

.ai-icon--float {
  animation: ai-float 3s ease-in-out infinite;
}

@keyframes ai-pulse {
  0%,
  100% {
    transform: scale(1);
    filter: drop-shadow(0 0 0 rgba(224, 184, 90, 0));
  }
  50% {
    transform: scale(1.08);
    filter: drop-shadow(0 0 8px rgba(224, 184, 90, 0.55));
  }
}

@keyframes ai-spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes ai-draw {
  0% {
    stroke-dashoffset: 64;
  }
  40%,
  100% {
    stroke-dashoffset: 0;
  }
}

@keyframes ai-bounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

@keyframes ai-float {
  0%,
  100% {
    transform: translateY(0) rotate(-2deg);
  }
  50% {
    transform: translateY(-5px) rotate(2deg);
  }
}

.ax-bento-card .ai-icon,
.ax-feature .ai-icon {
  margin-bottom: 0.85rem;
}

@media (prefers-reduced-motion: reduce) {
  .orb-ring,
  .btn-liquid .lb-blob,
  .ai-icon--pulse,
  .ai-icon--spin-slow svg,
  .ai-icon--draw .ai-stroke,
  .ai-icon--bounce,
  .ai-icon--float {
    animation: none !important;
  }

  .ai-icon--draw .ai-stroke {
    stroke-dashoffset: 0;
  }

  .sx-expand {
    height: auto;
  }

  .sx-expand-sticky {
    position: relative;
    height: auto;
    min-height: 100svh;
    padding: 6rem 0 4rem;
  }

  .sx-expand-media {
    position: relative;
    left: auto;
    top: auto;
    width: min(92vw, 36rem);
    margin: 2rem auto 0;
    transform: none;
  }

  .sx-expand-copy {
    margin-bottom: 0;
  }

  .sx-expand-after {
    margin-top: 0;
  }
}
