:root {
    --loft-bg: #080808;
    --loft-bg-2: #111111;
    --loft-panel: rgba(24, 24, 24, .92);
    --loft-card: #171717;
    --loft-line: rgba(255, 255, 255, .1);
    --loft-line-strong: rgba(216, 180, 93, .34);
    --loft-text: #f4f1ea;
    --loft-muted: #b8b1a4;
    --loft-dim: #7d766d;
    --loft-gold: #d8b45d;
    --loft-gold-2: #f0d993;
    --loft-red: #b9473f;
    --loft-radius: 8px;
    --loft-shadow: 0 28px 80px rgba(0, 0, 0, .42);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    background: var(--loft-bg);
}

body.loft-body {
    min-height: 100vh;
    color: var(--loft-text);
    background:
        radial-gradient(circle at 18% 0%, rgba(216, 180, 93, .12), transparent 30rem),
        radial-gradient(circle at 88% 12%, rgba(185, 71, 63, .1), transparent 26rem),
        linear-gradient(180deg, #080808 0%, #111 48%, #080808 100%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    line-height: 1.66;
}

a {
    color: inherit;
    text-decoration: none;
}

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

button,
input {
    font: inherit;
}

.loft-app > :not(.loft-header):not(.loft-drawer):not(.loft-main):not(.loft-hotwords):not(.loft-footer),
.loft-main > :not(.loft-hero):not(.loft-container):not(.loft-detail):not(.loft-empty),
.loft-header__inner > :not(.loft-brand):not(.loft-nav):not(.loft-search):not(.loft-menu-btn),
.loft-hero__inner > :not(.loft-hero__content):not(.loft-hero__poster),
.loft-hero__content > :not(.loft-kicker):not(h1):not(p):not(.loft-meta):not(.loft-actions),
.loft-section > :not(.loft-section__head):not(.loft-card-grid):not(.loft-ribbon__list):not(.loft-category-grid),
.loft-section__head > :not(div):not(.loft-more),
.loft-card-grid > :not(.loft-card),
.loft-list-grid > :not(.loft-card),
.loft-card > :not(.loft-card__poster):not(h2):not(h3):not(p),
.loft-detail-hero__inner > :not(.loft-detail-poster):not(.loft-detail-info),
.loft-detail-info > :not(.loft-breadcrumb):not(.loft-kicker):not(h1):not(p):not(.loft-meta):not(.loft-info-list):not(.loft-actions),
.loft-detail-layout > :not(.loft-detail-main):not(.loft-related),
.loft-watch-layout > :not(.loft-watch-main):not(.loft-related),
.loft-panel > :not(.loft-panel__head):not(.loft-source):not(.loft-story__content),
.loft-panel__head > :not(div):not(button),
.loft-source > :not(h3):not(.loft-episode-list),
.loft-episode-list > :not(.loft-episode),
.loft-related > :not(h2):not(a),
.loft-related a > :not(img):not(span),
.loft-related span > :not(strong):not(em),
.loft-meta > :not(span),
.loft-actions > :not(a):not(button),
.loft-filter > :not(a),
.loft-pagination > :not(a):not(span),
.loft-nextprev > :not(a):not(span),
.loft-adjacent > :not(a):not(span) {
    display: none !important;
}

.loft-container {
    width: min(1440px, calc(100% - 48px));
    margin: 0 auto;
}

.loft-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--loft-line);
    background: rgba(8, 8, 8, .78);
    backdrop-filter: blur(20px);
}

.loft-header__inner {
    min-height: 72px;
    display: flex;
    align-items: center;
    gap: 18px;
}

.loft-brand {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 11px;
    color: #fff;
    font-size: 21px;
    font-weight: 950;
}

.loft-brand__mark {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--loft-gold), var(--loft-gold-2));
    position: relative;
    box-shadow: 0 12px 30px rgba(216, 180, 93, .24);
}

