/**
 * Appeals Archive Page Styles
 * MPFoundation Design System
 */

/* ==========================================================================
   Base & Reset
   ========================================================================== */
.mpf-appeals-archive-page {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #1e293b;
    background-color: #f8fafc;
    line-height: 1.6;
    overflow-x: hidden;
}

.mpf-appeals-archive-page .mpf-container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
    box-sizing: border-box;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.mpf-appeals-hero {
    background: #0b253d;
    color: #ffffff;
    padding: 84px 0 76px 0;
    position: relative;
    overflow: hidden;
    text-align: center;
}

.mpf-hero-bg-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px);
    background-size: 24px 24px;
    opacity: 0.7;
    pointer-events: none;
}

.mpf-hero-content {
    position: relative;
    z-index: 2;
    max-width: 860px;
    margin: 0 auto;
}

.mpf-hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(22, 139, 139, 0.2);
    border: 1px solid rgba(22, 139, 139, 0.4);
    color: #38bdf8;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 6px 16px;
    border-radius: 9999px;
    margin-bottom: 22px;
}

.mpf-hero-eyebrow svg {
    fill: #f47c20;
}

.mpf-hero-title {
    font-family: 'Poppins', inherit;
    font-size: 44px;
    font-weight: 800;
    line-height: 1.18;
    color: #ffffff !important;
    margin: 0 0 18px 0;
    letter-spacing: -0.015em;
}

.mpf-hero-subtitle {
    font-size: 17px;
    line-height: 1.7;
    color: #cbd5e1 !important;
    margin: 0 auto 40px auto;
    max-width: 720px;
}

/* Hero Metrics Bar */
.mpf-hero-metrics {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    padding: 16px 36px;
    gap: 32px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.mpf-metric-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.mpf-metric-value {
    font-family: 'Poppins', inherit;
    font-size: 24px;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.2;
}

.mpf-metric-label {
    font-size: 12px;
    font-weight: 600;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-top: 3px;
}

.mpf-metric-divider {
    width: 1px;
    height: 36px;
    background: rgba(255, 255, 255, 0.12);
}

/* ==========================================================================
   Filter Toolbar
   ========================================================================== */
.mpf-appeals-filter-section {
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 18px rgba(11, 37, 61, 0.04);
}

.mpf-filter-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 0;
}

/* Category Pills */
.mpf-filter-pills {
    display: flex;
    align-items: center;
    gap: 10px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: 4px 0;
}

.mpf-filter-pills::-webkit-scrollbar {
    display: none;
}

.mpf-pill-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 18px;
    border-radius: 9999px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    color: #475569;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.25s ease;
}

.mpf-pill-btn:hover {
    background: #e2e8f0;
    color: #0b253d;
    transform: translateY(-1px);
}

.mpf-pill-btn.active {
    background: #0b253d;
    border-color: #0b253d;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(11, 37, 61, 0.22);
}

.mpf-pill-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
    background: rgba(0, 0, 0, 0.08);
    color: inherit;
    padding: 2px 7px;
    border-radius: 9999px;
    line-height: 1;
}

.mpf-pill-btn.active .mpf-pill-count {
    background: rgba(255, 255, 255, 0.25);
    color: #ffffff;
}

.mpf-pill-btn.pill-urgent {
    color: #dc2626;
    background: #fef2f2;
    border-color: #fecaca;
}

.mpf-pill-btn.pill-urgent:hover {
    background: #fee2e2;
}

.mpf-pill-btn.pill-urgent.active {
    background: #dc2626;
    border-color: #dc2626;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.3);
}

/* Search Box */
.mpf-filter-search {
    flex-shrink: 0;
    width: 300px;
}

.mpf-search-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.mpf-search-icon {
    position: absolute;
    left: 14px;
    color: #94a3b8;
    pointer-events: none;
}

.mpf-search-input-wrap input {
    width: 100%;
    height: 42px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    padding: 0 38px 0 40px;
    font-size: 13px;
    color: #1e293b;
    outline: none;
    transition: all 0.25s ease;
    box-sizing: border-box;
}

.mpf-search-input-wrap input:focus {
    background: #ffffff;
    border-color: #0284c7;
    box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

.mpf-search-clear {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    font-size: 18px;
    color: #94a3b8;
    cursor: pointer;
    line-height: 1;
    padding: 0;
}

.mpf-search-clear:hover {
    color: #0f172a;
}

/* ==========================================================================
   Appeals Grid
   ========================================================================== */
.mpf-appeals-grid-section {
    padding: 60px 0 80px 0;
}

.mpf-appeals-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

/* Appeal Card */
.mpf-appeal-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 24px rgba(11, 37, 61, 0.05);
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    box-sizing: border-box;
}

.mpf-appeal-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 40px rgba(11, 37, 61, 0.12);
    border-color: #cbd5e1;
}

/* Card Media */
.mpf-card-media {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #0f172a;
}

.mpf-card-img-link {
    display: block;
    width: 100%;
    height: 100%;
}

.mpf-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.mpf-appeal-card:hover .mpf-card-img {
    transform: scale(1.06);
}

.mpf-card-img-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0b253d 0%, #13426b 100%);
    color: rgba(255, 255, 255, 0.3);
}

/* Badges on Image */
.mpf-card-badges {
    position: absolute;
    top: 14px;
    left: 14px;
    right: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    pointer-events: none;
    z-index: 2;
}

