/* Font Family */
body {
    font-family: 'Tajawal', sans-serif;
    color: #3E3E3E;
    background-color: #F9F5E8;
    /* Light Beige Background */
}

/* Color Variables */
:root {
    --bs-primary: #C5A065;
    /* Gold/Bronze */
    --bs-primary-rgb: 197, 160, 101;
    --bs-dark: #2C2C2C;
    --bs-light: #F9F5E8;
}

/* ============================
   NAVBAR – BASE & SCROLLED
   ============================ */

/* NAVBAR default state → full white bar */
.main-nav {
    background: #fff !important;
    transition: background 0.3s ease;
}

.nav-logo {
    margin-left: 0 !important;
}

;


/* NAVBAR when scrolled → remove white bar behind the pill */
.main-nav.navbar-scrolled {
    background: transparent !important;
    box-shadow: none !important;
}

/* ==========================
   DESKTOP (≥ 992px)
   ========================== */
@media (min-width: 992px) {

    /* smoother transitions on desktop */
    .main-nav,
    .main-nav .container {
        transition:
            background 0.45s ease,
            box-shadow 0.45s cubic-bezier(0.25, 0.1, 0.25, 1),
            padding 0.45s ease,
            transform 0.45s cubic-bezier(0.4, 0, 0.2, 1),
            border-radius 0.45s ease,
            opacity 0.45s ease;
    }

    .main-nav.navbar-scrolled {
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;

        /* remove full bar background when scrolled */
        background: transparent !important;
        box-shadow: none !important;

        /* slight motion */
        transform: translateY(6px);
        opacity: 0.98;
    }

    .main-nav.navbar-scrolled .container {
        background: linear-gradient(135deg,
                rgba(255, 255, 255, 0.98),
                rgba(225, 225, 225, 0.95));
        border-radius: 50px;
        padding: 0.75rem 2rem;

        box-shadow: 0 18px 45px rgba(0, 0, 0, 0.18);
        border: 1px solid rgba(255, 255, 255, 0.8);
        backdrop-filter: blur(12px);

        /* float pill with margin from sides */
        width: calc(100% - 60px);
        margin-inline: auto;

        /* smooth shrink effect */
        transform: scale(0.98);
        opacity: 1;
    }

    .main-nav.navbar-scrolled .nav-link {
        color: #111;
    }

    .main-nav.navbar-scrolled .nav-link:hover,
    .main-nav.navbar-scrolled .nav-link.active {
        color: #000;
    }

    .main-nav.navbar-scrolled .btn {
        color: #fff !important;
        padding: 0.55rem 1.6rem;
    }
}

/* ==========================
   MOBILE & TABLET (< 992px)
   ========================== */
@media (max-width: 991.98px) {

    /* always just a normal white bar on mobile */
    .main-nav {
        background: #fff !important;
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
        transform: none;
        opacity: 1;
    }

    .main-nav.navbar-scrolled {
        background: #fff !important;
        /* keep the bar */
        box-shadow: none;
        transform: none;
        opacity: 1;
    }

    /* container should NOT be a pill on mobile */
    .main-nav .container,
    .main-nav.navbar-scrolled .container {
        background: transparent;
        border-radius: 0;
        box-shadow: none;
        border: none;
        backdrop-filter: none;
        width: 100%;
        margin: 0;
        padding-inline: 1rem;
        transform: none;
        opacity: 1;
    }
}

.bg-primary {
    background-color: var(--bs-primary) !important;
}

.btn-primary {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
    color: #fff;
}

.btn-primary:hover {
    background-color: #b08d55;
    border-color: #b08d55;
}

.bg-primary-subtle {
    background-color: #d8d5d080 !important;
}

.bg-primary-subtles {
    background-color: #C5A065 !important;
}

.mobile {
    display: none !important;
}


/* Hero Section */
/* .hero-section {
    height: 100vh;
    min-height: 600px;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)), url('../img/Header(5).webp');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
} */

.ptt {
    --bs-btn-padding-x: 0.75rem !important;
    --bs-btn-padding-y: 0.375rem !important;
}

.mobile {
    display: none;
}


/* Make the header full-height (you can adjust) */
.header {
    min-height: 80vh;
}

.headerCarousel .carousel-item {
    min-height: 80vh;
    /* same as header */
    position: relative;
}

.headerCarousel .carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* keep image nicely cropped */
}

/* Optional: dark overlay + centered text on top of images */
.headerCarousel .carousel-caption {
    bottom: 50%;
    transform: translateY(50%);
}

/* Force smooth sliding from right to left */
.headerCarousel .carousel-item {
    transition: transform 1s ease-in-out;
}

/* Base overlay: make sure it's above the carousel */
.header-overlay {
    z-index: 10;
    text-shadow: 1px 1px 8px rgba(0, 0, 0, 0.7);
}

