/* ================================= GLOBAL / RESET ================================= */

/* CRITICAL FIX: This ensures padding doesn't make elements wider than 100% */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

h1, h2, h3, h4, h5, h6,
.heading-font, .section-title, .featured-title, .campaign-title,
.btn, button, .raised, .campaign-count, .featured-badge, .pagination-number {
    font-family: "Poppins", sans-serif;
    letter-spacing: -0.01em; 
}

/* 2. Secondary Font: Lato (Body text, inputs, small UI) */
body, p, a, li, span, input, select, textarea, label,
.body-font, .section-desc, .featured-desc, .filters-label, .goal, .pagination-info {
    font-family: "Lato", sans-serif;
    font-weight: 400;
    text-decoration: none;
}

/* ================================= CAMPAIGN SECTION WRAPPERS ================================= */

.campaigns-section {
    background: #f8fafc;
    padding: 2px 0;
    border-bottom: 1px solid #e2e8f0;
}

.tk-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    width: 100%;
    position: relative;
}

/* ================================= SECTION HEADER ================================= */

.tk-section-header {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 40px;
    margin-top: 32px;
    width: 100%;
}

.tk-section-header-left {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

.section-title {
    font-size: clamp(26px, 4vw, 36px);
    font-weight: 800;
    color: #1e293b;
    margin: 0;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.section-desc {
    color: #64748b;
    margin: 0;
    line-height: 1.6;
    font-size: clamp(15px, 2vw, 17px);
}

.btn.create-campaign {
    background: #4f46e5;
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: clamp(12px, 2vw, 14px) clamp(20px, 2vw, 24px);
    font-size: clamp(14px, 2vw, 15px);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.3);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
}

.btn.create-campaign i { font-size: 18px; }

.btn.create-campaign:hover,
.btn.create-campaign:focus {
    background: #4338ca;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.4);
}

/* ================================= FEATURED PROGRAM ================================= */

.tk-featured-program {
    margin: 0 0 48px 0;
    display: flex;
    justify-content: center;
    width: 100%;
}

.tk-featured-card {
    width: 100%;
    max-width: 1200px;
    background: #fff;
    border-radius: 24px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.01);
    overflow: hidden;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    border: 1px solid #f1f5f9;
    transition: transform 0.3s ease;
}

/* FIX: Image Zooming on Featured Card */
.featured-img {
    width: 100%;
    /* Removed fixed height clamp which caused cropping/zooming */
    height: auto; 
    /* Enforces a wide cinematic ratio that scales proportionally */
    aspect-ratio: 21 / 9; 
    object-fit: cover;
    border-radius: 24px 24px 0 0;
}

.tk-featured-content {
    padding: clamp(24px, 3vw, 40px);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.tk-featured-content-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.featured-badge {
    background: #eef2ff;
    color: #4f46e5;
    font-weight: 700;
    font-size: 12px;
    border-radius: 99px;
    padding: 8px 16px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border: 1px solid #e0e7ff;
}

.featured-views {
    color: #64748b;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
}

.featured-title {
    font-size: clamp(24px, 3vw, 32px);
    font-family: "Poppins", sans-serif;
    font-weight: 700;
    margin: 0;
    color: #1e293b;
    line-height: 1.3;
}

.featured-desc {
    color: #475569;
    font-size: clamp(16px, 2vw, 17px);
    line-height: 1.7;
    margin: 0;
}
    
.tk-featured-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 12px;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.btn.featured-support {
    background: #4f46e5;
    color: #fff;
    border: none;
    border-radius: 12px;
    padding: 14px 28px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.2);
}

.btn.featured-support:hover {
    background: #4338ca;
    transform: translateY(-2px);
    box-shadow: 0 8px 12px -1px rgba(79, 70, 229, 0.3);
}

.btn.featured-share {
    background: #fff;
    color: #4f46e5;
    border: 1px solid #e2e8f0;
    padding: 14px 20px;
    border-radius: 12px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 600;
}