.mpf-badge-category {
    background: rgba(11, 37, 61, 0.88);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 5px 12px;
    border-radius: 9999px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.mpf-badge-urgent {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #dc2626;
    color: #ffffff;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 5px 12px;
    border-radius: 9999px;
    box-shadow: 0 3px 10px rgba(220, 38, 38, 0.4);
}

/* Card Body */
.mpf-card-body {
    padding: 26px 24px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.mpf-card-location {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #0284c7;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 10px;
}

.mpf-card-title {
    font-family: 'Poppins', inherit;
    font-size: 19px;
    font-weight: 800;
    line-height: 1.35;
    color: #0c3b5e;
    margin: 0 0 12px 0;
}

.mpf-card-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.25s ease;
}

.mpf-card-title a:hover {
    color: #f47c20;
}

.mpf-card-excerpt {
    font-size: 14px;
    line-height: 1.6;
    color: #64748b;
    margin: 0 0 22px 0;
    flex-grow: 1;
}

/* Card Progress */
.mpf-card-progress {
    background: #f8fafc;
    border: 1px solid #edf2f7;
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 20px;
}

.mpf-progress-track {
    width: 100%;
    height: 8px;
    background: #e2e8f0;
    border-radius: 9999px;
    overflow: hidden;
    margin-bottom: 10px;
}

.mpf-progress-bar {
    height: 100%;
    background: #f47c20;
    border-radius: 9999px;
    transition: width 1s ease;
}

.mpf-progress-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    line-height: 1;
}

.mpf-meta-raised {
    color: #0c3b5e;
}

.mpf-meta-raised strong {
    font-weight: 800;
}

.mpf-meta-goal {
    color: #64748b;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.mpf-percent-pill {
    background: #e0f2fe;
    color: #0369a1;
    font-size: 11px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 6px;
}

/* Card Actions */
.mpf-card-actions {
    margin-top: auto;
}

.mpf-btn-card-donate {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    background: #f47c20;
    color: #ffffff !important;
    font-family: 'Poppins', inherit;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 14px 20px;
    border-radius: 9999px;
    text-decoration: none !important;
    box-shadow: 0 4px 14px rgba(244, 124, 32, 0.3);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-sizing: border-box;
}

.mpf-btn-card-donate:hover {
    background: #e06b12;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(244, 124, 32, 0.45);
}

.mpf-btn-card-donate svg {
    transition: transform 0.25s ease;
}

.mpf-btn-card-donate:hover svg {
    transform: translateX(4px);
}

/* ==========================================================================
   No Results
   ========================================================================== */
.mpf-no-results {
    grid-column: 1 / -1;
    padding: 60px 20px;
    text-align: center;
}

.mpf-no-results-box {
    max-width: 440px;
    margin: 0 auto;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 40px 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
}

.mpf-no-results-box svg {
    margin-bottom: 16px;
}

.mpf-no-results-box h3 {
    font-family: 'Poppins', inherit;
    font-size: 20px;
    font-weight: 800;
    color: #0c3b5e;
    margin: 0 0 10px 0;
}

.mpf-no-results-box p {
    font-size: 14px;
    color: #64748b;
    margin: 0 0 20px 0;
}

.mpf-btn-reset-filters {
    background: #0b253d;
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    padding: 10px 22px;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease;
}

.mpf-btn-reset-filters:hover {
    background: #168b8b;
}

/* ==========================================================================
   Pagination
   ========================================================================== */
.mpf-pagination {
    margin-top: 50px;
    display: flex;
    justify-content: center;
}

.mpf-pagination ul.page-numbers {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.mpf-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 42px;
    height: 42px;
    padding: 0 14px;
    border-radius: 12px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    color: #0c3b5e;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.25s ease;
}

.mpf-pagination .page-numbers:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
}

.mpf-pagination .page-numbers.current {
    background: #f47c20;
    border-color: #f47c20;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(244, 124, 32, 0.35);
}

/* ==========================================================================
   Trust & Transparency Strip
   ========================================================================== */
.mpf-appeals-trust-strip {
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    padding: 50px 0;
    margin-top: 40px;
}

.mpf-trust-pillars-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
}

.mpf-trust-pillar {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.mpf-trust-icon-box {
    width: 48px;
    height: 48px;
    min-width: 48px;
    background: #e0f2fe;
    color: #0284c7;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.mpf-trust-info h4 {
    font-family: 'Poppins', inherit;
    font-size: 15px;
    font-weight: 800;
    color: #0c3b5e;
    margin: 0 0 4px 0;
}

.mpf-trust-info p {
    font-size: 13px;
    line-height: 1.45;
    color: #64748b;
    margin: 0;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 1024px) {
    .mpf-appeals-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }

    .mpf-trust-pillars-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 28px;
    }

    .mpf-hero-title {
        font-size: 36px;
    }

    .mpf-hero-metrics {
        gap: 20px;
        padding: 14px 24px;
    }

    .mpf-metric-value {
        font-size: 20px;
    }
}

@media (max-width: 767px) {
    .mpf-appeals-hero {
        padding: 56px 0 48px 0;
    }

    .mpf-hero-title {
        font-size: 28px;
    }

    .mpf-desktop-br {
        display: none;
    }

    .mpf-hero-subtitle {
        font-size: 15px;
        margin-bottom: 30px;
    }

    .mpf-hero-metrics {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
        padding: 20px;
        width: 100%;
        box-sizing: border-box;
    }

    .mpf-metric-divider {
        display: none;
    }

    .mpf-filter-toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 14px;
        padding: 14px 0;
    }

    .mpf-filter-search {
        width: 100%;
    }

    .mpf-appeals-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .mpf-card-body {
        padding: 20px 18px;
    }

    .mpf-trust-pillars-grid {
        grid-template-columns: 1fr;
        gap: 22px;
    }
}
