/* =========================================================
   CODEWORD ABOUT PAGE — PREMIUM 3D DESIGN
   File: assets/css/about.css
   Palette: Navy / Electric Blue / White
   Scoped to About page sections to avoid header/footer conflicts
========================================================= */

:root {
    --about-navy: #101b32;
    --about-navy-2: #1b3058;
    --about-blue: #2563eb;
    --about-blue-light: #60a5fa;
    --about-ink: #172033;
    --about-muted: #526178;
    --about-surface: #ffffff;
    --about-soft: #f3f7fc;
    --about-border: #dce5f0;
    --about-shadow: 0 22px 55px rgba(16, 27, 50, .12);
}

/* About-page sections only */
.about-hero,
.about-section,
.vision-section,
.why-section,
.cta-section {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    font-family: "Poppins", "Segoe UI", sans-serif;
}

.about-hero *,
.about-section *,
.vision-section *,
.why-section *,
.cta-section * {
    box-sizing: border-box;
}

.about-hero {
    min-height: 540px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(80px, 10vw, 140px) 22px;
    text-align: center;
    color: #fff;
    background:
        radial-gradient(ellipse at 15% 15%, rgba(59, 130, 246, .28), transparent 35%),
        radial-gradient(ellipse at 85% 80%, rgba(96, 165, 250, .18), transparent 32%),
        linear-gradient(135deg, rgba(9, 18, 36, .97), rgba(27, 48, 88, .94)),
        url("../images/about-us.png") center / cover no-repeat;
}

.about-hero::before,
.about-hero::after {
    content: "";
    position: absolute;
    z-index: -1;
    pointer-events: none;
    border: 1px solid rgba(147, 197, 253, .25);
    border-radius: 50%;
    transform-style: preserve-3d;
}

.about-hero::before {
    width: min(52vw, 620px);
    aspect-ratio: 1;
    right: -12%;
    top: -35%;
    box-shadow: 0 0 0 35px rgba(96, 165, 250, .035),
        0 0 0 75px rgba(96, 165, 250, .025);
    animation: about-orbit 22s linear infinite;
}

.about-hero::after {
    width: min(32vw, 380px);
    aspect-ratio: 1;
    left: -10%;
    bottom: -35%;
    box-shadow: 0 0 0 25px rgba(96, 165, 250, .035),
        0 0 0 55px rgba(96, 165, 250, .025);
    animation: about-orbit 28s linear infinite reverse;
}

.hero-content {
    position: relative;
    z-index: 1;
    width: min(100%, 950px);
    margin: 0 auto;
    padding: clamp(28px, 5vw, 58px);
    background: linear-gradient(145deg, rgba(255, 255, 255, .085), rgba(255, 255, 255, .025));
    border: 1px solid rgba(191, 219, 254, .2);
    border-radius: 30px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, .24), inset 0 1px 0 rgba(255, 255, 255, .12);
    backdrop-filter: blur(12px);
    transform-style: preserve-3d;
    animation: about-hero-enter .85s cubic-bezier(.2, .75, .25, 1) both;
}

.hero-content h1 {
    max-width: 850px;
    margin: 0 auto;
    color: #fff;
    font-size: clamp(34px, 5vw, 60px);
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -1.7px;
    text-wrap: balance;
    text-shadow: 0 8px 28px rgba(0, 0, 0, .22);
}

.hero-content p {
    max-width: 720px;
    margin: 24px auto 0;
    color: #dbeafe;
    font-size: clamp(15px, 1.4vw, 17px);
    font-weight: 400;
    line-height: 1.9;
}

/* Shared section heading accents */
.about-text h2,
.why-section>h2 {
    position: relative;
    margin: 0 0 24px;
    color: var(--about-navy-2);
    font-size: clamp(29px, 3vw, 40px);
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -.7px;
}

.about-text h2::after,
.why-section>h2::after {
    content: "";
    display: block;
    width: 66px;
    height: 4px;
    margin-top: 15px;
    border-radius: 99px;
    background: linear-gradient(90deg, var(--about-blue), #93c5fd);
}

/* ABOUT INTRO */
.about-section {
    padding: clamp(70px, 8vw, 115px) clamp(20px, 7vw, 110px);
    background:
        radial-gradient(circle at 4% 10%, rgba(37, 99, 235, .045), transparent 26%),
        #fff;
}

.about-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(300px, .9fr);
    gap: clamp(38px, 6vw, 85px);
    align-items: center;
    width: min(100%, 1240px);
    margin: 0 auto;
}

.about-text p {
    margin: 0 0 17px;
    color: var(--about-muted);
    font-size: 15.5px;
    line-height: 1.9;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 15px;
    perspective: 1000px;
}

