:root {
    --primary: #f97316;
    --primary-hover: #ea580c;
    --background: #1a1a1a;
    --card-bg: #262626;
    --text-primary: #ffffff;
    --text-secondary: #a3a3a3;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background-color: var(--background);
    color: var(--text-primary);
}

.video-section {
    min-height: 100vh;
    padding: 4rem 1rem;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
}

/* Header */
.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    letter-spacing: -0.025em;
}

.section-header p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 42rem;
    margin: 0 auto;
}

.accent-line {
    width: 6rem;
    height: 4px;
    background: var(--primary);
    border-radius: 9999px;
    margin: 1.5rem auto 0;
}

/* Video Grid */
.video-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .video-grid {
    grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .video-grid {
    grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1280px) {
    .video-grid {
    grid-template-columns: repeat(4, 1fr);
    }
}

/* Video Card */
.video-card {
    position: relative;
    overflow: hidden;
    border-radius: 0.75rem;
    background: var(--card-bg);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.video-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4);
}

.thumbnail-container {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.thumbnail-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.video-card:hover .thumbnail-container img {
    transform: scale(1.1);
}

.gradient-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.2), transparent);
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.video-card:hover .gradient-overlay {
    opacity: 0.8;
}

/* Play Button */
.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 4rem;
    height: 4rem;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 15px -3px rgba(249, 115, 22, 0.3);
    transition: all 0.3s ease;
}

.video-card:hover .play-button {
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 20px 25px -5px rgba(249, 115, 22, 0.5);
}

.play-button svg {
    width: 1.75rem;
    height: 1.75rem;
    fill: white;
    margin-left: 3px;
}

/* Video Badge */
.video-badge {
    position: absolute;
    bottom: 0.75rem;
    right: 0.75rem;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    font-weight: 500;
}

/* Card Title */
.card-title {
    padding: 1rem;
}

.card-title h3 {
    font-size: 1.3rem;
    font-weight: 600;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.3s ease;
}

.video-card:hover .card-title h3 {
    color: var(--primary);
}

/* Accent Border */
.accent-border {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 0;
    background: var(--primary);
    transition: width 0.3s ease;
}

.video-card:hover .accent-border {
    width: 100%;
}

/* Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 1rem;
}

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

/* Blurred thumbnail background */
.modal-backdrop {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: blur(30px);
    transform: scale(1.2);
    opacity: 0.2;
}

.modal-backdrop::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
}

.modal-content {
    position: relative;
    width: 100%;
    max-width: 900px;
    background: black;
    border-radius: 0.75rem;
    overflow: hidden;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-content.is-short {
    max-width: 400px;
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
}

.modal-content.is-short .video-wrapper {
    padding-bottom: 177.78%; /* 9:16 */
}

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

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.6);
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem 0.75rem;
    line-height: 1;
    opacity: 0.8;
    transition: all 0.2s ease;
    border-radius: 50%;
    z-index: 10;
}

.modal-close:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.8);
}

@media (min-width: 768px) {
    .section-header h1 {
    font-size: 3rem;
    }
}
