* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scrollbar-width: none; /* hides scrollbar */
    -ms-overflow-style: none; /* for IE 10+ */
}

body {
    background: #000;
    color: white;
    font-family: Arial, sans-serif;
    height: 100vh;
    overflow: hidden;
}

/* For WebKit browsers */
*::-webkit-scrollbar {
    display: none;
}

.home-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    color: rgba(255,255,255,0.7);
    background: #000;
    z-index: 1;
}

.home-screen.hidden {
    display: none;
}

.movie-grid {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 2rem;
    overflow-y: auto;
    background: rgba(0,0,0,0.95);
    z-index: 2;
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.movie-grid.active {
    display: block;
    opacity: 1;
    transform: scale(1);
}

.movie-category {
    margin-bottom: 2rem;
}

.category-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: rgba(255,255,255,0.9);
    padding-left: 0.5rem;
}

.movie-row {
    display: flex;
    gap: 1.5rem;
    padding: 0.5rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.movie-row::-webkit-scrollbar {
    display: none;
}

.movie-item {
    position: relative;
    flex: 0 0 auto;
    width: 180px;
    aspect-ratio: 2/3;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease, outline 0.2s ease;
    scroll-snap-align: start;
}

.movie-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.movie-item h3 {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    margin: 0;
    font-size: 1rem;
    font-weight: normal;
}

.movie-item.selected {
    outline: 3px solid #fff;
    outline-offset: 2px;
}

.movie-player {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    z-index: 3;
}

.movie-player.active {
    display: block;
}

.movie-player video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    padding: 20px;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.video-controls.hidden {
    opacity: 0;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.3);
    border-radius: 2px;
    cursor: pointer;
    margin-bottom: 10px;
}

.progress {
    height: 100%;
    background: #E50914;
    border-radius: 2px;
    width: 0%;
    position: relative;
}

.progress-handle {
    position: absolute;
    right: -6px;
    top: -4px;
    width: 12px;
    height: 12px;
    background: #E50914;
    border-radius: 50%;
    transform: scale(0);
    transition: transform 0.2s ease;
}

.progress-bar:hover .progress-handle {
    transform: scale(1);
}

.control-buttons {
    display: flex;
    align-items: center;
    gap: 20px;
}

.control-button {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 5px;
    transition: transform 0.2s ease;
}

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

.time-display {
    color: white;
    font-size: 14px;
    margin-left: 10px;
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.volume-slider {
    width: 80px;
    height: 4px;
    background: rgba(255,255,255,0.3);
    border-radius: 2px;
    cursor: pointer;
}

.volume-level {
    height: 100%;
    background: white;
    border-radius: 2px;
    width: 100%;
}

.navigationHint {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.8);
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
    border: 1px solid rgba(255,255,255,0.1);
    z-index: 4;
}
