/* ============================================================
   AI Extraction Section Block — Universal Styles
   Layouts: enterprise_stats, features_grid, timeline_steps,
            comparison, content_with_image
   ============================================================ */

/* ─── CSS Custom Properties ─────────────────────────────── */
:root {
    --aes-navy:       #0f2b46;
    --aes-navy-light: #1e3a5f;
    --aes-orange:     #ea580c;
    --aes-orange-hover:#c2410c;
    --aes-blue-accent: #2563eb;
    --aes-gray-bg:    #f8fafc;
    --aes-gray-100:   #f1f5f9;
    --aes-gray-200:   #e2e8f0;
    --aes-gray-500:   #64748b;
    --aes-gray-700:   #334155;
    --aes-white:      #ffffff;
    --aes-green:      #16a34a;
    --aes-red:        #dc2626;
    --aes-radius:     12px;
    --aes-radius-sm:  8px;
    --aes-shadow:     0 4px 24px rgba(0,0,0,.06);
    --aes-shadow-lg:  0 8px 32px rgba(0,0,0,.10);
    --aes-transition: .25s ease;
    --aes-max-width:  1200px;
}


/* ═══════════════════════════════════════════════════════════
   1. SECTION BASE
   ═══════════════════════════════════════════════════════════ */
.aes-section {
    padding: 60px 0;
    position: relative;
    overflow: hidden;
}

.aes-container {
    max-width: var(--aes-max-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* ─── White Text for Dark Backgrounds ────────────────────── */
.aes-section.aes-white-text .aes-heading {
    color: rgba(255, 255, 255, 0.9);
}

.aes-section.aes-white-text .aes-title {
    color: var(--aes-white);
}

.aes-section.aes-white-text .aes-description {
    color: rgba(255, 255, 255);
}

.aes-section.aes-white-text .aes-stat-title,
.aes-section.aes-white-text .aes-feature-title {
    color: var(--aes-white);
}

.aes-section.aes-white-text .aes-stat-desc,
.aes-section.aes-white-text .aes-feature-desc,
.aes-section.aes-white-text .aes-cwi-point {
    color: rgba(255, 255, 255);
}

.aes-section.aes-white-text .aes-timeline-caption {
    color: rgba(255, 255, 255);
}


/* ═══════════════════════════════════════════════════════════
   2. SECTION HEADER
   ═══════════════════════════════════════════════════════════ */
.aes-header {
    margin-bottom: 40px;
}

.aes-text-center {
    text-align: center;
}

.aes-text-center .aes-header {
    max-width: 780px;
    margin-left: auto;
    margin-right: auto;
}

.aes-text-left {
    text-align: left;
}

.aes-heading {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--aes-orange);
    margin-bottom: 10px;
}

.aes-title {
    font-family: var(--heading-font);
    font-size: 36px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--aes-navy);
    margin: 0 0 40px;
    position: relative;
}

.aes-title::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 35px;
    height: 6px;
    background: var(--secondary-clr, #f59e0b);
    border-radius: 6px;
}

.aes-title span {
    color: var(--aes-orange);
}

.aes-description {
    font-size: 20px;
    line-height: 1.65;
    color: #333333;
    margin: 0;
}

.aes-text-center .aes-description {
    margin-left: auto;
    margin-right: auto;
}


/* ═══════════════════════════════════════════════════════════
   3. ENTERPRISE STATS LAYOUT
   ═══════════════════════════════════════════════════════════ */
.aes-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.aes-stat-card {
    background: var(--aes-white);
    border: 1px solid var(--aes-gray-200);
    border-radius: var(--aes-radius);
    padding: 20px;
    text-align: center;
    transition: box-shadow var(--aes-transition), transform var(--aes-transition);
    color: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .2);
    border: 1px solid rgb(255 255 255 / 0.1);
}

.aes-stat-number {
    font-size: 32px;
    font-weight: 500;
    color: var(--aes-orange);
    line-height: 1;
    margin-bottom: 15px;
}

.aes-stat-suffix {
    font-size: 28px;
    font-weight: 700;
}

.aes-stat-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--aes-navy);
    margin: 0;
    line-height: 1.4;
}

