:root {
    --nf-bg: #141414;
    --nf-bg-elevated: #181818;
    --nf-bg-card: #1f1f25;
    --nf-red: #e50914;
    --nf-red-hover: #f40612;
    --nf-prime: #00a8e1;
    --nf-gold: #ffd54f;
    --nf-text: #ffffff;
    --nf-text-muted: #b3b3b3;
    --nf-border: rgba(255, 255, 255, 0.12);
    --nf-radius: 10px;
}

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

html, body {
    background-color: var(--nf-bg);
    color: var(--nf-text);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

.hidden {
    display: none !important;
}

/* Header */
.nf-header {
    position: sticky;
    top: 0;
    z-index: 90;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 24px;
    background: linear-gradient(180deg, rgba(10, 10, 12, 0.96) 0%, rgba(20, 20, 20, 0.88) 100%);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nf-header-left {
    display: flex;
    align-items: center;
    gap: 24px;
}

.nf-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--nf-red);
    font-weight: 900;
    letter-spacing: 1px;
    font-size: 1.25rem;
}

.nf-brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 6px;
    background: var(--nf-red);
    color: #fff;
    font-weight: 900;
}

.nf-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nf-nav-link {
    background: transparent;
    border: none;
    color: var(--nf-text-muted);
    font-size: 0.92rem;
    font-weight: 600;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: color 0.2s, background 0.2s;
}

.nf-nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.nf-nav-link.active {
    color: #fff;
    font-weight: 800;
}

.nf-header-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nf-search-box {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    padding: 4px 10px;
    transition: border-color 0.2s;
}

.nf-search-box:focus-within {
    border-color: var(--nf-red);
    background: rgba(0, 0, 0, 0.85);
}

.nf-search-box input {
    background: transparent;
    border: none;
    outline: none;
    color: #fff;
    font-size: 0.88rem;
    width: 170px;
    padding: 5px 8px;
}

.nf-icon-btn {
    background: transparent;
    border: none;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 4px;
}

.nf-search-clear {
    background: transparent;
    border: none;
    color: var(--nf-text-muted);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0 4px;
}

.nf-sync-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(229, 9, 20, 0.16);
    border: 1px solid rgba(229, 9, 20, 0.55);
    color: #fff;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}

.nf-sync-btn:hover {
    background: var(--nf-red);
}

.nf-sync-btn.spinning svg {
    animation: spin 0.9s linear infinite;
}

.nf-profile-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: #fff;
    padding: 4px 10px 4px 5px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
}

.nf-profile-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 0.78rem;
    color: #fff;
}

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

.nf-main {
    padding-bottom: 84px;
}

/* Home Quick Pills */
.nf-home-pills {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 14px 24px 6px;
    scrollbar-width: none;
}

.nf-home-pills::-webkit-scrollbar {
    display: none;
}

.nf-pill {
    background: #23232a;
    color: #e2e2e2;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    padding: 7px 15px;
    font-size: 0.82rem;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s;
}

.nf-pill.active {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
    font-weight: 800;
}

.nf-pill.pill-netflix.active {
    background: var(--nf-red);
    color: #fff;
    border-color: var(--nf-red);
}

.nf-pill.pill-prime.active {
    background: var(--nf-prime);
    color: #fff;
    border-color: var(--nf-prime);
}

.nf-pill.pill-cat {
    background: rgba(255, 213, 79, 0.12);
    border-color: rgba(255, 213, 79, 0.45);
    color: var(--nf-gold);
}

/* Hero Billboard */
.nf-hero-wrapper {
    padding: 12px 24px 20px;
}

.nf-hero-card {
    position: relative;
    width: 100%;
    height: 460px;
    border-radius: 18px;
    overflow: hidden;
    background: #101015;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
}

.nf-hero-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.nf-hero-scrim {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(12, 12, 15, 0.92) 0%, rgba(12, 12, 15, 0.55) 48%, rgba(12, 12, 15, 0.18) 100%),
                linear-gradient(180deg, rgba(12, 12, 15, 0.18) 0%, rgba(12, 12, 15, 0.0) 40%, #141414 100%);
}

