/* ============================================================
   Home Page — Responsive Overrides
   Covers: public/home.blade.php
   Targets: Calculator, results cards, features grid, slider,
            about section, counter section
   Breakpoints: ≤991px (tablet), ≤767px (mobile), ≤576px (small)
   ============================================================ */

/* ----------------------------------------------------------
   TABLET  (max-width: 991px)
   ---------------------------------------------------------- */
@media (max-width: 991px) {

    /* Calculator containers — loosen max-width */
    .pricing-one .container[style*="max-width: 1030px"],
    .pricing-one .container[style*="max-width: 1030px"] .container {
        max-width: 100% !important;
        padding-left: 1rem;
        padding-right: 1rem;
    }

    /* Calculator tab buttons — ensure they wrap */
    .pricing-one__main-tab-box .tab-buttons {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    /* Features grid — 2 columns on tablet */
    #calculator-options-section+.d-flex .row.g-3>.col-12.col-md-3,
    .pricing-one .row.g-3>.col-12.col-md-3 {
        flex: 0 0 50%;
        max-width: 50%;
    }

    /* Results section — stack on tablet */
    #results-section>.col-12.col-md-7,
    #results-section>.col-12.col-md-5 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    /* Fee display font size */
    .fw-extrabold[style*="font-size: 3rem"] {
        font-size: 2.25rem !important;
    }

    /* Total fee display */
    .fw-bold.text-brand[style*="font-size: 2.25rem"] {
        font-size: 1.75rem !important;
    }

    /* Slider text adjustments */
    .main-slider-three__title {
        font-size: 36px !important;
        line-height: 1.25 !important;
    }

    .main-slider-three__text {
        font-size: 15px !important;
    }

    .main-slider-three__text br {
        display: none;
    }

    /* About section image constraint */
    .about-three__img-two {
        max-width: 250px;
    }

    /* Calculator description text */
    .pricing-one .lead[style*="max-width: 720px"] {
        max-width: 100% !important;
    }
}

/* ----------------------------------------------------------
   MOBILE  (max-width: 767px)
   ---------------------------------------------------------- */
@media (max-width: 767px) {

    /* ---- Calculator Section ---- */
    .pricing-one {
        padding-top: 20 !important;
        padding-bottom: 40px !important;
    }

    /* Calculator containers full width */
    .pricing-one .container,
    .pricing-one .container-xl {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }

    .pricing-one .container[style*="max-width: 1030px"],
    .pricing-one .container[style*="max-width: 1030px"] .container {
        max-width: 100% !important;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }

    /* Calculator card less padding */
    .pricing-one .r-24.p-4.p-md-5 {
        padding: 1rem !important;
        border-radius: 1rem !important;
    }

    /* Card shadow sections */
    .card-shadow {
        border-radius: 1rem !important;
    }

    /* Radio option cards */
    .radio-card .radio-surface {
        padding: 0.85rem !important;
        border-radius: 0.85rem !important;
    }

    .radio-card .radio-surface .d-flex.gap-3 {
        gap: 0.5rem !important;
    }

    /* Radio card icon */
    .radio-card .rounded-3[style*="width: 48px"] {
        width: 40px !important;
        height: 40px !important;
        font-size: 0.9rem !important;
    }

    /* Toggle switch questions */
    #question-1,
    #question-2 {
        padding: 0.75rem !important;
    }

    /* ---- Results Display ---- */
    .fw-extrabold[style*="font-size: 3rem"] {
        font-size: 1.75rem !important;
    }

    .fw-bold.text-brand[style*="font-size: 2.25rem"] {
        font-size: 1.5rem !important;
    }

    /* Fee rows */
    .fee-row {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 0.25rem;
    }

    .fee-row .fw-bold[style*="font-size: 1.1rem"] {
        font-size: 1rem !important;
    }

    /* Total cost line */
    .d-flex.justify-content-between.align-items-end {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 0.5rem;
    }

    /* Results cards */
    #results-section .r-24.p-4.p-md-5 {
        padding: 1.25rem !important;
        border-radius: 1rem !important;
    }

    /* Mini icons in fee breakdown */
    .mini-icon {
        width: 28px;
        height: 28px;
        min-width: 28px;
    }

    /* ---- Features Grid ---- */
    .pricing-one .row.g-3>.col-12.col-md-3 {
        flex: 0 0 50%;
        max-width: 50%;
    }

    .pricing-one .row.g-3>.col-12.col-md-3 .p-4 {
        padding: 0.85rem !important;
    }

    .pricing-one .row.g-3>.col-12.col-md-3 .fw-bold[style*="font-size: 16px"] {
        font-size: 13px !important;
    }

    .pricing-one .row.g-3>.col-12.col-md-3 .rounded-circle[style*="width: 48px"] {
        width: 38px !important;
        height: 38px !important;
    }

    /* ---- Tab Buttons ---- */
    .pricing-one__main-tab-box .tab-buttons {
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 8px;
        justify-content: center;
        padding-top: 20px;
    }

    .pricing-one__main-tab-box .tab-btn {
        text-align: center;
    }

    .pricing-one__main-tab-box .tab-btn span {
        font-size: 13px !important;
        padding: 10px 16px !important;
        white-space: nowrap;
    }

    /* ---- Slider ---- */
    .main-slider-three__title {
        font-size: 28px !important;
        line-height: 1.3 !important;
    }

    .main-slider-three__title br {
        display: none;
    }

    .main-slider-three__sub-title {
        font-size: 14px !important;
    }

    .main-slider-three__text {
        font-size: 14px !important;
        line-height: 1.6 !important;
    }

    .main-slider-three__text br {
        display: none;
    }

    .main-slider-three__btn-box .thm-btn {
        padding: 12px 24px !important;
        font-size: 14px !important;
    }

    /* ---- About Section ---- */
    .about-three__img-two {
        max-width: 200px;
    }

    .about-one__points-content h4 {
        font-size: 16px;
    }

    .about-one__points-content p br {
        display: none;
    }

    /* ---- Counter Section ---- */
    .counter-one__top {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .counter-one .odometer {
        font-size: 36px !important;
    }

    /* ---- Calculator CTA button ---- */
    .btn-gold {
        font-size: 0.9rem;
        padding: 0.75rem 1rem !important;
    }

    /* Comparison header badge */
    .badge.rounded-pill {
        font-size: 0.75rem;
        padding: 0.35rem 0.5rem !important;
    }

    /* Description icon styling in results */
    .d-flex.align-items-center.justify-content-center.r-16[style*="width: 56px"] {
        width: 44px !important;
        height: 44px !important;
        font-size: 1.15rem !important;
    }

    /* Pattern overlay (decorative) */
    .pattern {
        display: none;
    }

    /* Video button in about section */
    .about-three__video-link {
        bottom: 50px;
    }

    /* Calculator section title */
    .pricing-one .section-title__title {
        font-size: 24px !important;
    }

    .pricing-one .section-title__tagline {
        font-size: 13px;
    }

    /* Calculation breakdown card */
    #calculation-breakdown {
        padding: 1rem !important;
    }
}