.loft-brand__mark::after {
    content: "";
    position: absolute;
    left: 15px;
    top: 10px;
    border-left: 12px solid #111;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.loft-nav {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.loft-nav > a,
.loft-nav__trigger {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 0 13px;
    border: 1px solid transparent;
    border-radius: 999px;
    color: var(--loft-muted);
    background: transparent;
    white-space: nowrap;
    font-size: 14px;
    transition: color .18s ease, background .18s ease, border-color .18s ease;
}

.loft-nav > a:hover,
.loft-nav > a.is-active,
.loft-nav__group:hover .loft-nav__trigger,
.loft-nav__trigger.is-active {
    color: #fff;
    border-color: var(--loft-line-strong);
    background: rgba(216, 180, 93, .1);
}

.loft-nav__group {
    position: relative;
}

.loft-nav__trigger {
    cursor: default;
}

.loft-nav__trigger span {
    width: 7px;
    height: 7px;
    border-right: 2px solid var(--loft-gold);
    border-bottom: 2px solid var(--loft-gold);
    transform: rotate(45deg) translateY(-2px);
    transition: transform .18s ease;
}

.loft-nav__group:hover .loft-nav__trigger span {
    transform: rotate(225deg) translateY(-1px);
}

.loft-nav__menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    min-width: 172px;
    padding: 8px;
    border: 1px solid var(--loft-line);
    border-radius: var(--loft-radius);
    background: #151515;
    box-shadow: var(--loft-shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}

.loft-nav__group:hover .loft-nav__menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.loft-nav__menu a {
    display: block;
    padding: 9px 10px;
    border-radius: 7px;
    color: var(--loft-muted);
    white-space: nowrap;
}

.loft-nav__menu a:hover,
.loft-nav__menu a.is-active {
    color: #fff;
    background: rgba(255, 255, 255, .07);
}

.loft-search {
    flex: 0 0 300px;
    height: 40px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 66px;
    border: 1px solid var(--loft-line);
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, .06);
}

.loft-search input {
    min-width: 0;
    border: 0;
    outline: 0;
    padding: 0 14px;
    color: var(--loft-text);
    background: transparent;
}

.loft-search input::placeholder {
    color: var(--loft-dim);
}

.loft-search button {
    border: 0;
    color: #111;
    background: var(--loft-gold);
    font-weight: 900;
    cursor: pointer;
}

.loft-menu-btn {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid var(--loft-line);
    border-radius: 50%;
    background: transparent;
}

.loft-menu-btn span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    background: var(--loft-text);
}

.loft-main {
    min-height: 60vh;
}

.loft-hero {
    position: relative;
    min-height: 620px;
    display: grid;
    align-items: center;
    overflow: hidden;
}

.loft-hero__bg,
.loft-detail-hero__bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    opacity: .42;
}

.loft-hero__bg img,
.loft-detail-hero__bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(18px) saturate(1.08);
    transform: scale(1.08);
}

.loft-hero::after,
.loft-detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        linear-gradient(90deg, rgba(8, 8, 8, .96) 0%, rgba(8, 8, 8, .72) 44%, rgba(8, 8, 8, .32) 100%),
        linear-gradient(180deg, rgba(8, 8, 8, .2), #080808 100%);
}

.loft-hero__inner {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: clamp(28px, 6vw, 90px);
    align-items: center;
    padding: 70px 0;
}

.loft-kicker {
    margin-bottom: 9px;
    color: var(--loft-gold);
    font-size: 12px;
    font-weight: 950;
    letter-spacing: 0;
}

.loft-hero h1,
.loft-detail-info h1,
.loft-page-head h1,
.loft-watch-head h1 {
    max-width: 900px;
    color: #fff;
    font-size: clamp(42px, 6vw, 86px);
    line-height: 1.02;
    letter-spacing: 0;
}

.loft-hero__content > p,
.loft-empty-hero p,
.loft-detail-info > p,
.loft-page-head p {
    max-width: 680px;
    margin-top: 16px;
    color: var(--loft-muted);
    font-size: 17px;
}

.loft-hero__poster {
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border: 1px solid var(--loft-line-strong);
    border-radius: var(--loft-radius);
    background: var(--loft-card);
    box-shadow: var(--loft-shadow);
}

.loft-hero__poster img,
.loft-card__poster img,
.loft-detail-poster img,
.loft-related img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.loft-meta,
.loft-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 18px;
}

.loft-meta span {
    min-height: 30px;
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border: 1px solid var(--loft-line);
    border-radius: 999px;
    color: var(--loft-muted);
    background: rgba(255, 255, 255, .06);
    font-size: 13px;
}

.loft-btn {
    min-height: 43px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 17px;
    border: 1px solid var(--loft-line);
    border-radius: 999px;
    color: var(--loft-text);
    background: rgba(255, 255, 255, .07);
    font-weight: 950;
    cursor: pointer;
}

.loft-btn--primary {
    color: #111;
    border-color: var(--loft-gold);
    background: linear-gradient(135deg, var(--loft-gold), var(--loft-gold-2));
}

.loft-empty-hero {
    padding: 90px 0;
}

.loft-section,
.loft-page-head,
.loft-watch {
    padding-top: 34px;
    padding-bottom: 18px;
}

.loft-section__head,
.loft-panel__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

.loft-section__head h2,
.loft-panel__head h2,
.loft-related h2,
.loft-hotwords h2 {
    color: #fff;
    font-size: 28px;
    line-height: 1.2;
}

