/* =========================================================
   NSC TOP / INFORMATION PAGES
   Shared stylesheet: top.css
   Pages:
   Chapters, Gallery, APELL-LAMP, ILO-IPEC, MOEF/World Bank,
   National Activities, International Activities, Contact
   ========================================================= */

:root {
    --top-navy: #16243E;
    --top-green: #00952b;
    --top-green-dark: #007a22;
    --top-orange: #ff9f1c;
    --top-text: #445063;
    --top-muted: #677486;
    --top-light: #f6fafc;
    --top-soft-green: #eef8f1;
    --top-border: #e1e8ed;
    --top-shadow: 0 16px 42px rgba(15,35,60,.10);
}

.top-page {
    color: var(--top-text);
    overflow-x: hidden;
}

.top-page p,
.top-page li,
.top-page td,
.top-page th,
.top-page a,
.top-page h1,
.top-page h2,
.top-page h3,
.top-page h4,
.top-page h5,
.top-page button,
.top-page input,
.top-page textarea {
    font-family: "Poppins", sans-serif;
}

.top-page p,
.top-page li {
    line-height: 1.72;
    letter-spacing: 0;
}

.top-page .text-justify {
    text-align: left !important;
}

.top-page a {
    text-decoration: none;
}

/* =========================================================
   COMMON CONTENT SHELL
   ========================================================= */

.top-content-section {
    padding: 68px 0 78px !important;
    background:
        radial-gradient(circle at 7% 4%, rgba(0,149,43,.06), transparent 22%),
        radial-gradient(circle at 93% 4%, rgba(255,159,28,.07), transparent 22%),
        linear-gradient(180deg, #fff 0%, #f6fafc 100%);
}

.top-content-section > .container {
    padding: 32px;
    border-top: 5px solid var(--top-green);
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--top-shadow);
}

.top-content-section hr {
    margin: 25px 0;
    border: 0;
    border-top: 1px solid #e7edf1;
    opacity: 1;
}

.top-content-section p {
    color: #566377;
}

.top-content-section p b,
.top-content-section p strong {
    color: var(--top-navy);
}

.top-content-section h3,
.top-content-section h4 {
    color: var(--top-navy);
    font-weight: 900;
}

/* =========================================================
   SHARED TOP SUBMENU
   ========================================================= */

.top-submenu {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 26px !important;
    padding: 9px !important;
    border: 1px solid var(--top-border) !important;
    border-radius: 14px !important;
    background: #f7f9fb;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.8);
}

.top-submenu .nav-item {
    flex: 1 1 170px;
}

.top-submenu .nav-link {
    height: 100%;
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 13px !important;
    border: 0 !important;
    border-radius: 9px !important;
    color: var(--top-navy) !important;
    background: transparent;
    font-size: 12px;
    line-height: 1.35;
    font-weight: 800;
    text-align: center;
    transition: all .22s ease;
}

.top-submenu .nav-link:hover {
    background: #eaf5ed;
    color: var(--top-green-dark) !important;
}

.top-submenu .nav-link.active {
    background: var(--top-green) !important;
    color: #fff !important;
    box-shadow: 0 7px 17px rgba(0,149,43,.18);
}

/* =========================================================
   PROJECT TEXT / LISTS
   ========================================================= */

.top-apell-page .top-content-section .mt-4,
.top-ilo-page .top-content-section .mt-4,
.top-moef-page .top-content-section .mt-4 {
    margin-top: 0 !important;
    padding: 5px 2px 0 !important;
}

.top-apell-page .top-content-section ul:not(.top-submenu),
.top-ilo-page .top-content-section ul:not(.top-submenu),
.top-moef-page .top-content-section ul:not(.top-submenu) {
    list-style: none;
    margin-left: 0 !important;
    padding-left: 0 !important;
}

.top-apell-page .top-content-section ul:not(.top-submenu) > li,
.top-ilo-page .top-content-section ul:not(.top-submenu) > li,
.top-moef-page .top-content-section ul:not(.top-submenu) > li {
    position: relative;
    margin-bottom: 9px;
    padding: 12px 15px 12px 44px;
    border: 1px solid #e6ecef;
    border-radius: 10px;
    background: #f8fafc;
}

.top-apell-page .top-content-section ul:not(.top-submenu) > li::before,
.top-ilo-page .top-content-section ul:not(.top-submenu) > li::before,
.top-moef-page .top-content-section ul:not(.top-submenu) > li::before {
    content: "✓";
    position: absolute;
    left: 14px;
    top: 13px;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--top-green);
    color: #fff;
    font-family: Arial, sans-serif;
    font-size: 10px;
    font-weight: 800;
}