/* ----------------------------------------------------------
   SMALL MOBILE  (max-width: 576px)
   ---------------------------------------------------------- */
@media (max-width: 576px) {

    /* Features grid — single column */
    .pricing-one .row.g-3>.col-12.col-md-3 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    /* Slider — even smaller */
    .main-slider-three__title {
        font-size: 22px !important;
    }

    .main-slider-three__content {
        padding: 0 0.5rem;
    }

    /* Calculator section title */
    .pricing-one .section-title__title {
        font-size: 20px !important;
    }

    /* Results font sizes */
    .fw-extrabold[style*="font-size: 3rem"] {
        font-size: 1.5rem !important;
    }

    .fw-bold.text-brand[style*="font-size: 2.25rem"] {
        font-size: 1.25rem !important;
    }

    /* About section points — remove break tags */
    .about-three__right .section-title__title {
        font-size: 24px;
    }

    /* Counter section */
    .counter-one .section-title__title {
        font-size: 24px;
    }

    .counter-one .odometer {
        font-size: 30px !important;
    }

    /* Radio cards text */
    .radio-card .fw-bold.text-dark {
        font-size: 0.85rem;
    }

    .radio-card .text-secondary.small {
        font-size: 0.75rem;
    }

    /* Toggle switch labels */
    #question-1 .small.fw-semibold,
    #question-2 .small.fw-semibold {
        font-size: 0.8rem !important;
    }

    /* Chairman fees input */
    #chairman-fees {
        font-size: 1rem !important;
    }
}