.nf-hero-dots {
    position: absolute;
    top: 18px;
    right: 18px;
    z-index: 3;
    display: flex;
    gap: 6px;
    background: rgba(0, 0, 0, 0.55);
    padding: 6px 10px;
    border-radius: 999px;
}

.nf-hero-dot {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.45);
    border: none;
    cursor: pointer;
    transition: width 0.2s, background 0.2s;
}

.nf-hero-dot.active {
    width: 22px;
    background: var(--nf-red);
}

.nf-hero-content {
    position: absolute;
    left: 28px;
    bottom: 28px;
    right: 28px;
    max-width: 600px;
    z-index: 2;
}

.nf-hero-date {
    display: inline-block;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.nf-hero-title {
    font-size: clamp(1.5rem, 3.4vw, 2.7rem);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 10px;
    text-shadow: 0 4px 16px rgba(0, 0, 0, 0.8);
}

.nf-hero-overview {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.86);
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 18px;
}

.nf-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.nf-btn-play {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    color: #000;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    font-weight: 800;
    font-size: 0.92rem;
    cursor: pointer;
    transition: transform 0.15s, background 0.15s;
}

.nf-btn-play:hover {
    background: rgba(255, 255, 255, 0.86);
    transform: scale(1.02);
}

.nf-btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: rgba(109, 109, 110, 0.65);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 8px;
    padding: 10px 16px;
    font-weight: 700;
    font-size: 0.88rem;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s;
}

.nf-btn-secondary:hover {
    background: rgba(109, 109, 110, 0.92);
}

.nf-btn-secondary.saved,
.nf-reaction-btn.active {
    border-color: var(--nf-gold);
    color: var(--nf-gold);
    background: rgba(255, 213, 79, 0.14);
}

.nf-reaction-group {
    display: inline-flex;
    gap: 6px;
}

.nf-reaction-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    border-radius: 999px;
    padding: 8px 12px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
}

/* Sections & Rails */
.nf-section {
    margin: 18px 0 24px;
}

.nf-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px 10px;
}

.nf-section-title-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nf-accent-bar {
    width: 4px;
    height: 20px;
    border-radius: 2px;
    background: var(--nf-red);
}

.nf-section-title {
    font-size: 1.2rem;
    font-weight: 800;
}

.nf-muted-count {
    font-size: 0.85rem;
    color: var(--nf-text-muted);
    font-weight: 600;
}

.nf-section-badge {
    font-size: 0.68rem;
    font-weight: 900;
    padding: 3px 7px;
    border-radius: 5px;
    letter-spacing: 0.5px;
    color: #fff;
}

.nf-see-all-btn {
    background: transparent;
    border: none;
    color: var(--nf-prime);
    font-weight: 700;
    font-size: 0.88rem;
    cursor: pointer;
}

.nf-window-toggle {
    display: inline-flex;
    background: #23232a;
    border-radius: 999px;
    padding: 3px;
}

.nf-window-btn {
    background: transparent;
    border: none;
    color: var(--nf-text-muted);
    font-size: 0.76rem;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 999px;
    cursor: pointer;
}

.nf-window-btn.active {
    background: var(--nf-red);
    color: #fff;
}

.nf-rail {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    padding: 4px 24px 14px;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: #3a3a44 transparent;
}

/* Categories 2-Row Rail */
.nf-categories-rail {
    display: grid;
    grid-auto-flow: column;
    grid-template-rows: repeat(2, 66px);
    grid-auto-columns: 158px;
    gap: 10px;
    overflow-x: auto;
    padding: 4px 24px 12px;
    scrollbar-width: thin;
}

.nf-cat-card {
    border-radius: 12px;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.14);
    transition: transform 0.15s, border-color 0.2s;
    text-align: left;
}

.nf-cat-card:hover {
    transform: translateY(-2px);
    border-color: #fff;
}

.nf-cat-card.selected {
    border: 2px solid #fff;
}

