/* ===== MPFoundation Zakat Page - Modern UI/UX ===== */

.mpf-zakat-page {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    background: #ffffff;
}

/* ===== Custom Header Integration ===== */
.mpf-zakat-page .mpf-custom-header {
    position: relative;
    z-index: 1000;
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    width: 100%;
}

.mpf-zakat-page .mpf-custom-header .mpf-nav {
    background: transparent;
}

.mpf-zakat-page .mpf-custom-header .mpf-nav ul {
    margin: 0;
    padding: 0;
}

/* ===== Hero Section ===== */
.mpf-zakat-hero {
    background: linear-gradient(135deg, #207dad 0%, #1e6aa0 100%);
    background-attachment: fixed;
    min-height: 70vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding: 40px 0;
}

.mpf-zakat-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="islamicPattern" width="50" height="50" patternUnits="userSpaceOnUse"><path d="M25 0L35 20L25 40L15 20Z" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23islamicPattern)"/></svg>');
    opacity: 0.3;
}

.mpf-hero-overlay {
    position: relative;
    z-index: 2;
    width: 100%;
}

.mpf-hero-content {
    text-align: center;
    color: white;
    padding: 40px 0;
    max-width: 900px;
    margin: 0 auto;
}

.mpf-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(15px);
    padding: 12px 24px;
    border-radius: 50px;
    border: 1px solid rgba(255,255,255,0.3);
    margin-bottom: 30px;
    font-weight: 600;
    font-size: 0.9rem;
    animation: fadeInUp 1s ease-out;
}

.mpf-hero-badge span:first-child {
    font-size: 1.2rem;
}

.mpf-hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 24px;
    color: #ffffff !important;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
    animation: fadeInUp 1s ease-out 0.2s both;
    line-height: 1.1;
}

.mpf-hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 50px;
    opacity: 1 !important;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    animation: fadeInUp 1s ease-out 0.4s both;
    line-height: 1.6;
    color: #ffffff !important;
    text-shadow: 0 2px 8px rgba(0,0,0,0.4);
    font-weight: 500;
}

.mpf-hero-stats {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    margin-top: 60px;
    animation: fadeInUp 1s ease-out 0.6s both;
    flex-wrap: wrap;
}

.mpf-stat {
    text-align: center;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(15px);
    border-radius: 24px;
    padding: 28px 24px;
    border: 1px solid rgba(255,255,255,0.25);
    transition: all 0.3s ease;
    min-width: 140px;
    flex: 1;
    max-width: 180px;
}

.mpf-stat:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px rgba(0,0,0,0.25);
    background: rgba(255,255,255,0.2);
}

.mpf-stat-number {
    display: block;
    font-size: 2.2rem;
    font-weight: 800;
    color: #fff !important;
    margin-bottom: 8px;
    line-height: 1;
    text-shadow: 0 3px 10px rgba(0,0,0,0.5);
}

.mpf-stat-label {
    font-size: 0.85rem;
    opacity: 1 !important;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: #ffffff !important;
    font-weight: 600;
    text-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

/* ===== Zakat Calculator Section ===== */
.mpf-zakat-calculator {
    padding: 100px 0;
    background: #f8fafc;
    position: relative;
}

.mpf-calculator-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    background: white;
    border-radius: 32px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.1);
    overflow: hidden;
    border: 1px solid #e2e8f0;
}

.mpf-calculator-header {
    text-align: center;
    padding: 60px 40px 40px;
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    border-bottom: 1px solid #e2e8f0;
}

.mpf-calculator-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 16px;
}

.mpf-calculator-header p {
    font-size: 1.1rem;
    color: #64748b;
    max-width: 500px;
    margin: 0 auto;
}

.mpf-calculator-content {
    display: grid;
    grid-template-columns: 1fr 400px;
    min-height: 600px;
}

.mpf-calculator-form {
    padding: 60px;
    background: white;
}

.mpf-form-section {
    margin-bottom: 50px;
    padding: 30px;
    background: #f8fafc;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.mpf-form-section:hover {
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    border-color: #207dad;
}

.mpf-form-section h3 {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.3rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
}

.mpf-icon {
    font-size: 1.4rem;
}