/* ----------------------------------------------------------
   BLOG / NEWS SECTION  (mobile)
   ---------------------------------------------------------- */
@media (max-width: 767px) {

    /* ---- Blog Three Section ---- */
    .blog-three {
        padding: 60px 0 40px;
    }

    .blog-three__single {
        padding: 14px 14px 18px;
    }

    .blog-three__img {
        border-radius: 10px;
    }

    /* Card image height */
    .blog-three__img img {
        height: 180px;
        object-fit: cover;
        width: 100%;
    }

    /* Title */
    .blog-three__title {
        font-size: 17px !important;
        line-height: 1.45 !important;
        margin-top: 10px;
        margin-bottom: 8px;
    }

    /* Excerpt */
    .blog-three__text {
        font-size: 13px !important;
        line-height: 1.6 !important;
        margin-bottom: 10px;
    }

    /* Footer row (date + read-more) */
    .blog-three__footer-date {
        font-size: 11px !important;
        white-space: nowrap;
    }

    .blog-three__read-more {
        font-size: 13px !important;
    }

    /* Date badge (day/month box) */
    .blog-three__date p {
        height: 40px;
        width: 50px;
        font-size: 20px;
    }

    .blog-three__date span {
        height: 30px;
        width: 50px;
        font-size: 14px;
    }

    /* Carousel nav arrows */
    .blog-three__carousel.owl-theme .owl-nav {
        top: -70px;
    }

    .blog-three__carousel .owl-nav .owl-next,
    .blog-three__carousel .owl-nav .owl-prev {
        width: 38px;
        height: 38px;
        font-size: 15px !important;
    }

    /* Blog section heading */
    .blog-three .section-title__title {
        font-size: 24px !important;
    }
}

/* ----------------------------------------------------------
   PAGE HEADER  (all public pages — mobile)
   ---------------------------------------------------------- */
@media (max-width: 767px) {
    .page-header {
        padding: 60px 0 40px;
    }

    .page-header__inner h2 {
        font-size: 24px !important;
        line-height: 1.3;
    }

    .thm-breadcrumb {
        font-size: 12px;
        flex-wrap: wrap;
        gap: 4px;
    }
}

/* ----------------------------------------------------------
   GENERAL PUBLIC TYPOGRAPHY  (mobile)
   ---------------------------------------------------------- */
@media (max-width: 767px) {

    /* thm-btn */
    .thm-btn {
        padding: 12px 22px !important;
        font-size: 14px !important;
    }

    /* Section top padding reduction */
    section {
        overflow-x: hidden;
    }



    .section-title__title {
        padding-bottom: 10px;
    }

    /* EMarbles footer logo */
    .emarbles-footer-logo {
        height: 40px !important;
    }

    /* Members buttons on same row */
    .btn.center {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap;
        gap: 8px;
        justify-content: center;
        align-items: center;
        margin-top: 20px !important;
    }

    .btn.center .thm-btn {
        font-size: 12px !important;
        padding: 8px 14px !important;
        white-space: nowrap;
    }
}

@media (max-width: 576px) {

    /* Blog heading even smaller */
    .blog-three .section-title__title {
        font-size: 20px !important;
    }

    /* Card footer stacks gracefully */
    .blog-three__footer-date {
        font-size: 10px !important;
    }

    .blog-three__read-more {
        font-size: 12px !important;
    }
}

/* ----------------------------------------------------------
   COUNTER SECTION — mobile
   ---------------------------------------------------------- */
