/**
 * About Page - Values Section
 * Pixel-perfect implementation of Figma design
 *
 * @package Sanjeevani
 */

.about-values {
    position: relative;
    padding: 100px 0;
    background: #ffffff;
    overflow: hidden;
}

/* Background decorative blurs */
.about-values__bg-blur {
    position: absolute;
    border-radius: 144px;
    filter: blur(250px);
    pointer-events: none;
}

.about-values__bg-blur--left {
    background: #00f0c1;
    width: 160px;
    height: 302px;
    top: 50%;
    left: -41px;
    transform: translateY(-50%);
}

.about-values__bg-blur--center {
    background: #00f0c1;
    width: 126px;
    height: 239px;
    top: 60%;
    left: 50%;
    transform: translate(-50%, -50%);
    filter: blur(200px);
}

.about-values__bg-blur--right {
    background: #3574cf;
    width: 100px;
    height: 189px;
    top: 40%;
    right: -50px;
    filter: blur(200px);
}

/* Decorative graphics */
.about-values__decor {
    position: absolute;
    pointer-events: none;
}

.about-values__decor--left {
    left: -10px;
    top: 42%;
    transform: translateY(-50%) rotate(180deg);
    width: 167px;
    height: 163.5px;
}

.about-values__decor--right {
    right: -10px;
    bottom: -40px;
    width: 167px;
    height: 163.5px;
}

.about-values__container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

/* Section Header */
.about-values__header {
    text-align: center;
    margin-bottom: 20px;
}

.about-values__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 173, 139, 0.1);
    border-radius: 9999px;
    padding: 8px 24px;
    margin-bottom: 24px;
}

.about-values__badge-text {
    font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 20px;
    color: #00b894;
}

/* Title Container with Ellipse */
.about-values__title-container {
    position: relative;
    margin-bottom: 24px;
}

.about-values__title {
    font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 700;
    font-size: 60px;
    line-height: 70px;
    color: #020817;
    margin: 0;
}

.about-values__title-highlight {
    color: #00b893;
    position: relative;
    padding-left: 5px;
    padding-right: 5px;
    z-index: 0; /* establish stacking context for pseudo element */
}

/* Ellipse behind the word "Values" */
.about-values__title-highlight::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 52%;
    transform: translate(-50%, -50%);
    width: 220px;
    height: 80px;
    background: url('../../images/about/values-ellipse.png') no-repeat center / contain;
    pointer-events: none;
    z-index: -1; /* behind the text, above section background */
}

.about-values__description {
    font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 500;
    font-size: 18px;
    line-height: 28px;
    color: rgba(0, 0, 0, 0.7);
    max-width: 653px;
    margin: 0 auto;
}

/* Values Grid */
.about-values__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-gap: 40px 33px;
    margin-top: 60px;
}

/* Value Cards */
.about-values__card {
    background: #ffffff;
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0px 1px 16px 0px rgba(0, 0, 0, 0.08);
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-values__card:hover {
    transform: translateY(-4px);
    box-shadow: 0px 8px 32px 0px rgba(0, 0, 0, 0.12);
}

.about-values__card-icon {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    position: relative;
}

.about-values__card-icon img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

/* Individual card icon backgrounds */
.about-values__card--compassion .about-values__card-icon {
    background: #e9f2ff;
}

.about-values__card--innovation .about-values__card-icon {
    background: #d4f9e1;
}

.about-values__card--integrity .about-values__card-icon {
    background: #ddd4f9;
}

.about-values__card--collaboration .about-values__card-icon {
    background: #d4f9ec;
}

.about-values__card--sustainability .about-values__card-icon {
    background: #f9ded4;
}

.about-values__card--excellence .about-values__card-icon {
    background: #f9ead4;
}

.about-values__card-title {
    font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 500;
    font-size: 20px;
    line-height: 28px;
    color: #020817;
    margin: 0 0 12px 0;
}

.about-values__card-description {
    font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 500;
    font-size: 16px;
    line-height: 22.8px;
    color: #64748b;
    margin: 0;
}

/* Responsive Design */
@media screen and (max-width: 1200px) {
    .about-values__decor--left {
        left: 120px;
    }
    
    .about-values__decor--right {
        right: 120px;
    }
    
    .about-values__grid {
        grid-gap: 32px 24px;
    }
}

@media screen and (max-width: 1024px) {
    .about-values {
        padding: 80px 0;
    }
    
    .about-values__header {
        margin-bottom: 60px;
    }
    
    .about-values__title {
        font-size: 48px;
        line-height: 56px;
    }
    .about-values__title-highlight::after {
        width: 190px;
        height: 64px;
    }
    
    .about-values__description {
        font-size: 16px;
        line-height: 24px;
    }
    
    .about-values__decor {
        display: none;
    }
    /* Hide blurred background blobs on tablets and below */
    .about-values__bg-blur {
        display: none !important;
    }
}

@media screen and (max-width: 768px) {
    .about-values {
        overflow-x: hidden;
    }
    .about-values__grid {
        grid-template-columns: repeat(2, 1fr);
        grid-gap: 24px;
        margin-top: 20px; /* reduced top margin on mobile */
    }
    
    .about-values__title {
        font-size: 36px;
        line-height: 44px;
    }
    
    .about-values__container {
        padding: 0 20px;
    }
    .about-values__title-container {
        overflow: hidden; /* prevent highlight ellipse from causing horizontal scroll */
    }
    /* Also hide the title ellipse on tablets to avoid overflow */
    .about-values__title-highlight::after { display: none !important; content: none !important; }
}

@media screen and (max-width: 600px) {
    .about-values {
        padding: 60px 0;
    }
    
    .about-values__grid {
        grid-template-columns: 1fr;
        grid-gap: 20px;
    }
    
    .about-values__header {
        margin-bottom: 40px;
    }
    
    .about-values__title {
        font-size: 32px;
        line-height: 40px;
    }
    .about-values__title-highlight::after {
        width: 160px;
        height: 54px;
    }
    
    .about-values__description {
        font-size: 15px;
        line-height: 22px;
    }
    
    .about-values__card {
        padding: 20px;
    }
}

@media screen and (max-width: 480px) {
    .about-values {
        padding: 40px 0;
    }
    .about-values__header { margin-bottom: 24px; }
    .about-values__grid { grid-gap: 16px; }
    /* Remove highlight ellipse for readability on small phones */
    .about-values__title-highlight::after { display: none !important; content: none !important; }
}

/* Animation for cards */
.about-values__card {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.6s ease-out forwards;
}

.about-values__card:nth-child(1) { animation-delay: 0.1s; }
.about-values__card:nth-child(2) { animation-delay: 0.2s; }
.about-values__card:nth-child(3) { animation-delay: 0.3s; }
.about-values__card:nth-child(4) { animation-delay: 0.4s; }
.about-values__card:nth-child(5) { animation-delay: 0.5s; }
.about-values__card:nth-child(6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    .about-values__card {
        animation: none;
        opacity: 1;
        transform: none;
    }
    
    .about-values__card:hover {
        transform: none;
    }
}

/* Focus states for accessibility */
.about-values__card:focus-within {
    outline: 2px solid #00b893;
    outline-offset: 2px;
}

/* High DPI displays */
@media screen and (-webkit-min-device-pixel-ratio: 2), 
       screen and (min-resolution: 192dpi) {
    .about-values__card-icon img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}