:root {
    --netflix-red: #E50914;
    --netflix-bg: #141414;
}

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

body, html {
    width: 100vw;
    height: 100vh;
    background-color: var(--netflix-bg);
    color: #fff;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    overflow: hidden;
    -webkit-font-smoothing: antialiased;
}

.back-btn {
    position: absolute;
    z-index: 999;
    background: transparent; 
    color: rgba(255, 255, 255, 0.6); 
    border: none;
    font-size: 1.5vw;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    top: 3.5vw;
    right: 5vw;
    padding: 10px;
    letter-spacing: 1px;
}

.back-btn:hover {
    color: #fff; 
    transform: translateX(-5px);
    text-shadow: 0px 0px 8px rgba(255, 255, 255, 0.5);
}

.global-logo {
    position: absolute;
    top: 3vw;
    left: 5vw;
    width: 20vw; 
    min-width: 180px; 
    z-index: 100;
    object-fit: contain;
}

.nav-logo-img {
    width: 20vw; 
    min-width: 180px; 
    margin-right: 0; 
    object-fit: contain;
    z-index: 100;
}

#landscape-guard {
    display: none;
    position: fixed;
    inset: 0;
    background-color: var(--netflix-bg);
    z-index: 9999;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
}

.phone-icon {
    width: 60px;
    height: 100px;
    border: 4px solid #fff;
    border-radius: 10px;
    position: relative;
    animation: rotatePhone 2s ease-in-out infinite;
    margin-bottom: 2rem;
}

@keyframes rotatePhone {
    0% { transform: rotate(0deg); }
    50% { transform: rotate(-90deg); }
    100% { transform: rotate(-90deg); }
}

@media (orientation: portrait) {
    #landscape-guard { display: flex; }
    #app-container { display: none; }
}

.phase {
    position: absolute;
    inset: 0;
    width: 100vw;
    height: 100vh;
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s ease-in-out;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.phase.active {
    opacity: 1;
    visibility: visible;
}

#hidden-trigger {
    background-color: #000;
    cursor: pointer;
    z-index: 1000;
}

.fake-player-icon {
    font-size: 5rem;
    color: rgba(255, 255, 255, 0.2);
    transition: color 0.3s;
}

#hidden-trigger:hover .fake-player-icon {
    color: rgba(255, 255, 255, 0.6);
}

#intro-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profiles-title {
    font-size: 3vw;
    font-weight: 500;
    margin-bottom: 2rem;
}

.profiles-container {
    display: flex;
    gap: 2vw;
}

.profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
}

.profile-img {
    width: 10vw;
    height: 10vw;
    min-width: 100px;
    min-height: 100px;
    border-radius: 4px;
    background-color: #333;
    background-size: cover;
    background-position: center;
    border: 3px solid transparent;
    transition: all 0.3s ease-in-out;
}

.profile:hover .profile-img {
    border-color: #fff;
    transform: scale(1.05);
}

.profile-name {
    margin-top: 15px;
    color: #808080;
    font-size: 1.5vw;
    transition: color 0.3s;
}

.profile:hover .profile-name {
    color: #fff;
}

#phase3 {
    position: relative;
    display: block; 
    background: #000;
}

#hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    z-index: 1; 
    filter: brightness(0.6);
}

.hero-ui-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2; 
}

.netflix-nav {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 3vw 5vw;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, transparent 100%);
}

.nav-links {
    display: flex;
    gap: 3vw;
    font-size: 1.2vw;
    font-weight: bold;
    color: #e5e5e5;
}

.nav-links span {
    cursor: pointer;
    transition: color 0.3s;
}

.nav-links span:hover {
    color: #fff;
}

.hero-content {
    position: absolute;
    bottom: 15vh;
    left: 5vw;
    max-width: 50vw;
    text-align: left;
}

.hero-episode {
    font-size: 1.5vw;
    font-weight: bold;
    margin-bottom: 0.5rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
    color: #fff;
}

.hero-title.cursive {
    font-family: 'Brush Script MT', 'Lucida Handwriting', cursive;
    font-size: 6vw;
    font-weight: normal;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
}

.hero-metadata {
    display: flex;
    align-items: center;
    gap: 1vw;
    font-size: 1.1vw;
    font-weight: bold;
    color: #d2d2d2;
    margin-bottom: 1.5rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
}