.loft-more {
    color: var(--loft-gold);
    font-weight: 900;
}

.loft-ribbon {
    margin-top: -34px;
    position: relative;
    z-index: 3;
    padding: 22px;
    border: 1px solid var(--loft-line);
    border-radius: var(--loft-radius);
    background: rgba(20, 20, 20, .86);
    box-shadow: var(--loft-shadow);
}

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

.loft-ribbon__list a {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 10px;
    padding: 12px;
    border: 1px solid var(--loft-line);
    border-radius: var(--loft-radius);
    background: rgba(255, 255, 255, .04);
}

.loft-ribbon__list em {
    color: var(--loft-gold);
    font-style: normal;
    font-weight: 950;
}

.loft-ribbon__list strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #fff;
}

.loft-ribbon__list span {
    grid-column: 2;
    color: var(--loft-dim);
    font-size: 12px;
}

.loft-card-grid,
.loft-list-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 18px;
}

.loft-card__poster {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: var(--loft-radius);
    background: var(--loft-card);
}

.loft-card__poster::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: inherit;
    pointer-events: none;
}

.loft-card__poster span {
    position: absolute;
    left: 8px;
    bottom: 8px;
    max-width: calc(100% - 16px);
    padding: 3px 8px;
    border-radius: 999px;
    color: #111;
    background: var(--loft-gold);
    font-size: 12px;
    font-weight: 900;
}

.loft-card h2,
.loft-card h3 {
    margin-top: 10px;
    color: #fff;
    font-size: 16px;
    line-height: 1.35;
}

.loft-card p {
    margin-top: 4px;
    color: var(--loft-dim);
    font-size: 13px;
}

.loft-category-grid,
.loft-filter,
.loft-pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.loft-category-grid a,
.loft-filter a,
.loft-pagination a,
.loft-pagination span {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 13px;
    border: 1px solid var(--loft-line);
    border-radius: 999px;
    color: var(--loft-muted);
    background: rgba(255, 255, 255, .05);
    font-weight: 800;
}

.loft-filter {
    margin-top: 18px;
    margin-bottom: 22px;
}

.loft-filter a.is-active,
.loft-pagination span {
    color: #111;
    border-color: var(--loft-gold);
    background: var(--loft-gold);
}

.loft-empty {
    margin-top: 26px;
    padding: 34px;
    border: 1px solid var(--loft-line);
    border-radius: var(--loft-radius);
    color: var(--loft-muted);
    background: rgba(255, 255, 255, .04);
    text-align: center;
}

.loft-detail-hero {
    position: relative;
    overflow: hidden;
}

.loft-detail-hero__inner {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 250px minmax(0, 1fr);
    gap: 34px;
    align-items: center;
    padding: 58px 0;
}

.loft-detail-poster {
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: var(--loft-radius);
    border: 1px solid var(--loft-line-strong);
    box-shadow: var(--loft-shadow);
    background: var(--loft-card);
}

.loft-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: var(--loft-dim);
    font-size: 13px;
}

.loft-info-list {
    display: grid;
    gap: 9px;
    margin-top: 20px;
    color: var(--loft-muted);
}

.loft-info-list div {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 12px;
}

.loft-info-list dt {
    color: var(--loft-gold);
    font-weight: 900;
}

.loft-info-list dd {
    min-width: 0;
}

.loft-detail-layout,
.loft-watch-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 22px;
    padding-top: 28px;
}

.loft-panel,
.loft-related {
    padding: 22px;
    border: 1px solid var(--loft-line);
    border-radius: var(--loft-radius);
    background: var(--loft-panel);
    box-shadow: 0 18px 48px rgba(0, 0, 0, .18);
}

.loft-panel {
    margin-bottom: 20px;
}

.loft-panel__head button {
    min-height: 36px;
    padding: 0 12px;
    border: 1px solid var(--loft-line);
    border-radius: 999px;
    color: var(--loft-text);
    background: rgba(255, 255, 255, .06);
    cursor: pointer;
}

.loft-source + .loft-source {
    margin-top: 18px;
}

.loft-source h3 {
    margin-bottom: 10px;
    color: var(--loft-muted);
}

.loft-episode-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
    gap: 9px;
}

.loft-episode {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 8px;
    border: 1px solid var(--loft-line);
    border-radius: 999px;
    color: var(--loft-muted);
    background: rgba(255, 255, 255, .05);
    font-size: 13px;
    text-align: center;
}

.loft-episode:hover,
.loft-episode.is-active {
    color: #111;
    border-color: var(--loft-gold);
    background: var(--loft-gold);
}

.loft-story-title {
    margin-top: 18px;
    color: #fff;
    font-size: 18px;
    font-weight: 950;
}

.loft-story-title:first-child {
    margin-top: 0;
}