.top-ilo-page .top-content-section h4,
.top-ilo-page .top-content-section p b,
.top-apell-page .top-content-section p b,
.top-moef-page .top-content-section p b {
    color: var(--top-navy);
}

/* =========================================================
   NATIONAL + INTERNATIONAL ACTIVITY CARDS
   ========================================================= */

.top-activity-page .top-content-section > .container {
    padding-bottom: 38px;
}

.top-activity-page .top-content-section .mt-4.pt-4 {
    margin-top: 0 !important;
    padding-top: 5px !important;
}

.top-activity-card {
    align-items: stretch;
    gap: 0;
    padding: 0 !important;
    overflow: hidden;
    border: 1px solid var(--top-border) !important;
    border-radius: 16px !important;
    background: #fff;
    box-shadow: 0 10px 28px rgba(15,35,60,.07);
    transition: transform .28s ease, box-shadow .28s ease, border-color .28s ease;
}

.top-activity-card:hover {
    transform: translateY(-4px);
    border-color: rgba(0,149,43,.24) !important;
    box-shadow: 0 17px 36px rgba(15,35,60,.12);
}

.top-activity-card > div:first-child {
    flex: 0 0 245px;
    min-height: 205px;
    padding: 10px;
    background: #f4f7f9;
}

.top-activity-card > div:first-child img {
    width: 100% !important;
    height: 100%;
    min-height: 185px;
    max-height: 240px;
    margin: 0 !important;
    display: block;
    object-fit: contain;
    border-radius: 10px;
    background: #fff;
}

.top-activity-card > div:last-child {
    flex: 1 1 auto;
    padding: 24px !important;
}

.top-activity-card > div:last-child > p:first-child {
    margin-bottom: 11px !important;
    color: var(--top-navy);
    font-size: 17px !important;
    line-height: 1.45;
    font-weight: 900;
}

.top-activity-card hr {
    margin: 13px 0 15px;
}

.top-activity-card p {
    margin-bottom: 7px !important;
}

/* =========================================================
   CHAPTERS
   ========================================================= */

.top-chapters-page .top-content-section > .container > div:first-child > p:first-child,
.top-chapters-page .top-content-section > .container > p:first-child {
    margin-bottom: 28px !important;
    padding: 20px 22px;
    border-left: 5px solid var(--top-green);
    border-radius: 13px;
    background: linear-gradient(135deg, #f4faf6, #f8fafc);
    border-top: 1px solid var(--top-border);
    border-right: 1px solid var(--top-border);
    border-bottom: 1px solid var(--top-border);
}

.top-chapters-grid > [class*="col-"] {
    display: flex;
}

.top-chapter-card {
    position: relative;
    width: 100%;
    padding: 23px !important;
    overflow: hidden;
    border: 1px solid var(--top-border) !important;
    border-radius: 15px !important;
    background: linear-gradient(180deg,#fff,#f8fafc) !important;
    box-shadow: 0 9px 25px rgba(15,35,60,.07) !important;
    transition: transform .28s ease, box-shadow .28s ease, border-color .28s ease;
}

.top-chapter-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg,var(--top-green),var(--top-orange));
}

.top-chapter-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0,149,43,.24) !important;
    box-shadow: 0 16px 35px rgba(15,35,60,.12) !important;
}

.top-chapter-card .fs-5 {
    margin-bottom: 12px;
    color: var(--top-navy);
    font-size: 17px !important;
    font-weight: 900;
}

.top-chapter-card hr {
    margin: 13px 0;
}

.top-chapter-card p {
    margin-bottom: 8px;
    font-size: 13px;
    line-height: 1.58;
}

.top-chapter-card svg {
    flex: 0 0 auto;
    margin-right: 5px;
    vertical-align: -4px;
}

.top-chapter-card a {
    color: var(--top-green-dark);
    font-weight: 700;
    word-break: break-word;
}

.top-chapter-download {
    margin-top: 30px;
}

.top-chapter-download .btn {
    min-height: 49px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0 !important;
    border-radius: 9px !important;
    background: var(--top-green) !important;
    color: #fff !important;
    font-weight: 800;
}

.top-chapter-download .btn:hover {
    background: var(--top-navy) !important;
}

/* =========================================================
   GALLERY
   ========================================================= */

.top-gallery-section {
    padding: 65px 0 78px !important;
    background:
        radial-gradient(circle at 7% 3%,rgba(0,149,43,.055),transparent 22%),
        linear-gradient(180deg,#fff,#f6fafc);
}

.top-gallery-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-bottom: 30px;
    padding: 9px;
    border: 1px solid var(--top-border);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 9px 26px rgba(15,35,60,.06);
}

.top-gallery-tabs .nav-link {
    min-height: 42px;
    padding: 9px 14px;
    border-radius: 8px !important;
    color: var(--top-navy);
    font-size: 18px;
    line-height: 1.35;
    font-weight: 800;
}