.stat-card {
    position: relative;
    min-width: 0;
    padding: 27px 14px;
    overflow: hidden;
    text-align: center;
    color: #fff;
    background: linear-gradient(145deg, #1c3766, #101b32);
    border: 1px solid rgba(96, 165, 250, .25);
    border-radius: 20px;
    box-shadow: 0 15px 30px rgba(16, 27, 50, .16), inset 0 1px 0 rgba(255, 255, 255, .09);
    transform: perspective(800px) rotateX(0) rotateY(0);
    transform-style: preserve-3d;
    transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}

.stat-card::before {
    content: "";
    position: absolute;
    top: -70%;
    left: -80%;
    width: 75%;
    height: 230%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .13), transparent);
    transform: rotate(25deg);
    transition: left .65s ease;
    pointer-events: none;
}

.stat-card:hover {
    transform: perspective(800px) translateY(-10px) rotateX(4deg) rotateY(-4deg);
    border-color: rgba(147, 197, 253, .7);
    box-shadow: 0 25px 45px rgba(16, 27, 50, .24);
}

.stat-card:hover::before {
    left: 130%;
}

.stat-card h3 {
    position: relative;
    margin: 0 0 9px;
    color: #93c5fd;
    font-size: clamp(25px, 2.6vw, 35px);
    font-weight: 800;
    line-height: 1.1;
}

.stat-card p {
    position: relative;
    margin: 0;
    color: #e2e8f0;
    font-size: 12px;
    line-height: 1.5;
}

/* VISION / MISSION / COMMUNITY */
.vision-section {
    padding: clamp(70px, 8vw, 110px) clamp(20px, 7vw, 110px);
    background: linear-gradient(180deg, #f4f7fc, #edf3fa);
}

.vision-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(18px, 2.5vw, 32px);
    width: min(100%, 1240px);
    margin: 0 auto;
    perspective: 1200px;
}

.vision-card {
    position: relative;
    min-width: 0;
    padding: clamp(30px, 3.5vw, 45px) clamp(22px, 2.8vw, 35px);
    overflow: hidden;
    text-align: center;
    background: linear-gradient(150deg, #fff 0%, #fafdff 100%);
    border: 1px solid #e0e8f2;
    border-top: 4px solid var(--about-blue);
    border-radius: 24px;
    box-shadow: 0 14px 34px rgba(16, 27, 50, .07);
    transform-style: preserve-3d;
    transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}

.vision-card::after {
    content: "";
    position: absolute;
    right: -42px;
    top: -45px;
    width: 130px;
    height: 130px;
    border: 1px solid rgba(37, 99, 235, .09);
    border-radius: 50%;
    box-shadow: 0 0 0 18px rgba(37, 99, 235, .025), 0 0 0 36px rgba(37, 99, 235, .02);
    pointer-events: none;
}

.vision-card:hover {
    transform: translateY(-10px) rotateX(2deg) rotateY(-2deg);
    border-color: #bfdbfe;
    border-top-color: #1d4ed8;
    box-shadow: 0 26px 55px rgba(16, 27, 50, .13);
}

.vision-card>i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 76px;
    height: 76px;
    margin: 0 auto 23px;
    color: #fff;
    background: linear-gradient(145deg, #3b82f6, #1e40af);
    border: 1px solid rgba(255, 255, 255, .45);
    border-radius: 22px;
    box-shadow: 0 12px 24px rgba(37, 99, 235, .25), inset 0 1px 0 rgba(255, 255, 255, .25);
    font-size: 30px;
    transform: translateZ(22px);
    transition: transform .35s ease;
}

.vision-card:hover>i {
    transform: translateZ(32px) rotate(-5deg) scale(1.06);
}

.vision-card h3 {
    position: relative;
    margin: 0 0 14px;
    color: var(--about-navy-2);
    font-size: 22px;
    font-weight: 800;
}

.vision-card p {
    position: relative;
    margin: 0;
    color: var(--about-muted);
    font-size: 14px;
    line-height: 1.85;
}

/* WHY CHOOSE CODEWORD */
.why-section {
    padding: clamp(70px, 8vw, 115px) clamp(20px, 7vw, 110px);
    text-align: center;
    background: #fff;
}

.why-section>h2 {
    margin-bottom: 48px;
}

.why-section>h2::after {
    margin-right: auto;
    margin-left: auto;
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(16px, 2vw, 25px);
    width: min(100%, 1300px);
    margin: 0 auto;
    perspective: 1200px;
}

.why-card {
    position: relative;
    min-width: 0;
    padding: 32px 23px;
    overflow: hidden;
    color: #fff;
    text-align: left;
    background: linear-gradient(145deg, #1c3766 0%, #101b32 100%);
    border: 1px solid rgba(96, 165, 250, .2);
    border-radius: 22px;
    box-shadow: 0 15px 34px rgba(16, 27, 50, .12);
    transform-style: preserve-3d;
    transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}

.why-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #2563eb, #93c5fd, transparent);
    transform: scaleX(.35);
    transform-origin: left;
    transition: transform .35s ease;
}

.why-card:hover {
    transform: translateY(-9px) rotateX(2deg) rotateY(-2deg);
    border-color: rgba(147, 197, 253, .55);
    box-shadow: 0 25px 48px rgba(16, 27, 50, .22);
}

.why-card:hover::before {
    transform: scaleX(1);
}

.why-card>i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    margin-bottom: 23px;
    color: #dbeafe;
    background: rgba(96, 165, 250, .14);
    border: 1px solid rgba(147, 197, 253, .28);
    border-radius: 17px;
    font-size: 24px;
    transition: transform .3s ease, background .3s ease;
}

