/* Reset e Variáveis Globais */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #ff0000;
    --primary-dark: #cc0000;
    --background-dark: #0f0f0f;
    --background-secondary: #1a1a1a;
    --background-tertiary: #16213e;
    --text-primary: #ffffff;
    --text-secondary: #aaaaaa;
    --border-color: #303030;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, var(--background-dark) 0%, var(--background-tertiary) 100%);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Container Principal */
.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 40px;
    animation: fadeIn 0.6s ease-in-out;
}

.header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    background: linear-gradient(135deg, var(--primary-color), #ff6b6b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header p {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 400;
}

/* Main Content */
.main-content {
    width: 100%;
    animation: slideUp 0.6s ease-in-out;
}

/* Image Wrapper */
.image-wrapper {
    position: relative;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    cursor: pointer;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transition: var(--transition);
}

.image-wrapper:hover {
    transform: translateY(-8px);
    box-shadow: 0 30px 80px rgba(255, 0, 0, 0.3);
}

.cover-image {
    width: 100%;
    height: auto;
    display: block;
    transition: var(--transition);
}

.image-wrapper:hover .cover-image {
    transform: scale(1.05);
    filter: brightness(0.8);
}

/* Play Button Overlay */
.play-button-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.3);
    opacity: 0;
    transition: var(--transition);
}

.image-wrapper:hover .play-button-overlay {
    opacity: 1;
}

.play-button {
    width: 70px;
    height: 70px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(255, 0, 0, 0.4);
    transition: var(--transition);
    transform: scale(0.8);
}

.play-button-overlay.active .play-button {
    transform: scale(1);
}

.play-button svg {
    width: 40px;
    height: 40px;
    color: white;
    margin-left: 4px;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 1000;
}

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

/* Modal Content */
.modal-content {
    position: relative;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    background: var(--background-secondary);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    animation: slideUp 0.4s ease-out;
    display: flex;
    flex-direction: column;
}

.modal.active .modal-content {
    animation: slideUp 0.4s ease-out;
}

/* Close Button */
.close-button {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
    background: rgba(255, 0, 0, 0.8);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    z-index: 10;
    hover: 0.2s;
}

.close-button:hover {
    background: var(--primary-color);
    transform: rotate(90deg) scale(1.1);
}

/* Video Wrapper */
.video-wrapper {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px;
}

/* Video Container */
.video-container {
    flex: 1;
    width: 100%;
    min-height: 400px;
    background: var(--background-dark);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
    position: relative;
}

#videoContainer > div {
    width: 100% !important;
    height: 100% !important;
}

#videoContainer iframe {
    width: 100% !important;
    height: 100% !important;
    border: none !important;
}

/* Player Controls */
.player-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--background-dark);
    border-radius: 8px;
    flex-wrap: wrap;
}

.control-btn {
    width: 36px;
    height: 36px;
    background: var(--background-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    padding: 0;
}

.control-btn:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: scale(1.1);
}

.control-btn:active {
    transform: scale(0.95);
}

.control-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

/* Separator */
.separator {
    width: 1px;
    height: 24px;
    background: var(--border-color);
}

/* Volume Control */
.volume-control {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 150px;
}

.volume-control svg {
    color: var(--text-secondary);
    flex-shrink: 0;
}

.volume-slider {
    flex: 1;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: var(--border-color);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.volume-slider::-webkit-slider-thumb:hover {
    transform: scale(1.3);
}

.volume-slider::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.volume-slider::-moz-range-thumb:hover {
    transform: scale(1.3);
}

#volumeValue {
    font-size: 0.85rem;
    color: var(--text-secondary);
    min-width: 40px;
    text-align: right;
}

/* Video Info */
.video-info {
    font-size: 0.85rem;
    color: var(--text-secondary);
    white-space: nowrap;
}

/* Animações */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsividade */
@media (max-width: 768px) {
    .container {
        padding: 16px;
    }

    .header h1 {
        font-size: 2rem;
    }

    .modal-content {
        width: 95%;
        max-height: 95vh;
    }

    .video-container {
        min-height: 580px;
    }

    .player-controls {
        gap: 8px;
        padding: 10px;
    }

    .control-btn {
        width: 32px;
        height: 32px;
    }

    .volume-control {
        min-width: 120px;
    }

    .separator {
        display: none;
    }
}

@media (max-width: 480px) {
    .header h1 {
        font-size: 1.5rem;
    }

    .header p {
        font-size: 0.9rem;
    }

    .modal-content {
        width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }

    .video-container {
        min-height: 580px;
        margin-bottom: 12px;
    }

    .player-controls {
        gap: 6px;
        padding: 8px;
    }

    .control-btn {
        width: 28px;
        height: 28px;
    }

    .control-btn svg {
        width: 16px;
        height: 16px;
    }

    .volume-control {
        min-width: 100px;
    }

    #volumeValue {
        min-width: 30px;
    }
}

/* Scroll Bar Personalizado */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}
