/* …existing code… */

/* AI‑Masterclass landing‑page styles */
.masterclass-hero {
    padding: 4rem 1.5rem;
    text-align: center;
    background-color: black;
}

.masterclass-hero .description {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: #b9d0ff;
    font-weight: 700;
}

.highlight-text {
    color: #fbbf24;
    text-decoration: underline;
    text-decoration-color: #fbbf24;
}

.masterclass-hero .workshop-image img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    box-shadow: var(--shadow-md);
    margin-bottom: 1.5rem;
}

.date-time {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    font-size: 1.125rem;
    color: white;
}

.date-time .date-info,
.date-time .time-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.icon-date,
.icon-clock {
    width: 24px;
    height: 24px;
    fill: var(--primary-color);
}

.masterclass-cta {
    display: inline-block;
    padding: 1rem 2.5rem;
    font-size: 1.125rem;
    font-weight: 700;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: var(--transition);
    animation: glow 2s ease-in-out 2s infinite,
               shake 0.6s ease-in-out 4s infinite;
    text-align: center;
    line-height: 1.2;
}

.cta-main {
    display: block;
    font-weight: 700;
    font-size: 1.125rem;
}

.cta-sub {
    display: block;
    font-size: 0.875rem;
    font-weight: 400;
    opacity: 0.9;
    margin-top: 0.25rem;
}

.cta-note {
    font-size: 0.875rem;
    color: #b9d0ff;
    text-align: center;
    margin-top: 1rem;
    opacity: 0.8;
}

@keyframes glow {
    0%, 100% { box-shadow: 0 0 8px var(--primary-color); }
    50%      { box-shadow: 0 0 20px var(--primary-color); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25%      { transform: translateX(-3px); }
    75%      { transform: translateX(3px); }
}

.audience-section {
    padding: 4rem 1.5rem;
    text-align: center;
    background-color: var(--white);
}

.audience-section h2 {
    font-size: 1.75rem;
    color: var(--text-dark);
}

.audience-section h3 {
    margin-bottom: 1.5rem;
    color: var(--text-dark);
}

/* Mobile-first responsive grid */
.audience-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.75rem;
    max-width: 100%;
    overflow-x: auto;
    padding: 0 0.5rem;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.audience-grid::-webkit-scrollbar {
    display: none; /* Chrome, Safari, and Opera */
}

.audience-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem;
    background-color: var(--bg-light);
    border-radius: 0.5rem;
    font-weight: 500;
    color: var(--text-dark);
    transition: var(--transition);
    white-space: nowrap;
    min-width: 0;
    flex-shrink: 0;
}

.check-icon {
    width: 20px;
    height: 20px;
    fill: var(--primary-color);
    margin-right: 0.5rem;
    flex-shrink: 0;
}

.audience-item:hover,
.audience-item:focus {
    background-color: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
}

.audience-item:hover .check-icon,
.audience-item:focus .check-icon {
    fill: var(--white);
}

/* What You Will Learn Section */
.learn-section {
    padding: 4rem 1.5rem;
    text-align: center;
    background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
}

.learn-section h2 {
    font-size: 2rem;
    margin-bottom: 3rem;
    color: var(--text-dark);
    font-weight: 700;
}

.learn-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    max-width: 900px;
    margin: 0 auto;
}

.learn-item {
    /* default mobile behaviour: stack icon above text to prevent overflow */
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 1.25rem 1.5rem;
    background-color: var(--white);
    border-radius: 0.75rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    text-align: center;
}

.learn-icon {
    width: 24px;
    height: 24px;
    fill: var(--primary-color);
    flex-shrink: 0;
}

.learn-item span {
    font-size: 1.0625rem;
    color: var(--text-dark);
    font-weight: 500;
}

.learn-item:hover {
    box-shadow: var(--shadow-md);
    transform: translateX(4px);
}

@media (min-width: 768px) {
    .learn-section {
        padding: 5rem 2rem;
    }
    
    .learn-section h2 {
        font-size: 2.25rem;
        margin-bottom: 3.5rem;
    }
    
    .learn-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }

    /* on tablet and up show icon and text side‑by‑side */
    .learn-item {
        flex-direction: row;
        text-align: left;
        gap: 1rem;
    }
}

@media (min-width: 1024px) {
    .learn-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
    
    .learn-item {
        flex-direction: column;
        text-align: center;
        padding: 1.75rem;
    }
    
    .learn-item span {
        font-size: 1rem;
    }
}

.carousel-track {
    display: flex;
    transition: transform 0.5s ease;
    gap: 1.5rem;
    /* Ensure proper width calculation */
    width: 100%;
}

.carousel-slide {
    min-width: 100%;
    flex-shrink: 0;
    /* Ensure slides don't overflow */
    max-width: 100%;
    overflow: hidden;
}

.carousel-container {
    position: relative;
    overflow: hidden;
    border-radius: 0.5rem;
    /* Ensure container properly clips content */
    width: 100%;
}