.btn.featured-share:hover {
    border-color: #4f46e5;
    background: #f5f3ff;
    transform: translateY(-2px);
}

/* ================================= MAIN LAYOUT ================================= */

.tk-campaigns-layout {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    width: 100%;
}

/* ================================= FILTERS SIDEBAR ================================= */

.tk-filters-sidebar {
    width: 280px;
    background: #fff;
    border-radius: 16px;
    border: 1px solid #f1f5f9;
    padding: 32px 24px;
    display: flex;
    flex-direction: column;
    gap: 28px;
    position: sticky;
    top: 24px;
    flex-shrink: 0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02);
}

.filters-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 18px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

.filters-reset {
    color: #4f46e5;
    font-size: 13px;
    background: none;
    border: none;
    font-weight: 600;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: background 0.2s;
}

.filters-reset:hover { background: #eef2ff; text-decoration: none; }

.filters-group { display: flex; flex-direction: column; gap: 12px; }

.filters-label {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.filter-checkbox {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 15px;
    margin: 4px 0;
    cursor: pointer;
    padding: 4px 0;
    transition: color 0.2s;
}

.filter-checkbox:hover label { color: #4f46e5; }

.filter-checkbox input[type="checkbox"] {
    accent-color: #4f46e5;
    width: 18px;
    height: 18px;
    cursor: pointer;
    border-radius: 4px;
}

.filter-checkbox label {
    cursor: pointer;
    color: #475569;
    flex: 1;
    transition: color 0.2s;
    font-weight: 500;
}

.filter-checkbox span {
    color: #94a3b8;
    font-size: 13px;
    font-weight: 500;
    background: #f1f5f9;
    padding: 2px 8px;
    border-radius: 10px;
}

.btn.filter-apply {
    background: #4f46e5;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: 10px;
    padding: 14px 0;
    margin-top: 12px;
    cursor: pointer;
    transition: all 0.2s;
    width: 100%;
    box-shadow: 0 2px 4px rgba(79, 70, 229, 0.2);
}

.btn.filter-apply:hover {
    background: #4338ca;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(79, 70, 229, 0.3);
}

/* ================================= CAMPAIGNS MAIN AREA ================================= */

.tk-campaigns-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    border: 1px solid #e2e8f0;
    overflow: hidden; /* Important for containing children */
    margin-bottom: 4rem;
    width: 100%;
}

/* ================================= ENHANCED TOOLBAR ================================= */

.tk-campaigns-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px; 
    padding: 24px 32px;
    background: #fff;
    border-bottom: 1px solid #f1f5f9;
    flex-wrap: wrap; 
    width: 100%;
    z-index: 5;
}

.campaign-count {
    font-size: 15px;
    color: #334155;
    font-weight: 600;
    background: #f1f5f9;
    padding: 8px 16px;
    border-radius: 99px;
    border: 1px solid #e2e8f0;
    white-space: nowrap;
}

.tk-campaign-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: flex-end;
    flex: 1;
}

.toolbar-sort, .toolbar-perpage {
    display: flex;
    align-items: center;
    gap: 12px;
}

.toolbar-sort label, .toolbar-perpage label {
    font-size: 14px;
    color: #64748b;
    font-weight: 600;
    white-space: nowrap;
}

.toolbar-sort select, .toolbar-perpage select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-color: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 10px 40px 10px 16px;
    font-size: 14px;
    color: #334155;
    font-weight: 500;
    outline: none;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 42px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    max-width: 100%; 
}

.toolbar-sort select:hover, .toolbar-perpage select:hover {
    border-color: #94a3b8;
    background-color: #f8fafc;
}

.toolbar-sort select:focus, .toolbar-perpage select:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

/* ================================= UNIFORM GRID & CAMPAIGN CARDS ================================= */

