:root {
    --ifsp-ink: #16253d;
    --ifsp-muted: #5f6f83;
    --ifsp-primary: #164e8c;
    --ifsp-teal: #087f83;
    --ifsp-gold: #A63635;
    --ifsp-line: #d9e3ed;
    --ifsp-surface: rgba(255, 255, 255, 0.94);
    --ifsp-shadow: 0 18px 45px rgba(23, 47, 75, 0.10);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ifsp-ink);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 0.98rem;
    line-height: 1.65;
    background-color: #edf3f7;
    background-image:
        linear-gradient(120deg, rgba(22, 78, 140, 0.075), transparent 42%),
        radial-gradient(circle at 88% 11%, rgba(8, 127, 131, 0.11), transparent 28%),
        repeating-linear-gradient(90deg, transparent 0, transparent 54px, rgba(22, 78, 140, 0.025) 55px);
}

main {
    display: flex;
    flex-direction: column;
    gap: 1.35rem;
    max-width: 1540px;
    margin: 0 auto;
    padding: clamp(1.5rem, 4vw, 4rem) clamp(1rem, 3vw, 2.5rem) 4rem;
}

.section1,
.section2 {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(1rem, 2vw, 1.5rem);
}

/* Keep the original three-card row on desktop. */
.section1-left {
    display: contents;
}

.p1,
.p2,
.p3,
.p4,
.p5,
.p6 {
    position: relative;
    min-width: 0;
    padding: clamp(1.35rem, 2.5vw, 2.1rem);
    overflow: hidden;
    border: 1px solid rgba(157, 177, 197, 0.58);
    border-radius: 8px;
    background: var(--ifsp-surface);
    box-shadow: var(--ifsp-shadow);
}

.p1::before,
.p2::before,
.p3::before,
.p4::before,
.p5::before,
.p6::before {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    content: "";
    /* background: linear-gradient(90deg, var(--ifsp-primary), var(--ifsp-teal)); */
}

.num-page {
    display: grid;
    width: 3.2rem;
    height: 3.2rem;
    margin-bottom: 1.15rem;
    place-items: center;
    color: var(--ifsp-primary);
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    line-height: 1;
    border: 1px solid #b9d0e2;
    border-radius: 50%;
    background: #eaf4f8;
    box-shadow: inset 0 0 0 5px rgba(255, 255, 255, 0.72);
}

main h1,
main h2,
main h3,
main p {
    margin-top: 0;
}

main h1 {
    color: #102d52;
    font-size: clamp(1.25rem, 1.7vw, 1.75rem);
    font-weight: 800;
    letter-spacing: 0;
    line-height: 1.22;
    text-align: center;
    text-transform: uppercase;
}

main h2 {
    margin: 1.65rem 0 0.7rem;
    color: var(--ifsp-primary);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    line-height: 1.35;
    text-transform: uppercase;
}

main h2::after {
    display: block;
    width: 2.2rem;
    height: 2px;
    margin-top: 0.5rem;
    content: "";
    background: var(--ifsp-teal);
}

main h3 {
    margin-bottom: 0.45rem;
    color: #1c3b62;
    font-size: 0.96rem;
    font-weight: 750;
    line-height: 1.45;
    text-align: center;
}

.p6 > h3,
.p4 > h3 {
    margin-top: 1.25rem;
}

main ul {
    margin: 0.45rem 0 0;
    padding-left: 1.2rem;
}

main li {
    margin: 0.35rem 0;
    padding-left: 0.35rem;
}

main li::marker {
    color: var(--ifsp-teal);
}

.bold {
    color: #173d6c;
    font-weight: 750;
}

.ifsp {
    color: var(--ifsp-teal);
}

.p5 table {
    width: 100%;
    margin: 1rem 0 1.55rem;
    overflow: hidden;
    border: 1px solid var(--ifsp-line);
    border-spacing: 0;
    border-radius: 6px;
    font-size: 0.9rem;
}

.p5 td {
    padding: 0.65rem 0.75rem;
    border-bottom: 1px solid var(--ifsp-line);
}

.p5 tr:last-child td {
    border-bottom: 0;
}

.p5 tr:nth-child(even) {
    background: #f4f8fb;
}

.p5 thead tr {
    color: #fff;
    text-align: center;
    background: var(--ifsp-primary);
}

.p5 thead td {
    border-bottom: 0;
    font-weight: 750;
}

tr > .percent {
    width: 4.5rem;
    color: var(--ifsp-teal);
    font-weight: 800;
    text-align: center;
}

.imgp1,
.imgp4,
.imgp5,
.imgp6 {
    margin-top: 1.35rem;
}

main img {
    display: block;
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    box-shadow: 0 10px 25px rgba(19, 48, 78, 0.15);
}

.imgp5 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    align-items: center;
}

.imgp5 img {
    width: 100%;
}

@media (max-width: 1080px) {
    .section1 {
        display: block;
    }

    .section1-left {
        /* display: grid; */
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
        gap: clamp(1rem, 2vw, 1.5rem);
    }

    .section1-left .p3 {
        grid-column: 1;
    }

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

@media (max-width: 700px) {
    body {
        font-size: 0.95rem;
    }

    main {
        padding: 1.15rem 0.8rem 2.75rem;
    }

    .section1,
    .section2 {
        gap: 0.9rem;
    }

    .section1-left {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.9rem;
    }

    .section1-left .p2 {
        grid-row: 2;
    }

    .section1-left .p3 {
        grid-row: 3;
    }

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

    .p1,
    .p2,
    .p3,
    .p4,
    .p5,
    .p6 {
        padding: 1.2rem;
    }
}
