@import url('https://fonts.googleapis.com/css2?family=Public+Sans:ital,wght@0,100..900;1,100..900&display=swap');

:root {
    /* Colours */
    --backgroundColour: #0e0e0e /* grey atm but I think I like #020202 more */;
    --accent1: #e11f4c;
    --accent2: #81122c;
    --muted: #838383;

    --transition: All 0.15s ease-in-out;

    color: white;
    background-color: var(--backgroundColour);

    font-family: "Public Sans";
}

button {
    appearance: none;
    -webkit-appearance: none;

    border: none;
    box-shadow: none;
}

body {
    margin: 0;
}

.nav {
    position: sticky;
    top: 0;
    left: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    height: 3.3rem;
    padding: 0.5rem 4rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0) 0%, #000000 100%);
    gap: 4rem;
}

.nav.scrolled {
    transition: var(--transition);
    background: 
        linear-gradient(to top, rgba(0, 0, 0, 0) 0%, #000000 100%),
        var(--backgroundColour);
    border-bottom: var(--accent1) solid 2px;
    box-shadow: var(--accent1) 0 0 20px;
}

.nav a:not(.logo) {
    font-size: 1.3rem;
    text-decoration: none;
    position: relative;
    padding-bottom: 0.25rem;
    font-weight: bold;
}

.nav a:not(.logo)::before {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    height: 4px;
    width: 0;
    background-color: var(--accent1);
    box-shadow: var(--accent1) 0 0 15px;
    border-radius: 100px;
}

.nav a:not(.logo):hover::before {
    width: 100%;
    transition: var(--transition);
}

.nav a:not(.logo):hover {
    transform: translateY(-2px);
    transition: var(--transition);
}

.navIcon {
    height: 1.3rem !important;
    width: auto;
    margin-right: 0.5rem;
}

.right {
    margin-left: auto;
    display: inline-block;
}

.right .navIcon {
    margin-right: 2rem;
}

.right img:hover, .imageButton:hover {
    transition: var(--transition);
    outline: 2px solid var(--accent1);
    outline-offset: 4px;
    box-shadow: var(--accent1) 0 0 20px;
}


.right img, .imageButton {
    border-radius: 5px;
    vertical-align: middle;
}

.nav img {
    height: 3rem;
    width: auto;
    display: inline-block;
}

.hero {
    top: -10rem;
    height: 1000px;               
    background-image: 
        linear-gradient(to bottom, #0e0e0e00 30%, #0e0e0e 100%),
        url("../images/Posters/TBS3E2.png");
    background-size: cover;       
    background-position: center;  
    background-repeat: no-repeat;
    position: relative;
    padding: 0 2rem;
}

.heroContent {
    font-size: 3rem;
    position: absolute;
    bottom: 5rem;
    left: 3rem;
    padding: 0 2rem;
}

.heroContent h5 {
    color: var(--muted);
    font-size: 2rem;
    line-height: 1rem;
}

.heroContent h1 {
    line-height: 0.2rem;
}

.majorBtn {
    background-color: white;
    border-radius: 6px;
    height: 4rem;
    width: 10rem;
    font-size: 2rem;
    font-weight: 550;
    padding: 0.5rem 0.5rem;
}

.majorBtn:hover {
    transition: var(--transition);
    outline: 2px solid var(--accent1);
    outline-offset: 4px;
    box-shadow: var(--accent1) 0 0 40px;
}

.minorBtn:hover {
    transition: var(--transition);
    outline: 2px solid var(--accent2);
    outline-offset: 4px;
    box-shadow: var(--accent2) 0 0 40px;
}

.minorBtn {
    color: white;
    background-color: #8a8a8abb;
    border-radius: 6px;
    height: 4rem;
    width: 15rem;
    font-size: 2rem;
    font-weight: 550;
    padding: 0.5rem 0.5rem;
}

button img {
    max-height: 2rem;
    vertical-align: middle;
    margin-right: 1rem;
}

.scroll-container {
    width: 90%;
    overflow-x: scroll;
    overflow-y: hidden; 
    white-space: nowrap;
    padding: 3rem 1.5rem 1.2rem;
    margin: 0 auto;
}

.showContent {
    display: inline-block;
}

.showContent img {
    display: inline-block;
    width: 20rem;
    max-height: 30rem;
    min-height: 12rem;
    height: auto;
    margin-right: 10px;
    box-shadow: #0000009b 0 10px 10px;
    max-width: 100%;
    border-radius: 5px;
}

.vertShowImg {
    min-height: 30rem !important;
    width: 20rem !important;
}

.showContent img:hover {
    transition: var(--transition);
    transform: scale(1.1);

    outline: 2px solid var(--accent1);
    outline-offset: 2px;
    box-shadow: var(--accent2) 0 10px 10px;
}

#shows h1{
    left: 5rem;
    position: absolute;
    margin: -5rem 0;
    font-size: 3rem;
}

#shows h5{
    left: 5rem;
    position: absolute;
    margin: -0.9rem 0;
    font-size: 1.2rem;
    color: var(--muted)
}

/* Scrollbar styling */
::-webkit-scrollbar {
    height: 7px;
    max-width: 7px;
}

