/* Grade 6 Science Page Styling */

.video-library-container {
    padding: 8rem 5% 4rem;
    max-width: 1400px;
    margin: 0 auto;
}

.library-hero {
    text-align: center;
    margin-bottom: 4rem;
}

.library-hero h1 {
    font-size: clamp(2.5rem, 8vw, 4rem);
    font-family: var(--font-display);
    font-weight: 900;
    margin-bottom: 1rem;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

.video-card {
    background: var(--liquid-bg);
    border: 1px solid var(--liquid-border);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    position: relative;
    backdrop-filter: blur(var(--liquid-blur));
}

.video-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--accent-emerald);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.video-thumbnail {
    width: 100%;
    aspect-ratio: 16/9;
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-thumbnail::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, rgba(1, 2, 4, 0.8), transparent);
}

.play-icon {
    width: 60px;
    height: 60px;
    background: var(--accent-emerald);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: transform 0.3s ease;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
}

.video-card:hover .play-icon {
    transform: scale(1.2);
}

.video-info {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.video-info h3 {
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    color: white;
}

.video-meta {
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

@media (max-width: 768px) {
    .video-grid {
        grid-template-columns: 1fr;
    }
}

/* Selection Hub Styling */
.selection-container {
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 8rem 5% 4rem;
    z-index: 10;
    position: relative;
}

.selection-header {
    text-align: center;
    margin-bottom: 4rem;
}

.selection-header h1 {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 8vw, 4rem);
    margin-bottom: 1rem;
    font-weight: 900;
}

.selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    width: 100%;
    max-width: 1200px;
}

.subject-card {
    background: var(--liquid-bg);
    backdrop-filter: blur(var(--liquid-blur)) saturate(180%);
    -webkit-backdrop-filter: blur(var(--liquid-blur)) saturate(180%);
    border: 1px solid var(--liquid-border);
    border-radius: 32px;
    padding: 3rem 2rem;
    text-align: center;
    text-decoration: none;
    color: white;
    transition: all 0.4s cubic-bezier(0.19, 1, 0.22, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
}

.subject-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.45);
}

.subject-icon {
    width: 70px;
    height: 70px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
    transition: transform 0.3s ease;
}

.subject-card:hover .subject-icon {
    transform: scale(1.1) rotate(5deg);
}

.subject-card h2 {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.subject-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
}

.science-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(16, 185, 129, 0.15), transparent);
    pointer-events: none;
}

.maths-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(59, 130, 246, 0.15), transparent);
    pointer-events: none;
}

.back-link {
    margin-top: 4rem;
    color: var(--text-secondary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    transition: color 0.2s;
}

.back-link:hover {
    color: white;
}
