:root {
  --background: #060916;
  --background-soft: #0a1022;
  --surface: rgba(15, 23, 45, 0.76);
  --surface-solid: #10182d;
  --text: #f4f7ff;
  --muted: #95a4c2;
  --line: rgba(147, 176, 222, 0.17);
  --cyan: #3ae7ff;
  --violet: #8f6fff;
  --active-accent: #ef7e00;
  --container: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  color-scheme: dark;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 4%, rgba(58, 231, 255, 0.13), transparent 27rem),
    radial-gradient(circle at 94% 24%, rgba(143, 111, 255, 0.14), transparent 30rem),
    linear-gradient(145deg, #050713 0%, var(--background-soft) 52%, #050914 100%);
  font-family: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
}

body::before {
  position: fixed;
  z-index: -2;
  inset: 0;
  background: linear-gradient(110deg, transparent 46%, rgba(58, 231, 255, 0.025) 50%, transparent 54%);
  content: "";
  pointer-events: none;
}

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.tech-grid {
  position: fixed;
  z-index: -1;
  inset: 0;
  opacity: 0.3;
  background-image:
    linear-gradient(rgba(91, 121, 174, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(91, 121, 174, 0.08) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 85%);
  pointer-events: none;
}

.site-header {
  position: relative;
  z-index: 10;
  border-bottom: 1px solid var(--line);
  background: rgba(5, 8, 20, 0.72);
  backdrop-filter: blur(18px);
}

.header-inner,
main,
.site-footer {
  width: min(var(--container), calc(100% - 40px));
  margin-inline: auto;
}

.header-inner {
  display: flex;
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.company-brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.company-logo {
  width: auto;
  max-width: min(230px, 52vw);
  height: 52px;
  object-fit: contain;
  object-position: left center;
}

.company-logo--placeholder {
  display: grid;
  width: 132px;
  place-items: center;
  border: 1px solid rgba(58, 231, 255, 0.4);
  border-radius: 9px;
  color: var(--cyan);
  background: rgba(58, 231, 255, 0.06);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.28em;
}

.header-status {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #c3cee2;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #45ffb2;
  box-shadow: 0 0 0 5px rgba(69, 255, 178, 0.08), 0 0 18px rgba(69, 255, 178, 0.7);
}

main {
  padding: 72px 0 96px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 48px;
  padding-bottom: 54px;
}

.eyebrow,
.section-kicker {
  margin: 0 0 12px;
  color: var(--cyan);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.19em;
  text-transform: uppercase;
}

.eyebrow span {
  color: var(--violet);
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  max-width: 820px;
  margin-bottom: 18px;
  font-size: clamp(2.45rem, 6vw, 5.4rem);
  font-weight: 720;
  letter-spacing: -0.055em;
  line-height: 0.98;
}

.hero-description {
  max-width: 690px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.8vw, 1.2rem);
}

.hero-metric {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 14px 0 8px 25px;
  border-left: 1px solid rgba(58, 231, 255, 0.35);
}

.hero-metric strong {
  color: transparent;
  background: linear-gradient(135deg, var(--cyan), #d3faff);
  background-clip: text;
  font-size: 3.55rem;
  font-weight: 300;
  letter-spacing: -0.08em;
  line-height: 0.85;
}

.hero-metric span {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  line-height: 1.45;
  text-transform: uppercase;
}

.player-section {
  scroll-margin-top: 24px;
}

.section-heading,
.catalog-heading,
.player-footer,
.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.section-heading {
  margin-bottom: 20px;
}

.section-heading h2,
.catalog-heading h2 {
  margin-bottom: 0;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.signal-label {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.signal-label span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--active-accent);
  box-shadow: 0 0 14px var(--active-accent);
  transition: background-color 220ms ease, box-shadow 220ms ease;
}

.player-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border: 1px solid color-mix(in srgb, var(--active-accent) 44%, var(--line));
  border-radius: 18px;
  background: #02040a;
  box-shadow:
    0 30px 90px rgba(0, 0, 0, 0.46),
    0 0 52px color-mix(in srgb, var(--active-accent) 12%, transparent);
  transition: border-color 220ms ease, box-shadow 220ms ease;
}

.player-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.player-loading {
  position: absolute;
  display: flex;
  visibility: hidden;
  align-items: center;
  justify-content: center;
  gap: 12px;
  inset: 0;
  opacity: 0;
  color: #c8d4ea;
  background: rgba(3, 6, 14, 0.84);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  transition: opacity 180ms ease, visibility 180ms ease;
  pointer-events: none;
}

.player-frame.is-loading .player-loading {
  visibility: visible;
  opacity: 1;
}

.loader {
  width: 19px;
  height: 19px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-top-color: var(--active-accent);
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}

.player-corner {
  position: absolute;
  width: 31px;
  height: 31px;
  pointer-events: none;
}

.player-corner--top {
  top: 12px;
  left: 12px;
  border-top: 2px solid var(--active-accent);
  border-left: 2px solid var(--active-accent);
}

.player-corner--bottom {
  right: 12px;
  bottom: 12px;
  border-right: 2px solid var(--active-accent);
  border-bottom: 2px solid var(--active-accent);
}

.player-footer {
  padding: 17px 4px 0;
  color: var(--muted);
  font-size: 0.8rem;
}

.player-footer p {
  margin-bottom: 0;
}

.player-footer strong {
  color: var(--text);
  font-weight: 650;
}

.player-index {
  color: var(--active-accent);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  letter-spacing: 0.08em;
}

.catalog {
  padding-top: 92px;
}

.catalog-heading {
  align-items: end;
  margin-bottom: 25px;
}

.catalog-heading > p {
  max-width: 340px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.86rem;
  text-align: right;
}

.channel-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.channel-card {
  --channel-accent: var(--cyan);
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 184px;
  overflow: hidden;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--text);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.035), transparent 54%),
    var(--surface);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.025);
  text-decoration: none;
  transition: border-color 180ms ease, background-color 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

