/* ==========================================================================
   PADMASHALI SEVA BHAVI SANSTHA - CSS Design System
   Traditional, Boxy, Trustworthy Newspaper & Ledger Aesthetic
   ========================================================================== */

/* 1. Imports & Core Variables */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Merriweather:ital,wght@0,300;0,400;0,700;1,300;1,400&display=swap');

:root {
    /* Color Palette - Traditional & Warm */
    --primary: #b91c1c;         /* Trustworthy Deep Crimson Red */
    --primary-dark: #7f1d1d;    /* Dark Crimson */
    --secondary: #b45309;       /* Warm Ochre/Gold */
    --secondary-light: #fef3c7; /* Light Warm Accent */
    --text-dark: #111827;       /* Deep Charcoal for High Contrast */
    --text-muted: #4b5563;      /* Muted charcoal */
    --bg-cream: #faf8f5;        /* Soft Cream Traditional Page Background */
    --bg-white: #ffffff;        /* Pure White for Inner Panels */
    --border-color: #2d3748;    /* Strong solid borders */
    
    /* Layout Constants */
    --border-thick: 3px solid var(--border-color);
    --border-thin: 1px solid var(--border-color);
    --border-double: 4px double var(--border-color);
    
    /* Typography */
    --font-heading: 'Merriweather', 'Georgia', serif;
    --font-body: 'Inter', 'Open Sans', sans-serif;
    
    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2.5rem;
    --space-xl: 4rem;
    
    /* Shadows - None or extremely flat */
    --shadow-flat: 2px 2px 0px 0px var(--border-color);
    --shadow-flat-large: 4px 4px 0px 0px var(--border-color);
}

/* 2. Base Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    border-radius: 0 !important; /* Force strict sharp boxy corners everywhere */
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-cream);
    color: var(--text-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* 3. Typography & General Layout */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-dark);
    margin-bottom: var(--space-sm);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; border-bottom: var(--border-thick); padding-bottom: 0.5rem; margin-bottom: var(--space-md); }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: var(--space-md);
}

a {
    color: var(--primary);
    text-decoration: underline;
    transition: color 0.15s ease;
}

a:hover {
    color: var(--primary-dark);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

/* 4. Top Announcement Notice & Registration Details */
.top-notice {
    background-color: var(--border-color);
    color: var(--bg-cream);
    font-size: 0.8rem;
    padding: 0.5rem 0;
    border-bottom: var(--border-thin);
}

.top-notice .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    max-width: 1400px;
    width: 100%;
}

.top-notice .info-group {
    display: flex;
    gap: var(--space-md);
    flex-wrap: wrap;
}

.top-notice span strong {
    color: var(--secondary-light);
}

/* 5. Header & Navigation */
header {
    background-color: var(--bg-white);
    border-bottom: var(--border-thick);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem var(--space-md);
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    gap: 2rem;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    text-decoration: none;
    color: var(--text-dark);
    flex-shrink: 0;
}

.logo-section img {
    height: 60px;
    width: auto;
    border: var(--border-thin);
}

.logo-section .title-group h1 {
    font-size: 1.3rem;
    margin-bottom: 0;
    font-family: var(--font-heading);
    color: var(--primary);
    letter-spacing: 0.5px;
}

.logo-section .title-group p {
    font-size: 0.75rem;
    margin-bottom: 0;
    color: var(--text-muted);
    font-weight: 600;
}

nav {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 1.25rem;
}

.nav-links a {
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 0.5rem 0.25rem;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
}

/* Highlighted Donate Button in Nav */
.nav-donate-btn {
    background-color: var(--primary);
    color: var(--bg-cream) !important;
    padding: 0.6rem 1.2rem !important;
    border: var(--border-thin);
    text-decoration: none !important;
    font-weight: bold !important;
    display: inline-block;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-donate-btn:hover {
    background-color: var(--border-color);
    color: var(--bg-cream) !important;
}

/* Mobile Menu Toggle Button */
.menu-toggle {
    display: none;
    background: none;
    border: var(--border-thin);
    padding: 0.5rem;
    cursor: pointer;
    font-weight: bold;
    font-family: var(--font-body);
}

/* 6. Buttons & Interactive Elements (Sharp Corners, Visible Borders) */
.btn {
    display: inline-block;
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    cursor: pointer;
    border: var(--border-thin);
    transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
    text-align: center;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--bg-cream);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    color: var(--bg-cream);
}

.btn-secondary {
    background-color: var(--secondary);
    color: var(--bg-cream);
}

