:root {
      --bg-deep: #07152b;
      --bg-mid: #123c74;
      --cyan: #35baff;
      --cyan-soft: rgba(53, 186, 255, .62);
      --white-12: rgba(255, 255, 255, .12);
      --white-20: rgba(255, 255, 255, .20);
      --white-36: rgba(255, 255, 255, .36);
      --panel: rgba(25, 64, 119, .38);
      --glass: rgba(255, 255, 255, .14);
      --glass-strong: rgba(255, 255, 255, .22);
      --purple: #5443a5;
      --purple-dark: #453390;
      --purple-soft: #918cdf;
      --gold: #f5a72e;
      --green: #32e476;
      --shadow: 0 26px 70px rgba(0, 0, 0, .36);
    }

    * {
      box-sizing: border-box;
    }

    html,
    body {
      width: 100%;
      height: 100%;
      margin: 0;
      overflow: hidden;
      background: #020814;
      color: #fff;
      font-family: "Yu Gothic", "Hiragino Kaku Gothic ProN", "Meiryo", system-ui, sans-serif;
      letter-spacing: 0;
    }

    button {
      color: inherit;
      font: inherit;
      border: 0;
      cursor: pointer;
    }

    .app {
      position: relative;
      width: 100vw;
      height: 100vh;
      min-width: 320px;
      background:
        radial-gradient(circle at 72% 34%, rgba(91, 181, 255, .42), transparent 20%),
        radial-gradient(circle at 18% 86%, rgba(36, 126, 255, .28), transparent 26%),
        linear-gradient(120deg, #071329 0%, #0d2853 42%, #154f92 70%, #07152f 100%);
      isolation: isolate;
    }

    .app::before,
    .app::after {
      content: "";
      position: absolute;
      inset: 0;
      z-index: -1;
      pointer-events: none;
    }

    .app::before {
      background:
        linear-gradient(118deg, transparent 0 24%, rgba(255, 255, 255, .13) 24.2% 35%, transparent 35.2% 100%),
        linear-gradient(63deg, transparent 0 57%, rgba(255, 255, 255, .08) 57.2% 72%, transparent 72.2% 100%),
        linear-gradient(141deg, transparent 0 74%, rgba(255, 255, 255, .15) 74.2% 86%, transparent 86.2% 100%);
      mix-blend-mode: screen;
      opacity: .88;
    }

    .app::after {
      background:
        radial-gradient(ellipse at 52% 54%, rgba(255, 255, 255, .20), transparent 18%),
        radial-gradient(ellipse at 66% 48%, rgba(118, 204, 255, .22), transparent 22%),
        linear-gradient(to bottom, rgba(0, 0, 0, .14), transparent 35%, rgba(0, 0, 0, .24));
      filter: blur(.2px);
    }

    .view {
      position: absolute;
      inset: 0;
      opacity: 0;
      transform: translate3d(0, 18px, 0) scale(.985);
      pointer-events: none;
      transition: opacity .34s ease, transform .34s ease;
    }

    .view.active {
      opacity: 1;
      transform: translate3d(0, 0, 0) scale(1);
      pointer-events: auto;
    }

    .top-exit {
      position: absolute;
      top: clamp(22px, 4.6vh, 58px);
      left: clamp(24px, 7.4vw, 96px);
      z-index: 5;
      width: clamp(44px, 4.3vw, 68px);
      height: clamp(44px, 4.3vw, 68px);
      color: rgba(255, 255, 255, .96);
      background: transparent;
      display: grid;
      place-items: center;
      opacity: .95;
    }

    .top-exit svg,
    .status svg,
    .tiny-icon {
      width: 100%;
      height: 100%;
      display: block;
    }

    .status {
      position: absolute;
      top: clamp(24px, 4.2vh, 50px);
      right: clamp(24px, 5.4vw, 76px);
      z-index: 5;
      display: flex;
      align-items: center;
      gap: clamp(16px, 2vw, 30px);
      color: rgba(255, 255, 255, .93);
      font-size: clamp(18px, 1.8vw, 31px);
      text-shadow: 0 3px 12px rgba(0, 0, 0, .35);
    }

    .status .device {
      width: clamp(34px, 3.4vw, 54px);
      opacity: .78;
    }

    .status .wifi {
      width: clamp(36px, 3.8vw, 62px);
      color: #4cef62;
      filter: drop-shadow(0 0 12px rgba(76, 239, 98, .36));
    }

    .home-promo {
      position: absolute;
      top: clamp(132px, 18vh, 240px);
      left: 50%;
      z-index: 4;
      transform: translateX(-50%);
      width: min(78vw, 1220px);
      min-height: clamp(54px, 7vh, 78px);
      display: flex;
      align-items: center;
      justify-content: center;
      gap: clamp(14px, 1.5vw, 24px);
      padding: clamp(12px, 1.5vw, 18px) clamp(22px, 3vw, 42px);
      color: rgba(255, 255, 255, .96);
      background:
        linear-gradient(90deg, rgba(255, 255, 255, .10), rgba(255, 255, 255, .18), rgba(255, 255, 255, .10)),
        rgba(10, 32, 66, .38);
      border: 1px solid rgba(255, 255, 255, .22);
      border-radius: 999px;
      box-shadow: inset 0 1px 0 rgba(255, 255, 255, .20), 0 18px 46px rgba(0, 0, 0, .22);
      backdrop-filter: blur(16px);
      -webkit-backdrop-filter: blur(16px);
      text-shadow: 0 3px 14px rgba(0, 0, 0, .35);
      letter-spacing: 0;
    }

    .promo-badge {
      flex: 0 0 auto;
      padding: .42em .92em;
      border-radius: 999px;
      color: #08203d;
      background: linear-gradient(180deg, #ffffff, #dff6ff);
      box-shadow: 0 0 24px rgba(100, 211, 255, .25);
      font-size: clamp(14px, 1vw, 18px);
      font-weight: 800;
      line-height: 1;
      white-space: nowrap;
    }

    .promo-text {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      column-gap: .25em;
      font-size: clamp(22px, 2vw, 34px);
      font-weight: 780;
      line-height: 1.2;
      text-align: center;
    }

    .promo-text span {
      white-space: nowrap;
    }

    .home-menu {
      position: absolute;
      top: 50%;
      left: 50%;
      width: min(78vw, 1220px);
      transform: translate(-50%, -47%);
      display: grid;
      grid-template-columns: repeat(4, minmax(150px, 1fr));
      gap: clamp(14px, 1.2vw, 24px);
    }

    .home-card {
      position: relative;
      aspect-ratio: 1 / 1;
      min-height: 180px;
      border-radius: 0;
      color: #fff;
      background:
        linear-gradient(180deg, rgba(255, 255, 255, .18), rgba(255, 255, 255, .09)),
        rgba(68, 95, 129, .30);
      border: 1px solid rgba(255, 255, 255, .20);
      box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08), 0 18px 44px rgba(0, 0, 0, .24);
      backdrop-filter: blur(18px);
      -webkit-backdrop-filter: blur(18px);
      transition: transform .24s ease, background .24s ease, color .24s ease, box-shadow .24s ease, border-color .24s ease;
      outline: none;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      gap: clamp(12px, 1.4vw, 18px);
    }

    .home-card::after {
      content: "";
      position: absolute;
      left: 0;
      right: 0;
      bottom: -16px;
      height: 12px;
      background: var(--cyan);
      box-shadow: 0 0 24px var(--cyan-soft);
      transform-origin: center;
      transition: height .24s ease, bottom .24s ease, background .24s ease;
    }

    .home-card:hover,
    .home-card:focus-visible,
    .home-card.selected {
      transform: translateY(-12px) scale(1.085);
      color: #0d2445;
      background: linear-gradient(180deg, rgba(255, 255, 255, .98), rgba(236, 248, 255, .92));
      border-color: rgba(255, 255, 255, .88);
      box-shadow: 0 30px 80px rgba(0, 0, 0, .36), 0 0 42px rgba(76, 196, 255, .28);
      z-index: 2;
    }

    .home-card:hover::after,
    .home-card:focus-visible::after,
    .home-card.selected::after {
      bottom: -20px;
      height: 16px;
      background: #64d3ff;
    }

    .home-icon {
      width: clamp(74px, 7.4vw, 124px);
      height: clamp(74px, 7.4vw, 124px);
      color: currentColor;
      filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .22));
    }

    .home-label {
      font-weight: 760;
      font-size: clamp(22px, 2.15vw, 36px);
      line-height: 1.1;
      text-shadow: 0 3px 10px rgba(0, 0, 0, .32);
      white-space: nowrap;
    }

    .home-card:hover .home-label,
    .home-card:focus-visible .home-label {
      text-shadow: none;
    }

    .bottom-license {
      position: absolute;
      left: clamp(26px, 7.8vw, 110px);
      right: clamp(26px, 7.8vw, 110px);
      bottom: clamp(28px, 8vh, 92px);
      height: clamp(42px, 6vh, 72px);
      border-radius: 10px;
      background: rgba(238, 244, 252, .54);
      box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45);
    }

    .bottom-info {
      position: absolute;
      right: clamp(34px, 5.4vw, 78px);
      bottom: clamp(24px, 4.2vh, 52px);
      display: flex;
      gap: 22px;
      align-items: center;
      font-size: clamp(16px, 1.5vw, 28px);
      color: rgba(255, 255, 255, .85);
    }

    .ipv6-pill {
      color: #65ee63;
      border: 2px solid rgba(101, 238, 99, .75);
      border-radius: 999px;
      padding: 0 8px;
      line-height: 1.05;
    }

    .days {
      position: absolute;
      left: 50%;
      bottom: clamp(22px, 4.2vh, 52px);
      transform: translateX(-50%);
      font-size: clamp(16px, 1.5vw, 28px);
      color: rgba(255, 255, 255, .84);
    }

    .back-button {
      position: absolute;
      top: clamp(24px, 3.6vh, 42px);
      left: clamp(22px, 3vw, 48px);
      z-index: 10;
      width: clamp(42px, 3.5vw, 58px);
      height: clamp(42px, 3.5vw, 58px);
      border-radius: 999px;
      background: rgba(255, 255, 255, .12);
      border: 1px solid rgba(255, 255, 255, .22);
      backdrop-filter: blur(14px);
      -webkit-backdrop-filter: blur(14px);
      display: grid;
      place-items: center;
      transition: transform .2s ease, background .2s ease;
    }

    .back-button:hover,
    .back-button:focus-visible {
      transform: scale(1.08);
      background: rgba(255, 255, 255, .22);
      outline: none;
    }

    .back-button svg {
      width: 62%;
      height: 62%;
    }

    .live-layout {
      height: 100%;
      padding: clamp(54px, 7.2vh, 88px) clamp(46px, 6.8vw, 132px) clamp(34px, 5vh, 58px);
      display: grid;
      grid-template-columns: minmax(260px, 27vw) 1fr;
      gap: clamp(18px, 2.5vw, 38px);
    }

    .live-sidebar,
    .channel-panel {
      min-height: 0;
      background: rgba(61, 119, 185, .22);
      border: 1px solid rgba(255, 255, 255, .06);
      box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08);
      backdrop-filter: blur(8px);
      -webkit-backdrop-filter: blur(8px);
    }

    .live-sidebar {
      padding: 0 0 20px;
      overflow: hidden;
    }

    .category-row {
      width: 100%;
      height: clamp(58px, 8.5vh, 88px);
      padding: 0 clamp(14px, 1.3vw, 24px);
      background: transparent;
      display: flex;
      align-items: center;
      color: rgba(255, 255, 255, .92);
      font-size: clamp(19px, 1.65vw, 32px);
      text-align: left;
      transition: background .2s ease, transform .2s ease;
    }

    .category-row:hover,
    .category-row:focus-visible {
      background: rgba(255, 255, 255, .13);
      outline: none;
    }

    .category-row.active {
      color: #fff;
      background: linear-gradient(90deg, #168eff, #33c5ff);
      box-shadow: 0 10px 30px rgba(31, 169, 255, .30);
      border-radius: 0 999px 999px 0;
      transform: translateX(0);
    }

    .channel-panel {
      position: relative;
      overflow: hidden;
      background: rgba(25, 83, 156, .08);
      border-color: transparent;
      box-shadow: none;
    }

    .channel-list {
      height: 100%;
      padding: 2px 0;
      overflow-x: hidden;
      overflow-y: auto;
      overscroll-behavior: contain;
      -webkit-overflow-scrolling: touch;
    }

    .channel-row {
      width: 100%;
      min-height: clamp(58px, 8.25vh, 88px);
      display: grid;
      grid-template-columns: minmax(92px, 8.6vw) minmax(120px, 8vw) minmax(74px, 5.2vw) 1fr minmax(94px, 8vw);
      align-items: center;
      gap: clamp(10px, 1.1vw, 18px);
      padding: 0 clamp(8px, 1.3vw, 22px);
      color: rgba(255, 255, 255, .92);
      background: transparent;
      border-radius: 14px;
      transition: background .18s ease, transform .18s ease, color .18s ease;
      text-align: left;
    }

    .channel-row:hover,
    .channel-row:focus-visible {
      background: rgba(255, 255, 255, .15);
      color: #fff;
      transform: translateX(7px);
      outline: none;
    }

    .channel-row .num,
    .channel-row .name,
    .channel-row .time,
    .channel-row .program {
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
      font-size: clamp(18px, 1.52vw, 29px);
      text-shadow: 0 3px 10px rgba(0, 0, 0, .30);
    }

    .channel-row .num {
      font-weight: 680;
    }

    .channel-actions {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: clamp(12px, 1.5vw, 24px);
      opacity: .9;
    }

    .channel-actions svg {
      width: clamp(26px, 2.1vw, 38px);
      height: clamp(26px, 2.1vw, 38px);
    }

    .movie-view {
      background:
        radial-gradient(circle at 74% 28%, rgba(255, 255, 255, .22), transparent 19%),
        linear-gradient(90deg, #4c3a99 0%, #5949ad 29%, #7772cc 69%, #9692de 100%);
    }

    .movie-layout {
      height: 100%;
      display: grid;
      grid-template-columns: minmax(256px, 24vw) 1fr;
    }

    .movie-side {
      position: relative;
      padding: clamp(28px, 3vh, 40px) clamp(20px, 2.2vw, 36px);
      background: rgba(64, 48, 150, .56);
      box-shadow: inset -1px 0 0 rgba(255, 255, 255, .08);
    }

    .movie-count {
      text-align: center;
      font-size: clamp(18px, 1.5vw, 30px);
      color: rgba(255, 255, 255, .94);
      margin-bottom: clamp(30px, 4.2vh, 54px);
    }

    .movie-tools {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: clamp(18px, 1.9vw, 30px);
      margin-bottom: clamp(28px, 4vh, 48px);
      align-items: center;
      justify-items: center;
    }

    .movie-tool {
      width: clamp(42px, 4vw, 64px);
      height: clamp(42px, 4vw, 64px);
      background: transparent;
      display: grid;
      place-items: center;
      opacity: .98;
      transition: transform .2s ease, opacity .2s ease;
    }

    .movie-tool:hover,
    .movie-tool:focus-visible {
      transform: scale(1.12);
      outline: none;
    }

    .movie-tool svg {
      width: 86%;
      height: 86%;
    }

    .movie-cats {
      display: flex;
      flex-direction: column;
      gap: clamp(10px, 1.8vh, 18px);
    }

    .movie-cat {
      width: 100%;
      min-height: clamp(42px, 5.8vh, 66px);
      border-radius: 14px;
      background: transparent;
      color: rgba(255, 255, 255, .96);
      font-size: clamp(21px, 1.95vw, 34px);
      text-align: center;
      transition: background .18s ease, box-shadow .18s ease, transform .18s ease;
    }

    .movie-cat:hover,
    .movie-cat:focus-visible,
    .movie-cat.active {
      background: rgba(255, 255, 255, .23);
      box-shadow: inset 0 0 0 4px rgba(255, 255, 255, .96);
      outline: none;
    }

    .movie-main {
      min-width: 0;
      overflow: hidden;
      padding: clamp(44px, 5.3vh, 64px) clamp(34px, 5.8vw, 92px) clamp(36px, 5vh, 64px);
    }

    .movie-slider {
      width: 200%;
      height: 100%;
      display: flex;
      transition: transform .45s cubic-bezier(.22, .8, .2, 1);
    }

    .movie-main.detail .movie-slider {
      transform: translateX(-50%);
    }

    .movie-main.detail .movie-page:first-child {
      opacity: 0;
    }

    .movie-page {
      width: 50%;
      height: 100%;
      min-width: 0;
      transition: opacity .2s ease;
    }

    .poster-grid {
      height: 100%;
      display: grid;
      grid-template-columns: repeat(4, minmax(130px, 1fr));
      grid-template-rows: repeat(2, minmax(0, 1fr));
      column-gap: clamp(36px, 5.4vw, 94px);
      row-gap: clamp(30px, 6.2vh, 64px);
      align-items: stretch;
    }

    .poster-card {
      min-width: 0;
      height: 100%;
      display: flex;
      flex-direction: column;
      justify-content: flex-start;
      background: rgba(255, 255, 255, .12);
      border-radius: 8px;
      padding: clamp(10px, .9vw, 14px);
      box-shadow: 0 12px 28px rgba(26, 18, 86, .20);
      transition: transform .22s ease, background .22s ease, box-shadow .22s ease;
      text-align: left;
      outline: none;
      overflow: hidden;
    }

    .poster-card:hover,
    .poster-card:focus-visible {
      transform: translateY(-8px) scale(1.045);
      background: rgba(255, 255, 255, .23);
      box-shadow: 0 22px 46px rgba(17, 10, 67, .34), 0 0 0 3px rgba(255, 255, 255, .86);
    }

    .poster-image-wrap {
      position: relative;
      width: 100%;
      aspect-ratio: 0.72 / 1;
      flex: 1 1 auto;
      min-height: 0;
      border-radius: 6px;
      overflow: hidden;
      background: rgba(230, 233, 242, .88);
      box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18);
    }

    .poster-card img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      display: block;
      opacity: 0;
      transform: scale(1.025);
      transition: opacity .52s ease, transform .52s ease;
    }

    .poster-card.loaded img {
      opacity: 1;
      transform: scale(1);
    }

    .poster-meta {
      height: clamp(32px, 3.8vh, 46px);
      display: grid;
      grid-template-columns: 1fr clamp(24px, 2vw, 34px);
      align-items: center;
      gap: 8px;
      color: #fff;
      font-size: clamp(15px, 1.15vw, 24px);
      line-height: 1;
      padding-top: clamp(8px, .8vw, 11px);
      min-width: 0;
    }

    .poster-title {
      overflow: hidden;
      white-space: nowrap;
      text-overflow: ellipsis;
      text-shadow: 0 2px 7px rgba(0, 0, 0, .32);
    }

    .arrow-chip {
      width: clamp(24px, 2vw, 34px);
      height: clamp(24px, 2vw, 34px);
      border-radius: 50%;
      display: grid;
      place-items: center;
      background: linear-gradient(180deg, #f1c45c, #d9a22d);
      color: #fff;
      font-size: clamp(17px, 1.25vw, 24px);
      line-height: 1;
      box-shadow: 0 2px 7px rgba(0, 0, 0, .22);
    }

    .skeleton {
      position: absolute;
      inset: 0;
      display: grid;
      place-items: center;
      color: rgba(48, 52, 70, .68);
      font-size: clamp(16px, 1.2vw, 22px);
      background:
        linear-gradient(110deg, rgba(255, 255, 255, .20) 8%, rgba(255, 255, 255, .62) 18%, rgba(255, 255, 255, .20) 33%),
        rgba(218, 222, 232, .88);
      background-size: 220% 100%;
      animation: shimmer 1.2s linear infinite;
    }

    .poster-card.loaded .skeleton {
      display: none;
    }

    @keyframes shimmer {
      from { background-position: 120% 0; }
      to { background-position: -120% 0; }
    }

    .detail-page {
      display: grid;
      grid-template-columns: minmax(230px, 32%) 1fr;
      gap: clamp(28px, 4vw, 70px);
      align-items: center;
      padding-right: clamp(4px, 1vw, 20px);
    }

    .detail-poster {
      width: min(100%, 430px);
      justify-self: center;
      border-radius: 10px;
      padding: 16px;
      background: rgba(255, 255, 255, .17);
      box-shadow: 0 28px 70px rgba(18, 11, 73, .38), inset 0 0 0 1px rgba(255, 255, 255, .18);
    }

    .detail-poster img {
      display: block;
      width: 100%;
      aspect-ratio: .72 / 1;
      border-radius: 7px;
      object-fit: cover;
    }

    .detail-info {
      min-width: 0;
      color: #fff;
      text-shadow: 0 3px 13px rgba(0, 0, 0, .25);
    }

    .detail-info h2 {
      margin: 0 0 clamp(16px, 2.5vh, 30px);
      font-size: clamp(34px, 4vw, 70px);
      line-height: 1.04;
      font-weight: 820;
    }

    .detail-table {
      display: grid;
      grid-template-columns: minmax(80px, 7vw) 1fr;
      gap: clamp(10px, 1.3vh, 18px) clamp(16px, 2.2vw, 36px);
      font-size: clamp(18px, 1.45vw, 28px);
      line-height: 1.45;
      margin-bottom: clamp(22px, 3vh, 38px);
    }

    .detail-table dt {
      color: rgba(255, 255, 255, .68);
    }

    .detail-table dd {
      margin: 0;
      color: rgba(255, 255, 255, .96);
    }

    .detail-desc {
      max-width: 780px;
      margin: 0 0 clamp(28px, 4vh, 50px);
      color: rgba(255, 255, 255, .84);
      font-size: clamp(16px, 1.2vw, 24px);
      line-height: 1.65;
    }

    .play-row {
      display: flex;
      align-items: center;
      gap: 18px;
    }

    .play-button {
      min-width: clamp(170px, 13vw, 260px);
      height: clamp(54px, 6.6vh, 78px);
      border-radius: 999px;
      background: linear-gradient(90deg, #f6a126, #ffd15f);
      color: #192039;
      font-size: clamp(22px, 1.8vw, 32px);
      font-weight: 820;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 12px;
      box-shadow: 0 18px 38px rgba(117, 71, 0, .32);
      transition: transform .2s ease, box-shadow .2s ease;
      outline: none;
    }

    .play-button:hover,
    .play-button:focus-visible {
      transform: translateY(-3px) scale(1.04);
      box-shadow: 0 24px 48px rgba(117, 71, 0, .42);
    }

    .detail-back {
      width: clamp(54px, 4.5vw, 74px);
      height: clamp(54px, 4.5vw, 74px);
      border-radius: 999px;
      background: rgba(255, 255, 255, .15);
      border: 1px solid rgba(255, 255, 255, .24);
      display: grid;
      place-items: center;
      outline: none;
    }

    .detail-back:hover,
    .detail-back:focus-visible {
      background: rgba(255, 255, 255, .26);
    }

    .detail-back svg {
      width: 55%;
      height: 55%;
    }

    .modal-layer {
      position: fixed;
      inset: 0;
      z-index: 40;
      display: grid;
      place-items: center;
      padding: 24px;
      background: rgba(2, 7, 20, .56);
      opacity: 0;
      pointer-events: none;
      transition: opacity .22s ease;
      backdrop-filter: blur(10px);
      -webkit-backdrop-filter: blur(10px);
    }

    .modal-layer.active {
      opacity: 1;
      pointer-events: auto;
    }

    .modal {
      position: relative;
      width: min(760px, 92vw);
      border-radius: 26px;
      padding: clamp(26px, 4vw, 48px);
      background:
        linear-gradient(145deg, rgba(255, 255, 255, .28), rgba(255, 255, 255, .12)),
        rgba(16, 44, 82, .72);
      border: 1px solid rgba(255, 255, 255, .34);
      box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, .26);
      transform: translateY(18px) scale(.98);
      transition: transform .25s ease;
      overflow: hidden;
    }

    .modal-layer.active .modal {
      transform: translateY(0) scale(1);
    }

    .modal h2 {
      margin: 0 0 22px;
      font-size: clamp(30px, 3.1vw, 50px);
      line-height: 1.1;
    }

    .modal-close {
      position: absolute;
      top: 18px;
      right: 18px;
      width: 48px;
      height: 48px;
      border-radius: 999px;
      display: grid;
      place-items: center;
      background: rgba(255, 255, 255, .16);
      border: 1px solid rgba(255, 255, 255, .22);
      font-size: 28px;
      line-height: 1;
      transition: transform .18s ease, background .18s ease;
    }

    .modal-close:hover,
    .modal-close:focus-visible {
      transform: rotate(90deg) scale(1.06);
      background: rgba(255, 255, 255, .28);
      outline: none;
    }

    .contact-body {
      display: grid;
      grid-template-columns: 1fr minmax(150px, 210px);
      gap: clamp(22px, 4vw, 46px);
      align-items: center;
    }

    .contact-list {
      display: grid;
      gap: 16px;
      font-size: clamp(18px, 1.55vw, 28px);
      line-height: 1.4;
    }

    .contact-item {
      display: grid;
      grid-template-columns: 112px 1fr;
      gap: 14px;
      align-items: baseline;
      padding: 13px 0;
      border-bottom: 1px solid rgba(255, 255, 255, .16);
    }

    .contact-label {
      color: rgba(255, 255, 255, .64);
      font-size: .86em;
    }

    .qr-box {
      width: 100%;
      aspect-ratio: 1;
      padding: 12px;
      border-radius: 20px;
      background: rgba(255, 255, 255, .92);
      box-shadow: 0 18px 38px rgba(0, 0, 0, .22);
      display: grid;
      place-items: center;
    }

    .qr-image {
      width: 100%;
      height: 100%;
      display: block;
      border-radius: 10px;
      object-fit: contain;
      background: #fff;
    }

    .qr-fake {
      width: 100%;
      height: 100%;
      border-radius: 10px;
      background:
        linear-gradient(90deg, #111 10px, transparent 10px 18px, #111 18px 28px, transparent 28px 40px, #111 40px 48px, transparent 48px),
        linear-gradient(#111 10px, transparent 10px 18px, #111 18px 28px, transparent 28px 40px, #111 40px 48px, transparent 48px),
        linear-gradient(45deg, transparent 0 36%, #111 36% 45%, transparent 45% 63%, #111 63% 72%, transparent 72%),
        #fff;
      background-size: 56px 56px, 56px 56px, 100% 100%, 100% 100%;
      position: relative;
    }

    .qr-fake::after {
      content: "QR";
      position: absolute;
      inset: 37% 33%;
      display: grid;
      place-items: center;
      border-radius: 8px;
      background: #fff;
      color: #111;
      font-weight: 800;
      font-size: 26px;
    }

    .app-grid {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      gap: 16px;
      margin-top: 24px;
    }

    .app-tile {
      min-height: 116px;
      border-radius: 18px;
      background: rgba(255, 255, 255, .14);
      border: 1px solid rgba(255, 255, 255, .18);
      display: grid;
      place-items: center;
      gap: 5px;
      padding: 12px;
      font-size: clamp(15px, 1.1vw, 20px);
      text-align: center;
    }

    .app-link {
      color: inherit;
      text-decoration: none;
      outline: none;
      transition: transform .18s ease, background .18s ease, border-color .18s ease;
    }

    .app-link:hover,
    .app-link:focus-visible {
      transform: translateY(-4px) scale(1.03);
      background: rgba(255, 255, 255, .24);
      border-color: rgba(255, 255, 255, .34);
    }

    .app-tile svg {
      width: 42px;
      height: 42px;
      opacity: .95;
    }

    .app-icon {
      width: 54px;
      height: 54px;
      display: block;
      filter: drop-shadow(0 6px 12px rgba(0, 0, 0, .20));
    }

    .app-platform {
      font-size: clamp(16px, 1.2vw, 22px);
      font-weight: 760;
      line-height: 1.15;
      white-space: nowrap;
    }

    .app-action {
      color: rgba(255, 255, 255, .68);
      font-size: clamp(11px, .82vw, 15px);
      line-height: 1.1;
      white-space: nowrap;
    }

    .player-layer {
      position: fixed;
      inset: 0;
      z-index: 80;
      background: #000;
      display: grid;
      place-items: center;
      opacity: 0;
      pointer-events: none;
      transition: opacity .18s ease;
    }

    .player-layer.active {
      opacity: 1;
      pointer-events: auto;
    }

    .player-video {
      position: absolute;
      inset: 0;
      width: 100%;
      height: 100%;
      object-fit: cover;
      opacity: 0;
      transition: opacity .22s ease;
      background: #000;
    }

    .player-layer.playing .player-video {
      opacity: 1;
    }

    .loader-hud {
      position: relative;
      z-index: 3;
      display: grid;
      justify-items: center;
      gap: 18px;
      color: rgba(255, 255, 255, .92);
      text-align: center;
      transition: opacity .2s ease;
    }

    .player-layer.playing .loader-hud {
      opacity: 0;
      pointer-events: none;
    }

    .spinner {
      width: clamp(78px, 8vw, 128px);
      height: clamp(78px, 8vw, 128px);
      border-radius: 50%;
      border: 8px solid rgba(50, 228, 118, .18);
      border-top-color: var(--green);
      border-right-color: var(--green);
      box-shadow: 0 0 32px rgba(50, 228, 118, .28);
      animation: spin .76s linear infinite;
    }

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

    .loading-title {
      font-size: clamp(22px, 2vw, 38px);
      font-weight: 720;
    }

    .loading-speed {
      font-size: clamp(18px, 1.5vw, 28px);
      color: rgba(255, 255, 255, .72);
    }

    .player-hint {
      position: absolute;
      bottom: 28px;
      left: 50%;
      transform: translateX(-50%);
      z-index: 4;
      color: rgba(255, 255, 255, .58);
      font-size: clamp(14px, 1vw, 18px);
      opacity: 0;
      transition: opacity .2s ease;
    }

    .player-layer.playing .player-hint {
      opacity: 1;
    }

    .replay-layer {
      position: fixed;
      inset: 0;
      z-index: 75;
      display: grid;
      place-items: center;
      padding: clamp(18px, 4vw, 54px);
      background: rgba(1, 8, 20, .78);
      opacity: 0;
      pointer-events: none;
      transition: opacity .2s ease;
      backdrop-filter: blur(10px);
      -webkit-backdrop-filter: blur(10px);
    }

    .replay-layer.active {
      opacity: 1;
      pointer-events: auto;
    }

    .replay-image {
      display: block;
      max-width: min(92vw, 1280px);
      max-height: 86vh;
      object-fit: contain;
      border-radius: 10px;
      background: rgba(255, 255, 255, .96);
      box-shadow: 0 28px 80px rgba(0, 0, 0, .52);
      transform: scale(.96);
      transition: transform .2s ease;
    }

    .replay-layer.active .replay-image {
      transform: scale(1);
    }

    .replay-close {
      position: fixed;
      top: clamp(18px, 3vw, 42px);
      right: clamp(18px, 3vw, 42px);
      width: 58px;
      height: 58px;
      border: 1px solid rgba(255, 255, 255, .44);
      border-radius: 50%;
      color: #fff;
      background: rgba(126, 143, 169, .62);
      font-size: 38px;
      line-height: 1;
      cursor: pointer;
      box-shadow: 0 16px 38px rgba(0, 0, 0, .28);
      transition: transform .18s ease, background .18s ease;
    }

    .replay-close:hover,
    .replay-close:focus-visible {
      transform: scale(1.08);
      background: rgba(167, 183, 209, .76);
      outline: none;
    }

    .toast {
      position: fixed;
      left: 50%;
      bottom: 7vh;
      transform: translate(-50%, 20px);
      z-index: 70;
      padding: 14px 22px;
      border-radius: 999px;
      background: rgba(6, 24, 50, .80);
      border: 1px solid rgba(255, 255, 255, .18);
      color: rgba(255, 255, 255, .94);
      box-shadow: 0 18px 48px rgba(0, 0, 0, .30);
      opacity: 0;
      pointer-events: none;
      transition: opacity .22s ease, transform .22s ease;
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
      font-size: 18px;
    }

    .toast.active {
      opacity: 1;
      transform: translate(-50%, 0);
    }

    @media (max-width: 980px) {
      body {
        overflow: hidden;
      }

      .app {
        min-height: 100vh;
        height: 100vh;
        overflow: hidden;
      }

      .view {
        min-height: 100vh;
        overflow-x: hidden;
        overflow-y: auto;
      }

      .home-promo {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        width: auto;
        margin: 112px 24px 20px;
        min-height: auto;
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
        border-radius: 18px;
        padding: 16px 18px;
      }

      .promo-text {
        justify-content: flex-start;
        text-align: left;
        font-size: 22px;
      }

      .home-menu {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        width: auto;
        grid-template-columns: repeat(2, minmax(130px, 1fr));
        padding: 28px 24px 170px;
      }

      .bottom-license {
        bottom: 90px;
      }

      .days {
        left: 24px;
        bottom: 58px;
        transform: none;
        font-size: 16px;
      }

      .bottom-info {
        left: 24px;
        right: 24px;
        bottom: 22px;
        justify-content: flex-end;
        gap: 12px;
        font-size: 16px;
      }

      .live-layout {
        grid-template-columns: 1fr;
        overflow: auto;
        padding: 86px 18px 28px;
      }

      .live-sidebar {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        height: auto;
      }

      .category-row.active {
        border-radius: 12px;
      }

      .channel-row {
        grid-template-columns: 56px 1fr 72px;
      }

      .channel-row .program,
      .channel-actions {
        grid-column: 2 / -1;
      }

      .movie-layout {
        grid-template-columns: 1fr;
        min-height: 100%;
        height: auto;
      }

      .movie-side {
        padding-top: 70px;
      }

      .movie-cats {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
      }

      .poster-grid {
        grid-template-columns: repeat(2, minmax(130px, 1fr));
        grid-template-rows: auto;
      }

      .movie-main {
        overflow: hidden;
      }

      .movie-slider,
      .movie-page,
      .poster-grid {
        height: auto;
      }

      .detail-page {
        grid-template-columns: minmax(190px, 40%) 1fr;
        align-items: start;
        gap: 20px;
      }

      .detail-poster {
        width: min(100%, 260px);
        padding: 10px;
      }

      .detail-info h2 {
        font-size: 30px;
        margin-bottom: 14px;
      }

      .detail-table {
        grid-template-columns: 54px 1fr;
        gap: 7px 10px;
        font-size: 15px;
        line-height: 1.34;
        margin-bottom: 14px;
      }

      .detail-desc {
        font-size: 14px;
        line-height: 1.48;
        margin-bottom: 16px;
      }

      .play-button {
        min-width: 126px;
        height: 48px;
        font-size: 18px;
      }

      .detail-back {
        width: 48px;
        height: 48px;
      }

      .contact-body {
        grid-template-columns: 1fr;
      }

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

    @media (max-width: 560px) {
      .detail-page {
        grid-template-columns: 1fr;
      }

      .detail-poster {
        width: min(68vw, 260px);
      }
    }

    @media (max-width: 980px) and (orientation: portrait) {
      html,
      body {
        width: 100%;
        height: 100%;
        overflow: hidden;
        background: #071329;
      }

      .app {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vh;
        height: 100vw;
        width: 100svh;
        height: 100svw;
        min-width: 0;
        min-height: 0;
        overflow: hidden;
        transform: rotate(90deg) translateY(-100%);
        transform-origin: top left;
      }

      .modal-layer,
      .player-layer,
      .replay-layer {
        top: 0;
        left: 0;
        width: 100vh;
        height: 100vw;
        width: 100svh;
        height: 100svw;
        transform: rotate(90deg) translateY(-100%);
        transform-origin: top left;
      }

      .modal-layer.active .modal {
        transform: translateY(0) scale(1);
      }
    }

    @media (max-width: 980px) and (orientation: portrait),
           (max-width: 980px) and (orientation: landscape) {
      .view {
        min-height: 0;
        overflow: hidden;
      }

      .top-exit {
        top: 20px;
        left: 36px;
        width: 44px;
        height: 44px;
      }

      .status {
        top: 18px;
        right: 34px;
        gap: 16px;
        font-size: 18px;
      }

      .status .device {
        width: 32px;
      }

      .status .wifi {
        width: 36px;
      }

      .home-promo {
        position: absolute;
        top: 12%;
        left: 50%;
        width: 78%;
        min-height: 48px;
        margin: 0;
        transform: translateX(-50%);
        flex-direction: row;
        align-items: center;
        justify-content: center;
        gap: 12px;
        border-radius: 999px;
        padding: 10px 22px;
      }

      .promo-badge {
        font-size: 13px;
      }

      .promo-text {
        justify-content: center;
        text-align: center;
        font-size: clamp(17px, 3.5vh, 24px);
      }

      .home-menu {
        position: absolute;
        top: 53%;
        left: 50%;
        width: 80%;
        padding: 0;
        transform: translate(-50%, -47%);
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 14px;
      }

      .home-card {
        min-height: 0;
        gap: 10px;
      }

      .home-icon {
        width: min(72px, 17vh);
        height: min(72px, 17vh);
      }

      .home-label {
        font-size: clamp(18px, 4.1vh, 28px);
      }

      .bottom-license {
        left: 7%;
        right: 7%;
        bottom: 34px;
        height: 30px;
      }

      .days {
        left: 50%;
        bottom: 7px;
        transform: translateX(-50%);
        font-size: 14px;
      }

      .bottom-info {
        right: 34px;
        left: auto;
        bottom: 7px;
        gap: 12px;
        font-size: 14px;
      }

      .back-button {
        top: 15px;
        left: 22px;
        width: 42px;
        height: 42px;
      }

      .live-layout {
        height: 100%;
        grid-template-columns: 240px minmax(0, 1fr);
        gap: 16px;
        padding: 38px 24px 18px;
        overflow: hidden;
      }

      .live-sidebar {
        display: block;
        height: 100%;
        min-height: 0;
        padding-bottom: 10px;
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
      }

      .category-row {
        min-height: 43px;
        padding: 0 14px;
        font-size: 18px;
        line-height: 1.1;
      }

      .category-row.active {
        border-radius: 0 999px 999px 0;
      }

      .channel-panel {
        min-height: 0;
        overflow: hidden;
      }

      .channel-list {
        height: 100%;
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
      }

      .channel-row {
        min-height: 48px;
        grid-template-columns: 42px 84px 58px minmax(0, 1fr) 62px;
        gap: 8px;
        padding: 0 6px;
        font-size: 16px;
      }

      .channel-row:hover,
      .channel-row:focus-visible {
        transform: none;
      }

      .channel-row .program,
      .channel-actions {
        grid-column: auto;
      }

      .channel-actions {
        gap: 8px;
      }

      .channel-actions svg {
        width: 24px;
        height: 24px;
      }

      .movie-layout {
        height: 100%;
        min-height: 0;
        grid-template-columns: 210px minmax(0, 1fr);
        overflow: hidden;
      }

      .movie-side {
        padding: 28px 16px 18px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
      }

      .movie-count {
        font-size: 18px;
        margin-bottom: 22px;
      }

      .movie-tools {
        gap: 14px;
        margin-bottom: 20px;
      }

      .movie-tool {
        width: 34px;
        height: 34px;
      }

      .movie-cats {
        display: flex;
        grid-template-columns: none;
        gap: 8px;
      }

      .movie-cat {
        min-height: 35px;
        border-radius: 10px;
        font-size: 17px;
      }

      .movie-main {
        min-height: 0;
        overflow: hidden;
        padding: 28px 24px 22px;
      }

      .movie-slider,
      .movie-page {
        height: 100%;
      }

      .poster-grid {
        height: 100%;
        grid-template-columns: repeat(4, minmax(90px, 1fr));
        grid-template-rows: repeat(2, minmax(0, 1fr));
        column-gap: 16px;
        row-gap: 14px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
      }

      .poster-card {
        padding: 8px;
      }

      .poster-meta {
        height: 28px;
        font-size: 13px;
      }

      .detail-page {
        height: 100%;
        grid-template-columns: 180px minmax(0, 1fr);
        gap: 18px;
        overflow-y: auto;
        padding-bottom: 8px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
      }

      .detail-poster {
        width: 170px;
        padding: 8px;
      }

      .detail-info h2 {
        font-size: 24px;
        margin-bottom: 10px;
      }

      .detail-table {
        grid-template-columns: 48px 1fr;
        gap: 6px 10px;
        font-size: 13px;
        line-height: 1.32;
        margin-bottom: 10px;
      }

      .detail-desc {
        font-size: 12px;
        line-height: 1.45;
        margin-bottom: 10px;
      }

      .play-button {
        min-width: 112px;
        height: 42px;
        font-size: 16px;
      }

      .detail-back {
        width: 42px;
        height: 42px;
      }

      .modal {
        width: min(720px, 86%);
        max-height: 88%;
        padding: 26px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
      }

      .live-sidebar::-webkit-scrollbar,
      .channel-list::-webkit-scrollbar,
      .movie-side::-webkit-scrollbar,
      .poster-grid::-webkit-scrollbar,
      .detail-page::-webkit-scrollbar,
      .modal::-webkit-scrollbar {
        display: none;
        width: 0;
        height: 0;
      }

      .modal h2 {
        font-size: 30px;
        margin-bottom: 16px;
      }

      .contact-body {
        grid-template-columns: 1fr minmax(120px, 170px);
        gap: 24px;
      }

      .app-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 12px;
      }

      .app-tile {
        min-height: 106px;
        padding: 10px;
      }

      .app-icon {
        width: 42px;
        height: 42px;
      }

      .app-platform {
        font-size: 14px;
      }

      .app-action {
        font-size: 10px;
      }
    }
