* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    font-family: Arial, sans-serif;
    background-color: #f4f6f9;
    color: #333;
}

/* NAVBAR RESPONSIVE */
.nav-bar {
    background-color: #2a40e3;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    padding: 15px 5%;
    width: 100%;
    gap: 15px;
}

.img1 { width: 7rem; flex-shrink: 0; }
.nav-links { display: flex; align-items: center; gap: 30px; flex-wrap: wrap; }
.nav-a { text-decoration: none; color: white; font-weight: bold; font-size: 1rem; }
.nav-btn { display: flex; align-items: center; gap: 15px; }
.nav-a2 { padding: 8px 16px; text-decoration: none; color: white; border-radius: 5px; border: 1px solid white; transition: 0.3s; }
.nav-a2:hover { background-color: white; color: #2a40e3; }

/* LAYOUT CONTAINER */
.duas-wrapper {
    max-width: 1100px;
    width: 100%;
    margin: 40px auto;
    padding: 0 20px;
}

.main-heading { text-align: center; font-size: 2.2rem; color: #222; margin-bottom: 10px; }
.sub-heading { text-align: center; font-size: 1.1rem; color: #666; margin-bottom: 40px; }

/* DYNAMIC CARDS GRID */
#duas-grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    width: 100%;
}

/* CARD LOOKS */
.dua-card {
    background-color: #ffffff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border-top: 4px solid #2a40e3;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    transition: 0.3s ease;
}

.dua-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.dua-card h3 { color: #222; font-size: 1.3rem; margin-bottom: 12px; }
.dua-card p { color: #666; font-size: 0.95rem; line-height: 1.5; margin-bottom: 20px; }

.dua-card button, #back-btn {
    padding: 10px 20px;
    background-color: #2a40e3;
    color: white;
    border: none;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.2s;
    align-self: flex-start;
}
.dua-card button:hover, #back-btn:hover { background-color: #1a2fb3; }

/* SUB-CARD BADGE */
.badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: #e3f2fd;
    color: #2a40e3;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
}

/* FINAL DUA DISPLAY BOX */
.dua-display-box {
    grid-column: 1 / -1; /* Take full width */
    background-color: #ffffff;
    padding: 35px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    margin-bottom: 15px;
}

.dua-display-box h2 { font-size: 1.4rem; color: #2a40e3; margin-bottom: 15px; }

.arabic-text {
    direction: rtl;
    text-align: right;
    font-size: 1.8rem;
    line-height: 2.2;
    color: #222;
    margin: 20px 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.translation-text { font-size: 1.1rem; line-height: 1.6; color: #444; }

/* RESPONSIVE BREAKPOINT */
@media (max-width: 768px) {
    .nav-bar { justify-content: center; }
    .nav-links, .nav-btn { justify-content: center; width: 100%; }
    .main-heading { font-size: 1.7rem; }
    .sub-heading { font-size: 1rem; }
}
/* ======================================================= */
/* 🔍 SEARCH BAR STYLING                                    */
/* ======================================================= */
.searchbar {
    height: 38px;
    width: 100%; /* Mobile par poori line cover karegi */
    max-width: 18rem; /* Laptop/Desktop par is size se barri nahi hogi */
    padding: 8px 15px;
    border-radius: 20px; /* Is se search bar side se round/smooth dikhegi */
    border: 1px solid #ccc;
    font-size: 0.95rem;
    outline: none;
    transition: all 0.3s ease;
    background-color: #ffffff;
}

/* Jab user search bar par click kare (Focus mode) */
.searchbar:focus {
    border-color: #ffffff; /* Border white ho jayega */
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.5); /* Halka sa glow effect aayega */
    max-width: 20rem; /* Thodi si barri ho jayegi look wise */
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    .searchbar {
        max-width: 100%; /* Mobile screens par container ke mutabiq stretch hogi */
        margin: 5px 0;
    }
}
