:root {
    --primary: #ec7505ff;
    --secondary-dark: #171614ff;
    --text-color: #b22222;
    --background: linear-gradient(#fffdf7, #fff);
    --dark: #000000ff;
    --light: #ffffffff;
}

/* 0. CSS Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: var(--background);
}

/* Header Styling Starts */

header {
    background-color: var(--secondary-dark);
    color: var(--light);
    display: flex;
    align-items: center;
    font-family: "Noto Serif", serif;
    font-size: larger;
    justify-content: space-between;
    height: 60px;
    padding: 0 20px;
}

header .logo {
    color: var(--text-colour);
    font-family: "Graduate", serif;
    font-weight: 400;
}

header .logo img {
    width: 200px;
}

.mobile-logo {
    display: none;
    margin: 27px 7px;
    color: var(--text-colour);
    font-family: "Graduate", serif;
    font-weight: 400;
}


.desktop-logo { display: block; }
.mobile-logo { display: none; }

@media (max-width: 678px) {
  .desktop-logo { display: none; }
  .mobile-logo { display: block; }
}

.social-media-icons {
    display: flex;
    flex-direction: row;
    align-items: center;
}
/* Hide mobile-only donate link on desktop */
.mobile-donate-link {
    display: none;
}

header nav {
    display: flex;
    align-items: center;
    height: 100%;
}

.links {
    display: flex;
    flex-direction: row;
    align-items: center;
    height: 100%;
    font-weight: 400;
}

.links a:hover {
    color: var(--primary);
    transition: 0.4s ease-in-out;
}

.links a {
    position: relative;
    /* This is crucial for positioning the pseudo-element */
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 12px;
    text-decoration: none;
    color: var(--light);
    /* No hover effect here, it will be handled by the pseudo-element */
}

/* Creating the underline effect */
.links a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background-color: var(--primary);
    transition: width 0.3s ease-in-out;
}

.links a:hover::before {
    width: 100%;
}

header i {
    color: var(--light);
}

#sidebar-active {
    display: none;
}

.open-sidebar,
.close-sidebar {
    display: none;
}

header .desktop-donate-link {
    color: var(--light);
    text-decoration: none;
    background: var(--primary);
    padding: 7px 12px;
    border-radius: 4px;
    border: 1px solid black;
    transition: 0.4s ease-in-out;
    height: auto;
}

header .desktop-donate-link:hover {
    position: relative;
    overflow: hidden;
    color: var(--light);
}

header .desktop-donate-link:hover::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -60%;
    width: 20px;
    height: 200%;
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(30deg);
    animation: glassShine 4s infinite;
}

@keyframes glassShine {
    0% {
        left: -60%;
    }

    20% {
        left: 120%;
    }

    100% {
        left: 120%;
    }
}

@keyframes shine {
    to {
        background-position: 200% center;
    }
}

/* === Mobile Styles === */
@media screen and (max-width: 757px) {

    /* Hide the main navigation links from the header */
    .links {
        display: none;
    }

    /* New layout for header items */
    header nav {
        order: 1;
        /* Left item (Hamburger) */
    }

    .logo {
        order: 2;
        /* Center item */
        padding-left: 0;
        position: absolute;
        left: 62%;
        transform: translateX(-50%);
        width: 200px;
    }

    header .logo img {
        width: 62px;
    }

    .mobile-donate-link {
        display: block;
        /* Show this link only on mobile */
        order: 3;
        /* Right item (Home) */
        color: var(--light);
        text-decoration: none;
        background: var(--primary);
        padding: 7px 2px;
        border-radius: 4px;
        border: 1px solid black;
        transition: 0.4s ease-in-out;
        font-size: medium;
    }

    .mobile-donate-link:hover {
        position: relative;
        overflow: hidden;
        color: var(--light);
    }

    .mobile-donate-link:hover::after {
        content: '';
        position: absolute;
        top: -50%;
        left: -60%;
        width: 20px;
        height: 200%;
        background: rgba(255, 255, 255, 0.3);
        transform: rotate(30deg);
        animation: glassShine 4s infinite;
    }

    header .desktop-donate-link {
        display: none !important;
        color: var(--light);
        text-decoration: none;
    }

    /* Sidebar styles */
    .links {
        display: flex;
        /* Overwrite the "none" when sidebar is active */
        flex-direction: column;
        justify-content: flex-start;
        align-items: flex-start;
        position: fixed;
        top: 0;
        left: -100%;
        width: 300px;
        height: 100vh;
        z-index: 9999;
        background: var(--secondary-dark);
        box-shadow: 2px 6px 10px black;
        transition: 0.7s ease-in-out;
    }

    .links a,
    .links .mobile-logo {
        display: block;
        border-bottom: 1px solid rgb(61, 36, 36);
        box-sizing: border-box;
        height: auto;
        width: 100%;
        padding: 22px 17px;
        transition: 0.4s ease-in-out;
    }

    /* Removing hover effect on mobile sidebar links */
    .links a:hover {
        transform: scale(1.07);
        background-color: transparent;
    }

    /* Disabling the underline effect on mobile */
    .links a::before,
    .links a:hover::before {
        display: none;
    }

    .open-sidebar,
    .close-sidebar {
        display: block;
        padding: 0;
        cursor: pointer;
    }

    .close-sidebar {
        align-self: flex-start;
        padding: 22px 17px;
    }

    #sidebar-active:checked~.links {
        left: 0;
        display: flex;
        /* Ensure it's visible when checked */
    }

    #sidebar-active:checked~#close-overlay {
        height: 100%;
        width: 100%;
        position: fixed;
        top: 0;
        right: 0;
        z-index: 7;
    }
}

