:root {
    --primary: #1f8144;
    --secondary: #aeff3c;
    --dark: #0f172a;
    --muted: #64748b;
    --light: #f8fafc;
    --card: #ffffff;
    --border: #e2e8f0;
}

* {
    box-sizing: border-box;
}

body {
    background: #f4f7fb;
    color: var(--dark);
}

.fw-black {
    font-weight: 900;
}

.text-white-75 {
    color: rgba(255,255,255,.78);
}

.app-navbar {
    background: rgb(11, 76, 15);
    box-shadow: 0 12px 30px rgba(0,0,0,.12);
}

.navbar-brand {
    letter-spacing: .4px;
}

.nav-link.active {
    color: var(--secondary) !important;
    font-weight: 700;
}

/*
.hero-section {
    background:
        radial-gradient(circle at 20% 20%, rgba(250,204,21,.24), transparent 26%),
        linear-gradient(135deg, #0f172a, #1f8144 55%, #27a44d);
}*/

.hero-section {
    background:
        linear-gradient(135deg, rgba(15, 23, 42, .90), rgba(31, 129, 68, .82) 55%, rgba(39, 164, 77, .78)),
        url('../img/Inabanga Municipal Hall.jpg');
    background-size: cover;
    background-position: center;
}

.min-vh-80 {
    min-height: 80vh;
}

.video-card {
    background: white;
    border-radius: 26px;
    padding: 10px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.32);
}

.video-card iframe,
.video-card video {
    border-radius: 18px;
}

.video-placeholder {
    min-height: 360px;
    border-radius: 18px;
    background-size: cover;
    background-position: center;
    display: grid;
    place-items: center;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.video-placeholder::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(15,23,42,.88), rgba(27, 115, 22, 0.78));
}

.video-placeholder > div {
    position: relative;
    max-width: 520px;
    padding: 28px;
}

.small-placeholder {
    min-height: 420px;
}

.feature-card,
.official-card,
.timeline-content {
    background: var(--card);
    border: 1px solid var(--border);
    box-shadow: 0 18px 40px rgba(15,23,42,.06);
    border-radius: 24px;
}

.feature-card {
    padding: 28px;
    height: 100%;
}

.feature-icon {
    width: 54px;
    height: 54px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: #eff6ff;
    font-size: 26px;
    margin-bottom: 18px;
}

.page-heading {
    background:
        linear-gradient(135deg, rgba(15, 23, 42, .90), rgba(31, 129, 68, .82) 55%, rgba(39, 164, 77, .78)),
        url('../img/Inabanga Municipal Hall.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 74px 0;
}

.map-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 20px;
    align-items: stretch;
}

#execonMap {
    min-height: 680px;
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: 0 20px 55px rgba(15,23,42,.12);
}

.map-sidebar {
    background: white;
    border: 1px solid var(--border);
    border-radius: 28px;
    padding: 20px;
    box-shadow: 0 20px 55px rgba(15,23,42,.08);
}

.place-item {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
    text-decoration: none;
    color: var(--dark);
    border: 1px solid transparent;
    margin-bottom: 10px;
    background: #f8fafc;
    transition: .2s ease;
}

.place-item:hover {
    border-color: #bfdbfe;
    transform: translateY(-2px);
    color: var(--primary);
}

.place-item.main {
    background: #fefce8;
}

.place-item img {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    object-fit: cover;
}

.place-item small {
    display: block;
    color: var(--muted);
}

.leaflet-popup-content {
    margin: 12px;
}

.popup-card {
    width: 220px;
}

.popup-card img {
    width: 100%;
    height: 110px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 10px;
}

.popup-card h6 {
    margin-bottom: 6px;
    font-weight: 800;
}

.popup-card p {
    font-size: 13px;
    margin-bottom: 10px;
    color: #475569;
}

.popup-card a {
    display: inline-block;
    padding: 8px 10px;
    background: #1f8144;
    color: white;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 700;
    font-size: 13px;
}

.timeline {
    max-width: 960px;
    margin: 0 auto;
}

.timeline-item {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 22px;
    margin-bottom: 18px;
    align-items: stretch;
}

.timeline-time {
    background: var(--dark);
    color: white;
    border-radius: 20px;
    padding: 20px;
    font-weight: 800;
    display: grid;
    place-items: center;
    text-align: center;
}

.timeline-content {
    padding: 22px;
}

.official-card {
    padding: 24px;
    text-align: center;
    height: 100%;
    transition: .2s ease;
}

.official-card:hover {
    transform: translateY(-4px);
}

