/* =========================================
   Base & Container Styles
========================================= */
body {
    margin: 0;
    font-family: "Noto Sans Devanagari", "Segoe UI", sans-serif;
    background-color: #f4f7f6; /* थोड़ा सॉफ्ट और मॉडर्न बैकग्राउंड */
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* General Header Styles */
.main-header {
    background-color: #ffffff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    height: 70px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 24px;
    font-weight: 700;
    color: #80184f;
    text-decoration: none;
}

.logo span {
    color: #333;
    font-weight: 400;
}

/* Desktop Menu Styles */
.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
    margin: 0;
    padding: 0;
}

.nav-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    font-size: 16px;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #80184f;
}

/* Hamburger Button Hidden on Desktop */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
}

.bar {
    width: 100%;
    height: 3px;
    background-color: #80184f;
    border-radius: 10px;
    transition: all 0.3s ease;
}

/* Responsive Tablet & Mobile Styles */
@media screen and (max-width: 992px) {
    .menu-toggle {
        display: flex;
        z-index: 1001;
    }

    .nav-wrapper {
        position: absolute;
        top: 70px;
        left: 0;
        width: 100%;
        background-color: #fff;
        border-top: 1px solid #eee;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease-in-out;
        box-shadow: 0 5px 10px rgba(0,0,0,0.05);
    }

    .nav-menu {
        flex-direction: column;
        align-items: center;
        padding: 20px 0;
        gap: 0;
    }

    .nav-menu li {
        width: 100%;
        text-align: center;
    }

    .nav-link {
        display: block;
        padding: 15px 0;
        width: 100%;
        border-bottom: 1px solid #f9f9f9;
    }

    /* Open Class for JS */
    .nav-wrapper.active {
        max-height: 400px; /* Adjust based on menu items */
    }

    /* Hamburger Animation to 'X' */
    .menu-toggle.is-active .bar:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }
    .menu-toggle.is-active .bar:nth-child(2) {
        opacity: 0;
    }
    .menu-toggle.is-active .bar:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
}

/* =========================================
   Main Tool Styles (Bhakti Calculator)
========================================= */
.bhakti-calculator {
    padding: 50px 0;
}

.bhakti-calculator h1 { 
    text-align: center; 
    font-size: 28px; 
    font-weight: 800;
    color: #80184f; 
    margin-bottom: 15px; 
    letter-spacing: -0.5px;
}

.bhakti-calculator p {
    font-size: 16px;
    margin-bottom: 35px;
    text-align: center;
    color: #555;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.bhakti-calculator .selector-card {
    background: #ffffff; 
    border-radius: 16px;
    padding: 25px;
    margin: 20px 0; 
    box-shadow: 0 8px 24px rgba(0,0,0,0.04);
    border: 1px solid rgba(128, 24, 79, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bhakti-calculator .selector-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(128, 24, 79, 0.08);
}

.bhakti-calculator .selector-card h3 { 
    margin: 0 0 12px; 
    color: #333; 
    display: flex; 
    align-items: center; 
    font-size: 18px;
    font-weight: 700;
}

.bhakti-calculator .selector-card h3 span.icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fdf0f8;
    color: #80184f;
    border-radius: 12px;
    width: 40px;
    height: 40px;
    margin-right: 12px;
    font-size: 18px;
    box-shadow: 0 2px 8px rgba(128, 24, 79, 0.1);
}

.bhakti-calculator .selector-card p { 
    margin: 0 0 12px; 
    font-size: 14px; 
    color: #666;
    text-align: left;
}

/* Inputs & Selects - Modernized */
.bhakti-calculator select, 
.bhakti-calculator input {
    width: 100%; 
    padding: 12px 15px; 
    border-radius: 10px; 
    border: 2px solid #e1e8ed;
    background-color: #f8fafc;
    font-size: 15px;
    color: #333;
    box-sizing: border-box;
    transition: all 0.3s ease;
    appearance: none;
}

/* Custom Dropdown Arrow */
.bhakti-calculator select {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2380184f' 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 15px center;
    background-size: 16px;
    padding-right: 40px;
}

.bhakti-calculator select:focus, 
.bhakti-calculator input:focus {
    border-color: #80184f;
    background-color: #ffffff;
    outline: none;
    box-shadow: 0 0 0 4px rgba(128, 24, 79, 0.1); /* Modern Focus Ring */
}