.top-gallery-tabs .nav-link:hover {
    color: var(--top-green-dark);
    background: #eef8f1;
}

.top-gallery-tabs .nav-link.active {
    background: var(--top-green) !important;
    color: #fff !important;
}

.top-gallery-page .tab-content > .tab-pane {
    padding-left: 0;
    padding-right: 0;
}

.top-gallery-page .gallery-grid > .col {
    position: relative;
}

.top-gallery-page .gallery-grid > .col > h2 {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    margin: 0 0 10px;
    padding: 5px 12px;
    border-radius: 18px;
    background: var(--top-navy);
    color: #fff;
    font-size: 18px;
    line-height: 1;
    font-weight: 900;
}

.top-gallery-image {
    position: relative;
    height: 245px;
    overflow: hidden;
    padding: 7px;
    border: 1px solid var(--top-border);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 10px 27px rgba(15,35,60,.08);
    cursor: zoom-in;
    transition: transform .28s ease, box-shadow .28s ease;
}

.top-gallery-image:hover {
    transform: translateY(-4px);
    box-shadow: 0 17px 34px rgba(15,35,60,.13);
}

.top-gallery-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    border-radius: 9px;
    transition: transform .32s ease;
}

.top-gallery-image:hover img {
    transform: scale(1.035);
}

.top-gallery-page .gallery-grid > .col > p {
    margin: 13px 5px 0 !important;
    color: #606d7f;
    font-size: 13px;
    line-height: 1.6;
}

/* Existing enlarge / exit SVG and modal logic remain untouched */
.top-gallery-page .carousel-caption {
    padding: 12px 15px;
    border-radius: 10px;
    background: rgba(22,36,62,.80);
}

/* =========================================================
   CONTACT
   ========================================================= */

.top-contact-section {
    padding: 68px 0 !important;
    background:
        radial-gradient(circle at 8% 5%,rgba(0,149,43,.06),transparent 22%),
        radial-gradient(circle at 92% 5%,rgba(255,159,28,.07),transparent 22%),
        linear-gradient(180deg,#fff,#f6fafc);
}

.top-contact-card {
    padding: 32px;
    border-top: 5px solid var(--top-green);
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--top-shadow);
}

.top-contact-card .row {
    align-items: stretch;
}

.top-contact-card .col-lg-7,
.top-contact-card .col-lg-5 {
    display: flex;
}

.top-contact-card .tp-contact-breadcrumb-content,
.top-contact-card .tp-contact-breadcrumb-wrapper {
    width: 100%;
}

.top-contact-card .tp-contact-breadcrumb-content {
    padding: 4px 20px 4px 4px;
}

.top-contact-card .tp-contact-breadcrumb-title {
    position: relative;
    margin-bottom: 8px;
    padding-bottom: 13px;
    color: var(--top-navy);
    font-size: clamp(29px,4vw,39px);
    font-weight: 900;
}

.top-contact-card .tp-contact-breadcrumb-title::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 62px;
    height: 4px;
    border-radius: 10px;
    background: linear-gradient(90deg,var(--top-green),var(--top-orange));
}

.top-contact-card .tp-contact-breadcrumb-content > p {
    margin-bottom: 22px;
    color: var(--top-muted);
}

.top-contact-card .tp-contact-input {
    margin-bottom: 15px;
}

