:root {
    --card-height: 11.25rem;
    --radius: 0.5rem;
    --gap: clamp(1rem, 2vw, 2.5rem);
    --primary: #0b8887;
    --primary-hover: #0ea5a4;
    --text-light: #ffffff;
    --text-dark: #111827;
    --text-muted: #6b7280;
    --bg: #ffffff;
    --shadow: rgba(0, 0, 0, 0.06);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Global reset */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    height: 100%;
    margin: 0;
    min-height: 100%;
    background: #f3f4f6;
    color: var(--text-dark);
    font-family: inherit;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.wrapper {
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

.content {
    flex: 1;
}

a {
    color: inherit;
}

/* Skip link */
.skip-link {
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.skip-link:focus {
    position: static;
    width: auto;
    height: auto;
    padding: .5rem .75rem;
    background: #111827;
    color: #fff;
    z-index: 10000;
    border-radius: 4px;
}

/* Sticky Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: linear-gradient(90deg, var(--primary), var(--primary-hover));
    color: var(--text-light);
    box-shadow: 0 2px 6px var(--shadow);
}

.nav-container {
    max-width: 80%;
    margin: 0 auto;
    padding: .875rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.menu-title {
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: .2px;
}

nav ul {
    list-style: none;
    display: flex;
    align-items: center;
}

nav a {
    text-decoration: none;
    color: var(--text-light);
    font-size: 1.2rem;
    padding: 0 .5rem;
}

.menu-toggle {
    display: none;
    background: none;
    border: 0;
    font-size: 1.5rem;
    color: var(--text-light);
    cursor: pointer;
}

@media (max-width:768px) {
    .menu-toggle {
        display: block;
    }

    nav {
        position: absolute;
        top: 100%;
        right: 0;
        width: 100%;
        background: linear-gradient(90deg, var(--primary), var(--primary-hover));
        max-height: 0;
        overflow: hidden;
        transition: max-height .25s ease;
    }

    nav.open {
        max-height: 20rem;
    }

    nav ul {
        flex-direction: column;
        margin: 0;
    }

    nav ul li {
        width: 100%;
        text-align: center;
        padding: .9rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    }

    nav ul li:hover {
        background: rgba(255, 255, 255, 0.05);
    }
}

main {
    padding-top: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 80%;
    margin: 0 auto;
    padding-inline: 1rem;
    flex: 1;
}

.main-title {
    color: #085353;
    font-size: clamp(1.8rem, 2.8vw, 2.4rem);
    font-weight: 700;
    margin-top: clamp(.5rem, 5vw, 2.5rem);
    text-align: center;
}

.main-title-detail {
    color: #085353;
    font-size: clamp(1rem, 1.6vw, 1.2rem);
    font-weight: 500;
    margin-top: 1rem;
    text-align: center;
}

main ul, 
main ol {
    margin-left: 2.5rem;
}


.section-title-box {
    text-align: left;
    width: 100%;
}

.section-title {
    width: 100%;
    text-align: left;
    font-size: clamp(1.2rem, 2vw, 1.4rem);
    font-weight: 600;
    margin: 2.5rem 0 0 1.5rem;
}

p.section-detail {
    display: block;
    max-width: 90%;
    text-align: left;
    margin: .25rem 0 1rem 1.5rem;
    color: var(--text-muted);
    font-size: clamp(.9rem, 1.2vw, 1rem);
}

.cards-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--gap);
    width: 100%;
    margin: 0 auto 2rem;
}

.cards-grid .card {
    flex: 1 1 calc(33.333% - var(--gap));
    max-width: calc(33.333% - var(--gap));
    background: var(--bg);
    border-radius: var(--radius);
    box-shadow: 0 6px 18px var(--shadow);
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: var(--card-height);
    transition: transform .18s ease, box-shadow .18s ease, opacity .4s ease;
}

/* 2-card rows */
@supports (display: grid) {}

.cards-grid .card:nth-last-child(2):first-child,
.cards-grid .card:nth-last-child(2):first-child~.card {
    flex: 1 1 calc(50% - var(--gap));
    max-width: calc(50% - var(--gap));
}

.cards-grid .card:only-child {
    flex: 1 1 100%;
    max-width: 100%;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.card-content {
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

.card svg {
    width: 1.5rem;
    height: 1.5rem;
    stroke: #2563eb;
    fill: none;
    stroke-width: 2;
}

.card h3 {
    font-size: clamp(1rem, 1.4vw, 1.1rem);
    font-weight: 600;
    color: var(--text-dark);
}

.card p {
    font-size: clamp(.9rem, 1.2vw, .95rem);
    color: var(--text-muted);
}

.card a.button {
    align-self: flex-start;
    background: var(--primary);
    color: var(--text-light);
    padding: .5rem .75rem;
    border-radius: .25rem;
    text-decoration: none;
    font-weight: 600;
    transition: background .15s;
    margin-top: .5rem;
}

.card a.button:hover {
    background: var(--primary-hover);
}

.inner-pages p {
    font-size: 1.1rem;
    font-weight: 400;
    margin: 1em 0em;
}

footer {
    background: #fff;
    padding: 1.25rem 1rem;
    box-shadow: 0 -1px 4px var(--shadow);
    text-align: center;
    margin-top: 1rem;
    position: relative;
    left: 0;
    right: 0;
    bottom: 0;
}

footer .footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: .75rem;
    margin-bottom: .5rem;
}

footer a {
    text-decoration: none;
    color: var(--text-muted);
}

footer a:hover {
    color: var(--primary);
}

footer p {
    font-size: .8rem;
}

/* ===== Responsive Breakpoints ===== */
/* Mobile: up to 640px */
@media (max-width: 640px) {
    main {
        max-width: 100%;
        padding-top: 2.5rem;
    }

    .nav-container {
        max-width: 95%;
    }

    .cards-grid .card {
        flex: 1 1 100%;
        max-width: 100%;
    }

    /*    .card p {
      display: none;
    }*/
}

/* Tablets: 641px – 991px */
@media (min-width: 641px) and (max-width: 991px) {
    main {
        max-width: 95%;
        padding-top: 3rem;
    }

    .nav-container {
        max-width: 90%;
    }

    .menu-title {
        font-size: 1.6rem;
    }

    .cards-grid .card {
        flex: 1 1 calc(45% - var(--gap));
        max-width: calc(45% - var(--gap));
    }
}

/* Small desktops: 992px – 1399px */
@media (min-width: 992px) and (max-width: 1399px) {
    main {
        max-width: 95%;
    }

    .nav-container {
        max-width: 90%;
    }
}

/* Large desktops: ≥1400px */
@media (min-width: 1400px) {
    main {
        max-width: 95%;
    }

    .nav-container {
        max-width: 85%;
    }
}

/* Reveal animation states (required for IntersectionObserver) */
.hidden {
    opacity: 0;
    transform: translateY(18px);
}

.visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity .6s cubic-bezier(.2, .9, .3, 1), transform .6s cubic-bezier(.2, .9, .3, 1);
}

/* Accessibility: focus */
a:focus,
button:focus {
    outline: 3px solid rgba(11, 136, 135, 0.18);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Utility */
img,
svg {
    max-width: 100%;
    height: auto;
    display: block;
}

.alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.alert.success {
    background: #e8f8f5;
    color: #0e6655;
    border: 1px solid #1abc9c;
}

.alert.error {
    background: #fdecea;
    color: #c0392b;
    border: 1px solid #e74c3c;
}
