:root {
  --bg-hue: 210;
  --bg-speed: 4;
  --color-bg: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.08), transparent 55%),
    radial-gradient(circle at 80% 30%, rgba(255, 255, 255, 0.05), transparent 60%),
    radial-gradient(circle at 50% 70%, rgba(255, 255, 255, 0.04), transparent 65%),
    #050713;
  --color-primary: hsl(var(--bg-hue), 95%, 60%);
  --color-secondary: hsl(calc(var(--bg-hue) + 40), 85%, 55%);
  --color-text: #f7f8ff;
  --color-muted: rgba(247, 248, 255, 0.7);
  --max-width: min(1200px, 90vw);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Space Grotesk", system-ui, sans-serif;
  color: var(--color-text);
  background: #03030f;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

.background {
  position: fixed;
  inset: 0;
  background: var(--color-bg);
  pointer-events: none;
  filter: saturate(160%);
  z-index: -2;
}

.background::after {
  content: "";
  position: absolute;
  inset: -100%;
  background: radial-gradient(circle, hsla(var(--bg-hue), 95%, 60%, 0.35), transparent 70%);
  animation: pulse calc(12s / var(--bg-speed)) ease-in-out infinite;
  opacity: 0.8;
}

body.is-powered .background::after {
  animation-duration: calc(7s / var(--bg-speed));
  opacity: 1;
  filter: saturate(180%) brightness(1.15);
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(0.95);
    opacity: 0.65;
  }
  50% {
    transform: scale(1.12);
    opacity: 1;
  }
}

main {
  width: var(--max-width);
  margin: 0 auto;
  padding-bottom: 8rem;
}

.hero {
  width: var(--max-width);
  margin: 0 auto;
  padding: 8rem 0 5rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 3rem;
  align-items: center;
}

.hero__content {
  backdrop-filter: blur(16px);
  background: rgba(5, 9, 27, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
}

body.is-powered .hero__content {
  border-color: hsla(var(--bg-hue), 95%, 60%, 0.5);
  box-shadow: 0 0 30px hsla(var(--bg-hue), 95%, 60%, 0.25);
}

.hero__content::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: conic-gradient(from 0deg, transparent 0 120deg, hsla(var(--bg-hue), 95%, 60%, 0.35) 160deg 200deg, transparent 240deg);
  animation: rotate calc(18s / var(--bg-speed)) linear infinite;
  filter: blur(50px);
  z-index: -1;
}

@keyframes rotate {
  to {
    transform: rotate(1turn);
  }
}

.tag {
  display: inline-block;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-size: 0.75rem;
  color: var(--color-muted);
  margin-bottom: 1.5rem;
}

h1 {
  margin: 0 0 1.25rem;
  font-size: clamp(2.8rem, 5vw, 4rem);
  line-height: 1.05;
}

.glow {
  color: var(--color-primary);
  text-shadow: 0 0 20px hsla(var(--bg-hue), 95%, 60%, 0.85);
}

.lead {
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--color-muted);
}

.hero__actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.btn {
  border: none;
  border-radius: 999px;
  padding: 0.9rem 1.8rem;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
  font-weight: 600;
}

.btn--primary {
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  color: #040510;
  box-shadow: 0 0 20px hsla(var(--bg-hue), 95%, 60%, 0.55);
}

.btn--primary:hover,
.btn--primary:focus-visible {
  transform: translateY(-3px);
  box-shadow: 0 0 30px hsla(var(--bg-hue), 95%, 60%, 0.75);
}