.tk-campaigns-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 32px;
    padding: 32px;
    width: 100%;
    align-items: stretch;
    background-color: #fcfcfc;
}

.tk-campaign-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    border: 1px solid #f1f5f9;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.tk-campaign-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.03);
    border-color: #e2e8f0;
}

/* FIX: Image Zooming on Campaign Cards */
.campaign-img-wrap {
    position: relative;
    width: 100%;
    /* Removed fixed 220px height which caused zoom on tablets/mobile */
    height: auto; 
    /* This ensures aspect ratio stays 16:9 regardless of screen size */
    aspect-ratio: 16 / 9; 
    overflow: hidden;
    flex-shrink: 0;
}

.campaign-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.tk-campaign-card:hover .campaign-img {
    transform: scale(1.08);
}

.views-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: rgba(255, 255, 255, 0.85);
    color: #1e293b;
    font-size: 12px;
    font-weight: 700;
    border-radius: 8px;
    padding: 6px 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.4);
}

.tk-campaign-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    flex: 1;
}

.campaign-title {
    font-size: 19px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.4;
    margin: 0;
    transition: color 0.2s;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 54px;
}

.tk-campaign-card:hover .campaign-title { color: #4f46e5; }

.progress-container {
    margin-top: auto; 
    width: 100%;
    padding-top: 12px;
}

.progress-bar-bg {
    background: #f1f5f9;
    border-radius: 9999px;
    height: 10px;
    width: 100%;
    margin-bottom: 12px;
    overflow: hidden;
}

.progress-bar {
    background: linear-gradient(90deg, #4f46e5, #818cf8);
    height: 10px;
    border-radius: 9999px;
    transition: width 0.8s ease-out;
}

.stats-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
}

.raised { font-weight: 400; color: #64748b; font-size: 14px; }
.goal { color: #4f46e5; font-weight: 700; }

/* ================================= PAGINATION FIX ================================= */

.modern-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 32px;
    border-top: 1px solid #e2e8f0;
    background: #fff;
    flex-wrap: wrap; 
    gap: 20px;
}

.pagination-info {
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
}

.pagination-info strong { color: #1e293b; }

.pagination-controls {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    flex-wrap: nowrap;
}

.pagination-numbers {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 6px;
}

.pagination-btn, .pagination-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #fff;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    flex-shrink: 0;
}

.pagination-btn:hover:not(.pagination-btn--disabled),
.pagination-number:hover {
    border-color: #4f46e5;
    color: #4f46e5;
    background: #eef2ff;
    transform: translateY(-1px);
}

.pagination-btn--disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #f8fafc;
}

.pagination-number--active {
    background: #4f46e5;
    color: white;
    border-color: #4f46e5;
    box-shadow: 0 2px 4px rgba(79, 70, 229, 0.25);
}

.pagination-number--active:hover {
    background: #4338ca;
    color: white;
}

@media (max-width: 600px) {
    .modern-pagination {
        justify-content: center;
        flex-direction: column;
        gap: 16px;
    }
}

/* ================= EVENT DETAILS MODAL (ENHANCED & FLOATING) ================= */

.evt-details-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    padding: 24px; 
    box-sizing: border-box;
}

.evt-details-modal.active { display: flex; }

.evt-details-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(6px);
    transition: opacity 0.3s ease;
}

