:root {
    --main-color: #8A2BE2;
    --secondary-color: #6a0dad;
    --dark-color: #141414;
    --light-color: #f8f8f8;
    --gray-color: #696969;
    --overlay-color: rgba(0, 0, 0, 0.85);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Arial', sans-serif;
}

body {
    background-color: var(--dark-color);
    color: var(--light-color);
    overflow-x: hidden;
    padding-bottom: 60px;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.9) 0%, transparent 100%);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--main-color);
    cursor: pointer;
}

.hero-nav {
    display: flex;
    align-items: center;
}

.search-btn {
    background: none;
    border: none;
    color: var(--gray-color);
    font-size: 18px;
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s;
    outline: none;
    position: absolute;
    top: 15px;
    right: 5%;
    z-index: 1001;
}

.search-btn:hover {
    color: var(--main-color);
}

/* Hero Section */
.hero {
    height: 70vh;
    display: flex;
    align-items: flex-end;
    padding: 30px 20px;
    margin-bottom: 15px;
    margin-top: 60px;
    position: relative;
    overflow: hidden;
}

.hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.hero-gradient {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(to top, rgba(0, 0, 0, 1), rgba(0, 0, 0, 0));
    z-index: 1;
}

.hero-content {
    max-width: 100%;
    z-index: 2;
}

.hero-title {
    font-size: 2.2rem;
    margin-bottom: 12px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.hero-desc {
    margin-bottom: 20px;
    color: #ccc;
    font-size: 14px;
    line-height: 1.5;
    max-width: 600px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.7);
}

.hero-buttons {
    display: flex;
    gap: 12px;
}

.hero-btn {
    background-color: var(--main-color);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}

.hero-btn:hover {
    background-color: var(--secondary-color);
    transform: scale(1.05);
}

.hero-btn.info {
    background-color: rgba(109, 109, 110, 0.7);
}

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

.hero-nav {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 15px;
    z-index: 3;
}

.hero-nav-btn {
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.hero-nav-btn:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.1);
}

.hero-dots {
    display: flex;
    gap: 8px;
}

.hero-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    transition: all 0.3s;
}

.hero-dot.active {
    background-color: var(--main-color);
    transform: scale(1.2);
}

/* Contenido */
.section-title {
    margin: 15px 0 12px 5%;
    font-size: 1.4rem;
}

.row {
    display: flex;
    padding: 10px 5%;
    gap: 15px;
}

.row.horizontal {
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    flex-wrap: nowrap;
}

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

.row.vertical {
    flex-wrap: wrap;
    overflow-y: auto;
    max-height: 70vh;
}

.item {
    flex: 0 0 auto;
    width: 140px;
    transition: transform 0.3s;
    position: relative;
    cursor: pointer;
}

.row.vertical .item {
    flex: 0 0 calc(20% - 12px);
}

.item:hover {
    transform: scale(1.05);
}

.item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
}

.item-info {
    padding: 10px 0;
}

.item-title {
    font-size: 14px;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.item-meta {
    font-size: 12px;
    color: var(--main-color);
    display: flex;
    justify-content: space-between;
}

.item-actions {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.3s;
    border-radius: 4px;
}

.item:hover .item-actions {
    opacity: 1;
}

.action-btn {
    background-color: var(--main-color);
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.3s;
}

.action-btn:hover {
    background-color: var(--secondary-color);
}

.action-btn.trailer {
    background-color: rgba(109, 109, 110, 0.7);
}

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

.like-btn {
    background: none;
    border: none;
    color: #ccc;
    font-size: 18px;
    cursor: pointer;
    transition: color 0.3s;
}

.like-btn.active {
    color: var(--main-color);
}

.like-btn:hover {
    transform: scale(1.2);
}

.more-btn {
    background: none;
    border: none;
    color: var(--main-color);
    font-size: 24px;
    cursor: pointer;
    padding: 10px;
    margin: 10px 5%;
    display: block;
}

.more-btn:hover {
    color: var(--secondary-color);
}

/* Modal de reproducción */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--overlay-color);
    z-index: 1002;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal-content {
    background-color: var(--dark-color);
    width: 100%;
    max-width: 500px;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

.help-content {
    max-width: 600px;
    text-align: center;
}

.close-modal {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 1003;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-modal:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.1);
}

.video-container {
    position: relative;
    padding-top: 56.25%;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.modal-info {
    padding: 15px;
}

.modal-title {
    font-size: 20px;
    margin-bottom: 8px;
}

.modal-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 10px;
}

.modal-year,
.modal-type {
    font-size: 14px;
    color: var(--main-color);
}