.btn-secondary:hover {
    background-color: var(--border-color);
    color: var(--bg-cream);
}

.btn-outline {
    background-color: transparent;
    color: var(--text-dark);
    border: 2px solid var(--border-color);
}

.btn-outline:hover {
    background-color: var(--border-color);
    color: var(--bg-cream);
}

.btn-block {
    display: block;
    width: 100%;
}

.btn-group {
    display: flex;
    gap: var(--space-sm);
    flex-wrap: wrap;
}

/* 7. Hero Carousel / Slider Section */
.hero-slider {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    border-bottom: var(--border-thick);
    background-color: #000;
}

.slider-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.6s ease-in-out, visibility 0.6s ease-in-out;
    display: flex;
    align-items: center;
}

.slide.active {
    opacity: 1;
    visibility: visible;
    z-index: 10;
}

.slide-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.4); /* Darken image to read text clearly */
}

.slide-content {
    position: relative;
    z-index: 20;
    max-width: 750px;
    padding: var(--space-lg);
    background-color: rgba(17, 24, 39, 0.9); /* Solid administrative backing box */
    color: var(--bg-cream);
    border: 3px solid var(--secondary);
    margin-left: var(--space-xl);
}

.slide-content h2 {
    font-size: 2.2rem;
    color: var(--bg-cream);
    border-bottom: 2px solid var(--secondary);
    padding-bottom: 0.5rem;
    margin-bottom: var(--space-sm);
}

.slide-content p {
    font-size: 1.1rem;
    margin-bottom: var(--space-md);
}

/* Slider Controls */
.slider-control-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--bg-white);
    border: var(--border-thick);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    z-index: 30;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.slider-control-btn:hover {
    background-color: var(--primary);
    color: var(--bg-cream);
}

.slider-control-prev {
    left: 20px;
}

.slider-control-next {
    right: 20px;
}

/* 8. Common Section Layout (Traditional Panels) */
section {
    padding: var(--space-xl) 0;
    border-bottom: var(--border-thin);
}

.section-alt {
    background-color: var(--bg-white);
}

.section-title-wrapper {
    margin-bottom: var(--space-lg);
    text-align: center;
}

.section-title-wrapper h2 {
    display: inline-block;
    border-bottom: var(--border-thick);
    padding-bottom: 0.5rem;
    margin-bottom: var(--space-xs);
}

.section-title-wrapper p {
    font-style: italic;
    color: var(--text-muted);
}

/* Two column boxy layout */
.boxy-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-lg);
    align-items: stretch;
}

/* 9. Component Layouts */

/* Boxy Panels */
.boxy-panel {
    background-color: var(--bg-white);
    border: var(--border-thick);
    padding: var(--space-lg);
    box-shadow: var(--shadow-flat-large);
    height: 100%;
}

.boxy-panel-accent {
    background-color: var(--secondary-light);
    border: var(--border-thick);
    padding: var(--space-lg);
    box-shadow: var(--shadow-flat-large);
}

/* Rectangular Card Grid */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-md);
}

/* Rectangular Programs Cards */
.boxy-card {
    background-color: var(--bg-white);
    border: var(--border-thick);
    padding: var(--space-md);
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: transform 0.1s ease;
}

.boxy-card:hover {
    transform: translate(-2px, -2px);
    box-shadow: 4px 4px 0px 0px var(--border-color);
}

.boxy-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border: var(--border-thin);
    margin-bottom: var(--space-sm);
}

.boxy-card .card-icon {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: var(--space-xs);
}

.boxy-card h3 {
    margin-bottom: var(--space-xs);
    font-size: 1.3rem;
}

.boxy-card p {
    font-size: 0.95rem;
    color: var(--text-muted);
    flex-grow: 1;
}

.boxy-card .card-footer {
    margin-top: var(--space-sm);
    padding-top: var(--space-xs);
    border-top: var(--border-thin);
}

/* 10. Impact Statistics Counters */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: var(--space-md);
}

.stat-box {
    background-color: var(--bg-white);
    border: var(--border-thick);
    padding: var(--space-md);
    text-align: center;
    box-shadow: var(--shadow-flat);
}

