/* Kids Programs Styles */

/* Program Cards and Product Cards */
.program-card,
.product-card {
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.program-card:hover,
.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.program-card .card-img-top,
.product-card .card-img-top {
    height: auto !important;
    width: 100% !important;
    object-fit: contain !important;
    transition: all 0.5s ease;
}

.program-card:hover .card-img-top,
.product-card:hover .card-img-top {
    transform: scale(1.05);
}

.product-price {
    font-weight: 600;
    margin-top: 10px;
}

.program-age-badge,
.product-age-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: rgba(13, 110, 253, 0.9);
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.product-category-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: rgba(25, 135, 84, 0.9);
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}


/* Align buttons to bottom - Program Cards Only */
.program-card .card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.program-card .card-body>div:last-child {
    margin-top: auto !important;
    width: 100%;
}

/* Feature Boxes - Scoped to Kids Page Only */
.kids-features .feature-box {
    padding: 30px;
    border-radius: 5px;
    background-color: #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    height: 100%;
}

.kids-features .feature-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.kids-features .feature-icon {
    font-size: 3rem;
    margin-bottom: 25px;
    color: #0d6efd;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    margin: 0 auto 25px auto !important;
}

.kids-features .feature-box .feature-icon {
    width: 80px !important;
    height: 80px !important;
    border-radius: 50% !important;
    text-align: center !important;
}

.kids-features .feature-box h4 {
    text-align: center !important;
    width: 100%;
}

/* Base rule */
.feature-box p {
    text-align: justify !important;
    text-align-last: left !important;
    margin-bottom: 0;
}

/* Specific override to ensure justification applies */
.section-padding .feature-box p {
    text-align: justify !important;
    text-align-last: left !important;
}

/* Kids Intro Justification */
.kids-intro-content p {
    text-align: justify !important;
    text-align-last: left !important;
}

/* Gallery */
.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    grid-gap: 15px;
    margin-bottom: 30px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.gallery-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.7);
    overflow: hidden;
    width: 100%;
    height: 0;
    transition: .5s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-item:hover .gallery-overlay {
    height: 100%;
}

.gallery-info {
    color: white;
    text-align: center;
    padding: 15px;
}

.gallery-info h5 {
    margin-bottom: 5px;
}

.gallery-info p {
    margin-bottom: 0;
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Registration Form */
.registration-form .card {
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 25px;
    overflow: hidden;
}

.registration-form .card-header {
    border-bottom: none;
    padding: 15px 20px;
}

.registration-form .card-body {
    padding: 25px;
}

.registration-form label {
    font-weight: 500;
}

.registration-form .form-control {
    padding: 12px;
    border-radius: 5px;
}

.registration-form textarea.form-control {
    min-height: 100px;
}

/* Testimonials */
.testimonial-card {
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Responsive Adjustments */
@media (max-width: 767.98px) {
    .program-card .card-img-top {
        height: auto !important;
    }

    .feature-icon {
        font-size: 2.5rem;
    }

    .gallery-container {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .gallery-item img {
        height: 150px;
    }

    /* Fix buttons in intro section for mobile */
    .kids-intro-content .d-flex {
        flex-direction: column !important;
        gap: 0.75rem !important;
    }

    .kids-intro-content .btn {
        width: 100% !important;
        white-space: normal !important;
        font-size: 0.9rem !important;
        padding: 0.5rem 1.5rem !important;
    }
}

/* Tablet adjustments */
@media (min-width: 768px) and (max-width: 991.98px) {
    .kids-intro-content .d-flex {
        flex-wrap: wrap !important;
    }

    .kids-intro-content .btn {
        white-space: normal !important;
        font-size: 0.95rem !important;
        padding: 0.5rem 1.75rem !important;
        flex: 1 1 auto;
        min-width: 0;
    }
}