.top-contact-card .tp-contact-input input,
.top-contact-card .tp-contact-input textarea {
    width: 100%;
    border: 1px solid var(--top-border);
    border-radius: 9px;
    background: #f9fbfc;
    color: var(--top-navy);
    outline: 0;
    box-shadow: none;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.top-contact-card .tp-contact-input input {
    min-height: 50px;
    padding: 10px 15px;
}

.top-contact-card .tp-contact-input textarea {
    min-height: 135px;
    padding: 13px 15px;
    resize: vertical;
}

.top-contact-card .tp-contact-input input:focus,
.top-contact-card .tp-contact-input textarea:focus {
    border-color: rgba(0,149,43,.55);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(0,149,43,.07);
}

.top-contact-card .tp-contact-breadcrumb-btn .tp-btn {
    min-width: 135px;
    min-height: 47px;
    border: 0;
    border-radius: 9px;
    background: var(--top-green);
    color: #fff;
    font-weight: 800;
}

.top-contact-card .tp-contact-breadcrumb-btn .tp-btn:hover {
    background: var(--top-navy);
}

.top-contact-card .tp-contact-breadcrumb-wrapper {
    height: 100%;
    padding: 24px;
    border-radius: 16px;
    background: linear-gradient(145deg,var(--top-navy),#223555);
    color: #fff;
}

.top-contact-card .tp-contact-breadcrumb-item {
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 16px !important;
    padding: 16px;
    border: 1px solid rgba(255,255,255,.13);
    border-radius: 12px;
    background: rgba(255,255,255,.06);
}

.top-contact-card .tp-contact-breadcrumb-item:last-child {
    margin-bottom: 0 !important;
}

.top-contact-card .tp-contact-breadcrumb-item-icon span {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--top-green);
    color: #fff;
}

.top-contact-card .tp-contact-breadcrumb-item-title {
    margin-bottom: 5px;
    color: #fff;
    font-size: 16px;
    font-weight: 900;
}

.top-contact-card .tp-contact-breadcrumb-item-content,
.top-contact-card .tp-contact-breadcrumb-item-content a {
    color: rgba(255,255,255,.88);
    font-size: 13px;
    line-height: 1.65;
}

.top-contact-tables {
    padding: 0 0 78px !important;
    background: #fff;
}

.top-contact-tables > .container {
    padding: 32px;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(15,35,60,.08);
}

.top-contact-tables h4 {
    position: relative;
    margin: 28px 0 16px !important;
    padding-bottom: 10px;
    color: var(--top-navy);
    font-size: 20px;
    font-weight: 900;
}

.top-contact-tables h4:first-child {
    margin-top: 0 !important;
}

.top-contact-tables h4::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 52px;
    height: 3px;
    border-radius: 10px;
    background: linear-gradient(90deg,var(--top-green),var(--top-orange));
}

.top-contact-tables > .container > p {
    color: #5d697b;
}

.top-table-scroll {
    width: 100%;
    margin-bottom: 35px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--top-border);
    border-radius: 13px;
    background: #fff;
    box-shadow: 0 7px 22px rgba(15,35,60,.05);
}

.top-table-scroll .table {
    min-width: 760px;
    margin: 0 !important;
    border-collapse: separate;
    border-spacing: 0;
}

.top-table-scroll .table th,
.top-table-scroll .table td {
    padding: 13px 14px;
    border-color: #e1e8ed !important;
    vertical-align: middle;
    font-size: 13px;
    line-height: 1.55;
}

.top-table-scroll .table thead th {
    background: var(--top-navy);
    color: #fff;
    font-weight: 800;
}

.top-table-scroll .table tbody tr:nth-child(even) td {
    background: #f8fafc;
}

.top-table-scroll .table tbody tr:hover td {
    background: #f2f8f4;
}

.top-table-scroll a {
    color: var(--top-green-dark);
    font-weight: 700;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 991px) {
    .top-content-section,
    .top-gallery-section,
    .top-contact-section {
        padding-top: 52px !important;
        padding-bottom: 60px !important;
    }

    .top-content-section > .container,
    .top-contact-card,
    .top-contact-tables > .container {
        padding: 25px;
        border-radius: 18px;
    }

    .top-activity-card {
        flex-direction: column;
    }

    .top-activity-card > div:first-child {
        flex-basis: auto;
        width: 100%;
        min-height: 0;
    }

    .top-activity-card > div:first-child img {
        height: auto;
        min-height: 0;
        max-height: 360px;
    }

    .top-contact-card .col-lg-7,
    .top-contact-card .col-lg-5 {
        display: block;
    }

    .top-contact-card .tp-contact-breadcrumb-content {
        padding: 0;
    }

    .top-contact-card .tp-contact-breadcrumb-wrapper {
        margin-top: 28px;
    }
}

@media (max-width: 767px) {
    .top-content-section,
    .top-gallery-section,
    .top-contact-section {
        padding-top: 42px !important;
        padding-bottom: 50px !important;
    }

    .top-content-section > .container,
    .top-contact-card,
    .top-contact-tables > .container {
        width: calc(100% - 24px);
        padding: 19px;
        border-radius: 15px;
    }

    .top-submenu {
        flex-wrap: nowrap;
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
    }

    .top-submenu .nav-item {
        flex: 0 0 190px;
    }

    .top-gallery-tabs {
        flex-wrap: nowrap;
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
    }

    .top-gallery-tabs .nav-item {
        flex: 0 0 auto;
    }

    .top-gallery-image {
        height: 230px;
    }

    .top-activity-card > div:last-child {
        padding: 19px !important;
    }

    .top-contact-card .tp-contact-breadcrumb-wrapper {
        padding: 18px;
    }

    .top-contact-tables {
        padding-bottom: 52px !important;
    }
}

@media (max-width: 575px) {
    .top-gallery-image {
        height: 220px;
    }

    .top-chapter-card {
        padding: 19px !important;
    }

    .top-contact-card .tp-contact-breadcrumb-item {
        padding: 13px;
    }
}

.contact-icon {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #00952b;
    flex: 0 0 38px;
}

.contact-icon svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: #fff;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