.channel-card::before {
  position: absolute;
  width: 110px;
  height: 110px;
  top: -72px;
  right: -48px;
  border-radius: 50%;
  background: var(--channel-accent);
  content: "";
  filter: blur(44px);
  opacity: 0.14;
  transition: opacity 180ms ease;
}

.channel-card::after {
  position: absolute;
  height: 2px;
  right: 18px;
  bottom: -1px;
  left: 18px;
  background: var(--channel-accent);
  box-shadow: 0 0 16px var(--channel-accent);
  content: "";
  opacity: 0;
  transform: scaleX(0.35);
  transition: opacity 180ms ease, transform 180ms ease;
}

.channel-card:hover,
.channel-card:focus-visible,
.channel-card.is-active {
  border-color: color-mix(in srgb, var(--channel-accent) 65%, rgba(255, 255, 255, 0.2));
  background-color: rgba(19, 29, 55, 0.92);
  box-shadow: 0 15px 36px rgba(0, 0, 0, 0.2);
  transform: translateY(-3px);
}

.channel-card:hover::before,
.channel-card:focus-visible::before,
.channel-card.is-active::before {
  opacity: 0.27;
}

.channel-card:hover::after,
.channel-card:focus-visible::after,
.channel-card.is-active::after {
  opacity: 1;
  transform: scaleX(1);
}

.channel-card:focus-visible {
  outline: 2px solid var(--channel-accent);
  outline-offset: 3px;
}

.card-number {
  position: absolute;
  top: 15px;
  right: 16px;
  color: rgba(199, 213, 237, 0.48);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.66rem;
  letter-spacing: 0.08em;
}

.channel-logo-shell {
  display: grid;
  width: 100%;
  height: 76px;
  place-items: center;
  padding: 6px 26px;
}

.channel-logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.channel-logo-placeholder {
  display: flex;
  align-items: baseline;
  gap: 6px;
  color: #eef4ff;
}

.channel-logo-placeholder small {
  color: var(--channel-accent);
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.2em;
}

.channel-logo-placeholder strong {
  font-size: 2.2rem;
  font-weight: 280;
  letter-spacing: -0.07em;
  line-height: 1;
}

.channel-name {
  overflow: hidden;
  margin-top: 7px;
  font-size: 0.84rem;
  font-weight: 720;
  letter-spacing: 0.02em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.card-action b {
  color: var(--channel-accent);
  font-size: 0.9rem;
}

.site-footer {
  min-height: 94px;
  padding: 25px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.75rem;
}

.site-footer p {
  margin-bottom: 0;
}

.footer-code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.66rem;
  letter-spacing: 0.12em;
}

.footer-code span {
  margin: 0 6px;
  color: var(--cyan);
}

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

@media (max-width: 900px) {
  .channel-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hero {
    align-items: center;
  }
}

@media (max-width: 680px) {
  .header-inner,
  main,
  .site-footer {
    width: min(100% - 28px, var(--container));
  }

  .header-inner {
    min-height: 74px;
  }

  .company-logo {
    height: 44px;
  }

  .header-status {
    font-size: 0;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .hero-metric {
    justify-self: start;
  }

  .section-heading,
  .catalog-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .catalog-heading > p {
    text-align: left;
  }

  .channel-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .channel-card {
    min-height: 164px;
    padding: 15px;
  }

  .catalog {
    padding-top: 70px;
  }
}

@media (max-width: 430px) {
  main {
    padding-top: 54px;
    padding-bottom: 72px;
  }

  .hero {
    padding-bottom: 44px;
  }

  .channel-grid {
    gap: 10px;
  }

  .channel-card {
    min-height: 154px;
    border-radius: 12px;
  }

  .channel-logo-shell {
    height: 64px;
    padding-inline: 12px;
  }

  .channel-name {
    font-size: 0.77rem;
  }

  .card-action {
    font-size: 0.58rem;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