.btn--ghost {
  background: rgba(9, 11, 34, 0.6);
  color: var(--color-text);
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.btn--ghost:hover,
.btn--ghost:focus-visible {
  background: rgba(18, 22, 55, 0.85);
  transform: translateY(-3px);
}

.hero__visual {
  display: grid;
  justify-items: center;
  gap: 1.5rem;
}

.orbital {
  position: relative;
  width: clamp(220px, 30vw, 320px);
  height: clamp(220px, 30vw, 320px);
}

.orbital__core {
  position: absolute;
  inset: 35%;
  border-radius: 50%;
  background: radial-gradient(circle, hsla(var(--bg-hue), 95%, 65%, 0.85), rgba(5, 10, 20, 0.95));
  box-shadow: 0 0 30px hsla(var(--bg-hue), 95%, 60%, 0.6), inset 0 0 50px rgba(5, 9, 27, 0.9);
}

.orbital__ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px dashed hsla(var(--bg-hue), 95%, 70%, 0.7);
  animation: orbit calc(22s / var(--bg-speed)) linear infinite;
}

.orbital__ring--small {
  inset: 15%;
  animation-duration: calc(16s / var(--bg-speed));
  animation-direction: reverse;
}

body.is-powered .orbital__ring {
  border-style: solid;
  box-shadow: 0 0 25px hsla(var(--bg-hue), 95%, 65%, 0.4);
}

body.is-powered .orbital__core {
  transform: scale(1.08);
  box-shadow: 0 0 45px hsla(var(--bg-hue), 95%, 60%, 0.7), inset 0 0 50px rgba(5, 9, 27, 0.9);
}

@keyframes orbit {
  to {
    transform: rotate(1turn);
  }
}

