/* ============================================================
   ABiG Studio — About/Facts Section (Modern Two-Column)
   public/web/css/about-facts.css
   ============================================================ */

.af-section {
    background: linear-gradient(135deg, #fff 0%, #faf5ff 100%);
    padding: 5rem 0;
}

.af-grid {
    display: grid;
    grid-template-columns: 60% 40%;
    gap: 3.5rem;
    align-items: start;
}

/* ── Left: content ───────────────────────────────────────────── */
.af-heading {
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 800;
    color: #1e1b4b;
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin: 0 0 1.25rem;
}

.af-heading span {
    background: linear-gradient(90deg, #3b5bdb 0%, #9b3ec8 60%, #e0257a 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.af-text {
    font-size: 1.0625rem;
    color: #475569;
    line-height: 1.8;
    margin: 0 0 1rem;
}

.af-lead {
    font-size: 1.125rem;
    color: #334155;
}

.af-audience {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

/* ── Facts wrap (holds track + nav arrows) ──────────────────── */
.af-facts-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 1.75rem 0;
}

.af-facts-track {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.af-facts-track::-webkit-scrollbar {
    display: none;
    height: 0;
}

.af-facts-track.is-fit {
    overflow-x: visible;
    flex-wrap: wrap;
}

.af-fact-card {
    flex: 0 0 auto;
    width: 190px;
    scroll-snap-align: start;
    background: #ffffff;
    border: 1px solid #e9e4fb;
    border-radius: 0.875rem;
    padding: 1rem;
    box-shadow: 0 4px 16px -8px rgba(107, 70, 193, 0.15);
}

.af-facts-track.is-fit .af-fact-card {
    flex: 1 1 0;
    min-width: 150px;
}

.af-fact-dot {
    display: inline-block;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    margin-bottom: 0.6rem;
    background: linear-gradient(135deg, #3b5bdb, #9b3ec8);
}

.af-fact-title {
    font-size: 0.975rem;
    font-weight: 700;
    color: #1e1b4b;
    margin-bottom: 0.3rem;
}

.af-fact-desc {
    font-size: 0.875rem;
    color: #64748b;
    line-height: 1.6;
}

/* ── Nav arrows ──────────────────────────────────────────────── */
.af-nav {
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid #e9e4fb;
    background: #ffffff;
    color: #6b46c1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 3px 10px -4px rgba(107, 70, 193, 0.3);
    transition: background 0.2s ease, transform 0.15s ease;
}

.af-nav:hover {
    background: #f5f3ff;
    transform: scale(1.06);
}

.af-nav svg {
    width: 16px;
    height: 16px;
}

/* ── Right: visual ───────────────────────────────────────────── */
.af-visual {
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.af-image {
    width: 100%;
    height: auto;
    max-width: 460px;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 1.5rem;
    box-shadow: 0 20px 50px -12px rgba(107, 70, 193, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.6);
}

.af-visual-placeholder {
    width: 100%;
    max-width: 460px;
    aspect-ratio: 1 / 1;
    border-radius: 1.5rem;
    background: linear-gradient(135deg, #ede9fe, #fce7f3);
}

/* ── Responsive: tablet ──────────────────────────────────────── */
@media (max-width: 900px) {
    .af-grid {
        grid-template-columns: 1fr;
        gap: 2.25rem;
    }
    .af-visual { order: -1; }
    .af-image, .af-visual-placeholder {
        max-width: 320px;
        margin: 0 auto;
    }
    .af-facts-track.is-fit {
        flex-wrap: nowrap;
        overflow-x: auto;
    }
    .af-facts-track.is-fit .af-fact-card {
        flex: 0 0 auto;
        width: 170px;
    }
}

/* ── Responsive: mobile ──────────────────────────────────────── */
@media (max-width: 600px) {
    .af-section { padding: 2.75rem 0; }

    .af-heading {
        font-size: 1.65rem;
        margin-bottom: 1rem;
    }

    .af-text {
        font-size: 0.975rem;
        line-height: 1.7;
        margin-bottom: 0.85rem;
    }

    .af-lead { font-size: 1rem; }

    .af-image, .af-visual-placeholder {
        max-width: 220px;
        border-radius: 1.1rem;
    }

    .af-facts-wrap {
        margin: 1.25rem 0;
    }

    /* Fixed 3-or-fewer cards: wrap instead of forcing one row */
    .af-facts-track.is-fit {
        flex-wrap: wrap;
    }
    .af-facts-track.is-fit .af-fact-card {
        flex: 1 1 calc(50% - 0.5rem);
        width: auto;
        min-width: 0;
    }

    /* Scrollable (4+) cards: keep single-row scroll, just smaller */
    .af-fact-card {
        width: 150px;
        padding: 0.85rem;
    }

    .af-fact-title { font-size: 0.9rem; }
    .af-fact-desc { font-size: 0.825rem; }

    .af-nav {
        width: 30px;
        height: 30px;
    }
    .af-nav svg { width: 14px; height: 14px; }

    .af-audience {
        margin-top: 1.1rem;
        padding-top: 1.1rem;
    }
}

@media (max-width: 380px) {
    .af-image, .af-visual-placeholder { max-width: 180px; }

    .af-facts-track.is-fit .af-fact-card {
        flex: 1 1 100%;
    }

    .af-facts-track:not(.is-fit) .af-fact-card {
        width: 130px;
    }
}