/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Hind Siliguri', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f9f9f9;
    color: #333;
    line-height: 1.6;
    overflow-x: hidden;
}

.arabic {
    font-family: 'Amiri', 'Traditional Arabic', serif;
}

html {
    scroll-behavior: smooth;
}

/* ===== HEADER ===== */
header {
    background: #1e3c3f;
    color: white;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    letter-spacing: 1px;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-size: 1.1rem;
    transition: color 0.3s;
}

nav ul li a:hover {
    color: #f4b41a;
}

.header-buttons {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.login-btn {
    background: transparent;
    color: white;
    border: 1px solid white;
    padding: 0.5rem 1.2rem;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s;
}

.login-btn:hover {
    background: white;
    color: #1e3c3f;
}

.donate-btn {
    background: #f4b41a;
    color: #1e3c3f;
    padding: 0.5rem 1.5rem;
    border-radius: 5px;
    font-weight: bold;
    text-decoration: none;
}

.menu-toggle {
    display: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: white;
}

/* ===== LANGUAGE DROPDOWN ===== */
.translate-wrapper {
    position: relative;
    display: inline-block;
    margin-right: 15px;
}

.lang-dropdown {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    padding: 8px 35px 8px 15px;
    font-size: 14px;
    font-weight: 400;
    color: #fff;
    cursor: pointer;
    outline: none;
    transition: all 0.2s ease;
    backdrop-filter: blur(5px);
    min-width: 120px;
}

.lang-dropdown:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 215, 0, 0.5);
}

.lang-dropdown:focus {
    border-color: #FFD700;
    box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.2);
}

.translate-wrapper::after {
    content: '\f0ac';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.7);
    pointer-events: none;
    font-size: 14px;
    transition: all 0.2s ease;
}

.translate-wrapper:hover::after {
    color: #FFD700;
}

.lang-dropdown option {
    background: #1B5E20;
    color: #fff;
    padding: 10px;
}

/* ===== DIGITAL WATCH (TRANSPARENT) ===== */
.digital-watch {
    text-align: center;
    margin-top: -40px;
    padding: 12px 25px;
    background: transparent;
    color: #fff;
    border: none;
    box-shadow: none;
    backdrop-filter: none;
    display: inline-block;
}

