/* ========================================
   Naamalu Background Decoration
   Scattered watermark image effect
======================================== */

.naamalu-bg {
    position: relative;
    overflow: hidden;
    background-color: #f8f9fb;
}

/* Create watermark using image */
.naamalu-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    background-image: url('/storage/namalu-imgs/naamalu-three.png');
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover; /* Changed to cover for mobile */
    opacity: 0.8;
}

/* Mobile-specific fix for watermark */
@media (max-width: 768px) {
    .naamalu-bg::before {
        /* background-size: 100% 100% !important; */
        object-fit: cover !important;
        opacity: 0.6 !important;
    }
}

/* Ensure content stays above watermark */
.naamalu-bg > * {
    position: relative;
    z-index: 1;
}

/* Fix for sections that use py-1 class with naamalu-bg */
.py-1.naamalu-bg {
    position: relative;
    background-color: #f8f9fb !important;
    background-image: none !important;
}

.py-1.naamalu-bg > * {
    position: relative;
    z-index: 1;
}

/* Mobile-specific fix for py-1 sections */
@media (max-width: 768px) {
    .py-1.naamalu-bg::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-image: url('/storage/namalu-imgs/naamalu-three.png');
        background-repeat: no-repeat;
        background-position: center center;
        /* background-size: 100% 100%; */
        opacity: 0.5;
        z-index: 0;
        pointer-events: none;
    }
}

/* ========================================
   Stats Section Specific Styles
======================================== */

.stats-section {
    position: relative;
    overflow: hidden;
}

.stats-container {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
}

/* Responsive Grid */
@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 992px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
}

/* Card Design */
.stat-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 1.75rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--accent-color, #012169);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.stat-card:hover::before {
    transform: scaleX(1);
}

/* Icon Design */
.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #ffffff;
    flex-shrink: 0;
}

.stat-icon i {
    font-size: 1.4rem;
}

/* Icon Colors */
.stat-icon.green { background: linear-gradient(135deg, #2ecc71, #27ae60); --accent-color: #2ecc71; }
.stat-icon.blue { background: linear-gradient(135deg, #3498db, #2980b9); --accent-color: #3498db; }
.stat-icon.red { background: linear-gradient(135deg, #e74c3c, #c0392b); --accent-color: #e74c3c; }
.stat-icon.purple { background: linear-gradient(135deg, #6c5ce7, #5b4cdb); --accent-color: #6c5ce7; }
.stat-icon.indigo { background: linear-gradient(135deg, #4b6cb7, #3a5a9a); --accent-color: #4b6cb7; }
.stat-icon.orange { background: linear-gradient(135deg, #f39c12, #d68910); --accent-color: #f39c12; }
.stat-icon.navy { background: linear-gradient(135deg, #012169, #0a3b7d); --accent-color: #012169; }
.stat-icon.teal { background: linear-gradient(135deg, #1abc9c, #16a085); --accent-color: #1abc9c; }
.stat-icon.dark-orange { background: linear-gradient(135deg, #e67e22, #d35400); --accent-color: #e67e22; }

/* Text Information */
.stat-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.2;
}

.stat-label {
    font-size: 0.9rem;
    color: #6b7280;
    font-weight: 500;
    line-height: 1.4;
}

/* Counter Animation */
@keyframes countUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.stat-value {
    animation: countUp 0.5s ease-out;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    .stat-card {
        padding: 1.5rem 1.25rem;
    }
    
    .stat-icon {
        width: 48px;
        height: 48px;
    }
    
    .stat-icon i {
        font-size: 1.2rem;
    }
    
    .stat-value {
        font-size: 1.75rem;
    }
}

@media (max-width: 576px) {
    .stat-card {
        padding: 1.25rem 1rem;
    }
    
    .stat-icon {
        width: 44px;
        height: 44px;
    }
    
    .stat-icon i {
        font-size: 1.1rem;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .stat-label {
        font-size: 0.85rem;
    }
}