.aes-stat-desc {
    font-size: 13px;
    color: var(--aes-gray-500);
    margin: 0;
    line-height: 1.5;
}


/* ═══════════════════════════════════════════════════════════
   4. FEATURES GRID LAYOUT
   ═══════════════════════════════════════════════════════════ */
.aes-features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.aes-feature-card {
    text-align: center;
    padding: 36px 24px 0;
    border-radius: var(--aes-radius);
    transition: box-shadow var(--aes-transition), transform var(--aes-transition);
}

.aes-feature-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #fde7e0;
    color: #f15b2a;
    font-size: 24px;
}

.aes-feature-icon img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.aes-feature-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--aes-navy);
    margin: 0 0 8px;
}

.aes-feature-desc {
    font-size: 16px;
    color: #1c1a1a;
    margin: 0;
    line-height: 1.6;
}

/* ═══════════════════════════════════════════════════════════
   5. TIMELINE STEPS LAYOUT
   ═══════════════════════════════════════════════════════════ */
.aes-timeline {
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.aes-timeline-track {
    position: absolute;
    top: 28px;
    left: 10%;
    right: 10%;
    height: 3px;
    background: var(--aes-gray-200);
    z-index: 0;
}

.aes-timeline-track::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, var(--aes-orange), var(--aes-blue-accent));
    border-radius: 2px;
}

.aes-timeline-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    width: 100%;
    position: relative;
    z-index: 1;
    max-width: 890px;
}

.aes-timeline-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.aes-timeline-dot {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--aes-navy);
    color: var(--aes-white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 20px;
    border: 4px solid var(--aes-white);
    box-shadow: 0 2px 12px rgba(0,0,0,.12);
    position: relative;
    z-index: 2;
}

.aes-timeline-content {
    background: var(--aes-white);
    border: 1px solid var(--aes-gray-200);
    border-radius: var(--aes-radius);
    padding: 24px 20px;
    box-shadow: var(--aes-shadow);
    width: 100%;
}

.aes-step-title {
    margin: 0;
    color: #f15b2a;
    font-weight: 700;
    font-size: 24px;
}

.aes-step-desc {
    font-size: 16px;
    color: #1c1a1a;
    margin: 0;
    line-height: 1.55;
}

.aes-timeline-caption {
    text-align: center;
    font-size: 20px;
    color: var(--aes-gray-500);
    margin-top: 32px;
    margin-bottom: 30px;
}

/* ═══════════════════════════════════════════════════════════
   6. COMPARISON BLOCK LAYOUT
   ═══════════════════════════════════════════════════════════ */
.aes-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    margin-top: 8px;
}

.aes-comparison-side {
    border-radius: var(--aes-radius);
    overflow: hidden;
    border: 2px dashed;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, .05);
}

.aes-comparison-side.aes-comparison-left {
    border-color: #f44336;
    background-color: #ffe5e5;
}

.aes-comparison-side.aes-comparison-right {
    border-color: #4caf50;
    background-color: #e6f9ec;  
}

.aes-comparison-label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 0 14px;
    font-size: 18px;
    font-weight: 600;
}

.aes-comparison-label i {
    font-size: 16px;
}

.aes-comparison-label--before {
    color: rgb(220 38 38);
}

.aes-comparison-label--after {
    color: rgb(21 128 61);
}

.aes-comparison-img {
    width: 100%;
    line-height: 0;
    border-radius: 12px;
    overflow: hidden;
}

.aes-comparison-img img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.aes-comparison-points {
    list-style: none;
    margin: 0;
    padding: 15px 0;
}

.aes-comparison-points li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 6px 0;
    font-size: 16px;
    color: var(--aes-gray-700);
}

.aes-comparison-points li i {
    margin-top: 6px;
    font-size: 18px;
    flex-shrink: 0;
}

.aes-comparison-points li i {
    color: var(--aes-red);
}

.aes-comparison-points--success li i {
    color: var(--aes-green);
}


/* ═══════════════════════════════════════════════════════════
   7. CONTENT WITH IMAGE LAYOUT
   ═══════════════════════════════════════════════════════════ */