.nf-cat-name {
    font-size: 0.88rem;
    font-weight: 800;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nf-cat-sub {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.78);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Poster Cards */
.nf-card {
    flex: 0 0 155px;
    cursor: pointer;
    transition: transform 0.22s ease;
    position: relative;
}

.nf-card:hover {
    transform: scale(1.04);
    z-index: 4;
}

.nf-poster-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 2 / 3;
    border-radius: 10px;
    overflow: hidden;
    background: var(--nf-bg-card);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
}

.nf-poster-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.nf-card-bookmark {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 3;
}

.nf-card-bookmark.saved {
    color: var(--nf-gold);
    border-color: var(--nf-gold);
}

.nf-upcoming-tag {
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--nf-gold);
    color: #000;
    font-size: 0.64rem;
    font-weight: 900;
    padding: 3px 6px;
    border-radius: 5px;
    letter-spacing: 0.5px;
}

.nf-card-rating-pill {
    position: absolute;
    bottom: 8px;
    left: 8px;
    background: rgba(10, 10, 14, 0.85);
    color: var(--nf-gold);
    border: 1px solid rgba(255, 213, 79, 0.5);
    font-size: 0.72rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 999px;
}

.nf-card-title {
    margin-top: 8px;
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.nf-card-date {
    margin-top: 3px;
    font-size: 0.75rem;
    color: var(--nf-text-muted);
}

/* Top 10 Ranked Cards */
.nf-top10-item {
    display: flex;
    align-items: flex-end;
    flex: 0 0 auto;
    position: relative;
    padding-left: 34px;
}

.nf-top10-rank {
    position: absolute;
    left: 0;
    bottom: 42px;
    font-size: 4.5rem;
    font-weight: 900;
    line-height: 0.85;
    color: #141414;
    -webkit-text-stroke: 2px rgba(255, 255, 255, 0.82);
    z-index: 2;
    pointer-events: none;
    user-select: none;
}

/* Continue Watching Cards */
.nf-cw-card {
    flex: 0 0 245px;
    background: var(--nf-bg-elevated);
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--nf-border);
}

.nf-cw-thumb {
    position: relative;
    height: 138px;
    cursor: pointer;
    background: #000;
}

.nf-cw-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.85;
}

.nf-cw-play-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.72);
    border: 2px solid #fff;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.nf-cw-ep-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--nf-red);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 800;
    padding: 3px 7px;
    border-radius: 5px;
}

.nf-cw-remove {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.72);
    border: none;
    color: #fff;
    cursor: pointer;
    font-size: 1rem;
}

.nf-cw-progress-track {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: rgba(255, 255, 255, 0.25);
}

.nf-cw-progress-fill {
    height: 100%;
    background: var(--nf-red);
}

.nf-cw-footer {
    padding: 10px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    cursor: pointer;
}