@media screen and (max-width: 417px) {
    .links {
        width: 100vw;
    }

    .links a {
        justify-content: flex-start;
    }

    .mobile-logo {
        display: block;
    }
}

/* Header Styling Ends */

/* Footer Styling Start  */
/* Footer Base */
.site-footer {
    position: relative;
    background: var(--secondary-dark);
    color: var(--light);
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji";
    overflow: clip;
}

/* Animated top ribbon */
.site-footer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--text-color), var(--primary));
    background-size: 200% 100%;
    animation: ribbon-move 10s linear infinite;
    opacity: 0.9;
}

@keyframes ribbon-move {
    0% {
        background-position: 0% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

.footer-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 56px 20px 36px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 28px 24px;
}

/* Grid responsive */
@media (min-width: 640px) {
    .footer-wrap {
        grid-template-columns: 1.2fr 1fr;
    }
}

@media (min-width: 900px) {
    .footer-wrap {
        grid-template-columns: 1.2fr 1fr 1fr 1fr;
    }
}

/* Brand */
.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--light);
    text-decoration: none;
    font-weight: 800;
    font-size: 1.25rem;
}



.brand-mark {
    position: relative;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary);
    color: var(--secondary-dark);
    font-weight: 900;
    font-size: 1.05rem;
    box-shadow: 0 6px 24px -10px rgba(236, 117, 5, 0.65);
}

.brand-mark::before {
    content: "";
    position: absolute;
    inset: -5px;
    border-radius: 50%;
    border: 2px solid rgba(236, 117, 5, 0.45);
    animation: pulse 2.6s ease-in-out infinite;
}

/* @keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.9;
    }

    70% {
        transform: scale(1.15);
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
} */

.tagline {
    margin-top: 8px;
    color: rgba(255, 255, 255, 0.78);
    max-width: 42ch;
    line-height: 1.6;
}

/* Titles */
.footer-title {
    font-size: 1rem;
    font-weight: 800;
    color: var(--light);
    margin: 0 0 12px;
    letter-spacing: 0.2px;
}

.footer-title::after {
    content: "";
    display: block;
    width: 36px;
    height: 2px;
    background: var(--primary);
    margin-top: 8px;
    border-radius: 2px;
}

/* Lists and links */
.list-unstyled {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 10px;
}

.site-footer a {
    color: rgba(255, 255, 255, 0.92);
    text-decoration: none;
    position: relative;
    transition: color .25s ease, opacity .25s ease, transform .25s ease;
}

.site-footer a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0%;
    height: 2px;
    background: var(--primary);
    transition: width .25s ease;
    border-radius: 1px;
}

.site-footer a:hover {
    color: var(--primary);
}

.site-footer a:hover::after {
    width: 100%;
}

.site-footer a:focus-visible {
    outline: 2px dashed var(--primary);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Contact */
.contact-list li {
    display: grid;
    grid-template-columns: 20px 1fr;
    align-items: start;
    gap: 12px;
}

.contact-list address {
    font-style: normal;
    color: rgba(255, 255, 255, 0.86);
}

/* Map Embed */
.map-wrap {
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.04);
    box-shadow: 0 12px 32px -14px rgba(0, 0, 0, 0.6);
    aspect-ratio: 16 / 10;
    transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}

.map-wrap:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 40px -18px rgba(0, 0, 0, 0.75);
    border-color: rgba(236, 117, 5, 0.5);
}

.map-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(120% 120% at 0% 0%, rgba(236, 117, 5, 0.15), transparent 50%);
    opacity: .6;
    transition: opacity .3s ease;
}

.map-wrap:hover::after {
    opacity: .85;
}

.map-wrap iframe {
    width: 100%;
    height: 100%;
    border: 0;
    filter: saturate(1.05) contrast(1.02);
}

/* Bottom bar */
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    margin-top: 10px;
    padding: 16px 20px 24px;
    /* max-width: 1200px; */
    margin-left: auto;
    margin-right: auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    align-items: center;
    grid-template-columns: 1fr auto;
}

@media (max-width: 640px) {
    .footer-bottom {
        text-align: center;
        grid-template-columns: auto;
    }
}

.credit {
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {

    .site-footer::before,
    .brand-mark::before,
    .reveal,
    .map-wrap {
        animation: none !important;
        transition: none !important;
        transform: none !important;
    }
}

@media screen and (max-width) {
    .brand img {
        width: 157px;
    }
}

.brand img {
    width: 200px;
}
/* Footer Styling Ends */