//*
 * This stylesheet provides custom styles and RTL support for the Kardeşlik Mescidi website.
 * It is referenced by index.html.
 */

/* Mobile Responsiveness Fixes */
html, body {
    overflow-x: hidden; /* Prevents horizontal scroll on mobile */
    width: 100%;
    margin: 0;
    padding: 0;
}

/* General Styles and Font Import */
@import url('https://fonts.googleapis.com/css2?family=Readex+Pro:wght@400;500;600;700&display=swap');
    :root {
  --Turquoise: #0dcaf0;
}
html,
body {
    font-family: 'Readex Pro', sans-serif;
    /* Set the background to the specified image, fixed and covering the viewport. */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Updated background with a repeating pattern */
    background-color: #f3f4f6;
    background-image: url('https://www.kardeslik.at/assets/img/pattern-i.png');
    background-repeat: repeat;
    background-size: 100px;
    /* Adjust size as needed */

    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

main {
    flex-grow: 1;
    width: 100%;
    max-width: 100vw; /* Ensures content stays within screen bounds */
}

/* --- Navigation Bar Customization --- */

/* Base Navbar Styling */
.navbar {
    background-color: #ffffff;
    /* Use a white base for a clean look */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Custom Nav Item Button Styling (Square/Rounded Corners) */
.nav-square-btn {
    display: inline-flex;
    /* Use flex for alignment */
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0.5rem 0.8rem;
    /* Adjusted padding for better fit */
    margin: 0.25rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: #f8f9fa !important;
    /* White Text */
    background-color: #495057;
    /* Gray Background */
    border-radius: 0.5rem;
    /* Subtly rounded corners */
    transition: background-color 0.3s, color 0.3s;
    height: 40px;
    /* Uniform height */
    line-height: 1;
    /* Center text vertically */
    text-transform: uppercase;
}

/* Nav Item Hover/Active State */
.nav-square-btn:hover,
.nav-square-btn.active {
    background-color: #0dcaf0 !important;
    /* Light Blue Background */
    color: #1a202c !important;
    /* Black Text */
}

/* Language Button Custom Styling (Square, Flag-Only) */
.lang-square-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    /* Make it square */
    height: 40px;
    padding: 0;
    border: none;
    cursor: pointer;
    background-color: #495057;
    /* Gray Background */
    color: white;
    border-radius: 0.5rem;
    /* Subtly rounded corners */
    transition: background-color 0.3s, color 0.3s;
    font-size: 1.25rem;
    /* Size up the flag */
}

.lang-square-btn:hover,
.lang-square-btn.active {
    background-color: #0dcaf0;
    /* Light Blue Background */
    color: #1a202c;
    /* Black Text (for non-flag content, though here it's just the flag) */
}

.lang-square-btn span {
    display: inline-block;
    line-height: 1;
    /* Ensure flag is centered */
}

/* Adjust language selector position for better alignment */
.language-selector {
    padding-left: 1rem;
}

/* Update navbar to use 'navbar-expand-lg' for desktop collapse threshold */
.navbar-expand-lg .navbar-nav {
    /* Desktop: Use flex-row */
    flex-direction: row !important;
}

/* Mobile: Collapse the menu and stack items */
@media (max-width: 991px) {
    .navbar-toggler {
        /* Align toggler button */
        margin-right: 0.5rem;
    }

    .navbar-collapse .navbar-nav {
        /* Force vertical stacking inside the collapsed menu */
        flex-direction: column !important;
        align-items: flex-start !important;
        /* Align links to the left */
        width: 100%;
        gap: 0.5rem;
        /* Add some spacing between stacked links */
    }

    .navbar-collapse .nav-item {
        width: 100%;
        /* Make each link take full width */
    }

    .nav-square-btn {
        width: 100%;
        /* Make the button inside the nav-item take full width */
        justify-content: flex-start;
        /* Left-align link text */
    }

    .language-selector {
        /* Reset language selector margin for better alignment with toggler */
        margin-left: 0 !important;
    }
}

/* On Desktop, hide the hamburger button (Bootstrap's .navbar-expand-lg handles this, but ensuring clarity) */
@media (min-width: 992px) {
    .navbar-toggler {
        display: none;
    }

    /* Ensure desktop nav is centered */
    .navbar-nav {
        margin: 0 auto !important;
    }
}

/* --- End of Navigation Bar Customization --- */

/* Navbar Styles */
.custom-navbar {
    /* Use custom styles above */
}


/* Carousel Styles */
/* Standardize carousel image size and appearance */
.carousel-image {
    width: 100%;
    height: 60vh;
    /* Set a fixed height relative to viewport */
    object-fit: cover;
    /* Ensure images cover the area without distortion */
}

/* Media query for smaller screens to adjust carousel height */
@media (max-width: 768px) {
    .carousel-image {
        height: 40vh;
        /* Shorter height on mobile */
    }
}


/* Custom Carousel indicators/controls for a cleaner look */
.carousel-indicators [data-bs-target] {
    background-color: #212529;
    /* Darker indicators */
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: rgba(0, 0, 0, 0.5);
    /* Semi-transparent background for better visibility */
    border-radius: 50%;
    padding: 1.5rem;
}

.carousel-control-prev:hover .carousel-control-prev-icon,
.carousel-control-next:hover .carousel-control-next-icon {
    background-color: rgba(0, 0, 0, 0.7);
}


/* Content Section Styling */
.content-section {
    background-color: #ffffff;
    border-radius: 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
    max-width: 100%; /* Prevent overflow */
}

/* Event Cards Styling */
.event-cards .card {
    transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

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

.event-cards .card-img-top {
    height: 180px;
    object-fit: cover;
}

.event-cards .card-body {
    padding: 1.5rem;
}

.event-cards .card-title {
    color: #007bff;
    /* Highlight title color */
}

/* Custom Accordion Styling for FAQ */
.accordion-button:not(.collapsed) {
    color: #ffffff;
    background-color: #495057;
    /* Darker background when open */
    box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.125);
}

.accordion-button:focus {
    box-shadow: none;
    border-color: inherit;
}

.accordion-item {
    border: 1px solid #495057;
    background-color: #0dcaf0;
    /* Highlight background when open */
    margin-bottom: 0.5rem;
    border-radius: 0.5rem !important;
    overflow: hidden;
}


/* Smooth Scroll Logic */
html {
    scroll-behavior: smooth;
}

/* RTL Support Styles (for dir="rtl" on html tag) */
[dir="rtl"] .bi.bi-arrow-right {
    transform: scaleX(-1);
    /* Inverts the arrow icon for RTL languages */
}

/* Make cards display correctly in a row on medium and larger screens. */
@media (min-width: 768px) {
    .row.row-cols-md-2.row-cols-lg-3 .col:nth-child(n+4) {
        margin-top: 1.5rem;
    }
}


/* Form Styles */

.form-control,
.form-select {
    border-radius: 0.5rem;
    /* rounded-lg */
    padding: 0.75rem 1rem;
    /* p-3 */
    max-width: 100%; /* Fixes form width on mobile */
}

/* Map Container Styles for Aspect Ratio */
.map-container {
    height: 0;
    padding-bottom: 75%;
    /* 4:3 aspect ratio (75%) */
    position: relative;
    overflow: hidden;
    width: 100%;
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}


/* Footer Styles */
.main-footer {
    background-color: #1a202c;
    color: #d1d5db;
    padding: 4rem 1rem;
    margin-top: auto;
    /* Pushes the footer to the bottom of the page */
    width: 100%;
}

/* Social media icon styles */
.footer-social a {
    font-size: 1.5rem;
    /* Increase icon size */
    margin-right: 1rem;
    /* Add spacing between icons */
    transition: transform 0.3s ease;
}

.footer-social a:hover {
    color: Turquoise;
    transform: translateY(-3px);
    /* Subtle hover effect */
}

/* Ensure footer remains LTR for RTL languages */
[dir="rtl"] .main-footer {
    direction: ltr;
    text-align: left;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-links,
.footer-contact,
.footer-social {
    flex: 1 1 200px;
    margin: 1rem 0;
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links a {
    color: #9ca3af;
    text-decoration: none;
}

.footer-links a:hover {
    color: Turquoise;
}

.footer-contact p {
    margin-bottom: 0.5rem;
    text-align: left;
}

.footer-social a {
    color: #9ca3af;
    margin-right: 1rem;
}

.footer-bottom {
    border-top: 1px solid #374151;
    margin-top: 2rem;
    padding-top: 1rem;
    width: 100%;
}

.footer_text {
    color: #0dcaf0;
    /* Light blue color for the link */
    text-decoration: none;
}

.footer_text:hover {
    text-decoration: underline;
}

.footer-logo img {
    margin-bottom: 1rem;
    max-width: 100%; /* Logo won't break mobile width */
    height: auto;
}

/* Mobile specific layout adjustments for navbar buttons */
@media (max-width: 991px) {
    .navbar .container-fluid {
        /* Allow logo and menu to wrap/stack */
        flex-direction: row;
        /* Keep elements inline at the top */
        justify-content: space-between;
        padding-left: 15px;
        padding-right: 15px;
    }

    .navbar-nav {
        /* Center menu buttons/links for mobile view */
        align-items: center !important;
        margin-top: 0.5rem;
        width: 100%;
    }

    .d-lg-block {
        display: block !important;
    }
}



/* --- ZAKAT CALCULATOR CUSTOM STYLES --- */

/* Result List Styling */
.list-group-item-result {
    font-size: 1.15rem;
    font-weight: 500;
}

/* Nisab Fail/Success Styling */
.list-group-item-result.nisab-fail {
    background-color: #fcebeb;
    /* Light red background */
    color: #c82e2e;
    /* Darker red text */
    font-weight: 700;
}

.list-group-item-result.nisab-success {
    background-color: #e6f7ea;
    /* Light green background */
    color: #1e7a3b;
    /* Darker green text */
    font-weight: 700;
}

.list-group-item-success {
    background-color: #e6f7ea !important;
    color: #1e7a3b !important;
}

.list-group-item-danger {
    background-color: #fcebeb !important;
    color: #c82e2e !important;
}

/* Input Group Styling for Currency Symbol */
.input-group-text {
    border-radius: 0.5rem 0 0 0.5rem !important;
    background-color: #e9ecef;
}

/* Ensure form control radius is consistent */
.form-control,
.form-select {
    border-radius: 0.5rem;
    /* rounded-lg */
    padding: 0.75rem 1rem;
    /* p-3 */
}

/*--------------------------------------------------------------
# Designed & Script by: Gamal Nabih |  1LineArt Studio | https://1lineart.com
--------------------------------------------------------------*/