.digital-watch .time,
.digital-watch .date {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.digital-watch .time {
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1.3;
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
}

.digital-watch .date {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-top: 5px;
    font-weight: 400;
}

/* ===== HERO SECTION ===== */
.hero {
    background: linear-gradient(rgba(30, 60, 63, 0.8), rgba(30, 60, 63, 0.8)), url('https://media.ndiganta.com/original_images/Medina-Munawwarah.jpg') center/cover no-repeat;
    color: white;
    text-align: center;
    padding: 4rem 2rem;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.hero .next-prayer {
    font-size: 1.5rem;
    background: rgba(255,255,255,0.2);
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: 40px;
    margin: 1.5rem 0;
}

.hero-buttons a {
    display: inline-block;
    margin: 0.5rem;
    padding: 0.8rem 2rem;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
}

.btn-primary {
    background: #f4b41a;
    color: #1e3c3f;
}

.btn-outline {
    background: transparent;
    border: 2px solid white;
    color: white;
}

.scrolling-message {
    background-color: #f4b41a;
    color: #1e3c3f;
    padding: 0.8rem 0;
    margin: 1.5rem 0;
    overflow: hidden;
    white-space: nowrap;
    font-weight: bold;
    font-size: 1.3rem;
    border-radius: 50px;
}

.scrolling-message p {
    display: inline-block;
    animation: scroll-left 40s linear infinite;
    padding-left: 100%;
    margin: 0;
}

@keyframes scroll-left {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}

/* ===== PRAYER TIMES BANNER ===== */
.prayer-banner {
    max-width: 1200px;
    margin: 2rem auto;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.prayer-green-header {
    background: #0b5e3c;
    color: #fff;
    text-align: center;
    padding: 40px 20px;
}

.prayer-green-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    font-family: 'Amiri', serif;
}

.prayer-green-header p {
    font-size: 1.3rem;
    opacity: 0.9;
}

/* Prayer Cards */
.prayer-cards {
    background: #f4f6f5;
    padding: 35px 20px;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 18px;
    margin: 20px auto 0;
    border-radius: 20px;
    max-width: 1100px;
}

.prayer-box {
    background: #fff;
    border-radius: 16px;
    padding: 22px 10px;
    text-align: center;
    box-shadow: 0 6px 16px rgba(0,0,0,0.1);
    color: #0b5e3c;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid rgba(30,60,63,0.1);
    position: relative;
}

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

.prayer-box.active {
    background: #0b5e3c;
    color: #fff;
    transform: scale(1.08);
    box-shadow: 0 10px 20px rgba(11,94,60,0.3);
}

.prayer-box.active h4,
.prayer-box.active p,
.prayer-box.active small {
    color: #fff;
}

.prayer-box .icon {
    font-size: 2.8rem;
    display: block;
    margin-bottom: 10px;
}

.prayer-box h4 {
    font-size: 1.4rem;
    margin-bottom: 6px;
    font-weight: 600;
    color: #0b5e3c;
}

.prayer-box p {
    font-size: 1.3rem;
    font-weight: 700;
    color: #0b5e3c;
    margin-bottom: 0.2rem;
}

.prayer-box .dot {
    color: red;
    font-size: 10px;
}

.prayer-box .current {
    display: inline-block;
    margin-top: 6px;
    background: #fff;
    color: #0b5e3c;
    padding: 4px 10px;
    border-radius: 14px;
    font-size: 11px;
    font-weight: 600;
}

.prayer-box small {
    color: #666;
    font-size: 0.9rem;
    background: rgba(255,255,255,0.7);
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    display: inline-block;
}

/* Additional time sections */
.time-sections {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
    margin: 40px 20px;
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
}

.time-card {
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
    overflow: hidden;
}

.time-card-header {
    background: #0b5e3c;
    color: #fff;
    padding: 14px 20px;
    font-size: 1.2rem;
    font-weight: 600;
}

.time-card-body {
    padding: 25px 20px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    text-align: center;
}

.time-box {
    background: #f1fff7;
    border-radius: 14px;
    padding: 18px 10px;
}

.time-box .icon {
    font-size: 26px;
    margin-bottom: 8px;
}

.time-box h4 {
    color: #0b5e3c;
    font-size: 1rem;
    margin-bottom: 6px;
    font-weight: 600;
}

.time-box p {
    font-size: 0.95rem;
    font-weight: 600;
    color: #333;
}

.time-box strong {
    display: block;
    margin-top: 4px;
    font-size: 1rem;
    color: #0b5e3c;
}

/* ===== ABOUT & CONTACT SECTIONS ===== */
.about-section,
.contact-section {
    max-width: 1100px;
    margin: 3rem auto;
    padding: 2rem;
    background: #f9f9f9;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.about-section h2,
.contact-section h2 {
    color: #1e3c3f;
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.contact-info p {
    margin: 0.5rem 0;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.contact-info i {
    width: 25px;
    color: #1e3c3f;
}

/* ===== FOOTER ===== */
footer {
    background: #1e2a3a;
    color: #fff;
    padding: 2rem 1rem 1rem;
}
.footer-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    gap: 2rem;
}
.footer-col {
    flex: 1 1 250px;
}
.footer-col h4 {
    margin-bottom: 1rem;
    font-size: 1.2rem;
}
.footer-links {
    list-style: none;
    padding: 0;
}
.footer-links li {
    margin-bottom: 0.5rem;
}
.footer-links a, .social-icons a {
    color: #ddd;
    text-decoration: none;
    transition: color 0.3s;
}
.footer-links a:hover, .social-icons a:hover {
    color: #f4c542;
}
.social-icons {
    display: flex;
    gap: 1rem;
    font-size: 1.5rem;
}
.footer-bottom {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #444;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.back-to-top {
    background: #f4c542;
    color: #1e2a3a;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
}
.back-to-top:hover {
    background: #ffd966;
}
/* RTL support */
[dir="rtl"] .social-icons {
    justify-content: flex-end;
}

/* ===== MODAL STYLES ===== */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    margin: 5% auto;
    padding: 2rem;
    border-radius: 20px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    position: relative;
    animation: slideDown 0.3s ease;
}

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

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #666;
    cursor: pointer;
}

.close-modal:hover {
    color: #1e3c3f;
}

.modal h2 {
    color: #1e3c3f;
    margin-bottom: 0.5rem;
    font-size: 2rem;
}

.modal p {
    color: #666;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #1e3c3f;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group select {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
}

.amount-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 10px;
}

.amount-radio {
    background: #f0f0f0;
    border-radius: 8px;
    padding: 0.8rem;
    text-align: center;
    cursor: pointer;
    border: 2px solid transparent;
}

.amount-radio input[type="radio"] {
    display: none;
}

.amount-radio input[type="radio"]:checked + label {
    background: #f4b41a;
    color: #1e3c3f;
    border-color: #1e3c3f;
}

.custom-amount {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.custom-amount input[type="radio"] {
    width: auto;
    margin-right: 5px;
}

.custom-amount input[type="number"] {
    flex: 1;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 8px;
}

.submit-donation {
    background: #f4b41a;
    color: #1e3c3f;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.2rem;
    font-weight: bold;
    border-radius: 50px;
    cursor: pointer;
    width: 100%;
}

.submit-donation:hover {
    background: #e09e0f;
}

.modal-note {
    font-size: 0.9rem;
    color: #888;
    margin-top: 1rem;
    text-align: center;
}

/* ===== RTL SUPPORT ===== */
[dir="rtl"] {
    text-align: right;
}

[dir="rtl"] .header-buttons {
    flex-direction: row-reverse;
}

[dir="rtl"] .prayer-box {
    text-align: right;
}

[dir="rtl"] .lang-dropdown {
    padding: 8px 15px 8px 35px;
}

[dir="rtl"] .translate-wrapper::after {
    right: auto;
    left: 12px;
}

/* ===== RESPONSIVE MEDIA QUERIES ===== */
@media (max-width: 992px) {
    .prayer-cards {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    header {
        flex-direction: column;
        padding: 0.8rem;
        gap: 0.5rem;
    }

    .logo {
        font-size: 1.2rem;
        text-align: center;
        white-space: normal;
        line-height: 1.3;
        max-width: 100%;
    }

    nav {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .menu-toggle {
        display: block;
        font-size: 2rem;
        padding: 0.3rem 1rem;
        background: rgba(255,255,255,0.1);
        border-radius: 8px;
        width: fit-content;
        cursor: pointer;
    }

    nav ul {
        display: none;
        flex-direction: column;
        width: 100%;
        text-align: center;
        gap: 0.5rem;
        margin: 0.8rem 0 0.2rem;
        padding: 0;
        list-style: none;
    }

    nav ul.show {
        display: flex;
    }

    nav ul li a {
        display: block;
        padding: 0.8rem 1rem;
        font-size: 1.2rem;
        background: rgba(255,255,255,0.05);
        border-radius: 8px;
        transition: background 0.2s;
    }

    nav ul li a:hover {
        background: rgba(255,215,0,0.2);
    }

    .header-buttons {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 0.8rem;
        margin-top: 0.5rem;
    }

    .translate-wrapper {
        width: 100%;
        margin: 0;
    }

    .lang-dropdown {
        width: 100%;
        padding: 0.8rem 2.5rem 0.8rem 1rem;
        font-size: 1.1rem;
    }

    .login-btn,
    .donate-btn {
        display: block;
        width: 100%;
        text-align: center;
        padding: 0.9rem 1rem;
        font-size: 1.2rem;
        border-radius: 8px;
        box-sizing: border-box;
    }

    .digital-watch {
        margin: 10px auto 20px;
        padding: 8px 15px;
        max-width: 90%;
    }

    .digital-watch .time {
        font-size: 1.8rem;
    }

    .digital-watch .date {
        font-size: 1rem;
    }

    .hero {
        padding: 2rem 1rem;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .prayer-green-header h1 {
        font-size: 2rem;
    }

    .prayer-green-header p {
        font-size: 1rem;
    }

    .prayer-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        padding: 20px 10px;
        margin-top: -40px;
    }

    .prayer-box {
        padding: 15px 5px;
    }

    .prayer-box .icon {
        font-size: 2rem;
    }

    .prayer-box h4 {
        font-size: 1.2rem;
    }

    .prayer-box p {
        font-size: 1.1rem;
    }

    .time-card-body {
        grid-template-columns: 1fr;
    }

    .about-section,
    .contact-section {
        padding: 1.5rem 1rem;
        margin: 1.5rem 1rem;
        text-align: center;
    }

    .contact-info p {
        justify-content: center;
        font-size: 1rem;
    }

    .footer-container {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }

    .footer-col {
        flex: 1 1 100%;
    }

    .social-icons {
        justify-content: center;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.5rem;
    }

    .hero-buttons a {
        display: block;
        margin: 0.5rem auto;
        width: 80%;
        text-align: center;
    }

    .prayer-cards {
        grid-template-columns: 1fr;
    }

    .prayer-box .time {
        font-size: 1.3rem;
    }

    .digital-watch .time {
        font-size: 1.5rem;
    }

    .digital-watch .date {
        font-size: 0.9rem;
    }
}