:root {
    /* Color Palette */
    --primary: #115E59;
    /* Teal 800 */
    --primary-light: #14B8A6;
    /* Teal 500 */
    --primary-dark: #0F3D3E;
    --accent: #F59E0B;
    /* Amber */
    --bg-body: #F9FAFB;
    --surface: #FFFFFF;
    --text-main: #1F2937;
    --text-sub: #6B7280;
    --border: #E5E7EB;
}

/* Base Styles */
.charity-wrapper {
    font-family: 'Cairo', sans-serif;
    color: var(--text-main);
    line-height: 1.6;
    direction: rtl;
    text-align: right;
}

.charity-wrapper * {
    box-sizing: border-box;
}

.charity-wrapper a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

.charity-wrapper ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* Utility Classes */
.charity-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

.charity-btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.charity-btn-primary {
    background-color: var(--primary);
    color: #fff !important;
}

.charity-btn-primary:hover {
    background-color: var(--primary-dark);
}

.charity-btn-outline {
    border-color: #fff;
    color: #fff !important;
}

.charity-btn-outline:hover {
    background-color: #fff;
    color: var(--primary) !important;
}

.charity-section-title {
    font-size: 2rem;
    color: var(--primary-dark);
    text-align: center;
    margin-bottom: 0.5rem;
}

.charity-section-subtitle {
    text-align: center;
    color: var(--text-sub);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Hero Section */
.charity-hero {
    position: relative;
    min-height: 500px;
    height: 80vh;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    margin-bottom: 2rem;
}

.charity-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6));
    z-index: 1;
}

.charity-hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 2rem;
}

.charity-hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    color: #fff;
}

.charity-hero p {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
}

.charity-hero-btns {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Featured Grid */
.charity-grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.charity-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--border);
}

.charity-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.charity-card-img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.charity-card-body {
    padding: 1.5rem;
}

.charity-card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--primary-dark);
}

.charity-card-text {
    color: var(--text-sub);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.charity-card-link {
    color: var(--primary);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Categories */
.charity-categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1.5rem;
    margin-bottom: 4rem;
}

.charity-cat-card {
    text-align: center;
    padding: 2rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg-body);
    transition: 0.3s;
    display: block;
}

.charity-cat-card:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.charity-cat-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

/* Needs Grid */
.charity-needs-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
    padding: 1rem 0;
}

@media (max-width: 1200px) {
    .charity-needs-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .charity-needs-grid {
        grid-template-columns: repeat(1, 1fr);
    }
}

.charity-need-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
}

.charity-need-img {
    height: 140px;
    width: 100%;
    object-fit: cover;
}

.charity-need-body {
    padding: 1rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.charity-need-parent {
    font-size: 0.8rem;
    color: var(--text-sub);
    margin-bottom: 0.25rem;
    display: block;
}

.charity-need-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.4;
    flex-grow: 1;
}

.charity-progress-wrapper {
    margin-bottom: 1rem;
}

.charity-progress-bg {
    background: #E5E7EB;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.charity-progress-fill {
    background: var(--primary-light);
    height: 100%;
    border-radius: 4px;
}

.charity-progress-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    font-weight: 600;
}

.charity-need-btn {
    width: 100%;
    padding: 0.6rem;
    font-size: 0.9rem;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    text-align: center;
}

.charity-need-btn:hover {
    background: var(--primary-dark);
    color: #fff;
}

/* Mini Entity Cards */
.charity-mini-card {
    text-align: center;
    padding: 1.5rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    transition: 0.3s;
    background: #fff;
}

.charity-mini-card:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.charity-mini-img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin: 0 auto 1rem;
    object-fit: cover;
    background: #f0f0f0;
}

.charity-mini-name {
    font-weight: 700;
    margin-bottom: 0.25rem;
    font-size: 1rem;
}

.charity-mini-loc {
    color: var(--text-sub);
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
}

.charity-project-count {
    display: inline-block;
    background: #ECFDF5;
    color: var(--primary);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.charity-cta-section {
    background: var(--primary);
    color: #fff;
    text-align: center;
    padding: 5rem 0;
    border-radius: 12px;
    margin: 2rem 0;
}

/* Header */
.charity-header {
    position: relative;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    padding: 1rem 0;
    width: 100%;
}

.charity-nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.charity-logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.charity-nav-links {
    display: flex;
    gap: 2rem;
}

.charity-nav-links a {
    font-weight: 600;
    color: var(--text-main);
}

.charity-nav-links a:hover,
.charity-nav-links a.active {
    color: var(--primary);
}

@media (max-width: 992px) {
    .charity-nav-links {
        display: none;
    }
}

/* Footer */
.charity-footer {
    background: #1F2937;
    color: #D1D5DB;
    padding: 4rem 0 1rem;
    margin-top: 4rem;
}

.charity-footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.charity-footer-brand h3 {
    color: #fff;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.charity-footer-heading {
    color: #fff;
    font-weight: 700;
    margin-bottom: 1.25rem;
}

.charity-footer ul li {
    margin-bottom: 0.75rem;
}

.charity-footer ul li a:hover {
    color: var(--primary-light);
}

.charity-social-icons {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.charity-social-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: 0.3s;
    color: #fff;
}

.charity-social-icon:hover {
    background: var(--primary);
    color: #fff;
}

.charity-copyright {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    font-size: 0.9rem;
}

@media (max-width: 576px) {
    .charity-footer-grid {
        grid-template-columns: 1fr;
    }
}