/**
 * Frontend Styles for Visual Section Builder
 * Responsive design with hover effects
 */

/* Container */
.vsb-sections-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin: 20px 0;
    font-family: 'Manrope', Helvetica, Arial, Lucida, sans-serif;
}

/* Individual Section */
.vsb-section {
    flex: 0 0 calc((100% - 60px) / 4);
    box-sizing: border-box;
    min-width: 250px;
    height: 440px;
    position: relative;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
/*
.vsb-section:hover {
    transform: translateY(-5px);
}
*/
/* Section Content */
.vsb-section-content {
    width: 100%;
    text-align: center;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    position: relative;
    z-index: 2;
}

/* Title - Always visible with background */
.vsb-section-title {
    margin: 0;
    color: #ffffff;
    background: rgba(27, 45, 56, 0.80);
    transition: all 0.3s ease;
    width: 100%;
    padding: 35px 15px;
    font-size: 28px;
    line-height: 32px;
    font-weight: 700;
    text-align: center;
}
/*
.vsb-section:hover .vsb-section-title {
    font-size: 1.8rem;
}
*/
/* Hover Content - Hidden by default */
.vsb-section-hover-content {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.4s ease;
    pointer-events: none;
    background: rgba(27, 45, 56, 0.80);
    margin-top: auto;
    padding: 30px 20px;
    width: 100%;
    height: 100%;
}

.vsb-section:hover .vsb-section-hover-content {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* Description */
.vsb-section-description {
    font-size: 1rem;
    line-height: 1.5;
    margin: 0 0 20px 0;
    color: #ffffff;
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
}

/* Button */
.vsb-section-button {
    display: inline-block;
    color: #ffffff;
    text-decoration: none;
    transition: all 0.3s ease;
    padding: 10px 22px;
    border-radius: 100px;
    background: #CDA773 !important;
    text-align: center;
    font-family: Manrope;
    font-size: 14px;
    font-style: normal;
    font-weight: 700;
    line-height: 160%;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.vsb-section-button:hover {
    background-color: #005a87;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    color: #ffffff;
    text-decoration: none;
}

/* No sections message */
.vsb-no-sections {
    text-align: center;
    padding: 40px 20px;
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 5px;
    color: #666;
    font-style: italic;
}

@media (max-width: 1200px) {
    .vsb-section {
        flex: 0 0 calc((100% - 40px) / 3);
        box-sizing: border-box;

    }
}

@media (max-width: 991px) {
    .vsb-section {
        flex: 0 0 calc((100% - 20px) / 2);
        box-sizing: border-box;

    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .vsb-sections-container {
        flex-direction: column;
        gap: 20px;
    }
    
    .vsb-section {
        flex: 0 0 calc((100% - 20px) / 2);
        box-sizing: border-box;
        height: 300px;
    }
    
    .vsb-section-title {
        font-size: 1.3rem;
        padding-top: 24px;
        padding-bottom: 24px;
    }
    /*
    .vsb-section:hover .vsb-section-title {
        font-size: 1.5rem;
    }*/
    
    .vsb-section-description {
        font-size: 0.9rem;
    }
    
    .vsb-section-hover-content {
        padding: 20px 15px;
    }
}

@media (max-width: 480px) {
    .vsb-section {
        flex: 1;
        height: 300px;
    }
    
    .vsb-section-title {
        font-size: 1.2rem;
        padding-top: 20px;
        padding-bottom: 20px;
    }

    /*
    .vsb-section:hover .vsb-section-title {
        font-size: 1.4rem;
    }*/
    
    .vsb-section-button {
        padding: 10px 20px;
        font-size: 0.8rem;
    }
    
    .vsb-section-hover-content {
        padding: 15px 12px;
    }
}

/* Accessibility */
.vsb-section:focus {
    outline: 2px solid #007cba;
    outline-offset: 2px;
}

.vsb-section-button:focus {
    outline: 2px solid #ffffff;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .vsb-section-overlay {
        background: rgba(0, 0, 0, 0.8);
    }
    
    .vsb-section:hover .vsb-section-overlay {
        background: rgba(0, 0, 0, 0.9);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .vsb-section,
    .vsb-section-overlay,
    .vsb-section-title,
    .vsb-section-hover-content,
    .vsb-section-button {
        transition: none;
    }
    
    .vsb-section:hover {
        transform: none;
    }
    
    .vsb-section-button:hover {
        transform: none;
    }
}