.hero__status {
  font-size: 0.9rem;
  color: var(--color-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.section {
  margin: 5rem 0;
}

.section__title {
  font-size: clamp(2rem, 4vw, 2.8rem);
  margin-bottom: 0.8rem;
}

.section__subtitle {
  font-size: 1rem;
  color: var(--color-muted);
  margin-bottom: 2.5rem;
  max-width: 560px;
}

.zones {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.zone-card {
  position: relative;
  padding: 2.2rem;
  border-radius: 22px;
  background: rgba(7, 10, 28, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.06);
  min-height: 260px;
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.zone-card:hover {
  transform: translateY(-8px);
  border-color: hsla(var(--bg-hue), 95%, 60%, 0.45);
}

.zone-card__trigger {
  margin-top: 1.5rem;
  padding: 0.6rem 1.2rem;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(10, 15, 40, 0.6);
  color: var(--color-text);
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease;
}

.zone-card__trigger:hover,
.zone-card__trigger:focus-visible {
  background: hsla(var(--bg-hue), 95%, 60%, 0.2);
  transform: translateY(-2px);
}

.zone-card__pulse {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--x, 50%) var(--y, 50%), hsla(var(--bg-hue), 95%, 60%, 0.4), transparent 55%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.section--glow {
  display: grid;
  gap: 2.5rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  align-items: center;
}

.glow-controls {
  display: grid;
  gap: 1rem;
  background: rgba(6, 8, 24, 0.65);
  padding: 2rem;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.glow-controls label {
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.85rem;
  color: var(--color-muted);
}

.glow-controls input[type="range"] {
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  outline: none;
}

.glow-controls input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--color-primary);
  box-shadow: 0 0 12px hsla(var(--bg-hue), 95%, 60%, 0.65);
  cursor: pointer;
}

.glow-controls input[type="range"]::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: none;
  background: var(--color-primary);
  box-shadow: 0 0 12px hsla(var(--bg-hue), 95%, 60%, 0.65);
  cursor: pointer;
}

.glow-preview {
  justify-self: center;
  text-align: center;
}

.glow-preview__orb {
  width: clamp(220px, 50vw, 320px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, hsla(var(--bg-hue), 95%, 55%, 0.2), transparent 65%);
  display: grid;
  place-items: center;
  position: relative;
  box-shadow: 0 0 30px hsla(var(--bg-hue), 95%, 60%, 0.4);
}

.glow-preview__orb::after {
  content: "";
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  border: 1px solid hsla(var(--bg-hue), 95%, 65%, 0.5);
  filter: blur(0.5px);
  animation: orbit calc(20s / var(--bg-speed)) linear infinite;
}

.glow-preview__inner {
  width: 60%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 30%, rgba(255, 255, 255, 0.9), hsla(var(--bg-hue), 95%, 60%, 0.8) 40%, rgba(4, 6, 20, 0.9));
  filter: blur(0.3px);
  animation: innerPulse calc(6s / var(--bg-speed)) ease-in-out infinite;
}

@keyframes innerPulse {
  0%,
  100% {
    transform: scale(0.92);
  }
  50% {
    transform: scale(1.05);
  }
}

.glow-preview__caption {
  margin-top: 1rem;
  color: var(--color-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.85rem;
}

.sequencer {
  background: rgba(5, 8, 23, 0.75);
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 2.5rem;
  display: grid;
  gap: 2rem;
}

.sequencer__grid {
  display: grid;
  grid-template-columns: repeat(8, minmax(36px, 1fr));
  gap: 0.9rem;
}

.sequencer__tile {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(10, 12, 35, 0.5);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.sequencer__tile[data-active="true"] {
  background: hsla(var(--bg-hue), 95%, 60%, 0.35);
  box-shadow: inset 0 0 20px hsla(var(--bg-hue), 95%, 60%, 0.6), 0 0 12px hsla(var(--bg-hue), 95%, 60%, 0.45);
  transform: translateY(-3px);
}

.sequencer__tile.playing::after {
  content: "";
  position: absolute;
  inset: -10%;
  border-radius: inherit;
  border: 2px solid hsla(var(--bg-hue), 95%, 70%, 0.6);
  animation: tilePulse 0.5s ease;
}

@keyframes tilePulse {
  from {
    opacity: 1;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(1.25);
  }
}

.sequencer__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  justify-content: space-between;
}

.sequencer__tempo {
  color: var(--color-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 0.75rem;
}

.timeline {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.timeline__card {
  padding: 2rem;
  border-radius: 20px;
  background: rgba(7, 10, 28, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}

.timeline__card::after {
  content: "";
  position: absolute;
  inset: -40% 40% 60% -40%;
  background: linear-gradient(120deg, hsla(var(--bg-hue), 95%, 60%, 0.5), transparent 60%);
  transform: rotate(12deg);
  opacity: 0.3;
}

.section--contact {
  background: rgba(5, 8, 22, 0.9);
  border-radius: 30px;
  padding: 3rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.contact-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.form-group--full {
  grid-column: 1 / -1;
}

label {
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted);
}

input,
textarea {
  background: rgba(7, 11, 28, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  padding: 0.85rem 1rem;
  color: var(--color-text);
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
textarea:focus {
  outline: none;
  border-color: hsla(var(--bg-hue), 95%, 60%, 0.5);
  box-shadow: 0 0 0 2px hsla(var(--bg-hue), 95%, 60%, 0.2);
}

.form-response {
  grid-column: 1 / -1;
  margin: 0;
  min-height: 1.5rem;
  color: var(--color-muted);
}

.footer {
  text-align: center;
  padding: 4rem 1rem;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.85rem;
}

.tour {
  position: fixed;
  inset: 0;
  background: rgba(3, 4, 12, 0.7);
  display: grid;
  place-items: center;
  backdrop-filter: blur(12px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
  z-index: 10;
}

.tour[aria-hidden="false"] {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.tour__content {
  position: relative;
  background: rgba(6, 9, 26, 0.95);
  padding: 2.5rem 2.8rem;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  max-width: 420px;
  box-shadow: 0 0 40px hsla(var(--bg-hue), 95%, 60%, 0.35);
}

.tour__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(12, 16, 36, 0.7);
  color: var(--color-text);
  font-size: 1.5rem;
  cursor: pointer;
}

.tour__content ol {
  padding-left: 1.25rem;
  color: var(--color-muted);
  line-height: 1.7;
}

@media (max-width: 640px) {
  .hero {
    padding-top: 6rem;
  }

  .hero__content {
    padding: 2rem;
  }

  .sequencer__grid {
    grid-template-columns: repeat(4, minmax(56px, 1fr));
  }
}