.bhakti-calculator label span.required { color: #e74c3c; font-weight: bold; }
.bhakti-calculator input:invalid { border-color: #e74c3c; }

/* Buttons Row */
.bhakti-calculator .button-row { display: flex; gap: 15px; margin: 25px 0; }

.bhakti-calculator .btn {
    padding: 14px;
    font-size: 16px;
    font-weight: 700;
    border: none; 
    border-radius: 10px; 
    cursor: pointer;
    color: #fff;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.bhakti-calculator #calculateBtn { 
    background: linear-gradient(135deg, #80184f, #ab206a); 
    flex: 6; 
    box-shadow: 0 4px 15px rgba(128, 24, 79, 0.3);
}
.bhakti-calculator #calculateBtn:hover { 
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(128, 24, 79, 0.4);
}

.bhakti-calculator #resetBtn { 
    background: #64748b; 
    flex: 4; 
}
.bhakti-calculator #resetBtn:hover { 
    background: #475569; 
}

/* Result Circular Progress */
.bhakti-calculator .circle {
    width: 180px; height: 180px; 
    position: relative; 
    margin: 25px auto;
    filter: drop-shadow(0 4px 10px rgba(128, 24, 79, 0.2));
}
.bhakti-calculator .circle svg { transform: rotate(-90deg); width: 100%; height: 100%; }
.bhakti-calculator .circle-text {
    position: absolute; top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    font-size: 32px; font-weight: 800; color: #80184f;
}
.bhakti-calculator #progress { transition: stroke-dashoffset 1.2s cubic-bezier(0.4, 0, 0.2, 1); }

