/* Homepage-only design for the supplied 123Movies screenshot.
   Never affects movie pages, TV pages, account/admin, or the shared DB. */
.screen-reference {
    --site-width: 1440px;
    --brand-red: #f0444e;
    --brand-red-hover: #ff5862;
    background: #080d12;
    color: #f3f5f7;
    overflow-x: hidden;
}
.screen-reference .site-container { width: calc(100% - 56px); max-width: 1440px; }
.screen-reference a:focus-visible,
.screen-reference button:focus-visible,
.screen-reference input:focus-visible { outline: 2px solid #fb626c; outline-offset: 3px; }

/* Slim top navigation and search */
.screen-reference .ref-header { background: #0b1117; border-bottom: 1px solid #252c34; position: relative; z-index: 100; }
.screen-reference .ref-header-inner { min-height: 80px; display: flex; align-items: center; gap: 32px; }
.screen-reference .ref-brand { flex: 0 0 auto; display: flex; align-items: center; text-decoration: none; }
.screen-reference .ref-logo-text { color: #f7f9fc; font-size: 26px; line-height: 1; font-weight: 1000; font-style: italic; letter-spacing: -.09em; white-space: nowrap; }
.screen-reference .ref-logo-text i { font-style: italic; }
.screen-reference .ref-logo-text b { color: #fa4350; font-weight: 1000; }
.screen-reference .ref-nav { flex: 1; align-self: stretch; display: flex; align-items: stretch; gap: 25px; }
.screen-reference .ref-nav > a,
.screen-reference .ref-nav-dropdown > a { position: relative; display: flex; align-items: center; height: 100%; color: #d6dce3; text-decoration: none; font-size: 12px; font-weight: 800; letter-spacing: .06em; white-space: nowrap; }
.screen-reference .ref-nav > a:hover,
.screen-reference .ref-nav-dropdown > a:hover { color: #fff; }
.screen-reference .ref-nav > a.is-current { color: #fff; }
.screen-reference .ref-nav > a.is-current::after { content: ''; display: block; position: absolute; bottom: 0; left: 0; right: 0; height: 3px; background: #f24653; }
.screen-reference .ref-nav-dropdown { position: relative; }
.screen-reference .ref-dropdown-panel { min-width: 166px; position: absolute; top: 100%; left: -15px; display: none; padding: 9px; border: 1px solid #2a343f; border-radius: 0 0 10px 10px; background: #121921; box-shadow: 0 18px 30px rgba(0,0,0,.3); }
.screen-reference .ref-nav-dropdown:hover .ref-dropdown-panel,
.screen-reference .ref-nav-dropdown:focus-within .ref-dropdown-panel { display: grid; gap: 2px; }
.screen-reference .ref-dropdown-panel a { display: block; padding: 9px 11px; color: #d6dce3; text-decoration: none; font-size: 12px; border-radius: 5px; }
.screen-reference .ref-dropdown-panel a:hover { color: #fff; background: #25313c; }
.screen-reference .ref-search { flex: 0 1 320px; height: 43px; margin-left: auto; display: flex; background: #141c25; border: 1px solid #2b343e; border-radius: 7px; overflow: hidden; }
.screen-reference .ref-search:focus-within { border-color: #788797; }
.screen-reference .ref-search input { border: 0; outline: 0; min-width: 0; width: 100%; background: transparent; padding: 0 13px; color: #fff; font-size: 13px; }
.screen-reference .ref-search input::placeholder { color: #8b97a4; }
.screen-reference .ref-search button { display: grid; place-items: center; width: 42px; flex: 0 0 42px; border: 0; border-left: 1px solid #27313c; background: #141c25; color: #e3e9f0; cursor: pointer; }
.screen-reference .ref-search button:hover { background: #25313d; }
.screen-reference .ref-menu-toggle { display: none; border: 0; background: transparent; padding: 12px; }
.screen-reference .ref-menu-toggle span { width: 22px; height: 2px; display: block; margin: 4px 0; background: #f2f5f8; }

/* Large hero plus two editorial cards */
.screen-reference .nmhero-section { padding: 0 0 18px; }
.screen-reference .nmhero-layout { display: grid; grid-template-columns: minmax(0, 3.34fr) minmax(220px, 1fr); gap: 18px; }
.screen-reference .nmhero-main { min-height: 505px; border-radius: 14px; border-color: #27323b; box-shadow: none; }
.screen-reference .nmhero-side { gap: 18px; }
.screen-reference .nmhero-side-card { border-radius: 14px; border-color: #27323b; box-shadow: none; }
.screen-reference .nmhero-side-label { top: 16px; left: 16px; padding: 7px 11px; min-height: 0; background: #131b25; border: 1px solid #42505b; font-size: 10px; color: #fff; }
.screen-reference .nmhero-side-copy { left: 18px; right: 15px; bottom: 18px; }
.screen-reference .nmhero-side-title { font-size: 19px; line-height: 1.22; }
.screen-reference .nmhero-side-stats { color: #d3d9df; margin-top: 5px; }
.screen-reference .nmhero-side-arrow, .screen-reference .nmhero-side-logo-wrap { display: none; }
.screen-reference .nmhero-side-copy .nmhero-side-title[style*="none"] { display: block !important; }
.screen-reference .nmhero-content { left: 44px; bottom: 38px; width: min(590px, calc(100% - 85px)); }
.screen-reference .nmhero-eyebrow { color: #ffdb7f; font-size: 12px; letter-spacing: .16em; margin-bottom: 8px; }
.screen-reference .nmhero-eyebrow::before { content: '▍'; margin-right: 5px; color: #fff5ba; }
.screen-reference .nmhero-logo-wrap { margin-bottom: 20px; max-height: 200px; }
.screen-reference .nmhero-logo { max-height: 200px; }
.screen-reference .nmhero-title { max-width: 480px; font-size: clamp(42px, 5vw, 82px); line-height: 1; letter-spacing: -.04em; }
.screen-reference .nmhero-meta { gap: 7px; }
.screen-reference .nmhero-meta > span { min-height: 30px; display: inline-flex; align-items: center; padding: 0 9px; border: 1px solid rgba(255,255,255,.4); border-radius: 6px; background: rgba(3,7,12,.65); color: #fff; font-size: 12px; font-weight: 800; }
.screen-reference .nmhero-meta > span:nth-child(n+4) { display: none; }
.screen-reference .nmhero-meta .nmhero-rating { color: #fff; }
.screen-reference .nmhero-copy { display: none; }
.screen-reference .nmhero-actions { margin-top: 22px; }
.screen-reference .nmhero-btn-primary { padding: 0 21px; min-height: 48px; border-radius: 8px; background: #f14954; font-size: 13px; }
.screen-reference .nmhero-btn-primary::before { content: '▶'; font-size: 10px; margin-right: 9px; }
.screen-reference .nmhero-btn-primary:hover { background: #ff5762; }
.screen-reference .nmhero-btn-secondary { display: none; }
.screen-reference .nmhero-controls { bottom: 17px; right: 17px; left: auto; padding: 5px 7px; border: 1px solid #3a4552; border-radius: 8px; background: rgba(8,13,18,.83); gap: 3px; }
.screen-reference .nmhero-dots { gap: 4px; }
.screen-reference .nmhero-dot { width: 43px; height: 40px; padding: 0; border: 1px solid transparent; border-radius: 6px; background: transparent; color: #d3dbe5; font-size: 11px; font-weight: 900; }
.screen-reference .nmhero-dot.is-active { width: 43px; background: rgba(240,68,78,.17); border-color: #f0444e; color: #fff; }
.screen-reference .nmhero-arrow, .screen-reference .nmhero-counter { display: none; }

/* Discover strip */
.screen-reference .ref-discover { display: flex; align-items: center; gap: 8px; min-height: 62px; padding: 12px 17px; background: #111922; border: 1px solid #24303a; border-radius: 11px; overflow-x: auto; scrollbar-width: none; }
.screen-reference .ref-discover::-webkit-scrollbar { display: none; }
.screen-reference .ref-discover strong { color: #ffdc89; font-size: 11px; letter-spacing: .06em; margin-right: 4px; }
.screen-reference .ref-discover a { padding: 8px 13px; border: 1px solid #2b3946; background: #182432; color: #eef3f7; font-size: 11px; font-weight: 700; text-decoration: none; white-space: nowrap; border-radius: 25px; }
.screen-reference .ref-discover a:hover { background: #283749; }
.screen-reference .ref-ad-slot { margin-top: 14px; padding: 10px 0; text-align: center; overflow: hidden; }
.screen-reference .ref-ad-slot iframe, .screen-reference .ref-ad-slot img { max-width: 100%; }

/* Section titles and poster grids */
.screen-reference .ref-section { margin: 49px 0 0; }
.screen-reference .ref-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 46px; margin-bottom: 23px; }
.screen-reference .ref-section-intro { padding-left: 13px; border-left: 3px solid #ee4752; flex: 0 0 auto; min-width: 0; }
.screen-reference .ref-heading h2 { margin: 0; color: #f6f7f8; font-size: 24px; line-height: 1.15; font-weight: 850; letter-spacing: -.02em; }
.screen-reference .ref-heading p { margin: 5px 0 0; color: #a9b5c1; font-size: 12px; }
.screen-reference .ref-more { color: #ff505c; font-size: 12px; font-weight: 800; white-space: nowrap; text-decoration: none; margin-left: auto; }
.screen-reference .ref-more:hover { text-decoration: underline; }
.screen-reference .ref-tabs, .screen-reference .ref-tags { display: flex; align-items: center; gap: 8px; }
.screen-reference .ref-tabs button,
.screen-reference .ref-tags span { display: inline-flex; align-items: center; min-height: 36px; border: 1px solid #2c3742; border-radius: 22px; padding: 0 15px; background: #151e28; color: #e0e7ec; font-size: 11px; font-weight: 700; }
.screen-reference .ref-tabs button { cursor: pointer; }
.screen-reference .ref-tabs button:hover { background: #27313d; }
.screen-reference .ref-tabs .is-active,
.screen-reference .ref-tags .is-active { color: #fff; background: #ed4752; border-color: #ed4752; }
.screen-reference [hidden] { display: none !important; }
.screen-reference .ref-poster-grid { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 23px 17px; }
.screen-reference .ref-poster-grid .poster-card { min-width: 0; width: 100%; }
.screen-reference .ref-poster-grid .poster-card-link { position: relative; display: block; height: 100%; text-decoration: none; }
.screen-reference .ref-poster-grid .poster-card-image { position: relative; width: 100%; overflow: hidden; aspect-ratio: 2 / 3; border: 1px solid #35404a; border-radius: 10px; background: #141a21; }
.screen-reference .ref-poster-grid .poster-card-image img { width: 100%; height: 100%; object-fit: cover; }
.screen-reference .ref-poster-grid .poster-card h3 { position: absolute; z-index: 3; bottom: 1px; left: 1px; right: 1px; width: auto; min-height: 0; max-height: 67px; margin: 0; padding: 30px 10px 9px; border-radius: 0 0 9px 9px; overflow: hidden; background: linear-gradient(0deg, rgba(4,8,12,.99) 0%, rgba(5,8,12,.77) 56%, transparent 100%); color: #fff; font-size: 12px; line-height: 1.18; font-weight: 850; text-overflow: ellipsis; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.screen-reference .ref-poster-grid .poster-card-rating { top: 9px; left: auto; right: 8px; min-height: 28px; display: inline-flex; align-items: center; padding: 0 9px; background: #f7da9c; border-radius: 5px; color: #151613; font-size: 11px; font-weight: 900; }
.screen-reference .ref-poster-grid .poster-card-star { display: none; }
.screen-reference .ref-poster-grid .poster-card-quality { display: none !important; }
.screen-reference .ref-poster-grid .poster-card-context { left: 8px; bottom: 34px; border: 0; border-radius: 4px; padding: 4px 6px; background: rgba(4,8,12,.89); font-size: 10px; }
.screen-reference .ref-poster-grid .poster-card-badge { right: 8px; bottom: 33px; }
.screen-reference .ref-poster-grid .poster-card-link:hover h3 { color: #fff; }
.screen-reference .ref-poster-grid .poster-card-link:hover .poster-card-image { border-color: #f0444e; }

/* Episode subtitles sit below the artwork, exactly as in the screenshot. */
.screen-reference .ref-episode-grid .poster-card h3 { display: block; position: static; padding: 8px 0 0; margin: 0; background: none; line-height: 1.3; color: #f5f6f8; max-height: none; font-size: 12px; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.screen-reference .ref-episode-grid .poster-card-context { bottom: 9px; }
.screen-reference .ref-episode-grid .poster-card-rating { display: none; }
.screen-reference .ref-browse-bar { display: flex; align-items: center; gap: 8px; margin-top: 25px; min-height: 68px; background: #111922; border: 1px solid #2a3640; border-radius: 11px; padding: 13px 16px; }
.screen-reference .ref-browse-bar span { font-size: 12px; font-weight: 750; color: #e4edf4; margin-right: 5px; }
.screen-reference .ref-browse-bar a { padding: 10px 15px; background: #1a2734; border: 1px solid #31404d; border-radius: 7px; color: #e2ebf3; text-decoration: none; font-size: 11px; font-weight: 800; }
.screen-reference .ref-browse-bar a:hover { background: #314353; }
.screen-reference .ref-browse-bar .ref-primary-small { margin-left: auto; color: #fff; background: #f04a54; border-color: #f04a54; }
.screen-reference .ref-browse-bar .ref-primary-small:hover { background: #ff5862; }

/* Footer feature cards */
.screen-reference .ref-discovery-section { margin-top: 55px; padding: 30px 0 45px; border-top: 1px solid #2a3540; }
.screen-reference .ref-discovery-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 17px; }
.screen-reference .ref-discovery-grid a { display: block; padding: 38px 28px; min-width: 0; border: 1px solid #39404b; border-radius: 14px; background: linear-gradient(120deg,#181b24,#30242d); text-decoration: none; }
.screen-reference .ref-discovery-grid a:hover { border-color: #f04a54; transform: translateY(-2px); }
.screen-reference .ref-discovery-grid h3 { font-size: 19px; color: #fff; margin: 0 0 12px; }
.screen-reference .ref-discovery-grid p { margin: 0 0 12px; color: #cbd2d9; font-size: 12px; line-height: 1.6; }
.screen-reference .ref-discovery-grid strong { color: #fa5663; font-size: 12px; }
.screen-reference .ref-footer { border-top: 1px solid #27313c; background: #101720; padding: 67px 0 30px; }
.screen-reference .ref-footer-cols { display: grid; grid-template-columns: 2fr repeat(4,1fr); gap: 55px; }
.screen-reference .ref-footer-brand .ref-logo-text { display: inline-block; font-size: 34px; }
.screen-reference .ref-footer-brand p { color: #aab6c2; font-size: 12px; line-height: 1.7; max-width: 345px; margin-top: 19px; }
.screen-reference .ref-footer h4 { font-size: 13px; margin: 0 0 16px; color: #fff; }
.screen-reference .ref-footer-cols a, .screen-reference .ref-footer-cols span:not(.ref-logo-text) { display: block; font-size: 12px; color: #c5d0da; text-decoration: none; margin-bottom: 12px; }
.screen-reference .ref-footer-cols a:hover { color: #ff5e69; }
.screen-reference .ref-footer-bottom { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; margin-top: 42px; padding-top: 22px; border-top: 1px solid #26303a; color: #8393a2; font-size: 10px; }
.screen-reference .ref-footer-bottom a { color: #ff777d; text-decoration: none; }

@media (max-width: 1250px) {
    .screen-reference .ref-header-inner { gap: 20px; }
    .screen-reference .ref-nav { gap: 17px; }
    .screen-reference .ref-search { flex-basis: 245px; }
    .screen-reference .nmhero-layout { grid-template-columns: minmax(0,3fr) minmax(200px,1fr); }
    .screen-reference .ref-poster-grid { grid-template-columns: repeat(6,minmax(0,1fr)); }
}
@media (max-width: 980px) {
    .screen-reference .ref-menu-toggle { display: block; margin-left: auto; order: 3; cursor: pointer; }
    .screen-reference .ref-header-inner { flex-wrap: wrap; min-height: 70px; }
    .screen-reference .ref-nav { display: none; order: 4; width: 100%; flex: 0 0 100%; height: auto; padding: 8px 0 18px; gap: 0; flex-direction: column; }
    .screen-reference .ref-nav.is-open { display: flex; }
    .screen-reference .ref-nav > a, .screen-reference .ref-nav-dropdown > a { display: block; padding: 11px 13px; height: auto; }
    .screen-reference .ref-nav > a.is-current::after { height: auto; top: 5px; bottom: 5px; left: 0; right: auto; width: 3px; }
    .screen-reference .ref-dropdown-panel { position: static; display: none; box-shadow: none; }
    .screen-reference .ref-nav-dropdown:hover .ref-dropdown-panel, .screen-reference .ref-nav-dropdown:focus-within .ref-dropdown-panel { display: grid; }
    .screen-reference .ref-search { margin-left: auto; flex: 0 1 300px; order: 2; }
    .screen-reference .nmhero-layout { grid-template-columns: 1fr; }
    .screen-reference .nmhero-main { min-height: 480px; }
    .screen-reference .nmhero-side { grid-template-columns: repeat(2,minmax(0,1fr)); grid-template-rows: auto; }
    .screen-reference .nmhero-side-card { min-height: 190px; }
    .screen-reference .ref-poster-grid { grid-template-columns: repeat(4,minmax(0,1fr)); }
    .screen-reference .ref-discovery-grid { gap: 12px; }
    .screen-reference .ref-discovery-grid a { padding: 26px 18px; }
    .screen-reference .ref-footer-cols { gap: 25px; }
}
@media (max-width: 650px) {
    .screen-reference .site-container { width: calc(100% - 28px); }
    .screen-reference .ref-header-inner { gap: 10px; padding-top: 9px; padding-bottom: 9px; }
    .screen-reference .ref-brand .ref-logo-text { font-size: 22px; }
    .screen-reference .ref-search { flex: 1 1 100%; order: 4; height: 40px; }
    .screen-reference .ref-menu-toggle { order: 2; }
    .screen-reference .ref-nav { order: 5; }
    .screen-reference .nmhero-section { padding: 12px 0 12px; }
    .screen-reference .nmhero-main { min-height: 400px; border-radius: 12px; }
    .screen-reference .nmhero-content { left: 20px; right: 20px; bottom: 58px; width: auto; }
    .screen-reference .nmhero-title { font-size: 43px; }
    .screen-reference .nmhero-logo { max-height: 114px; }
    .screen-reference .nmhero-eyebrow { font-size: 10px; }
    .screen-reference .nmhero-meta > span { min-height: 25px; font-size: 10px; padding: 0 6px; }
    .screen-reference .nmhero-btn-primary { min-height: 42px; font-size: 12px; }
    .screen-reference .nmhero-controls { bottom: 10px; right: 10px; }
    .screen-reference .nmhero-dot, .screen-reference .nmhero-dot.is-active { width: 25px; height: 25px; font-size: 9px; }
    .screen-reference .nmhero-side { gap: 10px; }
    .screen-reference .nmhero-side-card { min-height: 145px; }
    .screen-reference .nmhero-side-title { font-size: 13px; }
    .screen-reference .nmhero-side-copy { left: 12px; bottom: 12px; }
    .screen-reference .nmhero-side-label { left: 10px; top: 10px; font-size: 8px; padding: 5px 7px; }
    .screen-reference .ref-discover { min-height: 54px; padding: 10px 12px; }
    .screen-reference .ref-section { margin-top: 38px; }
    .screen-reference .ref-heading { align-items: flex-start; gap: 12px; flex-wrap: wrap; margin-bottom: 17px; }
    .screen-reference .ref-heading h2 { font-size: 20px; }
    .screen-reference .ref-heading p { font-size: 11px; }
    .screen-reference .ref-more { font-size: 11px; }
    .screen-reference .ref-tabs { order: 3; width: 100%; }
    .screen-reference .ref-poster-grid { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 15px 10px; }
    .screen-reference .ref-poster-grid .poster-card h3 { font-size: 10px; padding: 25px 7px 7px; }
    .screen-reference .ref-poster-grid .poster-card-rating { top: 6px; right: 6px; min-height: 22px; padding: 0 6px; font-size: 10px; }
    .screen-reference .ref-browse-bar { flex-wrap: wrap; }
    .screen-reference .ref-browse-bar .ref-primary-small { width: 100%; text-align: center; margin-left: 0; }
    .screen-reference .ref-discovery-grid { grid-template-columns: 1fr; }
    .screen-reference .ref-footer-cols { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 24px; }
    .screen-reference .ref-footer-brand { grid-column: 1 / -1; }
    .screen-reference .ref-footer { padding-top: 40px; }
    .screen-reference .ref-footer-bottom { gap: 12px; }
}
@media (max-width: 380px) {
    .screen-reference .ref-poster-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .screen-reference .nmhero-dot, .screen-reference .nmhero-dot.is-active { width: 22px; }
    .screen-reference .nmhero-side { grid-template-columns: 1fr; }
}


/* ============================================================
   Full-width homepage featured slider (v2).
   Match the site's normal full content width. The smaller
   "Popular Today"/"Popular This Week" hero cards are removed
   from this area; titles remain accessible in the sections below.
   Higher-specificity !important rules intentionally override the
   legacy css/home.css hero width and two-column hard fix.
   ============================================================ */
.screen-reference .nmhero-section > .site-container.nmhero-layout {
    width: calc(100% - 56px) !important;
    max-width: 1440px !important;
    margin-inline: auto !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0 !important;
}
.screen-reference .nmhero-section .nmhero-layout {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0 !important;
}
.screen-reference .nmhero-section .nmhero-main {
    width: 100%;
    min-width: 0;
    min-height: 520px;
}
.screen-reference .nmhero-section .nmhero-side {
    display: none !important;
}
@media (max-width: 980px) {
    .screen-reference .nmhero-section .nmhero-main {
        min-height: 460px;
    }
}
@media (max-width: 650px) {
    .screen-reference .nmhero-section > .site-container.nmhero-layout {
        width: calc(100% - 28px) !important;
    }
    .screen-reference .nmhero-section .nmhero-main {
        min-height: 400px;
    }
}