::-webkit-scrollbar-track {
    background: #1a1a1a;
    border-radius: 100px;
}

::-webkit-scrollbar-thumb {
    background: var(--muted);
    border-radius: 100px;
}

::-webkit-scrollbar-thumb:hover {
    transition: var(--transition);
    background: var(--accent1);
}

.buffer {
    height: 7rem;
}

footer {
    margin-top: 3rem;
    height: 6rem;
    background-color: #0a0a0a;
    border-top: #121212 solid 5px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 0 5rem;
    color: #7a7a7ac4;
}

footer img {
    max-height: 5rem;
}


a {
    color: white;
}

.originalImg {
    height: 2.5rem;
    display: inline-block;
    vertical-align: middle;
}

.popupMenu {
    display: flex;          /* use flexbox */
    flex-direction: column; /* stack items vertically */
    position: fixed;
    transform-origin: top right;
    background: 
        linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, #000000 100%),
        var(--backgroundColour);
    border-radius: 6px;
    min-width: 160px;
    overflow: hidden;
    opacity: 0;
    transform: scaleY(0);
    transition: var(--transition);
    z-index: 1000;
    margin-top: 0.5rem;
}

.popupMenu.show {
    opacity: 1;
    transform: scaleY(1);
}

.popupMenu a {
    padding: 12px 16px;       /* space for each item */
    text-decoration: none;     /* remove underline */
    color: white;
    transition: var(--transition);
}

.popupMenu a:hover {
    background-color: #36363661;
}

.popupMenu img{
    max-height: 2rem;
    margin-right: 1rem;
    vertical-align: middle;
    border-radius: 3px;
}

.imageButton {
    max-width: 50px;          /* set the size of your button */
    max-height: 50px;
    background-size: cover;    /* scale image to fill button */
    background-position: center;
    border: none;             /* remove default button border */
    padding: 0;               /* remove default padding */
    cursor: pointer;          /* show pointer on hover */
    outline: none;            /* remove focus outline */
    background-color: #00000000;
}

#profile {
    background-image: url("../images/profiles/profile-blue.png");
    width: 2.5rem;
    height: 2.5rem;
}

#search {
    background-image: url("../images/icons/search.png");
    width: 1.5rem;
    height: 1.5rem;
    margin-right: 1rem;
}

.player {
    position: fixed;
    inset: 0; /* top:0; right:0; bottom:0; left:0; */
    background: rgba(4, 4, 4, 0.863);
    display: flex; /* center child */
    align-items: center; /* vertical centering */
    justify-content: center; /* horizontal centering */
    z-index: 80;
    display: none; /* hide by default */
}

.playerInner {
    background: #0f0f0f;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: var(--shadow);
    width: 70%; /* or any fixed width you want */
    display: flex;
    flex-direction: column; /* stack video + info vertically */
    align-items: center; /* center video horizontally */
    position: relative; /* for close button positioning */
}

.playerInner video {
    width: 100%; /* fills the inner container */
    height: auto; /* keeps aspect ratio */
    display: block;
    background: #000;
}

.playerInfo {
    padding: 12px 16px;
    text-align: center;
    color: #fff;
}

.closeButton {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 18px;
    cursor: pointer;
}

.popupPanel {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 80;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.popupPanel.active {
    opacity: 1;
    pointer-events: auto;
    display: flex;
}

.bannerInfo {
    z-index: 1000;
    position: absolute;
}

.popupContent {
    padding: 20px;
    position: relative;
    backdrop-filter: saturate(1.2) blur(8px);
    width: 90%;
    max-width: 800px;
    border: 1px solid var(--panel-2);
    border-radius: 10px;
    background: 
        linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, #000000 100%),
        var(--backgroundColour);
    box-shadow: 0 8px 24px rgba(0,0,0,0.6);
    transform: scale(0.95);
    transition: transform 0.3s ease;
    max-height: 80vh;
    overflow: auto;
}

.popupPanel.active .popupContent {
    transform: scale(1);
}

.popupBannerWrapper {
    position: relative;
    margin: -20px -20px 20px -20px;
    overflow: hidden;
    border-radius: 10px 10px 0 0;
}

.popupPanel.buttons {
    display: inline-block;
    vertical-align: middle;
}

.popupBanner {
    display: block;
    width: 100%;
    max-height: 300px;
    object-fit: cover;
}

.popupBannerWrapper::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, var(--backgroundColour), #0e0e0e00);
}

.showTitle {
    position: absolute;
    bottom: 20px;
    left: 20px;
    color: #fff;
    font-size: 2rem;
    font-weight: bold;
}

.episodes {
    gap: 15px;
    margin-top: 20px;
}

.episodes ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.episodes li {
    display: flex;
    align-items: center;
    background: #1a1a1a;
    border-radius: 6px;
    margin-bottom: 10px;
    padding: 10px;
    transition: background 0.2s ease;
}

.episodes li:hover {
  background: #222;
}

.episodes img {
    height: 90px;
    max-width: 160px;
    object-fit: cover;
    border-radius: 4px;
    margin-right: 15px;
}