.stat-number {
    font-family: var(--font-heading);
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* 11. Newspaper-Style Layout for Success Stories */
.newspaper-row {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: var(--space-lg);
    border: var(--border-thick);
    background-color: var(--bg-white);
    padding: var(--space-lg);
}

.newspaper-col-main {
    border-right: var(--border-thin);
    padding-right: var(--space-lg);
}

.newspaper-col-side {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.newspaper-headline {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    line-height: 1.1;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: var(--space-sm);
    text-transform: uppercase;
}

.newspaper-meta {
    font-size: 0.8rem;
    font-weight: bold;
    color: var(--text-muted);
    border-top: var(--border-thin);
    border-bottom: var(--border-thin);
    padding: 0.4rem 0;
    margin-bottom: var(--space-md);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.newspaper-lead {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: var(--space-md);
    line-height: 1.5;
}

.newspaper-body-columns {
    column-count: 2;
    column-gap: var(--space-md);
    text-align: justify;
    font-size: 0.95rem;
}

.newspaper-side-img {
    width: 100%;
    height: auto;
    border: var(--border-thin);
    margin-bottom: var(--space-sm);
}

.newspaper-side-quote {
    font-family: var(--font-heading);
    font-style: italic;
    font-size: 1.15rem;
    color: var(--primary);
    border-left: 4px solid var(--primary);
    padding-left: var(--space-sm);
    margin: var(--space-sm) 0;
}

/* 12. Testimonials (Traditional Cards) */
.testimonial-card {
    background-color: var(--bg-white);
    border: var(--border-thin);
    padding: var(--space-md);
    position: relative;
    border-left: 5px solid var(--primary);
}

.testimonial-text {
    font-style: italic;
    font-size: 0.95rem;
    margin-bottom: var(--space-sm);
}

.testimonial-author {
    font-weight: bold;
    font-size: 0.9rem;
    color: var(--text-dark);
}

.testimonial-role {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* 13. Events Grid */
.event-row {
    display: flex;
    border: var(--border-thin);
    background-color: var(--bg-white);
    margin-bottom: var(--space-sm);
    transition: transform 0.1s ease;
}

.event-row:hover {
    transform: translate(-1px, -1px);
    box-shadow: var(--shadow-flat);
}

.event-date-box {
    background-color: var(--border-color);
    color: var(--bg-cream);
    width: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    text-align: center;
    padding: var(--space-xs);
}

.event-date-day {
    font-size: 1.8rem;
    font-weight: bold;
}

.event-date-month {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.event-details {
    padding: var(--space-md);
    flex-grow: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-md);
}

.event-info h3 {
    margin-bottom: 0.25rem;
    font-size: 1.2rem;
}

.event-meta {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.event-meta span {
    margin-right: var(--space-sm);
}

/* 14. Photo Gallery & Lightbox */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: var(--space-sm);
}

.gallery-item {
    position: relative;
    border: var(--border-thin);
    overflow: hidden;
    cursor: pointer;
    background-color: #000;
}

.gallery-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: filter 0.2s ease;
}

.gallery-item:hover img {
    filter: brightness(0.7);
}

.gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(17, 24, 39, 0.95);
    color: var(--bg-cream);
    padding: 0.5rem;
    font-size: 0.85rem;
    border-top: var(--border-thin);
    text-align: center;
    transform: translateY(100%);
    transition: transform 0.2s ease;
}

.gallery-item:hover .gallery-caption {
    transform: translateY(0);
}

/* Traditional Lightbox Modal */
.lightbox-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(17, 24, 39, 0.98);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
}

.lightbox-content {
    max-width: 90%;
    max-height: 85%;
    border: 3px solid var(--bg-cream);
    position: relative;
    background-color: #000;
}

.lightbox-content img {
    display: block;
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
}

.lightbox-caption {
    color: var(--bg-cream);
    padding: var(--space-sm);
    text-align: center;
    font-family: var(--font-heading);
    border-top: 1px solid #444;
    background-color: var(--text-dark);
}

.lightbox-close {
    position: absolute;
    top: -45px;
    right: 0;
    color: var(--bg-cream);
    font-size: 2rem;
    cursor: pointer;
    font-weight: bold;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: var(--bg-cream);
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--bg-cream);
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.lightbox-prev { left: -50px; }
.lightbox-next { right: -50px; }

/* 15. Form Elements (Sharp Borders) */
.form-group {
    margin-bottom: var(--space-md);
}

.form-group label {
    display: block;
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
    text-transform: uppercase;
    color: var(--text-dark);
}

.form-control {
    width: 100%;
    font-family: var(--font-body);
    font-size: 0.95rem;
    padding: 0.7rem var(--space-sm);
    border: var(--border-thick);
    background-color: var(--bg-white);
    color: var(--text-dark);
    outline: none;
}

.form-control:focus {
    border-color: var(--primary);
    background-color: #fff;
    box-shadow: 2px 2px 0px 0px var(--primary);
}

select.form-control {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%232d3748' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 16px;
    padding-right: 2.5rem;
    cursor: pointer;
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

.form-checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: var(--space-xs);
    margin-bottom: var(--space-md);
}

.form-checkbox-group input[type="checkbox"] {
    margin-top: 0.35rem;
    width: 18px;
    height: 18px;
    border: var(--border-thick);
    cursor: pointer;
    flex-shrink: 0;
}

.form-checkbox-group label {
    font-weight: normal;
    text-transform: none;
    font-size: 0.9rem;
    cursor: pointer;
}

/* Form Success & Error Panels */
.alert-box {
    padding: var(--space-sm) var(--space-md);
    border: var(--border-thick);
    margin-bottom: var(--space-md);
    font-weight: 600;
}

.alert-success {
    background-color: #d1fae5;
    border-color: #065f46;
    color: #065f46;
}

.alert-warning {
    background-color: #fef3c7;
    border-color: #92400e;
    color: #92400e;
}

/* 16. Donation CTA Banner & Donation Page Elements */
.cta-box {
    background-color: var(--secondary-light);
    border: 4px double var(--border-color);
    padding: var(--space-lg) var(--space-md);
    text-align: center;
}

.cta-box h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    margin-bottom: var(--space-sm);
    border-bottom: none;
    padding-bottom: 0;
}