.nf-cw-title {
    font-size: 0.86rem;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nf-cw-sub {
    font-size: 0.74rem;
    color: var(--nf-text-muted);
    margin-top: 2px;
}

/* Browse & Search 3-Column Grid */
.nf-browse-header {
    padding: 20px 24px 12px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.nf-browse-title {
    font-size: 1.6rem;
    font-weight: 900;
}

.nf-browse-subtitle {
    color: var(--nf-text-muted);
    font-size: 0.85rem;
    margin-top: 2px;
}

.nf-scope-tabs {
    display: flex;
    gap: 8px;
}

.nf-scope-btn {
    background: #23232a;
    border: 1px solid var(--nf-border);
    color: #fff;
    padding: 7px 14px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
}

.nf-scope-btn.active {
    background: var(--nf-red);
    border-color: var(--nf-red);
}

.nf-filters-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 0 24px 18px;
}

.nf-select {
    background: #1f1f26;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 0.84rem;
    font-weight: 600;
    cursor: pointer;
}

.nf-reset-btn {
    background: rgba(229, 9, 20, 0.16);
    color: #fff;
    border: 1px solid rgba(229, 9, 20, 0.5);
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 0.84rem;
    font-weight: 700;
    cursor: pointer;
}

.nf-grid-3col {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    padding: 0 24px 24px;
    max-width: 1180px;
    margin: 0 auto;
}

.nf-grid-3col .nf-card {
    flex: unset;
    width: 100%;
}

.nf-infinite-sentinel {
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.nf-spinner {
    width: 34px;
    height: 34px;
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-top-color: var(--nf-red);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.nf-end-msg {
    color: var(--nf-text-muted);
    font-size: 0.85rem;
}

.nf-empty-state {
    text-align: center;
    padding: 60px 24px;
    color: var(--nf-text-muted);
}

.nf-empty-state h3 {
    color: #fff;
    margin-bottom: 8px;
}

/* Modals */
.nf-modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.nf-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.84);
    backdrop-filter: blur(6px);
}

.nf-modal-card {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 960px;
    max-height: 92vh;
    overflow-y: auto;
    background: #18181c;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.85);
}

.nf-modal-compact {
    max-width: 720px;
}

.nf-modal-pad {
    padding: 24px;
}

.nf-modal-heading {
    font-size: 1.4rem;
    font-weight: 900;
}

.nf-modal-sub {
    color: var(--nf-text-muted);
    font-size: 0.88rem;
    margin: 4px 0 18px;
}

.nf-modal-topbar {
    position: sticky;
    top: 0;
    z-index: 15;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    pointer-events: none;
}

.nf-modal-topbar button {
    pointer-events: auto;
}

.nf-modal-back {
    background: rgba(0, 0, 0, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    padding: 7px 14px;
    border-radius: 999px;
    font-size: 0.84rem;
    font-weight: 700;
    cursor: pointer;
}

.nf-modal-close {
    margin-left: auto;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(0, 0, 0, 0.78);
    color: #fff;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}

.nf-detail-hero {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
    margin-top: -58px;
}

.nf-detail-hero img,
.nf-detail-hero iframe {
    width: 100%;
    height: 100%;
    border: none;
    object-fit: cover;
    display: block;
}

.nf-detail-hero-scrim {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 35%, #18181c 100%);
    pointer-events: none;
}

.nf-detail-body {
    padding: 18px 24px 30px;
}

.nf-tagline {
    color: var(--nf-gold);
    font-style: italic;
    font-size: 0.92rem;
    margin-top: 4px;
}

.nf-detail-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 10px 0 14px;
    font-size: 0.85rem;
    color: var(--nf-text-muted);
}

.nf-meta-chip {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 3px 9px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.78rem;
}

.nf-maturity-chip {
    border: 1px solid rgba(255, 255, 255, 0.45);
    color: #fff;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 800;
    font-size: 0.75rem;
}

.nf-detail-overview {
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.58;
    font-size: 0.95rem;
    margin-bottom: 18px;
}

/* Detail Tabs */
.nf-detail-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    padding-bottom: 10px;
    margin-bottom: 18px;
}

.nf-dtab {
    background: transparent;
    border: none;
    color: var(--nf-text-muted);
    font-size: 0.9rem;
    font-weight: 700;
    padding: 8px 14px;
    border-radius: 8px;
    white-space: nowrap;
    cursor: pointer;
}

.nf-dtab.active {
    background: var(--nf-red);
    color: #fff;
}

/* Episodes */
.nf-episode-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 14px;
}

.nf-episode-card {
    display: grid;
    grid-template-columns: 168px 1fr;
    gap: 14px;
    background: #212128;
    border-radius: 10px;
    padding: 10px;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.nf-episode-card:hover {
    border-color: var(--nf-red);
}

.nf-episode-thumb {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 8px;
    overflow: hidden;
    background: #101014;
    position: relative;
}

.nf-episode-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nf-ep-watched {
    position: absolute;
    top: 6px;
    left: 6px;
    background: #1b5e20;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
}

/* Cast & Clickable Person Cards */
.nf-cast-rail {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 8px;
}

.nf-cast-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(124px, 1fr));
    gap: 14px;
}

.nf-cast-card {
    flex: 0 0 112px;
    text-align: center;
    background: #202027;
    padding: 10px 8px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    cursor: pointer;
    transition: transform 0.16s, border-color 0.2s;
}

.nf-cast-card:hover {
    transform: translateY(-3px);
    border-color: var(--nf-red);
}

.nf-cast-card img {
    width: 82px;
    height: 82px;
    border-radius: 50%;
    object-fit: cover;
    background: #282830;
}