.mpf-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    margin-bottom: 20px;
}

.mpf-form-row:last-child {
    margin-bottom: 0;
}

.mpf-form-group {
    display: flex;
    flex-direction: column;
}

.mpf-form-group label {
    font-weight: 600;
    color: #374151;
    margin-bottom: 8px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mpf-form-group input {
    padding: 16px 20px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: white;
    font-weight: 500;
}

.mpf-form-group input:focus {
    outline: none;
    border-color: #207dad;
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1);
    transform: translateY(-2px);
}

.mpf-calculator-actions {
    display: flex;
    gap: 20px;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #e2e8f0;
}

.mpf-calculate-btn {
    flex: 1;
    background: linear-gradient(135deg, #207dad, #1e6aa0);
    color: white;
    border: none;
    padding: 18px 32px;
    border-radius: 16px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.mpf-calculate-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(40, 167, 69, 0.3);
}

.mpf-reset-btn {
    background: #f1f5f9;
    color: #64748b;
    border: 2px solid #e2e8f0;
    padding: 18px 32px;
    border-radius: 16px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mpf-reset-btn:hover {
    background: #e2e8f0;
    color: #374151;
    transform: translateY(-2px);
}

/* ===== Calculator Results ===== */
.mpf-calculator-results {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    color: white;
    padding: 60px 40px;
    position: relative;
    overflow: hidden;
}

.mpf-calculator-results::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="resultPattern" width="30" height="30" patternUnits="userSpaceOnUse"><circle cx="15" cy="15" r="2" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23resultPattern)"/></svg>');
    opacity: 0.3;
}

.mpf-results-header {
    position: relative;
    z-index: 2;
    text-align: center;
    margin-bottom: 40px;
}

.mpf-results-header h3 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #ffffff;
}

.mpf-results-content {
    position: relative;
    z-index: 2;
}

.mpf-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

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

.mpf-result-label {
    font-weight: 500;
    opacity: 0.9;
    color: #ffffff;
    font-size: 1rem;
}

.mpf-result-value {
    font-size: 1.2rem;
    font-weight: 700;
    color: #1e6aa0;
}

.mpf-zakat-amount {
    background: rgba(32, 201, 151, 0.1);
    border-radius: 16px;
    padding: 25px 20px !important;
    margin: 20px 0;
    border: 1px solid rgba(32, 201, 151, 0.3) !important;
}

.mpf-zakat-amount .mpf-result-value {
    font-size: 2rem;
    color: #1e6aa0;
}

.mpf-nisab-status {
    text-align: center;
    padding: 20px;
    border-radius: 16px;
    margin: 30px 0;
    font-weight: 600;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
}

.mpf-status-success {
    color: #22c55e !important;
    font-size: 1.1rem;
}

.mpf-status-info {
    color: #60a5fa !important;
    font-size: 1.1rem;
}

.mpf-status-text {
    color: #e2e8f0 !important;
    font-size: 1.1rem;
}