.official-card img {
    width: 112px;
    height: 112px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 16px;
    border: 5px solid #eff6ff;
}

.official-card h5 {
    font-weight: 800;
}

.official-card p {
    color: var(--muted);
    margin-bottom: 0;
}

.official-card.deped img {
    border-color: #fef3c7;
}

.official-card.visitor img {
    border-color: #dcfce7;
}

.gallery-card {
    display: block;
    background: white;
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid var(--border);
    text-decoration: none;
    color: var(--dark);
    box-shadow: 0 20px 50px rgba(15,23,42,.08);
    transition: .2s ease;
}

.gallery-card:hover {
    transform: translateY(-5px);
    color: var(--primary);
}

.gallery-card img {
    width: 100%;
    height: 260px;
    object-fit: cover;
    background: #e2e8f0;
}

.gallery-caption {
    padding: 18px;
}

.gallery-caption small {
    display: block;
    color: var(--muted);
}

.school-hero {
    min-height: 520px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
}

.school-hero-content {
    max-width: 740px;
    padding: 70px 0;
}

.school-logo-lg {
    width: 96px;
    height: 96px;
    border-radius: 28px;
    object-fit: cover;
    margin-bottom: 18px;
    background: white;
    padding: 8px;
}

.section-title {
    margin-bottom: 24px;
}

.section-title h2 {
    font-weight: 900;
}

.section-title p {
    color: var(--muted);
}

.footer-section {
    background: var(--dark);
    color: white;
}

/* ===============================
   Custom Map Marker with Logo
   =============================== */

.event-map-marker {
    background: transparent;
    border: 0;
}

.event-marker {
    width: 64px;
    height: 72px;
    position: relative;
}

.event-marker-pin {
    width: 64px;
    height: 64px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 10px 12px rgba(15, 23, 42, .35));
}

.event-marker-logo-wrap {
    position: absolute;
    top: 13px;
    left: 50%;
    transform: translateX(-50%);
    width: 31px;
    height: 31px;
    border-radius: 50%;
    background: #ffffff;
    display: grid;
    place-items: center;
    overflow: hidden;
    border: 2px solid rgba(255,255,255,.9);
    box-shadow: 0 2px 6px rgba(0,0,0,.22);
}

.event-marker-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.event-marker-label {
    position: absolute;
    left: 50%;
    bottom: 4px;
    transform: translateX(-50%);
    background: #ffffff;
    color: #0f172a;
    border-radius: 999px;
    padding: 2px 7px;
    font-size: 9px;
    line-height: 1.1;
    font-weight: 900;
    letter-spacing: .35px;
    box-shadow: 0 5px 12px rgba(15, 23, 42, .22);
    white-space: nowrap;
}

.event-marker-main .event-marker-label {
    background: var(--secondary);
    color: #0f172a;
}

.event-marker-school .event-marker-label {
    background: var(--primary);
    color: white;
}

.event-marker-user .event-marker-label {
    background: #22c55e;
    color: #052e16;
}

/* ===============================
   Route Summary Box on Map
   =============================== */

.route-summary-box {
    background: #ffffff;
    color: var(--dark);
    padding: 12px 14px;
    border-radius: 16px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .18);
    border: 1px solid var(--border);
    min-width: 230px;
    max-width: 280px;
}

.route-summary-box strong,
.route-summary-box span {
    display: block;
}

.route-summary-box strong {
    color: var(--primary);
    font-weight: 900;
}

.route-summary-box span {
    color: var(--muted);
    font-size: 13px;
    margin-top: 2px;
}

/* ===============================
   Responsive Design
   =============================== */

@media (max-width: 992px) {
    .hero-badge{
        margin-top: 20px;
        text-align: center;
    }
    .map-layout {
        grid-template-columns: 1fr;
    }

    #execonMap {
        min-height: 520px;
    }

    .timeline-item {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {

    .hero-badge{    
        margin-top: 20px;
    }
    .hero-section .display-4 {
        font-size: 2.2rem;
    }

    .page-heading {
        padding: 54px 0;
    }

    .video-placeholder {
        min-height: 280px;
    }

    .event-marker {
        width: 56px;
        height: 64px;
    }

    .event-marker-pin {
        width: 56px;
        height: 56px;
    }

    .event-marker-logo-wrap {
        top: 11px;
        width: 28px;
        height: 28px;
    }

    .event-marker-label {
        font-size: 8px;
        bottom: 5px;
    }

    .route-summary-box {
        min-width: 200px;
        max-width: 240px;
        font-size: 13px;
    }
}

/* ===============================
   Map Marker with Image and Name
   =============================== */

.event-map-marker {
    background: transparent;
    border: none;
}

.event-marker {
    width: 180px;
    min-height: 105px;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    pointer-events: auto;
}

.event-marker-pin-wrap {
    width: 66px;
    height: 72px;
    position: relative;
}

.event-marker-pin {
    width: 66px;
    height: 66px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 8px 12px rgba(15, 23, 42, .35));
}