.cta-box p {
    font-size: 1.15rem;
    max-width: 800px;
    margin: 0 auto var(--space-md) auto;
}

.donate-options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: var(--space-sm);
    margin-bottom: var(--space-md);
}

.donate-option-card {
    border: var(--border-thick);
    background-color: var(--bg-white);
    padding: var(--space-sm);
    text-align: center;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.1s ease, color 0.1s ease;
}

.donate-option-card.active,
.donate-option-card:hover {
    background-color: var(--primary);
    color: var(--bg-cream);
    border-color: var(--primary);
}

.donate-option-card span {
    display: block;
    font-size: 1.4rem;
    font-family: var(--font-heading);
}

.bank-details-box {
    background-color: var(--bg-white);
    border: var(--border-thick);
    padding: var(--space-md);
    font-family: monospace;
    font-size: 0.95rem;
}

.bank-details-box table {
    width: 100%;
    border-collapse: collapse;
}

.bank-details-box td {
    padding: 0.5rem;
    border-bottom: 1px solid #ddd;
}

.bank-details-box td:first-child {
    font-weight: bold;
    width: 150px;
}

/* Accordion FAQs */
.accordion {
    border: var(--border-thick);
    background-color: var(--bg-white);
}

.accordion-item {
    border-bottom: var(--border-thin);
}

.accordion-item:last-child {
    border-bottom: none;
}

.accordion-header {
    background-color: var(--bg-cream);
    padding: var(--space-sm) var(--space-md);
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: var(--border-thin);
}

.accordion-header::after {
    content: '+';
    font-size: 1.4rem;
}

.accordion-item.active .accordion-header::after {
    content: '-';
}

.accordion-content {
    padding: var(--space-md);
    display: none;
}

.accordion-item.active .accordion-content {
    display: block;
}

/* 17. Footer Layout */
footer {
    background-color: var(--text-dark);
    color: var(--bg-cream);
    border-top: var(--border-thick);
    padding: var(--space-xl) 0 var(--space-md) 0;
    font-size: 0.9rem;
}

footer a {
    color: var(--bg-cream);
    text-decoration: none;
    border-bottom: 1px solid transparent;
}

footer a:hover {
    color: var(--secondary-light);
    border-bottom-color: var(--secondary-light);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 2fr;
    gap: var(--space-lg);
    margin-bottom: var(--space-lg);
    border-bottom: var(--border-thin);
    padding-bottom: var(--space-lg);
}

.footer-col h3 {
    color: var(--bg-cream);
    border-bottom: 2px solid var(--secondary);
    padding-bottom: 0.35rem;
    margin-bottom: var(--space-sm);
    font-size: 1.15rem;
    text-transform: uppercase;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: var(--space-xs);
}

.footer-col p {
    margin-bottom: var(--space-sm);
    color: #d1d5db;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    margin-bottom: var(--space-sm);
}

.footer-logo img {
    height: 45px;
    border: var(--border-thin);
    background-color: var(--bg-white);
}

.footer-logo h2 {
    font-size: 1.1rem;
    color: var(--bg-cream);
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 0;
}