.nf-cast-name {
    font-size: 0.82rem;
    font-weight: 700;
    margin-top: 7px;
}

.nf-cast-role {
    font-size: 0.72rem;
    color: var(--nf-text-muted);
    margin-top: 2px;
}

/* Person Profile Modal */
.nf-person-header {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 20px;
    padding: 12px 24px 20px;
    align-items: start;
}

.nf-person-photo {
    width: 100%;
    aspect-ratio: 2 / 3;
    border-radius: 14px;
    object-fit: cover;
    background: #22222a;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
}

.nf-person-facts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 10px;
    margin: 12px 0;
}

.nf-fact-box {
    background: #212128;
    border-radius: 10px;
    padding: 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.nf-fact-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--nf-text-muted);
    font-weight: 700;
    letter-spacing: 0.5px;
}

.nf-fact-value {
    font-size: 0.88rem;
    font-weight: 700;
    margin-top: 3px;
}

/* Details & Languages Spec Table */
.nf-specs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.nf-pill-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 8px;
}

.nf-lang-chip {
    background: #23232c;
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #fff;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 600;
}

.nf-logo-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.92);
    color: #111;
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 800;
}

.nf-logo-chip img {
    height: 18px;
    width: auto;
    object-fit: contain;
}

.nf-video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
}

.nf-video-card {
    background: #212128;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.nf-video-card:hover {
    border-color: var(--nf-red);
}

.nf-video-thumb {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000;
}

.nf-video-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nf-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
}

.nf-gallery-grid img {
    width: 100%;
    border-radius: 8px;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    background: #101014;
}

.nf-review-card {
    background: #212128;
    border-radius: 10px;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 10px;
}

/* Profiles Grid */
.nf-profiles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.nf-profile-tile {
    background: #22222a;
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 14px 10px;
    text-align: center;
    cursor: pointer;
    color: #fff;
}

.nf-profile-tile.active {
    border-color: #fff;
}

.nf-profile-tile-icon {
    width: 52px;
    height: 52px;
    border-radius: 10px;
    margin: 0 auto 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 900;
}

.nf-profile-form {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.nf-profile-form input[type="text"] {
    flex: 1;
    min-width: 170px;
    background: #22222a;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 9px 12px;
    border-radius: 8px;
}

.nf-kids-check {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
}

.nf-categories-modal-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.nf-bottom-nav {
    display: none;
}

.nf-hero-skeleton {
    height: 460px;
    border-radius: 18px;
    background: linear-gradient(90deg, #1b1b22 25%, #272730 50%, #1b1b22 75%);
    background-size: 200% 100%;
    animation: shimmer 1.4s infinite;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.nf-toast {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 300;
    background: #23232b;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 10px 18px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

@media (max-width: 768px) {
    .nf-header {
        padding: 10px 12px;
    }
    .nf-nav {
        display: none;
    }
    .nf-search-box input {
        width: 105px;
    }
    .nf-sync-btn span,
    .nf-profile-name {
        display: none;
    }
    .nf-hero-wrapper,
    .nf-home-pills,
    .nf-section-head,
    .nf-rail,
    .nf-categories-rail,
    .nf-browse-header,
    .nf-filters-bar,
    .nf-grid-3col {
        padding-left: 12px;
        padding-right: 12px;
    }
    .nf-grid-3col {
        gap: 10px;
    }
    .nf-hero-card {
        height: 360px;
    }
    .nf-episode-card {
        grid-template-columns: 118px 1fr;
    }
    .nf-person-header {
        grid-template-columns: 1fr;
        padding: 12px 16px;
    }
    .nf-person-photo {
        max-width: 170px;
        margin: 0 auto;
    }
    .nf-bottom-nav {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 95;
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        background: rgba(15, 15, 18, 0.96);
        backdrop-filter: blur(12px);
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        padding: 6px 0;
    }
    .nf-bottom-item {
        background: transparent;
        border: none;
        color: var(--nf-text-muted);
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 3px;
        font-size: 0.68rem;
        font-weight: 600;
        cursor: pointer;
    }
    .nf-bottom-item.active {
        color: #fff;
    }
}