/* Default Desktop */
.header-overlay h1 {
    font-size: 48px;
    line-height: 1.2;
}

.header-overlay h3 {
    font-size: 26px;
}

.header-overlay a {
    font-size: 20px;
    padding: 10px 32px;
}

/* ≤ 992px */
@media (max-width: 992px) {
    .header-overlay h1 {
        font-size: 40px;
    }

    .header-overlay h3 {
        font-size: 22px;
    }

    .header-overlay a {
        font-size: 18px;
        padding: 9px 28px;
    }
}

/* ≤ 768px */
@media (max-width: 768px) {
    .header-overlay h1 {
        font-size: 32px;
    }

    .header-overlay h3 {
        font-size: 18px;
    }

    .header-overlay a {
        font-size: 16px;
        padding: 8px 24px;
    }
}

/* ≤ 576px (mobiles) */
@media (max-width: 576px) {
    .header-overlay {
        top: 55%;
        /* still centered but a bit lower */
    }

    .header-overlay h1 {
        font-size: 26px;
    }

    .header-overlay h3 {
        font-size: 16px;
    }

    .header-overlay a {
        font-size: 14px;
        padding: 6px 20px;
    }
}

/* ≤ 360px (very small phones) */
@media (max-width: 360px) {
    .header-overlay h1 {
        font-size: 22px;
    }

    .header-overlay h3 {
        font-size: 14px;
    }

    .header-overlay a {
        font-size: 12px;
        padding: 5px 16px;
    }
}


@supports (-webkit-touch-callout: none) {
    .hero {
        min-height: -webkit-fill-available;
    }
}

.hero {
    min-height: 100svh;
    position: relative;
    overflow: hidden;
}

.hero-section img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}


.important {
    font-weight: bolder;
    color: #fff !important;
    text-align: center;
}


.logo {
    width: 150px !important;
}

/* Section Padding */
.section-padding {
    padding: 100px 0;
}

/* Cards */
.card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1) !important;
}

.permit-carousel,
.facilities-carousel {
    cursor: grab;
    overflow: hidden;
    /* just in case */
}

.permit-carousel.is-dragging,
.facilities-carousel.is-dragging {
    cursor: grabbing;
}


/* Form Controls */
.form-control:focus {
    box-shadow: none;
    border: 2px solid var(--bs-primary);
}

/* Footer */
footer {
    background-color: #30261d !important;
}

.bg-developer {
    background-color: #30261d !important;
}

/* Responsive Google Maps iframe */
.map-container {
    position: relative;
    width: 100%;
    /* padding-bottom: 56.25%; */
    /* 16:9 ratio (adjust if needed) */
    /* height: 50%; */
    overflow: hidden;
    border-radius: 12px;
    /* Optional */
}

.map-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.form-control {
    direction: rtl;
}

.navbar-toggler-icon {
    display: inline-block;
    width: 0.5em;
    height: 0.5em;
    vertical-align: middle;
    background-image: var(--bs-navbar-toggler-icon-bg);
    background-repeat: no-repeat;
    background-position: center;
    background-size: 100%;
}

.menu-btn {
    font-size: 15px !important;
}

.pxx-4 {
    padding-left: 0.3rem !important;
    padding-right: 0.3rem !important;
}

.footer a {
    color: #fff;
}


/* ==============================
       CARD FLIP STYLING
       ============================== */

.permit-card {
    position: relative;
    height: 380px;
    perspective: 1200px;
}

.permit-card .card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s ease;
    transform-style: preserve-3d;
}

.permit-card:hover .card-inner {
    transform: rotateY(180deg);
}

.permit-card .card-front,
.permit-card .card-back {
    position: absolute;
    inset: 0;
    border-radius: 26px;
    background-color: var(--card-bg);
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.card-front {
    display: flex;
    flex-direction: column;
}

.card-front img.card-img-top {
    height: 210px;
    object-fit: cover;
}

.card-front .card-body {
    padding: 1.25rem 1.8rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.sub-card {
    font-size: 1.2rem;
}

.card-front .card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
}

.card-back {
    padding: 1.75rem 1.9rem;
    transform: rotateY(180deg);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-back h5 {
    font-weight: 700;
    color: var(--text-main);
}

.card-back p {
    color: var(--accent);
}

/* ==============================
       PRICE PILL
       ============================== */

.price-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 1rem;
    background-color: var(--pill-bg);
    border-radius: 999px;
    font-size: 1.5rem !important;
    font-weight: 500;
    color: var(--text-main);
}

.price-pill i {
    color: var(--accent);
    margin-right: 0.4rem;
}

/* ==============================
       BACK ROW ICON + TEXT
       ============================== */

.back-row {
    display: flex;
    align-items: flex-start;
    margin-bottom: 0.8rem;
}

.back-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--pill-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    font-size: 1.2rem;
    margin-right: 0.8rem;
}