/* Result Card - Premium Gradient */
.bhakti-calculator .result-card {
    text-align: center; 
    color: #ffffff;
    background: linear-gradient(135deg, #ab206a 0%, #80184f 100%);
    padding: 30px 20px;
    border-radius: 16px; 
    box-shadow: 0 10px 30px rgba(128, 24, 79, 0.2);
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

/* Subtle background shine effect for result card */
.bhakti-calculator .result-card::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%; width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

/* Share & Donate Buttons */
.bhakti-calculator .sikhe-donate-row { display: flex; justify-content: center; gap: 12px; margin-top: 20px; flex-wrap: nowrap; }
.bhakti-calculator .sikhe-btn { background: #22c55e; }
.bhakti-calculator .sikhe-btn:hover { background: #16a34a; transform: translateY(-2px); }
.bhakti-calculator .donate-btn { background: #f43f5e; }
.bhakti-calculator .donate-btn:hover { background: #e11d48; transform: translateY(-2px); }

.bhakti-calculator .whatsapp-row { display: flex; justify-content: center; margin-top: 12px; }
.bhakti-calculator .whatsapp-btn { background: #25D366; }
.bhakti-calculator .whatsapp-btn:hover { background: #1ebd57; transform: translateY(-2px); }

/* Modern Table Design */
.bhakti-calculator #historyTable {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 20px;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.bhakti-calculator #historyTable th, 
.bhakti-calculator #historyTable td {
    padding: 15px;
    text-align: center;
    border-bottom: 1px solid #f1f5f9;
}

.bhakti-calculator #historyTable th {
    background: #80184f;
    color: #fff;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 14px;
    letter-spacing: 0.5px;
}

.bhakti-calculator #historyTable tr:last-child td { border-bottom: none; }
.bhakti-calculator #historyTable tbody tr:hover { background-color: #fdf0f8; transition: 0.2s; }

/* Responsive Grid Layout */
.bhakti-calculator .factors-grid { display: flex; flex-direction: column; gap: 0; }
@media (min-width: 768px) {
    .bhakti-calculator .result-grid { display: flex; flex-direction: row; align-items: center; margin-top: 40px; gap: 30px;}
    .bhakti-calculator .result-left, .bhakti-calculator .result-right { flex: 1; }
    .bhakti-calculator .result-left { display: flex; justify-content: center; align-items: center; }
}

/* Mobile Adjustments */
@media (max-width: 767px) {
    .header-flex { flex-direction: column; text-align: center; gap: 12px; }
    .site-nav { gap: 15px; flex-wrap: wrap; justify-content: center; }
    .bhakti-calculator h1 { font-size: 22px; }
    .bhakti-calculator .selector-card { padding: 15px; margin: 15px 0; }
    .bhakti-calculator .btn { font-size: 14px; padding: 12px; }
    .bhakti-calculator .sikhe-donate-row, .bhakti-calculator .whatsapp-row { flex-direction: column; align-items: stretch; gap: 10px; }
    .bhakti-calculator .sikhe-btn, .bhakti-calculator .donate-btn, .bhakti-calculator .whatsapp-btn { width: 100%; max-width: 100%; }
}

/* =========================================
   Donate Popup Styles
========================================= */
#donatePopup { position: fixed; top:0; left:0; width:100%; height:100%; display:flex; justify-content:center; align-items:center; z-index:9999; }
.donate-popup-overlay { position:absolute; top:0; left:0; width:100%; height:100%; background:rgba(15, 23, 42, 0.6); backdrop-filter: blur(4px); }
.donate-popup-content {
    position: relative;
    background: #fff; 
    border-radius: 20px; 
    padding: 30px;
    margin: 15px;
    max-width: 380px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0,0,0,0.2);
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popIn {
    0% { transform: scale(0.8); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.donate-popup-content h2 { color: #80184f; margin-top:0; margin-bottom:10px; font-weight: 800; }
.donate-popup-content p { font-size:15px; color:#64748b; margin-bottom:20px; }
.donate-popup-content .donate-qr { width:220px; height:220px; margin-bottom:15px; border-radius:12px; border: 1px solid #e2e8f0; padding: 5px; }
.donate-popup-content .upi-id { 
    font-size:16px; color:#334155; display:flex; align-items:center; justify-content:center; gap:8px; margin-bottom:20px; background: #f8fafc; padding: 10px; border-radius: 10px; border: 1px dashed #cbd5e1;
}
.donate-popup-content .close-popup {
    background: #e2e8f0; color: #475569; padding: 12px 20px; border: none; border-radius: 10px; cursor: pointer; font-weight: 700; transition: all 0.2s; width: 100%;
}
.donate-popup-content .close-popup:hover { background: #cbd5e1; color: #1e293b; }

#copyUpiBtn { background: #80184f; color: #fff; border: none; padding: 8px 12px; border-radius: 8px; cursor: pointer; font-size: 14px; transition: 0.2s; }
#copyUpiBtn:hover { background: #ab206a; }
#upiText { font-weight: 700; color: #1e293b; }

/* Tips Section Styling */
.tips-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
}
.section-title {
    color: #80184f;
    margin-bottom: 40px;
    font-size: 28px;
    text-align: center;
}
.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}
.tip-card {
    background: #fff;
    padding: 25px;
    border-radius: 15px;
    transition: transform 0.3s ease;
    border: 1px solid #80184f;
}
.tip-card:hover {
    transform: translateY(-5px);
}
.tip-icon {
    font-size: 35px;
    color: #80184f;
    margin-bottom: 15px;
}
.tip-card h3 {
    margin-bottom: 10px;
    color: #333;
}
.tip-card p {
    font-size: 15px;
    color: #666;
    line-height: 1.6;
    text-align: left;
}

/* FAQ Styling */
.faq-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: left;
}
.faq-item {
    background: #f9f9f9;
    margin-bottom: 10px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #ddd;
}
.faq-question {
    padding: 15px 20px;
    cursor: pointer;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    transition: background 0.3s;
}
.faq-question:hover {
    background: #f1f1f1;
}
.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    color: #555;
    background: #fff;
}
.faq-item.active .faq-answer {
    padding: 15px 20px;
    max-height: 200px;
    border-top: 1px solid #eee;
}
.faq-item.active i {
    transform: rotate(180deg);
}

/* =========================================
   Footer Styles
========================================= */
.site-footer {
    background-color: #1e293b; /* Modern Dark Slate */
    color: #f8fafc;
    padding: 50px 0 30px; 
    text-align: center;
    position: relative;
}

/* Decorative Top Border Line */
.site-footer::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 4px;
    background: linear-gradient(90deg, #80184f, #ab206a, #f9dff4);
}

.footer-links { margin-bottom: 20px; font-size: 15px; color: #475569; }
.footer-links a {
    color: #cbd5e1;
    text-decoration: none;
    margin: 0 15px; 
    transition: color 0.3s ease;
    font-weight: 500;
}
.footer-links a:hover { color: #f9dff4; }
.copyright { font-size: 14px; color: #94a3b8; margin: 0; }

@media (max-width: 768px) {
    .site-footer { padding: 40px 0 20px; }
    .footer-links { display: flex; flex-direction: row; gap: 15px; color: transparent; }
    .footer-links a { margin: 0; }
}