.hd-badge {
    border: 1px solid #d2d2d2;
    padding: 0.1vw 0.5vw;
    border-radius: 3px;
    font-size: 0.9vw;
}

.hero-desc {
    font-size: 1.2vw;
    margin-bottom: 2rem;
    line-height: 1.5;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
}

.hero-actions {
    display: flex;
    gap: 1vw;
}

.hero-btn {
    padding: 0.8vw 3vw;
    font-size: 1.3vw;
    font-weight: bold;
    border: none;
    border-radius: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.hero-btn.disabled {
    background-color: rgba(255, 255, 255, 0.5);
    color: #000;
    cursor: not-allowed;
}

.hero-btn.active {
    background-color: #fff;
    color: #000;
    cursor: pointer;
}

.hero-btn.active:hover {
    background-color: rgba(255,255,255,0.7);
}

.hero-btn.secondary {
    background-color: rgba(80, 80, 80, 0.7);
    color: #fff;
    cursor: pointer;
}

.hero-btn.secondary:hover {
    background-color: rgba(109, 109, 110, 0.9);
}

#player-container {
    position: relative;
    width: 100%;
    height: 100%;
    background: #000;
}

#main-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.custom-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: opacity 0.3s ease-in-out;
}

.progress-container {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.2);
    cursor: pointer;
    border-radius: 3px;
    position: relative;
}

.progress-bar {
    height: 100%;
    background: var(--netflix-red);
    width: 0%;
    border-radius: 3px;
    position: relative;
}

.progress-bar::after {
    content: '';
    position: absolute;
    right: -6px;
    top: -4px;
    width: 14px;
    height: 14px;
    background: var(--netflix-red);
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.2s;
}

.progress-container:hover .progress-bar::after { opacity: 1; }

.controls-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.control-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    padding: 0 10px;
    transition: transform 0.2s;
}

.control-btn:hover { transform: scale(1.1); }

.left-controls, .right-controls { display: flex; align-items: center; }

.credits-text {
    position: absolute;
    top: 0;
    left: 50%;
    width: 85%;
    max-width: 1200px; 
    text-align: center;
    font-size: 1.8vw; 
    line-height: 2.2;
    color: #ccc;
    white-space: pre-line;
    transform: translate(-50%, 50vh); 
}

.credits-text strong { 
    display: block;
    color: #fff; 
    font-size: 2.2vw;
    margin-top: 5rem;
    margin-bottom: 1.5rem;
    letter-spacing: 2px;
}

.credits-text strong:first-child {
    margin-top: 0;
}

.scroll-animation {
    animation: scrollUp var(--scroll-duration, 126s) linear forwards;
}

@keyframes scrollUp {
    0% { transform: translate(-50%, 50vh); }
    100% { transform: translate(-50%, -100%); }
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    position: relative; 
    background: #141414;
    padding: 30px;
    border-radius: 4px;
    text-align: center;
    border: 1px solid #333;
    width: 90%;
    max-width: 400px;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    color: #808080;
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s;
}

.close-modal:hover {
    color: #fff;
}

.modal-content h2 {
    margin-bottom: 10px;
    font-size: 1.5rem;
}

.modal-content p {
    color: #808080;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.pin-input-group input {
    width: 100%;
    padding: 10px;
    background: #333;
    border: 1px solid #555;
    color: white;
    font-size: 1.2rem;
    text-align: center;
    border-radius: 4px;
    margin-bottom: 10px;
    outline: none;
    letter-spacing: 5px; 
}

.pin-input-group input:focus {
    border-color: #fff;
}

.pin-error {
    color: var(--netflix-red);
    font-size: 0.85rem;
    margin-bottom: 10px;
    opacity: 0;
    transition: opacity 0.3s;
}

.pin-error.visible {
    opacity: 1;
}

.made-with-love {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    opacity: 0;
    visibility: hidden;
    color: #ccc;
    font-size: 1.8vw;
    transition: opacity 1s ease-in-out, visibility 1s ease-in-out;
    white-space: pre-line;
}

.made-with-love strong {
    display: block;
    color: #fff;
    font-size: 2.2vw;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}

.made-with-love.visible {
    opacity: 1;
    visibility: visible;
}
