:root {
  --bg: #020b19;
  --surface: rgba(5, 22, 43, .86);
  --text: #f7fbff;
  --muted: #a6c6e7;
  --cyan: #18dcf5;
  --blue: #4ca9ff;
  --violet: #a85cff;
  --line: rgba(89, 189, 255, .28);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; color: var(--text); background: var(--bg); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }

.ecosystem-header { height: 64px; padding: 0 max(28px, calc((100vw - 1180px) / 2)); display: flex; align-items: center; justify-content: space-between; gap: 32px; border-bottom: 1px solid rgba(42,177,255,.26); background: rgba(2,11,25,.84); backdrop-filter: blur(16px); position: relative; z-index: 50; }
/* IPatyj: cyan bar “I” = capital height of “P”, then white “Patyj”. */
.wordmark,
.hero-title-wrap h1 {
  display: inline-flex;
  align-items: baseline;
  font-weight: 820;
  letter-spacing: -.055em;
  line-height: 1.12;
}
.wordmark { font-size: 2rem; }
.brand-i {
  display: inline-block;
  flex: 0 0 auto;
  width: .42em;
  height: .72em;
  height: 1cap;
  margin: 0 .08em 0 0;
  border-radius: .11em;
  vertical-align: baseline;
  background: linear-gradient(180deg, #25f4ff, #05a6eb);
  box-shadow: 0 0 12px rgba(24, 220, 245, .38);
}
.brand-j {
  background: linear-gradient(150deg, #b890ff 14%, #e85de9 52%, #55e6ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 18px rgba(205, 105, 255, .28);
}
nav { display: flex; align-items: center; gap: 46px; color: #d9e6f3; }
nav a { padding: 21px 0 18px; border-bottom: 3px solid transparent; font-size: .94rem; }
nav a:hover, nav a.active { color: white; border-color: var(--cyan); }
.language { display: flex; border: 1px solid rgba(25,184,255,.48); border-radius: 999px; overflow: hidden; }
.language button { min-width: 52px; padding: 8px 14px; border: 0; color: #a8c9ee; background: transparent; cursor: pointer; }
.language button.active { color: white; background: linear-gradient(135deg, rgba(11,169,224,.7), rgba(13,53,94,.65)); box-shadow: inset 0 0 0 1px rgba(60,227,255,.28); }

.ecosystem-hero { height: calc(100vh - 64px); min-height: 0; position: relative; isolation: isolate; padding: clamp(18px, 3vh, 32px) 0 54px; overflow: hidden; background: #020b19; }
.earth-horizon {
  position: absolute;
  z-index: -2;
  inset: -6%;
  background: url("assets/earth-background-v1.png") 50% 50% / cover no-repeat;
  pointer-events: none;
  will-change: transform;
  animation: earth-drift 34s ease-in-out infinite;
}
.ecosystem-hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,7,19,.2), transparent 25%, rgba(0,7,18,.06) 60%, rgba(0,7,18,.42));
  pointer-events: none;
  animation: horizon-glow 22s ease-in-out infinite;
}
@keyframes earth-drift {
  0% { transform: translate3d(0, 0, 0) scale(1.07) rotate(0deg); }
  25% { transform: translate3d(-2.5%, -.45%, 0) scale(1.09) rotate(-.25deg); }
  50% { transform: translate3d(-4.2%, -.15%, 0) scale(1.1) rotate(-.42deg); }
  75% { transform: translate3d(-2.2%, .4%, 0) scale(1.09) rotate(-.2deg); }
  100% { transform: translate3d(0, 0, 0) scale(1.07) rotate(0deg); }
}
@keyframes horizon-glow {
  0%, 100% { opacity: 1; }
  50% { opacity: .88; }
}
.edge-note { position: absolute; top: 50px; width: 190px; color: #79b9ef; font-size: .68rem; line-height: 1.75; letter-spacing: .28em; text-transform: uppercase; }
.edge-note::after { content: ""; display: block; width: 36px; height: 1px; margin-top: 12px; background: var(--cyan); }
.edge-note-left { left: max(30px, calc((100vw - 1500px) / 2)); }
.edge-note-right { right: max(30px, calc((100vw - 1500px) / 2)); text-align: left; }
.hero-title-wrap { text-align: center; position: relative; z-index: 4; }
.hero-title-wrap h1 {
  justify-content: center;
  margin: 0;
  font-size: clamp(3.7rem, 6.1vw, 5.8rem);
  letter-spacing: -.07em;
  text-shadow: 0 0 34px rgba(63,167,255,.34);
}
.hero-title-wrap p { margin: 12px 0 0; font-size: clamp(1rem, 1.45vw, 1.35rem); color: #d4e6f7; text-shadow: 0 2px 16px #00152d; }

.orbit { max-width: 1620px; margin: clamp(22px, 3.6vh, 36px) auto 0; padding: 0 30px; position: relative; outline: none; }
.orbit-stage { height: clamp(286px, 35vh, 330px); position: relative; perspective: 1200px; perspective-origin: 50% 42%; cursor: grab; touch-action: pan-y; user-select: none; }
.orbit.is-dragging .orbit-stage { cursor: grabbing; }
.product-card { --glow: var(--cyan); width: clamp(196px, 14vw, 232px); min-width: 0; height: clamp(270px, 34vh, 322px); padding: 12px 12px 17px; border: 1px solid color-mix(in srgb, var(--glow) 72%, white 28%); border-radius: 22px; background: linear-gradient(155deg, rgba(8,34,62,.88), rgba(3,15,31,.95)); box-shadow: 0 0 22px color-mix(in srgb, var(--glow) 22%, transparent), inset 0 0 30px rgba(17,99,155,.09); text-align: center; overflow: hidden; position: absolute; left: 50%; top: 0; transform: translate3d(calc(-50% + var(--card-x, 0px)), var(--card-y, 0px), var(--card-z, 0px)) rotateY(var(--card-rotate, 0deg)) scale(var(--card-scale, 1)); transform-origin: 50% 55%; opacity: var(--card-opacity, 1); z-index: var(--card-layer, 1); transition: transform .46s cubic-bezier(.2,.78,.24,1), opacity .32s ease, border-color .18s ease, box-shadow .18s ease, filter .18s ease; will-change: transform, opacity; }
.orbit.is-dragging .product-card { transition: border-color .18s ease, box-shadow .18s ease, filter .18s ease; }
.product-card[aria-hidden="true"] { pointer-events: none; }
.product-card::after { content: ""; position: absolute; left: 34%; right: 34%; bottom: 15px; height: 3px; border-radius: 99px; background: var(--glow); box-shadow: 0 0 13px var(--glow); }
.product-card[data-product="vpn"], .product-card[data-product="radar"] { --glow: var(--violet); }
.product-card:hover, .product-card:focus-visible { border-color: white; box-shadow: 0 0 38px color-mix(in srgb, var(--glow) 42%, transparent), inset 0 0 36px color-mix(in srgb, var(--glow) 12%, transparent); outline: none; }
.product-card[aria-current="true"] { border-color: color-mix(in srgb, var(--glow) 62%, white 38%); box-shadow: 0 0 34px color-mix(in srgb, var(--glow) 38%, transparent), inset 0 0 38px color-mix(in srgb, var(--glow) 12%, transparent); }
.product-card.is-opening { border-color: white; filter: brightness(1.18); box-shadow: 0 0 28px white, 0 0 74px color-mix(in srgb, var(--glow) 78%, transparent), inset 0 0 44px color-mix(in srgb, var(--glow) 28%, transparent); }
.product-art { display: block; width: 100%; max-width: 215px; height: clamp(132px, 17.5vh, 166px); margin: -5px auto 3px; background-image: url("assets/ecosystem.png"); background-size: 1680px 944px; background-repeat: no-repeat; border-radius: 16px; }
[data-product="player"] .product-art { background-position: -49px -356px; }
[data-product="traffic"] .product-art { background-position: -323px -356px; }
[data-product="vpn"] .product-art { background-position: -598px -354px; }
[data-product="navigator"] .product-art { background-position: -838px -350px; }
[data-product="radar"] .product-art { background-position: -1114px -350px; }
[data-product="games"] .product-art { background-position: -1385px -350px; }
.product-card h2 { margin: 0; font-size: clamp(.96rem, 1.2vw, 1.22rem); letter-spacing: -.025em; white-space: nowrap; }
.product-card p { min-height: 39px; margin: 7px auto 0; color: #b7d2ee; font-size: clamp(.75rem, .82vw, .86rem); line-height: 1.35; }
.open-label { display: inline-flex; align-items: center; gap: 6px; margin-top: 7px; color: var(--glow); font-size: .7rem; font-weight: 760; letter-spacing: .08em; text-transform: uppercase; opacity: .86; }
.open-label::after { content: "↗"; }

.carousel-controls { height: 38px; margin: 5px auto 0; display: flex; align-items: center; justify-content: center; gap: 15px; position: relative; z-index: 20; }
.carousel-arrow { width: 36px; height: 36px; padding: 0; border: 1px solid rgba(46,214,255,.72); border-radius: 50%; color: #dffaff; background: rgba(3,20,39,.75); box-shadow: 0 0 16px rgba(0,203,255,.13); cursor: pointer; transition: background .18s ease, box-shadow .18s ease, transform .18s ease; }
.carousel-arrow:hover, .carousel-arrow:focus-visible { outline: none; background: rgba(0,154,209,.3); box-shadow: 0 0 22px rgba(0,213,255,.35); transform: scale(1.06); }
.carousel-dots { display: flex; align-items: center; gap: 8px; }
.carousel-dot { width: 7px; height: 7px; padding: 0; border: 0; border-radius: 50%; background: rgba(144,199,230,.36); cursor: pointer; transition: width .2s ease, background .2s ease, box-shadow .2s ease; }
.carousel-dot.active { width: 24px; border-radius: 99px; background: var(--cyan); box-shadow: 0 0 11px rgba(24,220,245,.8); }
.drag-hint { margin: 4px 0 0; color: #75a6d0; font-size: .72rem; text-align: center; letter-spacing: .04em; }
footer { height: 48px; padding: 0 max(30px, calc((100vw - 1580px) / 2)); display: flex; align-items: center; justify-content: space-between; gap: 24px; color: #70a8d6; border-top: 1px solid rgba(89,189,255,.17); background: rgba(0,8,20,.58); backdrop-filter: blur(10px); font-size: .72rem; position: fixed; z-index: 40; left: 0; right: 0; bottom: 0; }
.footer-note { max-width: 260px; letter-spacing: .16em; text-transform: uppercase; }
footer a { color: #6faee4; }

@media (min-width: 901px) {
  html, body { height: 100%; overflow: hidden; }
}

@media (min-width: 901px) and (max-height: 760px) {
  .ecosystem-hero { padding-top: 16px; }
  .hero-title-wrap h1 { font-size: 3.65rem; }
  .hero-title-wrap p { margin-top: 8px; font-size: 1rem; }
  .orbit { margin-top: 25px; }
  .product-card { height: 270px; }
  .product-art { height: 132px; }
  .orbit-stage { height: 276px; }
  .carousel-controls { margin-top: 2px; }
  .drag-hint { display: none; }
  .edge-note { top: 34px; }
}

@media (max-width: 900px) {
  nav { display: none; }
  .edge-note { display: none; }
  .ecosystem-hero { height: auto; min-height: calc(100vh - 64px); padding-top: 50px; padding-bottom: 70px; }
  .earth-horizon { background-position: 50% 15%; }
  .orbit { margin-top: 42px; padding: 0 10px; }
  .orbit-stage { height: 355px; perspective: 900px; overflow: hidden; }
  .product-card { width: min(230px, 68vw); height: 350px; }
  .product-art { transform: scale(.9); }
  footer { min-height: 92px; height: auto; padding: 22px; position: static; }
}

@media (max-width: 560px) {
  .ecosystem-header { height: 64px; padding: 0 14px; }
  .wordmark { font-size: 1.65rem; }
  .language button { min-width: 43px; padding: 7px 10px; }
  .hero-title-wrap h1 { font-size: 4rem; }
  .hero-title-wrap p { width: min(310px, 90vw); margin-inline: auto; font-size: .98rem; }
  .ecosystem-hero::before { top: 160px; height: 230px; }
  .orbit { margin-top: 34px; padding: 0 8px; }
  .orbit-stage { height: 336px; }
  .product-card { width: min(210px, 72vw); height: 330px; padding: 14px; }
  .product-art { width: 100%; height: 174px; transform: scale(.86); }
  .product-card h2 { font-size: 1.08rem; }
  .product-card p { font-size: .79rem; }
  footer { flex-direction: column; text-align: center; }
  .footer-note { max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .product-card { transition-duration: 0ms !important; }
  .earth-horizon,
  .ecosystem-hero::before {
    animation: none !important;
    transform: none !important;
  }
  .earth-horizon {
    inset: 0;
    background-position: center center;
  }
}