.event-marker-image-wrap {
    position: absolute;
    top: 13px;
    left: 50%;
    transform: translateX(-50%);
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: white;
    overflow: hidden;
    border: 2px solid white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .25);
}

.event-marker-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.event-marker-name {
    margin-top: -2px;
    max-width: 175px;
    background: white;
    color: #0f172a;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 11px;
    line-height: 1.2;
    font-weight: 800;
    text-align: center;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .22);
    border: 1px solid #e2e8f0;
    white-space: normal;
}

.event-marker-main .event-marker-name {
    background: var(--secondary);
    color: #0f172a;
}

.event-marker-school .event-marker-name {
    background: var(--primary);
    color: white;
}

.event-marker-user .event-marker-name {
    background: #22c55e;
    color: #052e16;
}

/* Route box */

.route-summary-box {
    background: white;
    color: var(--dark);
    padding: 12px 14px;
    border-radius: 16px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .18);
    border: 1px solid var(--border);
    min-width: 230px;
    max-width: 280px;
}

.route-summary-box strong,
.route-summary-box span {
    display: block;
}

.route-summary-box strong {
    color: var(--primary);
    font-weight: 900;
}

.route-summary-box span {
    color: var(--muted);
    font-size: 13px;
    margin-top: 2px;
}

@media (max-width: 576px) {
    .event-marker {
        width: 145px;
    }

    .event-marker-pin-wrap {
        width: 58px;
        height: 64px;
    }

    .event-marker-pin {
        width: 58px;
        height: 58px;
    }

    .event-marker-image-wrap {
        top: 11px;
        width: 30px;
        height: 30px;
    }

    .event-marker-name {
        max-width: 140px;
        font-size: 9px;
        padding: 4px 8px;
    }
}

/* ===============================
   Map Marker with Different Colors
   =============================== */

.event-map-marker {
    background: transparent;
    border: none;
}

.event-marker {
    width: 180px;
    min-height: 105px;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    pointer-events: auto;
}

.event-marker-pin-wrap {
    width: 66px;
    height: 72px;
    position: relative;
}

/* This uses your marker image as a shape, then colors it */
.event-marker-pin {
    width: 66px;
    height: 66px;
    display: block;
    background: #1f8144;

    -webkit-mask-image: url('../img/map-marker.png');
    -webkit-mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;

    mask-image: url('../img/map-marker.png');
    mask-size: contain;
    mask-repeat: no-repeat;
    mask-position: center;

    filter: drop-shadow(0 8px 12px rgba(15, 23, 42, .35));
}

/* Image/logo inside marker */
.event-marker-image-wrap {
    position: absolute;
    top: 13px;
    left: 50%;
    transform: translateX(-50%);
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: white;
    overflow: hidden;
    border: 2px solid white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .25);
}

.event-marker-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Name below marker */
.event-marker-name {
    margin-top: -2px;
    max-width: 175px;
    background: white;
    color: #0f172a;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 11px;
    line-height: 1.2;
    font-weight: 800;
    text-align: center;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .22);
    border: 1px solid #e2e8f0;
    white-space: normal;
}

/* Main venue marker */
.event-marker-main .event-marker-pin {
    background: #facc15;
}

.event-marker-main .event-marker-name {
    background: #facc15;
    color: #0f172a;
}

/* School 1 marker */
.event-marker-school-1 .event-marker-pin {
    background: #1f8144;
}

.event-marker-school-1 .event-marker-name {
    background: #1f8144;
    color: white;
}

/* School 2 marker */
.event-marker-school-2 .event-marker-pin {
    background: #2563eb;
}

.event-marker-school-2 .event-marker-name {
    background: #2563eb;
    color: white;
}

/* School 3 marker */
.event-marker-school-3 .event-marker-pin {
    background: #dc2626;
}

.event-marker-school-3 .event-marker-name {
    background: #dc2626;
    color: white;
}

/* School 4 marker */
.event-marker-school-4 .event-marker-pin {
    background: #7c3aed;
}

.event-marker-school-4 .event-marker-name {
    background: #7c3aed;
    color: white;
}