.loft-story-text {
    margin-top: 8px;
    color: var(--loft-muted);
}

.loft-adjacent,
.loft-nextprev {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.loft-adjacent a,
.loft-nextprev a,
.loft-nextprev > span {
    padding: 14px;
    border: 1px solid var(--loft-line);
    border-radius: var(--loft-radius);
    background: var(--loft-panel);
}

.loft-adjacent span,
.loft-nextprev span {
    display: block;
    color: var(--loft-dim);
    font-size: 12px;
}

.loft-adjacent strong,
.loft-nextprev strong {
    display: block;
    margin-top: 4px;
    color: #fff;
}

.loft-related {
    position: sticky;
    top: 92px;
    align-self: start;
}

.loft-related a {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 10px;
    padding: 10px 0;
    border-top: 1px solid var(--loft-line);
}

.loft-related img {
    aspect-ratio: 2 / 3;
    border-radius: 6px;
    background: var(--loft-card);
}

.loft-related strong {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #fff;
}

.loft-related em {
    color: var(--loft-dim);
    font-size: 12px;
    font-style: normal;
}

.loft-watch-head {
    margin-bottom: 20px;
}

.loft-watch-head h1 small {
    display: block;
    margin-top: 10px;
    color: var(--loft-muted);
    font-size: 18px;
}

.loft-player {
    overflow: hidden;
    border: 1px solid var(--loft-line);
    border-radius: var(--loft-radius);
    background: #000;
    box-shadow: var(--loft-shadow);
}

.loft-player-container {
    width: 100%;
    aspect-ratio: 16 / 9;
    min-height: 390px;
    background: #000;
}

.loft-hotwords {
    padding: 26px 0;
}

.loft-hotwords h2 {
    font-size: 22px;
}

.loft-hotwords__list {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 12px;
}

.loft-hotwords a {
    padding: 6px 11px;
    border: 1px solid var(--loft-line);
    border-radius: 999px;
    color: var(--loft-muted);
    background: rgba(255, 255, 255, .04);
}

.loft-footer {
    padding: 24px 0 36px;
    color: var(--loft-dim);
    text-align: center;
}

.loft-drawer {
    position: fixed;
    top: 72px;
    right: 0;
    bottom: 0;
    z-index: 999;
    width: min(340px, 88vw);
    border-left: 1px solid var(--loft-line);
    background: #101010;
    transform: translateX(105%);
    transition: transform .22s ease;
}

body.is-drawer-open .loft-drawer {
    transform: translateX(0);
}

.loft-drawer__inner {
    height: 100%;
    overflow: auto;
    padding: 18px;
}

.loft-drawer__search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 68px;
    gap: 8px;
    margin-bottom: 14px;
}

.loft-drawer__search input,
.loft-drawer__search button,
.loft-drawer a,
.loft-drawer summary {
    min-height: 40px;
    border: 1px solid var(--loft-line);
    border-radius: var(--loft-radius);
}

.loft-drawer__search input {
    min-width: 0;
    padding: 0 10px;
    color: var(--loft-text);
    background: rgba(255, 255, 255, .06);
}

.loft-drawer__search button {
    color: #111;
    background: var(--loft-gold);
    font-weight: 900;
}

.loft-drawer a,
.loft-drawer summary {
    display: block;
    margin-top: 8px;
    padding: 9px 10px;
    color: var(--loft-muted);
    background: rgba(255, 255, 255, .04);
}

@media (max-width: 1180px) {
    .loft-nav,
    .loft-search {
        display: none;
    }

    .loft-menu-btn {
        display: block;
        margin-left: auto;
    }

    .loft-hero__inner,
    .loft-detail-layout,
    .loft-watch-layout {
        grid-template-columns: 1fr;
    }

    .loft-hero__poster {
        display: none;
    }

    .loft-card-grid,
    .loft-list-grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }

    .loft-related {
        position: static;
    }
}

@media (max-width: 860px) {
    .loft-container {
        width: min(100% - 28px, 1440px);
    }

    .loft-hero {
        min-height: 500px;
    }

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

    .loft-card-grid,
    .loft-list-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 14px;
    }

    .loft-detail-hero__inner {
        grid-template-columns: 1fr;
    }

    .loft-detail-poster {
        width: min(240px, 70vw);
    }

    .loft-player-container {
        min-height: 250px;
    }
}

@media (max-width: 560px) {
    .loft-hero h1,
    .loft-detail-info h1,
    .loft-page-head h1,
    .loft-watch-head h1 {
        font-size: 36px;
    }

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

    .loft-ribbon__list,
    .loft-adjacent,
    .loft-nextprev {
        grid-template-columns: 1fr;
    }
}