.mpf-donate-section {
    text-align: center;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.mpf-zakat-page .mpf-donate-zakat-btn {
    display: inline-flex !important;
    align-items: center !important;
    gap: 15px !important;
    background: linear-gradient(135deg, #207dad 0%, #1e6aa0 50%, #17a2b8 100%) !important;
    color: white !important;
    text-decoration: none !important;
    padding: 20px 40px !important;
    border-radius: 25px !important;
    font-weight: 700 !important;
    font-size: 1.2rem !important;
    transition: all 0.4s ease !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
    position: relative !important;
    overflow: hidden !important;
    box-shadow: 0 10px 30px rgba(40, 167, 69, 0.3) !important;
    border: 2px solid rgba(255,255,255,0.2) !important;
    height: auto !important;
    min-width: auto !important;
}

.mpf-zakat-page .mpf-donate-zakat-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.6s ease;
}

.mpf-zakat-page .mpf-donate-zakat-btn:hover::before {
    left: 100%;
}

.mpf-zakat-page .mpf-donate-zakat-btn:hover {
    transform: translateY(-5px) scale(1.05) !important;
    box-shadow: 0 20px 50px rgba(40, 167, 69, 0.4) !important;
    text-decoration: none !important;
    color: white !important;
    background: linear-gradient(135deg, #1e6aa0 0%, #207dad 50%, #17a2b8 100%) !important;
}

.mpf-zakat-page .mpf-donate-zakat-btn svg {
    width: 24px !important;
    height: 24px !important;
    transition: transform 0.3s ease;
}

.mpf-zakat-page .mpf-donate-zakat-btn:hover svg {
    transform: rotate(360deg) scale(1.2);
}

/* Alternative donate button style */
.mpf-donate-zakat-btn.style-2 {
    background: linear-gradient(45deg, #ff6b6b, #ee5a24, #ff9ff3, #54a0ff);
    background-size: 400% 400%;
    animation: gradientShift 3s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* ===== Zakat Information Section ===== */
.mpf-zakat-info {
    padding: 100px 0;
    background: white;
}

.mpf-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.mpf-info-card {
    text-align: center;
    padding: 50px 30px;
    background: #f8fafc;
    border-radius: 24px;
    border: 1px solid #e2e8f0;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.mpf-info-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #207dad, #1e6aa0);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.mpf-info-card:hover::before {
    transform: scaleX(1);
}

.mpf-info-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 60px rgba(0,0,0,0.15);
    background: white;
}

.mpf-card-icon {
    font-size: 3rem;
    margin-bottom: 25px;
    opacity: 0.8;
}

.mpf-info-card h3 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 20px;
}

.mpf-info-card p {
    color: #64748b;
    line-height: 1.7;
    font-size: 1rem;
}

/* ===== FAQ Section ===== */
.mpf-zakat-faq {
    padding: 100px 0;
    background: #f8fafc;
}

.mpf-faq-header {
    text-align: center;
    margin-bottom: 80px;
}

.mpf-faq-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 20px;
}

.mpf-faq-header p {
    font-size: 1.1rem;
    color: #64748b;
    max-width: 500px;
    margin: 0 auto;
}

.mpf-faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.mpf-faq-item {
    background: white;
    border-radius: 16px;
    margin-bottom: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    border: 1px solid #e2e8f0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.mpf-faq-item:hover {
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.mpf-faq-question {
    padding: 30px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: white;
    transition: all 0.3s ease;
}

.mpf-faq-question:hover {
    background: #f8fafc;
}

.mpf-faq-question h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
    flex: 1;
}

.mpf-faq-toggle {
    width: 30px;
    height: 30px;
    background: #207dad;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
}

.mpf-faq-item.active .mpf-faq-toggle {
    background: #dc3545;
    transform: rotate(180deg);
}

.mpf-faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: all 0.4s ease;
    background: #f8fafc;
    padding: 0 30px;
}

.mpf-faq-item.active .mpf-faq-answer {
    max-height: 300px;
    padding: 20px 30px 30px;
}

.mpf-faq-answer p {
    color: #64748b;
    line-height: 1.7;
    margin: 0;
    font-size: 1rem;
    transition: opacity 0.2s ease 0.2s;
}

/* ===== Animations ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mpf-results-active {
    animation: slideInRight 0.5s ease-out;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.mpf-calculation-complete {
    animation: pulse 0.5s ease-in-out;
}

.mpf-form-reset {
    animation: shake 0.3s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* ===== Loading States ===== */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    border: 2px solid #e2e8f0;
    border-top: 2px solid #207dad;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    transform: translate(-50%, -50%);
    z-index: 10;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* ===== Error States ===== */
.mpf-calculation-error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    padding: 15px 20px;
    border-radius: 12px;
    margin: 20px 0;
    text-align: center;
    font-weight: 600;
    display: none;
    animation: slideInDown 0.3s ease-out;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Enhanced Form States ===== */
.mpf-form-group input.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.mpf-form-group input.success {
    border-color: #22c55e;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1);
}

.mpf-form-group input:valid {
    border-color: #22c55e;
}

.mpf-form-group input:invalid:not(:placeholder-shown) {
    border-color: #ef4444;
}

/* ===== Progressive Enhancement ===== */
.js-enabled .mpf-calculator-form {
    transition: opacity 0.3s ease;
}