.evt-details-modal-content {
    position: relative;
    background: #ffffff;
    width: 100%;
    max-width: 750px;
    max-height: 100%; 
    display: flex;
    flex-direction: column;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.6);
    overflow: hidden;
    animation: modalPopIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.evt-details-modal-body {
    padding: 32px 40px;
    overflow-y: auto; 
    flex-grow: 1;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

.evt-details-modal-body::-webkit-scrollbar { width: 6px; }
.evt-details-modal-body::-webkit-scrollbar-track { background: transparent; }
.evt-details-modal-body::-webkit-scrollbar-thumb { background-color: #cbd5e1; border-radius: 20px; }

.evt-details-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(0,0,0,0.05);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    color: #4b5563;
    z-index: 20;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.evt-details-modal-close:hover {
    background: #fff;
    color: #ef4444;
    transform: rotate(90deg) scale(1.1);
}

.evt-details-modal-header {
    flex-shrink: 0;
    position: relative;
    background: #f3f4f6;
}

.evt-details-modal-image {
    width: 100%;
    height: 0;
    padding-bottom: 45%;
    position: relative;
}

.evt-details-modal-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.evt-details-modal-title {
    font-family: 'Poppins', sans-serif;
    font-size: 1.85rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 12px;
    line-height: 1.3;
}

.evt-status-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 24px;
}
.evt-status-upcoming { background: #eff6ff; color: #2563eb; border: 1px solid #bfdbfe; }
.evt-status-ongoing { background: #fffbeb; color: #d97706; border: 1px solid #fde68a; }
.evt-status-ended { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; }
.evt-status-closed { background: #f3f4f6; color: #4b5563; border: 1px solid #e5e7eb; }

.evt-details-modal-info {
    background: #f8fafc;
    padding: 24px;
    border-radius: 12px;
    margin-bottom: 32px;
    border: 1px solid #e2e8f0;
    display: grid;
    gap: 16px;
}

.evt-detail-item {
    display: flex;
    align-items: flex-start;
    color: #475569;
    font-size: 0.95rem;
    line-height: 1.5;
}
.evt-detail-item i {
    flex-shrink: 0; margin-right: 14px; margin-top: 3px;
    font-size: 1.2rem; color: #4f46e5; width: 24px; text-align: center;
}

.evt-details-modal-section { margin-bottom: 32px; }
.evt-details-modal-section h3 {
    font-size: 1.15rem; font-weight: 600; color: #1e293b;
    margin-bottom: 12px; border-left: 4px solid #4f46e5; padding-left: 12px;
}
.evt-details-modal-section p { color: #64748b; line-height: 1.7; font-size: 0.95rem; }

.evt-volunteer-roles {
    display: grid; gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.evt-volunteer-role {
    background: white; padding: 16px; border-radius: 12px;
    border: 1px solid #e2e8f0; box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.evt-volunteer-role h4 { font-size: 0.95rem; font-weight: 600; color: #334155; margin-bottom: 4px; }
.evt-volunteer-role p { color: #64748b; font-size: 0.85rem; margin: 0; }

.evt-details-modal-footer {
    padding: 24px 40px 32px;
    background: white;
    border-top: 1px solid #f1f5f9;
    display: flex;
    gap: 16px;
    flex-shrink: 0;
}

.evt-details-modal-register-btn, .evt-details-modal-close-btn {
    flex: 1; padding: 14px 24px; border: none; border-radius: 12px;
    font-weight: 600; cursor: pointer; transition: all 0.2s ease;
    font-size: 1rem; display: inline-flex; justify-content: center; align-items: center; gap: 8px;
}

.evt-details-modal-register-btn {
    background: #4f46e5; color: white;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2);
}
.evt-details-modal-register-btn:hover { background: #4338ca; transform: translateY(-2px); }
.evt-details-modal-register-btn:disabled { background: #e2e8f0; color: #94a3b8; box-shadow: none; cursor: not-allowed; transform: none; }

.evt-details-modal-close-btn { background: white; color: #475569; border: 1px solid #e2e8f0; }
.evt-details-modal-close-btn:hover { background: #f8fafc; border-color: #cbd5e1; }

@keyframes modalPopIn {
    0% { opacity: 0; transform: scale(0.95) translateY(10px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}

/* ================================= MEDIA QUERIES ================================= */

.mobile-filter-wrap {
    display: none;
}

/* Large Desktop */
@media (min-width: 1280px) {
    .tk-campaigns-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Desktop/Laptop */
@media (min-width: 1024px) and (max-width: 1279px) {
    .tk-campaigns-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tk-filters-sidebar {
        width: 250px;
    }
}

/* Tablet Landscape */
@media (min-width: 900px) and (max-width: 1023px) {
    .tk-campaigns-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .tk-filters-sidebar {
        width: 230px;
    }
}

/* Tablet Portrait */
@media (max-width: 899px) {
    .tk-campaigns-layout {
        flex-direction: column;
        gap: 24px;
    }
    
    .tk-filters-sidebar {
        width: 100%;
        position: static;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 20px;
    }
    
    .filters-group {
        flex: 1;
        min-width: 180px;
    }

    .tk-campaigns-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
    
    .evt-details-modal {
        padding: 24px;
        align-items: center;
    }
    .evt-details-modal-content {
        max-width: 100%;
        max-height: 85vh;
        border-radius: 16px;
        margin: 0;
    }
    .evt-details-modal-image { padding-bottom: 50%; }
    .evt-details-modal-body { padding: 24px; }
    .evt-details-modal-title { font-size: 1.6rem; }
    .evt-details-modal-footer { padding: 20px 24px 24px; }
}

/* Mobile */
@media only screen and (max-width: 767px) {
    .tk-filters-sidebar {
        display: none; 
    }
    
    .mobile-filter-wrap {
        display: block; 
        margin-bottom: 20px;
        width: 100%;
    }

    .tk-section-header {
        flex-direction: column;
        align-items: flex-start;
        padding-top: 100px;
    }
    
    /* FIX: Ensure featured image is not too tall on mobile */
    .featured-img {
        aspect-ratio: 16 / 9;
    }
    
    .btn.create-campaign {
        width: 100%;
        justify-content: center;
        margin-top: 12px;
    }
    
    /* TOOLBAR MOBILE FIXES */
    .tk-campaigns-toolbar {
        flex-direction: column;
        align-items: stretch; /* Stretches elements to full width */
        gap: 16px;
        padding: 20px;
    }
    
    .campaign-count {
        text-align: center;
    }
    
    .tk-campaign-toolbar-actions {
        width: 100%;
        justify-content: space-between;
    }
    
    .modern-pagination {
        flex-direction: column;
        text-align: center;
    }
    
    .tk-container {
        padding: 0 20px;
    }
    
    .evt-details-modal {
        padding: 16px; 
        align-items: center;
    }
    .evt-details-modal-content {
        max-height: 90vh; 
        border-radius: 16px;
    }
    .evt-details-modal-close {
        top: 12px; right: 12px;
        width: 32px; height: 32px; font-size: 1rem;
    }
    
    /* FIX: Reduce modal image height on mobile */
    .evt-details-modal-image { padding-bottom: 35%; }

    .evt-details-modal-body { padding: 20px 16px; }
    .evt-details-modal-title { font-size: 1.4rem; margin-bottom: 12px; }
    
    /* FIX: Stack buttons efficiently */
    .evt-details-modal-footer {
        padding: 12px 16px;
        flex-direction: column-reverse;
        gap: 8px;
    }
    .evt-details-modal-register-btn, 
    .evt-details-modal-close-btn {
        width: 100%;
        padding: 10px 12px;
    }
    .evt-volunteer-roles { grid-template-columns: 1fr; }
}

/* Small Mobile */
@media only screen and (max-width: 480px) {
    .tk-campaigns-grid {
        grid-template-columns: 1fr; 
        padding: 20px;
    }
    
    .tk-campaign-toolbar-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .toolbar-sort, .toolbar-perpage {
        width: 100%;
        justify-content: space-between;
    }
    
    .toolbar-sort select, .toolbar-perpage select {
        flex: 1;
    }
    
    .tk-featured-content-header,
    .tk-featured-actions {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }
    
    .btn.featured-support,
    .btn.featured-share {
        width: 100%;
        text-align: center;
        justify-content: center;
    }
}