@media (max-width: 767px) {

    .counter-one {
        padding: 40px 0 0;
    }

    .counter-one__bg-box {
        height: 280px;
    }

    /* Title + button on one row */
    .counter-one__top {
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 20px;
    }

    .counter-one__top .section-title {
        margin-bottom: 0;
    }

    .counter-one__top .section-title__title {
        font-size: 22px !important;
    }

    .counter-one__btn-box {
        margin-top: 0 !important;
    }

    .counter-one__btn-box .thm-btn {
        padding: 10px 18px !important;
        font-size: 13px !important;
    }

    /* Counter cards smaller */
    .counter-one__icon {
        height: 70px;
        width: 70px;
        margin: 0 auto -30px;
    }

    .counter-one__icon span {
        font-size: 30px;
    }

    .counter-one__content {
        padding: 45px 12px 20px;
    }

    .counter-one__count-box h3,
    .counter-one__count-box span {
        font-size: 36px !important;
        line-height: 36px !important;
    }

    .counter-one__text {
        font-size: 14px;
        padding: 8px 14px;
    }
}

/* ----------------------------------------------------------
   PARTNERS / BRAND CAROUSEL — mobile (2 logos)
   ---------------------------------------------------------- */
@media (max-width: 767px) {

    .brand-one {
        padding: 40px 0 !important;
    }

    .brand-one .section-title__title {
        font-size: 22px !important;
    }

    .brand-one__single {
        padding: 10px;
    }

    .brand-one__single img {
        max-height: 100px;
        object-fit: contain;
    }
}

/* ----------------------------------------------------------
   ABOUT SECTION (points grid) — mobile
   ---------------------------------------------------------- */
@media (max-width: 767px) {

    /* About section overall padding */
    .about-three {
        padding: 60px 0 40px !important;
    }

    /* Center the image on mobile */
    .about-three__left {
        text-align: center;
    }

    .about-three__img-box {
        text-align: center;
        display: flex;
        justify-content: center;
    }

    .about-three__img {
        margin: 0 auto;
        max-width: 90%;
        display: block;
        left: auto !important;
        right: auto !important;
    }

    .about-three__img img {
        width: 100%;
        border-radius: var(--judges-bdr-radius);
    }

    /* Hide floating elements on mobile */
    .about-three__satisfied-box,
    .about-three__shape-1,
    .about-three__shape-2,
    .about-three__high-quality-service-box {
        display: none !important;
    }

    /* Center title and tagline */
    .about-one__right .section-title {
        text-align: center !important;
    }

    .about-one__right .section-title__tagline-box {
        justify-content: center;
    }

    .about-one__right .section-title__title {
        font-size: 24px !important;
    }

    /* Points box: two columns side by side like desktop */
    .about-one__points-box {
        flex-direction: row !important;
        gap: 10px;
    }

    .about-one__points-box .about-one__points {
        flex: 0 0 calc(50% - 5px);
        max-width: calc(50% - 5px);
    }

    /* Each item compact */
    .about-one__points li {
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        gap: 6px;
        border-bottom: none;
        padding: 12px 6px;
        margin-bottom: 8px;
        background: rgba(183, 144, 36, 0.04);
        border-radius: 12px;
        border: 1px solid rgba(183, 144, 36, 0.1);
    }

    .about-one__points li:last-child {
        margin-bottom: 0;
    }

    /* Smaller icons */
    .about-one__points-icon i,
    .about-one__points-icon span {
        font-size: 28px !important;
    }

    /* Smaller text */
    .about-one__points-content h4 {
        font-size: 12px !important;
        line-height: 1.4 !important;
    }

    /* Remove the divider on the second list */
    .about-one__points--two {
        margin-top: 0 !important;
        border-top: none !important;
        padding-top: 0 !important;
    }

    /* About button — centered */
    .about-one__btn-box {
        margin-top: 24px;
        text-align: center;
    }
}

@media (max-width: 576px) {

    .about-one__points-icon i,
    .about-one__points-icon span {
        font-size: 24px !important;
    }

    .about-one__points-content h4 {
        font-size: 11px !important;
    }

    .about-one__points li {
        padding: 10px 4px;
    }
}

/* ----------------------------------------------------------
   Downloads / Rules & Regulations sidebar list (mobile)
   ---------------------------------------------------------- */