.js-enabled .mpf-results-content {
    opacity: 0;
    transition: opacity 0.5s ease;
}

.js-enabled .mpf-results-active .mpf-results-content {
    opacity: 1;
}

/* ===== Responsive Design ===== */
@media (max-width: 1200px) {
    .mpf-calculator-content {
        grid-template-columns: 1fr;
    }
    
    .mpf-calculator-results {
        order: -1;
    }
}

@media (max-width: 768px) {
    .mpf-zakat-hero {
        min-height: 60vh;
        padding: 20px 0;
    }
    
    .mpf-hero-title {
        font-size: 2.8rem;
        margin-bottom: 20px;
        text-shadow: 0 4px 20px rgba(0,0,0,0.6) !important;
        font-weight: 900 !important;
    }
    
    .mpf-hero-subtitle {
        font-size: 1.1rem;
        margin-bottom: 40px;
        padding: 0 15px;
        text-shadow: 0 3px 10px rgba(0,0,0,0.5) !important;
        font-weight: 600 !important;
    }
    
    .mpf-hero-stats {
        gap: 20px;
        margin-top: 40px;
        padding: 0 15px;
    }
    
    .mpf-stat {
        min-width: 120px;
        padding: 24px 20px;
    }
    
    .mpf-stat-number {
        font-size: 1.8rem;
    }
    
    .mpf-calculator-content {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .mpf-calculator-form {
        padding: 30px 15px;
        width: 100%;
        max-width: none;
    }
    
    .mpf-form-section {
        margin-bottom: 30px;
        padding: 20px 15px;
        border-radius: 15px;
    }
    
    .mpf-calculator-header {
        padding: 30px 15px 20px;
    }
    
    .mpf-calculator-header h2 {
        font-size: 2rem;
    }
    
    .mpf-form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .mpf-calculator-actions {
        flex-direction: column;
    }
    
    .mpf-info-grid {
        grid-template-columns: 1fr;
        gap: 25px;
        padding: 0 15px;
    }
    
    .mpf-faq-list {
        padding: 0 15px;
    }
}

@media (max-width: 480px) {
    .mpf-hero-title {
        font-size: 2.2rem;
        text-shadow: 0 4px 25px rgba(0,0,0,0.7) !important;
        font-weight: 900 !important;
    }
    
    .mpf-hero-subtitle {
        padding: 0 10px;
        text-shadow: 0 3px 12px rgba(0,0,0,0.6) !important;
        font-weight: 600 !important;
        font-size: 1.15rem !important;
    }
    
    .mpf-hero-stats {
        flex-direction: column;
        gap: 15px;
        padding: 0 10px;
    }
    
    .mpf-stat {
        max-width: none;
        width: 100%;
    }
    
    .mpf-stat-number {
        text-shadow: 0 3px 12px rgba(0,0,0,0.6) !important;
        font-weight: 900 !important;
    }
    
    .mpf-stat-label {
        text-shadow: 0 2px 8px rgba(0,0,0,0.5) !important;
        font-weight: 700 !important;
    }
    
    .mpf-calculator-form {
        padding: 25px 10px;
    }
    
    .mpf-form-section {
        margin-bottom: 25px;
        padding: 15px 10px;
        border-radius: 12px;
    }
    
    .mpf-calculator-header {
        padding: 25px 10px 15px;
    }
    
    .mpf-calculator-results {
        padding: 30px 10px;
    }
    
    .mpf-zakat-page .mpf-donate-zakat-btn {
        padding: 18px 30px !important;
        font-size: 1.1rem !important;
        gap: 12px !important;
    }
    
    .mpf-zakat-page .mpf-donate-zakat-btn svg {
        width: 20px !important;
        height: 20px !important;
    }
    
    .mpf-faq-question {
        padding: 18px 10px;
    }
    
    .mpf-faq-answer {
        padding: 0 10px;
    }
    
    .mpf-faq-item.active .mpf-faq-answer {
        padding: 15px 10px 15px;
    }
    
    .mpf-info-grid {
        padding: 0 10px;
    }
    
    .mpf-faq-list {
        padding: 0 10px;
    }
}