.back-row .small {
    color: var(--text-muted);
}

/* ==============================
       BUTTON ON BACK
       ============================== */

.permit-card .btn {
    background-color: var(--accent);
    border: none;
    color: #fff;
    font-weight: 600;
    padding-block: 0.55rem;
    border-radius: 999px;
}

.permit-card .btn:hover {
    background-color: var(--accent-dark);
}

/* ==============================
       CAROUSEL (JS DRIVEN)
       ============================== */

.permit-carousel {
    overflow: hidden;
    width: 100%;
    position: relative;
    padding-block: 1rem;
}

.permit-track {
    display: flex;
    gap: 1.5rem;
    width: max-content;
    transform: translateX(0);
    will-change: transform;
}

.permit-item {
    flex: 0 0 280px;
}

.permit-carousel.is-paused .permit-track {
    /* Visual style if you want when paused */
}

@media (max-width: 575.98px) {
    .permit-card {
        height: 420px;
    }

    .permit-item {
        flex-basis: 240px;
    }
}

/* === PERMIT CARDS FLIP + CAROUSEL === */

/* Card container */
.permit-card {
    position: relative;
    height: 380px;
    perspective: 1200px;
}

.permit-card .card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s ease;
    transform-style: preserve-3d;
}

.permit-card:hover .card-inner {
    transform: rotateY(180deg);
}

.permit-card .card-front,
.permit-card .card-back {
    position: absolute;
    inset: 0;
    border-radius: 26px;
    background-color: #ffffff;
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

/* FRONT */
.card-front {
    display: flex;
    flex-direction: column;
}

.card-front img.card-img-top {
    height: 210px;
    object-fit: cover;
}

.card-front .card-body {
    padding: 1.25rem 1.8rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* BACK */
.card-back {
    padding: 1.75rem 1.9rem;
    transform: rotateY(180deg);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* RTL text inside cards (important on your page) */
.permit-card .card-body,
.permit-card .card-back {
    direction: rtl;
    text-align: right;
}

/* Price pill */
.price-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 1rem;
    background-color: #f6efe3;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 500;
    color: #18212f;
}

.price-pill i {
    color: #d2a35a;
    margin-inline-start: 0.4rem;
    /* RTL friendly */
}

/* Back rows */
.back-row {
    display: flex;
    align-items: flex-start;
    margin-bottom: 0.8rem;
}

.back-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: #f6efe3;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d2a35a;
    font-size: 1.2rem;
    margin-inline-start: 0.8rem;
    /* RTL friendly */
}

.back-row .small {
    color: #8c9099;
}

/* Button on back */
.permit-card .btn {
    background-color: #d2a35a;
    border: none;
    color: #fff;
    font-weight: 600;
    padding-block: 0.55rem;
    border-radius: 999px;
}

.permit-card .btn:hover {
    background-color: #ba8740;
}

/* === CAROUSEL TRACK === */

/* Force LTR only for the scrolling logic, keep text RTL inside cards */
.permit-carousel {
    overflow: hidden;
    width: 100%;
    position: relative;
    padding-block: 1rem;
    direction: ltr;
    /* IMPORTANT */
}

.permit-track {
    display: flex;
    gap: 1.5rem;
    width: max-content;
    transform: translateX(0);
    will-change: transform;
}

.permit-item {
    flex: 0 0 280px;
    direction: ltr;
    /* scrolling math assumes LTR layout */
}

/* Pause style hook (JS only uses the class name) */
.permit-carousel.is-paused .permit-track {
    /* Optional styling when paused */
}

@media (max-width: 575.98px) {
    .permit-card {
        height: 420px;
    }

    .permit-item {
        flex-basis: 240px;
    }
}

/* ==============================
   FACILITIES INFINITE CAROUSEL
   ============================== */

.facilities-carousel {
    overflow: hidden;
    width: 100%;
    position: relative;
    padding-block: 1.5rem;
    direction: ltr;
    /* scrolling math uses LTR */
}

.facilities-track {
    display: flex;
    gap: 1.5rem;
    width: max-content;
    transform: translateX(0);
    will-change: transform;
}

/* Single slide width */
.facility-slide {
    flex: 0 0 260px;
}

/* Keep content RTL inside the card */
.facility-item {
    direction: rtl;
}

/* Optional hover scale */
.facility-item:hover {
    transform: translateY(-4px);
    transition: transform 0.2s ease;
}



@media (max-width: 991px) {
    .mobile {
        display: none !important;
    }

    .desktop {
        display: block !important;

    }
}

@media (max-width: 767px) {
    .mobile {
        display: block !important;
    }

    .desktop {
        display: none !important;
    }
}

@media (max-width: 479px) {
    .mobile {
        display: block !important;
    }

    .desktop {
        display: none !important;
    }
}