.episodeInfo {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex: 1; /* take up remaining space */
}

.episodeInfo h3 {
    margin: 0;
    font-size: 1rem;
    color: #fff;
}

.playBtn {
    background: rgba(255,255,255,0.1);
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.playBtn img {
    height: 60px !important;
}

.playBtn:hover {
    background: rgba(255,255,255,0.2);
    transform: scale(1.05);
}

.popupPanel h1 {
    font-size: 3rem;
    font-weight: 800;
}

.buttonA {
    display: inline-block;
    vertical-align: middle;
    margin-left: 1.5rem;
    background: rgba(255,255,255,0.1);
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    color: #fff;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.buttonA:hover {
    background: rgba(255,255,255,0.2);
    transform: scale(1.05);
}

.subtext {
    color: var(--muted);
    font-size: 1.2rem;
    margin-top: -1.7rem;
}

#sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;             /* full height */
    max-width: 15rem;              /* sidebar width */
    background: 
        linear-gradient(to bottom, rgba(160, 160, 160, 0) 0%, #000000 100%),
        var(--backgroundColour);
    border-right: var(--backgroundColour) solid 5px;
    display: flex;
    flex-direction: column;    /* stack children vertically */
    box-shadow: 2px 0 10px rgba(0,0,0,0.5);
    z-index: 100;
    padding-left: 2rem;
    padding-right: 2rem;

}

#sidebar a {
    color: white;
    text-decoration: none;
    font-size: 1.2rem;
    margin: 1rem 0;
    transition: var(--transition);
}

#sidebar a:hover {
    color: var(--accent1);
    transform: translateX(5px);
    font-weight: 900;
}

#sidebar .bottom {
    margin-top: auto;          /* pushes it to the bottom */
    gap: 1rem;                 /* spacing between buttons */
    display: flex;
    flex-direction: column;    /* stack children vertically */
    margin-bottom: 2rem;
}


#sidebar img {
    max-width: 100px;
    height: auto;
}

#tv {
    margin-left: 10rem;
    overflow-y: scroll;
    overflow-x: hidden;
}

/* Remove default blue outline */
:focus {
    outline: none;
}

/* Specific TV Focus Styles */
#tv [tabindex="0"]:focus,
#tv button:focus,
#tv a:focus {
    transform: scale(1.05); /* Slight grow effect */
    box-shadow: 0 0 0 4px var(--accent1); /* Red border ring (Netflix style) */
    z-index: 10;
    transition: transform 0.2s, box-shadow 0.2s;
    border-radius: 4px;
}

/* Sidebar Specific Focus */ 
#sidebar a:focus {
    background-color: #333;
    border-left: 3px solid var(--accent1);
    box-shadow: none;
}

/* Adjust scroll containers for smooth scrolling */
.scroll-container {
    scroll-behavior: smooth;
    /* Ensure padding so focused items aren't cut off by scale effect */
    padding-top: 20px; 
    padding-bottom: 20px;
}

#tv #shows h1 {
    position: relative !important;
    font-size: 3rem !important;
    margin-bottom: 1px !important;
}

.bottom p {
    color: var(--muted);
    max-width: 7rem;
    font-size: 0.8rem;
}

#loginPage {
    background-image: url("../images/loginBG.png");
    background-size: stretch;       
    height: 100vh;
    width: 100vw;
}

#signin {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 84vh;
    text-align: center;
}

#signin .login-box, #signin .signup-box {
    background-color: #0c0c0c;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 0 20px #000000b0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    max-width: 40rem;
}

#signin h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

#signin p, #signin a:not(label a) {
    color: var(--muted);
    margin-top: 1rem;
}

#signin input:not(input[type="checkbox"]) {
    width: 100%;
    max-width: 30rem;
    min-height: 3rem;
    max-height: 20rem;
    margin: 0.5rem 0;
    background-color: #0a0a0a;
    border-radius: 10px;
    padding: 0.5rem 1rem;
    font-weight: 700;
    color: var(--muted);
    transition: var(--transition);
    border: 1px solid #222;
}

#signin input:focus:not(input[type="checkbox"]) {
    border-color: var(--accent1);
    box-shadow: 
        inset 0 0 10px var(--accent2),
        0 0 20px var(--accent2);
}

#signin button {
    margin-top: 1rem;
    width: 100%;
    max-width: 32rem;
    min-height: 3.5rem;
    max-height: 20rem;
    border: 1px solid #222;
    background-color: #00000000;
    border-radius: 10px;
    color: #222;
    font-size: 1.2rem;
    font-weight: 800;
    cursor: not-allowed;
    transition: var(--transition);
}

#signin button.usable {
    border-color: var(--accent1);
    box-shadow: 
        inset 0 0 10px var(--accent2),
        0 0 20px var(--accent2);
    cursor: pointer;
}

#signin button.usable:hover {
    border-width: 3px;
    box-shadow: 
        inset 0 0 10px var(--accent2),
        0 0 50px var(--accent2),
        0 0 10px var(--accent1);
}

#signin input[type="checkbox"] {
    margin-right: 1rem;
    vertical-align: middle;
}