.social-links {
    display: flex;
    gap: var(--space-sm);
    margin-top: var(--space-sm);
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    border: 1px solid var(--bg-cream);
    background-color: transparent;
    font-weight: bold;
    text-decoration: none;
}

.social-icon:hover {
    background-color: var(--primary);
    border-color: var(--primary);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-md);
    color: #9ca3af;
    font-size: 0.8rem;
}

.footer-bottom .right-links {
    display: flex;
    gap: var(--space-md);
}

/* 18. Responsive Overrides (Desktop First) */

@media (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 1120px) {
    .header-main {
        padding: 0.5rem var(--space-sm);
        gap: 1rem;
    }
    
    .logo-section img {
        height: 50px;
    }
    
    .logo-section .title-group h1 {
        font-size: 1.05rem;
    }
    
    .menu-toggle {
        display: block;
    }
    
    nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--bg-white);
        border-top: var(--border-thin);
        border-bottom: var(--border-thick);
        flex-direction: column;
        align-items: stretch;
        padding: var(--space-sm);
        gap: var(--space-sm);
        display: none; /* JS will toggle block */
        z-index: 99;
    }
    
    nav.active {
        display: flex;
    }
    
    .nav-links {
        flex-direction: column;
        gap: var(--space-xs);
        text-align: center;
    }
    
    .nav-links a {
        display: block;
        padding: 0.5rem;
    }
    
    .nav-donate-btn {
        text-align: center;
        width: 100%;
    }
}

@media (max-width: 992px) {
    .boxy-grid-2 {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }
}

@media (max-width: 768px) {

    /* HTML and Body Overflow Reset */
    html, body {
        overflow-x: hidden;
        width: 100%;
    }

    /* Top Notice Bar Grid Layout (Mobile: 3 rows, 2 columns) */
    .top-notice .container {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 0.5rem 0.75rem !important;
        padding: 0.5rem var(--space-sm) !important;
        justify-content: stretch !important;
        align-items: center !important;
        width: 100% !important;
    }
    
    .top-notice .info-group {
        display: contents !important;
    }

    .top-notice span,
    .top-notice #google_translate_element {
        font-size: 0.72rem !important;
        line-height: 1.3 !important;
        display: block !important;
    }

    .top-notice #google_translate_element {
        width: 100% !important;
        text-align: right !important;
    }

    .goog-te-gadget .goog-te-combo {
        width: 100% !important;
        max-width: 100% !important;
        padding: 2px 4px !important;
        font-size: 0.7rem !important;
    }

    /* Align left column (odd positions) left, right column (even positions) right */
    .top-notice .info-group:first-child span:nth-child(1),
    .top-notice .info-group:first-child span:nth-child(3),
    .top-notice .info-group:last-child span:nth-child(1) {
        text-align: left !important;
    }

    .top-notice .info-group:first-child span:nth-child(2),
    .top-notice .info-group:first-child span:nth-child(4),
    .top-notice .info-group:last-child #google_translate_element {
        text-align: right !important;
        justify-self: end !important;
    }

    /* Mobile Header Layout (Shrink logo sections to fit small screens) */
    .logo-section {
        flex-shrink: 1 !important;
    }
    
    .logo-section img {
        height: 45px !important;
    }
    
    .logo-section .title-group h1 {
        font-size: 0.95rem !important;
    }
    
    .logo-section .title-group p {
        font-size: 0.65rem !important;
    }
    
    .header-main {
        padding: 0.5rem var(--space-sm) !important;
        gap: 0.5rem !important;
    }

    /* Hero Slide Content Width constraint to prevent horizontal scrolling */
    .slide-content {
        width: calc(100% - 2 * var(--space-sm)) !important;
        margin-left: var(--space-sm) !important;
        margin-right: var(--space-sm) !important;
    }

    /* Events Listing Mobile Stacking */
    .event-row {
        flex-direction: column !important;
    }
    
    .event-date-box {
        width: 100% !important;
        flex-direction: row !important;
        gap: 0.5rem !important;
        padding: 0.5rem !important;
        justify-content: center !important;
    }
    
    .event-details {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 1rem !important;
        padding: 1rem !important;
    }
    
    .event-details .btn {
        width: 100% !important;
        text-align: center !important;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.6rem; }
    
    .hero-slider {
        height: 400px;
    }
    
    .slide-content {
        margin-left: var(--space-sm);
        margin-right: var(--space-sm);
        padding: var(--space-sm);
    }
    
    .slide-content h2 {
        font-size: 1.5rem;
    }
    
    .slide-content p {
        font-size: 0.95rem;
    }
    
    .boxy-grid-2 {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }
    
    .newspaper-row {
        grid-template-columns: 1fr;
        padding: var(--space-sm);
    }
    
    .newspaper-col-main {
        border-right: none;
        border-bottom: var(--border-thin);
        padding-right: 0;
        padding-bottom: var(--space-md);
    }
    
    .newspaper-body-columns {
        column-count: 1;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-bottom .right-links {
        justify-content: center;
        width: 100%;
    }

    /* Stack bank details layout on mobile devices */
    .bank-details-box td {
        display: block;
        width: 100% !important;
        padding: 0.35rem 0.5rem;
        border-bottom: none;
    }
    
    .bank-details-box td:first-child {
        font-weight: bold;
        width: 100% !important;
        padding-top: 0.6rem;
        font-size: 0.85rem;
        color: var(--text-muted);
        border-bottom: none;
    }
    
    .bank-details-box td:last-child {
        padding-bottom: 0.6rem;
        border-bottom: 1px solid #ddd;
        font-weight: bold;
    }
    
    .bank-details-box tr:last-child td:last-child {
        border-bottom: none;
    }
}