/* User location marker */
.event-marker-user .event-marker-pin {
    background: #22c55e;
}

.event-marker-user .event-marker-name {
    background: #22c55e;
    color: #052e16;
}

/* Mobile marker size */
@media (max-width: 576px) {
    .event-marker {
        width: 145px;
    }

    .event-marker-pin-wrap {
        width: 58px;
        height: 64px;
    }

    .event-marker-pin {
        width: 58px;
        height: 58px;
    }

    .event-marker-image-wrap {
        top: 11px;
        width: 30px;
        height: 30px;
    }

    .event-marker-name {
        max-width: 140px;
        font-size: 9px;
        padding: 4px 8px;
    }
}

.navbar-logo {
    width: 42px;
    height: 42px;
    object-fit: contain;
}

@media (max-width: 576px) {
    .navbar-logo {
        width: 40px;
        height: 40px;
    }

    .navbar-brand span {
        font-size: 15px;
    }
}

.feature-card {
    height: 100%;
    padding: 0;
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid rgba(31, 129, 68, .18);
    box-shadow: 0 18px 45px rgba(15, 23, 42, .12);
    transition: .25s ease;
}

.feature-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 28px 65px rgba(15, 23, 42, .18);
}

.feature-img {
    width: 100%;
    height: 230px;
    object-fit: contain;
    display: block;
    padding: 18px;
    background: linear-gradient(135deg, #f8fafc, #ecfdf5);
}

.feature-body {
    padding: 26px 20px 28px;
}

.feature-card h4 {
    font-weight: 900;
    color: #0f172a;
    margin-bottom: 0;
}

.feature-btn {
    border-radius: 999px;
    padding: 10px 28px;
    font-weight: 800;
    color: white;
    background: #1f8144;
    border: none;
    box-shadow: 0 10px 22px rgba(31, 129, 68, .28);
}

.feature-btn:hover {
    background: #facc15;
    color: #0f172a;
}

/* Card background designs */
.feature-map {
    background: linear-gradient(180deg, #ffffff, #dcfce7);
}

.feature-program {
    background: linear-gradient(180deg, #ffffff, #fef9c3);
}

.feature-gallery {
    background: linear-gradient(180deg, #ffffff, #dbeafe);
}

@media (max-width: 576px) {
    .feature-img {
        height: 210px;
        padding: 14px;
    }

    .feature-body {
        padding: 22px 18px 24px;
    }

    .feature-card h4 {
        font-size: 1.2rem;
    }
}

/* ===============================
   Mobile Navbar Menu Button
   =============================== */

.menu-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    border-radius: 999px;
    border: 1px solid rgba(50, 230, 41, 0.85) !important;
    background: rgba(250, 204, 21, .14);
    color: white;
    font-weight: 900;
    letter-spacing: .4px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, .22);
    transition: .25s ease;
}

.menu-toggle:hover {
    background: var(--secondary);
    color: var(--dark);
    transform: translateY(-1px);
}

.menu-toggle:focus {
    box-shadow: 0 0 0 .25rem rgba(250, 204, 21, .35);
}

.menu-text {
    font-size: 14px;
    line-height: 1;
}

.menu-icon {
    width: 24px;
    height: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.menu-icon span {
    display: block;
    height: 3px;
    width: 100%;
    border-radius: 999px;
    background: currentColor;
    transition: .25s ease;
}

/* Turns hamburger into X when opened */
.menu-toggle:not(.collapsed) .menu-icon span:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
}

.menu-toggle:not(.collapsed) .menu-icon span:nth-child(2) {
    opacity: 0;
}

.menu-toggle:not(.collapsed) .menu-icon span:nth-child(3) {
    transform: translateY(-7.5px) rotate(-45deg);
}

/* Mobile dropdown menu design */
@media (max-width: 991.98px) {
    #mainNav {
        margin-top: 14px;
        padding: 14px;
        background: rgba(255, 255, 255, .10);
        border: 1px solid rgba(255, 255, 255, .18);
        border-radius: 20px;
        box-shadow: 0 18px 40px rgba(0, 0, 0, .18);
        backdrop-filter: blur(8px);
    }

    #mainNav .navbar-nav {
        gap: 8px;
    }

    #mainNav .nav-link {
        padding: 12px 14px;
        border-radius: 14px;
        color: white;
        font-weight: 700;
        background: rgba(255, 255, 255, .08);
    }

    #mainNav .nav-link:hover,
    #mainNav .nav-link.active {
        background: var(--secondary);
        color: var(--dark) !important;
    }
}