@media (min-width: 768px) {
    .audience-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    /* ...existing code... */
    
    .carousel-slide {
        min-width: calc(50% - 0.75rem);
        max-width: calc(50% - 0.75rem);
    }
    
    /* ...existing code... */
}

@media (min-width: 1024px) {
    .audience-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
    
    /* ...existing code... */
    
        .contact-row select {
            width: 90px;
            min-width: 70px;
            font-size: 0.95rem;
        }
        .contact-row input[type="tel"] {
            font-size: 1rem;
        }
    .carousel-slide {
        min-width: calc(33.333% - 1rem);
        max-width: calc(33.333% - 1rem);
    }
    
    /* Shorts carousel - show 3 on desktop since they're narrower */
    .shorts-carousel-wrapper .carousel-slide {
        min-width: calc(33.333% - 0.5rem);
        max-width: calc(33.333% - 0.5rem);
    }
    
    /* ...existing code... */
}

@media (min-width: 1280px) {
    /* Shorts carousel - show 4 on large screens */
    .shorts-carousel-wrapper .carousel-slide {
        min-width: calc(25% - 0.45rem);
        max-width: calc(25% - 0.45rem);
    }
}

/* Modal Styles */
.modal-overlay {
    display: none;
    position: fixed;
    z-index: 9999;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(16, 24, 40, 0.65);
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s;
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-dialog {
    background: #111827;
    color: #b9d0ff;
    border-radius: 1rem;
    box-shadow: 0 8px 32px rgba(37,99,235,0.15);
    padding: 1.5rem 1.5rem 1.5rem;
    max-width: 420px;
    width: 90vw;
    position: relative;
    animation: fadeUp 0.4s;
}

.modal-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #fbbf24;
    text-align: center;
    padding-top: 0.25rem;
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    color: #b9d0ff;
    font-size: 2rem;
    cursor: pointer;
    transition: color 0.2s;
}

.modal-close:hover,
.modal-close:focus {
    color: #fbbf24;
}

.modal-form .form-group {
    margin-bottom: 0.75rem;
    display: flex;
    flex-direction: column;
}

.recaptcha-container {
    display: flex;
    justify-content: center;
    margin: 0.5rem 0 0.75rem;
}

.modal-form label {
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 0.125rem;
    color: #b9d0ff;
}

.required {
    color: #fbbf24;
    font-weight: 700;
}

.modal-form input,
.modal-form select {
    padding: 0.625rem;
    border-radius: 0.5rem;
    border: 1px solid #2563eb;
    background: #1e293b;
    color: #b9d0ff;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.modal-form input:focus,
.modal-form select:focus {
    border-color: #fbbf24;
    outline: none;
}

.contact-row {
    display: flex;
    gap: 0.5rem;
}

.contact-row select {
    width: 140px;
    min-width: 120px;
    flex-shrink: 0;
    font-size: 1rem;
}

.contact-row input[type="tel"] {
    flex: 1;
}

.modal-register-btn {
    width: 100%;
    padding: 0.875rem;
    font-size: 1.125rem;
    font-weight: 700;
    background: linear-gradient(90deg, #2563eb 60%, #fbbf24 100%);
    color: #fff;
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    margin-top: 0.5rem;
    box-shadow: 0 2px 8px rgba(37,99,235,0.15);
    transition: background 0.2s, transform 0.2s;
    animation: glow 2s ease-in-out 2s infinite;
}

.modal-register-btn:hover,
.modal-register-btn:focus {
    background: linear-gradient(90deg, #fbbf24 0%, #2563eb 100%);
    transform: translateY(-2px);
}

.modal-message {
    margin-top: 0.5rem;
    font-size: 1rem;
    text-align: center;
    min-height: 1.5em;
}

.modal-message.success {
    color: #10b981;
}

.modal-message.error {
    color: #ef4444;
}

/* Responsive */
@media (max-width: 480px) {
    .modal-dialog {
        padding: 1.25rem 0.5rem 1rem;
        max-width: 98vw;
    }
    .modal-title {
        font-size: 1.1rem;
        margin-top: 2.2rem;
    }
    .modal-close {
        top: 0.3rem;
        right: 0.3rem;
        font-size: 1.7rem;
        z-index: 2;
    }
    .modal-dialog {
        padding: 1rem 1rem 1rem;
        width: 95vw;
    }
    
    .modal-title {
        font-size: 1.1rem;
        margin-bottom: 0.25rem;
    }
    
    .modal-form .form-group {
        margin-bottom: 0.5rem;
    }
    
    .modal-form label {
        margin-bottom: 0.0625rem;
        font-size: 0.95rem;
    }
    
    .recaptcha-container {
        margin: 0.25rem 0 0.5rem;
    }
    
    .modal-message {
        margin-top: 0.25rem;
        font-size: 0.9rem;
    }
    
    .contact-row select {
        width: 100px;
        min-width: 90px;
        font-size: 0.9rem;
    }
    .contact-row input[type="tel"] {
        font-size: 0.95rem;
        flex: 1;
        min-width: 0;
    }
}