.why-card:hover>i {
    transform: translateY(-3px) rotate(-5deg);
    background: rgba(96, 165, 250, .24);
}

.why-card h4 {
    margin: 0 0 12px;
    color: #bfdbfe;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.45;
}

.why-card p {
    margin: 0;
    color: #dbe4f0;
    font-size: 13.5px;
    line-height: 1.8;
}

/* CALL TO ACTION */
.cta-section {
    margin: 0;
    padding: clamp(70px, 9vw, 115px) 22px;
    text-align: center;
    color: #fff;
    background:
        radial-gradient(circle at 15% 15%, rgba(96, 165, 250, .2), transparent 28%),
        radial-gradient(circle at 90% 85%, rgba(37, 99, 235, .24), transparent 30%),
        linear-gradient(135deg, #101b32, #1b3058);
}

.cta-section::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: -120px;
    left: calc(50% - 160px);
    width: 320px;
    height: 320px;
    border: 1px solid rgba(191, 219, 254, .15);
    border-radius: 50%;
    box-shadow: 0 0 0 25px rgba(191, 219, 254, .025), 0 0 0 55px rgba(191, 219, 254, .02);
    animation: about-orbit 30s linear infinite;
}

.cta-section h2 {
    position: relative;
    max-width: 850px;
    margin: 0 auto 15px;
    color: #fff;
    font-size: clamp(29px, 4vw, 44px);
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -.8px;
}

.cta-section p {
    max-width: 680px;
    margin: 0 auto;
    color: #dbeafe;
    font-size: 15px;
    line-height: 1.85;
}

.cta-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
    padding: 15px 32px;
    color: #fff;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    border: 1px solid rgba(191, 219, 254, .4);
    border-radius: 13px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .2px;
    text-decoration: none;
    box-shadow: 0 12px 28px rgba(0, 0, 0, .2), inset 0 1px 0 rgba(255, 255, 255, .2);
    transition: transform .3s ease, box-shadow .3s ease, background .3s ease;
}

.cta-btn::after {
    content: "→";
    font-size: 18px;
    line-height: 1;
    transition: transform .25s ease;
}

.cta-btn:hover {
    color: #fff;
    background: linear-gradient(135deg, #60a5fa, #2563eb);
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(0, 0, 0, .27), 0 0 0 5px rgba(96, 165, 250, .1);
}

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

/* Motion */
@keyframes about-orbit {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes about-hero-enter {
    from {
        opacity: 0;
        transform: perspective(1000px) translateY(22px) rotateX(3deg);
    }

    to {
        opacity: 1;
        transform: perspective(1000px) translateY(0) rotateX(0);
    }
}

/* Responsive layouts */
@media (max-width: 1100px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 38px;
    }

    .about-stats {
        max-width: 650px;
    }

    .why-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .about-hero {
        min-height: 460px;
        padding: 70px 18px;
    }

    .hero-content {
        padding: 30px 22px;
        border-radius: 23px;
    }

    .hero-content h1 {
        letter-spacing: -.8px;
    }

    .about-stats {
        grid-template-columns: 1fr;
        gap: 13px;
    }

    .stat-card {
        padding: 23px 18px;
    }

    .vision-grid {
        grid-template-columns: 1fr;
    }

    .vision-card {
        padding: 32px 25px;
    }

    .why-grid {
        grid-template-columns: 1fr;
    }

    .why-card {
        padding: 28px 23px;
    }

    .about-section,
    .vision-section,
    .why-section {
        padding: 68px 20px;
    }
}

@media (max-width: 420px) {
    .about-hero {
        min-height: 420px;
        padding: 55px 14px;
    }

    .hero-content {
        padding: 26px 17px;
    }

    .hero-content p,
    .about-text p,
    .cta-section p {
        font-size: 14px;
    }

    .cta-btn {
        width: 100%;
        max-width: 280px;
        padding: 14px 20px;
    }
}

/* Respect accessibility preferences */
@media (prefers-reduced-motion: reduce) {

    .about-hero::before,
    .about-hero::after,
    .cta-section::before,
    .hero-content {
        animation: none !important;
    }

    .stat-card,
    .vision-card,
    .vision-card>i,
    .why-card,
    .why-card>i,
    .cta-btn {
        transition: none !important;
    }
}