.aes-cwi {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

/* Image on the left → reverse order */
.aes-cwi-img-left {
    direction: rtl;
}

.aes-cwi-img-left > * {
    direction: ltr;
}

.aes-cwi-text {
    order: 1;
}

.aes-cwi-image {
    order: 2;
}

.aes-cwi-img-left .aes-cwi-text {
    order: 2;
}

.aes-cwi-img-left .aes-cwi-image {
    order: 1;
}

.aes-cwi-image img {
    width: 100%;
    height: auto;
    border-radius: var(--aes-radius);
}

.aes-cwi-points {
    list-style: none;
    margin: 0;
    padding: 0;
}

.aes-cwi-point {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 0;
    font-size: 18px;
    line-height: 1.6;
    color: var(--aes-gray-700);
}

.aes-cwi-point-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--aes-orange);
    font-size: 18px;
    margin-top: 5px;
}

.aes-cwi-point-text {
    flex: 1;
}

.aes-cwi-point-text strong {
    display: block;
    color: var(--aes-navy);
    font-weight: 700;
    margin-bottom: 2px;
}


/* ═══════════════════════════════════════════════════════════
   8. CTA BUTTON
   ═══════════════════════════════════════════════════════════ */
.aes-cta-wrap {
    text-align: center;
    margin-top: 40px;
}

.aes-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 32px;
    font-size: 15px;
    font-weight: 700;
    color: var(--aes-white);
    background: var(--aes-orange);
    border: none;
    border-radius: 6px;
    text-decoration: none;
    cursor: pointer;
    transition: background var(--aes-transition), transform var(--aes-transition);
}

.aes-cta-btn:hover {
    background: var(--aes-orange-hover);
    transform: translateY(-2px);
    color: var(--aes-white);
    text-decoration: none;
}

.aes-cta-btn i {
    font-size: 13px;
    transition: transform var(--aes-transition);
}

.aes-cta-btn:hover i {
    transform: translateX(4px);
}


/* ═══════════════════════════════════════════════════════════
   9. RESPONSIVE — TABLET (≤ 1024px)
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    .aes-section {
        padding: 60px 0;
    }

    .aes-title {
        font-size: 30px;
    }

    /* Stats → 2 cols */
    .aes-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Features → 2 cols */
    .aes-features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }

    /* Timeline → 2 cols (last centered) */
    .aes-timeline-cards {
        grid-template-columns: repeat(2, 1fr);
    }

    .aes-timeline-track {
        display: none;
    }

    /* Comparison → stack */
    .aes-comparison {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    /* CWI → stack */
    .aes-cwi {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .aes-cwi-img-left {
        direction: ltr;
    }

    .aes-cwi-text {
        order: 2 !important;
    }

    .aes-cwi-image {
        order: 1 !important;
    }
}


/* ═══════════════════════════════════════════════════════════
   10. RESPONSIVE — MOBILE (≤ 640px)
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
    .aes-section {
        padding: 48px 0;
    }

    .aes-container {
        padding: 0 16px;
    }

    .aes-header {
        margin-bottom: 32px;
    }

    .aes-title {
        font-size: 24px;
    }

    .aes-description {
        font-size: 14px;
    }

    /* Stats → 1 col */
    .aes-stats-grid {
        grid-template-columns: 1fr;
    }

    .aes-stat-number {
        font-size: 32px;
    }

    /* Features → 1 col */
    .aes-features-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .aes-feature-card {
        padding: 24px 16px;
    }

    /* Timeline → 1 col */
    .aes-timeline-cards {
        grid-template-columns: 1fr;
    }

    .aes-timeline-dot {
        width: 44px;
        height: 44px;
        font-size: 15px;
    }

    .aes-timeline-content {
        padding: 18px 16px;
    }

    /* CTA */
    .aes-cta-btn {
        padding: 12px 24px;
        font-size: 14px;
        width: 100%;
        justify-content: center;
    }

    /* Comparison cards */
    .aes-comparison-points {
        padding: 16px;
    }

    /* CWI */
    .aes-cwi {
        gap: 24px;
    }

    .aes-cwi-point {
        font-size: 14px;
        gap: 10px;
    }
}