@media (max-width: 767px) {
    .service-details__sidebar-single-download ul li {
        padding: 10px 0;
    }

    .service-details__sidebar-single-download ul li .content-box .icon span {
        font-size: 32px !important;
        line-height: 32px !important;
    }

    .service-details__sidebar-single-download ul li .content-box .icon {
        margin-left: 10px !important;
    }

    .service-details__sidebar-single-download ul li .content-box .text-box {
        margin-left: 10px !important;
    }

    .service-details__sidebar-single-download ul li .content-box .text-box h2 {
        font-size: 15px !important;
        line-height: 22px !important;
    }

    .service-details__sidebar-single-download ul li .content-box .text-box h2 a {
        font-size: 15px !important;
    }

    .service-details__sidebar-single-download ul li .content-box .text-box p {
        font-size: 13px !important;
        line-height: 20px !important;
    }

    .service-details__sidebar-single-download ul li .btn-box a {
        width: 35px !important;
        height: 35px !important;
    }

    .service-details__sidebar-single-download ul li .btn-box a span::before,
    .service-details__sidebar-single-download ul li .btn-box a svg {
        font-size: 16px !important;
    }

    /* Footer spacing */
    .site-footer {
        padding-bottom: 30px;
    }

    /* 1. Add padding top in mobile view for service-details__sidebar-single-download col-xl-6 */
    .service-details__faq-box .service-details__sidebar-single-download {
        padding-top: 15px;
    }

    /* 2. Make القيم (Values) 2 items per row on mobile */
    .service-details__points-list {
        display: flex;
        flex-wrap: wrap;
        margin-right: 0 !important;
    }

    .service-details__points-list li {
        width: 50%;
        margin-top: 10px !important;
    }

    /* 3. Update title and body font size in mobile view */
    .service-details__title-1 {
        font-size: 28px !important;
        line-height: 38px !important;
        margin-top: 30px !important;
        margin-bottom: 15px !important;
    }

    .service-details__text-1,
    .service-details__text-2,
    .service-details__img-box-content-text {
        font-size: 15px !important;
        line-height: 24px !important;
    }

    .service-details__img-box-content-title {
        font-size: 20px !important;
        line-height: 28px !important;
    }

    .service-details__services-title {
        font-size: 20px !important;
        line-height: 28px !important;
        margin-bottom: 20px !important;
    }

    /* Footer Copyright & Logo sizing */
    #CopyRights p {
        font-size: 16px !important;
    }

    #CopyRights span {
        font-size: 15px !important;
    }

    #CopyRights .emarbles-footer-logo {
        height: 120px !important;
    }

    #CopyRights {
        padding-bottom: 20px !important;
        width: 100% !important;
        flex: 0 0 100% !important;
    }

    [dir="rtl"] .footer-widget__right {
        margin-right: 15px !important;
        margin-left: 0 !important;
    }

    /* Quick Links and Contact Us on one row in mobile */
    .footer-widget__right-bottom .row {
        display: flex;
        flex-wrap: wrap;
    }

    .footer-widget__right-bottom .row>.col-xl-4.col-lg-4.col-md-4 {
        width: 50% !important;
        flex: 0 0 50% !important;
        padding-left: 5px;
        padding-right: 5px;
    }

    .footer-widget__title {
        font-size: 16px !important;
    }

    /* Mobile Nav Contact (Email & Phone in one row, no gold circle) */
    [dir="rtl"] .mobile-nav__contact,
    .mobile-nav__contact {
        display: flex !important;
        flex-direction: row !important;
        justify-content: center !important;
        gap: 20px !important;
        flex-wrap: wrap !important;
        border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
        padding-top: 20px !important;
    }

    [dir="rtl"] .mobile-nav__contact li,
    .mobile-nav__contact li {
        width: auto !important;
        flex-direction: row-reverse !important;
        border-top: none !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    [dir="rtl"] .mobile-nav__contact li i,
    .mobile-nav__contact li>i {
        background-color: transparent !important;
        width: auto !important;
        height: auto !important;
        border-radius: 0 !important;
        color: var(--judges-base) !important;
        margin: 0 !important;
        font-size: 18px !important;
    }

    [dir="rtl"] .mobile-nav__contact li a,
    .mobile-nav__contact li a {
        font-size: 13px !important;
    }
}