.modal-desc {
    color: #ccc;
    margin-bottom: 15px;
    font-size: 14px;
    line-height: 1.5;
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.help-text {
    background-color: var(--dark-color);
    color: white;
    padding: 20px;
    border-radius: 8px;
}

.help-text h3 {
    margin-bottom: 15px;
}

.help-text p {
    margin-bottom: 10px;
}

.help-text strong {
    color: var(--main-color);
}

/* Overlay de búsqueda */
.search-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--overlay-color);
    z-index: 1000;
    padding: 70px 5% 20px;
    overflow-y: auto;
}

.search-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 15px;
}

.close-search {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
}

.close-search:hover {
    transform: scale(1.1);
}

.search-box {
    position: relative;
    margin-bottom: 20px;
}

.search-box input {
    width: 100%;
    padding: 10px;
    padding-left: 0;
    background: transparent;
    border: none;
    color: white;
    font-size: 18px;
}

.search-box input:focus {
    outline: none;
}

.search-box::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--main-color);
}

/* Barra de navegación inferior */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--dark-color);
    display: flex;
    justify-content: space-around;
    padding: 12px 0;
    border-top: 1px solid var(--gray-color);
    z-index: 999;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--gray-color);
    font-size: 12px;
    text-decoration: none;
    transition: all 0.3s;
}

.nav-item.active,
.nav-item:hover {
    color: var(--main-color);
    transform: translateY(-2px);
}

.nav-item i {
    font-size: 20px;
    margin-bottom: 4px;
}

/* Paneles de contenido */
.profile-panel,
.config-panel,
.auth-panel,
.public-admin-panel {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    width: 300px;
    height: 100%;
    background-color: var(--dark-color);
    z-index: 1001;
    padding: 70px 20px 20px;
    overflow-y: auto;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.5);
}

.config-panel {
    width: 300px;
}

.close-panel {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
}

.close-panel:hover {
    transform: scale(1.1);
}

.profile-header {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.profile-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--main-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
    margin-right: 15px;
}

.profile-info h3 {
    font-size: 18px;
    margin-bottom: 5px;
}

.profile-info p {
    color: var(--gray-color);
    font-size: 14px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    color: var(--gray-color);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--gray-color);
    border-radius: 4px;
    color: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--main-color);
}

.form-group textarea {
    height: 100px;
    resize: vertical;
}

.auth-form-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 20px;
}

.auth-form-group input {
    padding: 10px;
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--gray-color);
    border-radius: 4px;
    color: white;
}

.auth-form-group input:focus {
    outline: none;
    border-color: var(--main-color);
}

.auth-btn,
.save-btn,
.search-content-btn {
    background-color: var(--main-color);
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
    margin-bottom: 10px;
}

.auth-btn:hover,
.save-btn:hover,
.search-content-btn:hover {
    background-color: var(--secondary-color);
}

.admin-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 20px;
}

.content-list {
    margin-top: 15px;
    max-height: 300px;
    overflow-y: auto;
}

.content-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
}

.content-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.content-item-info {
    flex: 1;
}

.content-item-title {
    font-size: 16px;
    margin-bottom: 5px;
}

.content-item-meta {
    font-size: 12px;
    color: var(--gray-color);
}

.delete-btn,
.featured-btn,
.remove-featured-btn {
    background-color: #ff4d4d;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.featured-btn,
.remove-featured-btn {
    background-color: var(--main-color);
}

.delete-btn:hover {
    background-color: #ff1a1a;
}

.featured-btn:hover,
.remove-featured-btn:hover {
    background-color: var(--secondary-color);
}

.featured-selector {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.featured-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s;
}

.featured-dot.active {
    background-color: var(--main-color);
    transform: scale(1.2);
}

.empty-message {
    text-align: center;
    padding: 20px;
    color: var(--gray-color);
    font-style: italic;
}

.hidden {
    display: none !important;
}

/* Config Panel */
.config-panel {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    width: 300px;
    height: 100%;
    background-color: var(--dark-color);
    z-index: 1001;
    padding: 70px 20px 20px;
    overflow-y: auto;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.5);
}

.config-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.config-btn {
    background-color: var(--main-color);
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 10px;
}

.config-btn:hover {
    background-color: var(--secondary-color);
}

/* Ocultar barra de navegación inferior cuando el panel de configuración está abierto */
.config-panel ~ .bottom-nav {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-title {
        font-size: 1.8rem;
    }
    .row.vertical .item {
        flex: 0 0 calc(33.33% - 10px);
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.5rem;
    }
    .row.vertical .item {
        flex: 0 0 calc(50% - 7.5px);
    }
}