/* ==========================================================================
   Responsive Table Utilities
   ========================================================================== */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: var(--border-thick);
    margin-bottom: var(--space-md);
    background-color: var(--bg-white);
}

.table-traditional {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.95rem;
    min-width: 650px; /* Triggers local horizontal scrolling inside table-responsive box on narrow screens */
}

.table-traditional th,
.table-traditional td {
    padding: var(--space-sm);
    border: var(--border-thin);
    vertical-align: top;
}

.table-traditional th {
    background-color: var(--border-color);
    color: var(--bg-cream);
    font-family: var(--font-heading);
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.table-traditional tr:nth-child(even) {
    background-color: var(--bg-cream);
}

/* ==========================================================================
   Google Translate Styling
   ========================================================================== */
#google_translate_element {
    display: inline-block;
    vertical-align: middle;
}

/* Customize Translate Dropdown styling to match our boxy ledger theme */
.goog-te-gadget {
    font-family: var(--font-body) !important;
    font-size: 0.75rem !important;
    color: transparent !important;
}

.goog-te-gadget .goog-te-combo {
    margin: 0 !important;
    padding: 3px 6px !important;
    background-color: var(--bg-cream) !important;
    color: var(--text-dark) !important;
    border: 1px solid var(--border-color) !important;
    font-family: var(--font-body) !important;
    font-size: 0.75rem !important;
    font-weight: 600 !important;
    outline: none !important;
}

.goog-te-gadget a, .goog-logo-link {
    display: none !important;
}

.goog-te-banner-frame.skiptranslate {
    display: none !important;
}

body {
    top: 0px !important;
}

/* ==========================================================================
   Floating Action Buttons (WhatsApp & Scroll-to-Top)
   ========================================================================== */
.whatsapp-float {
    position: fixed;
    bottom: 25px;
    left: 25px;
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: #fff;
    border-radius: 50% !important; /* Override reset */
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: transform 0.2s ease, background-color 0.2s ease;
    cursor: pointer;
    text-decoration: none;
}

.whatsapp-float:hover {
    background-color: #128c7e;
    transform: scale(1.1);
    color: #fff;
}

.whatsapp-float svg {
    width: 32px;
    height: 32px;
    fill: currentColor;
}

.scroll-to-top {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 50px;
    height: 50px;
    background-color: var(--primary);
    color: var(--bg-cream);
    border: 2px solid var(--border-color);
    border-radius: 50% !important; /* Override reset */
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.2s ease, background-color 0.2s ease;
}

.scroll-to-top:hover {
    background-color: var(--border-color);
    color: var(--bg-cream);
    transform: scale(1.1);
}

.scroll-to-top.show {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top svg {
    width: 24px;
    height: 24px;
}

/* 19. Developer Note Style */
.developer-note {
    background-color: var(--bg-cream);
    border-top: var(--border-thin);
    text-align: center;
    padding: 0.5rem 0;
    font-size: 0.85rem;
    font-family: var(--font-body);
    color: var(--text-muted);
}
.developer-note p {
    margin: 0;
}
.developer-note a {
    color: var(--primary);
    text-decoration: none;
    font-weight: bold;
}
.developer-note a:hover {
    text-decoration: underline;
    color: var(--primary-dark);
}

