/* =====================================================================
   modern-responsive.css — Responsive overrides for the modernisation layer
   ===================================================================== */


/* ── Tablet: 768px – 991px ──────────────────────────────────────────── */
@media (min-width: 768px) and (max-width: 991px) {

    /* Section padding — reduce from 120px to something less airy */
    .pt-120 { padding-top:    80px !important; }
    .pb-120 { padding-bottom: 80px !important; }
    .pt-90  { padding-top:    60px !important; }
    .pb-90  { padding-bottom: 60px !important; }
    .pt-80  { padding-top:    56px !important; }
    .pb-80  { padding-bottom: 56px !important; }
    .pt-50  { padding-top:    36px !important; }
    .pb-50  { padding-bottom: 36px !important; }

    /* Card lift reduced on narrower screens */
    .courses-item:hover,
    .event-item:hover,
    .single-post2:hover {
        transform: translateY(-5px) !important;
    }

    /* Breadcrumb */
    .breadcrumb-title h2 { font-size: 28px !important; }

    /* Glassmorphism — slightly less blur to keep performance light */
    .header-three .sticky-menu {
        -webkit-backdrop-filter: blur(10px) saturate(160%);
        backdrop-filter:         blur(10px) saturate(160%);
    }
}


/* ── Mobile: < 768px ────────────────────────────────────────────────── */
@media (max-width: 767px) {

    /* Compact section padding */
    .pt-120 { padding-top:    56px !important; }
    .pb-120 { padding-bottom: 56px !important; }
    .pt-90  { padding-top:    48px !important; }
    .pb-90  { padding-bottom: 48px !important; }
    .pt-80  { padding-top:    42px !important; }
    .pb-80  { padding-bottom: 42px !important; }
    .pt-50  { padding-top:    28px !important; }
    .pb-50  { padding-bottom: 28px !important; }

    /* ── Cards ── */
    .courses-item,
    .event-item,
    .single-post2 {
        border-radius: 8px !important;
        margin-bottom: 20px !important;
    }

    /* Gentler lift on mobile (touch interactions don't have hover states
       but JS-driven hovers may fire on tap) */
    .courses-item:hover,
    .event-item:hover,
    .single-post2:hover {
        transform: translateY(-4px) !important;
    }

    /* ── Hero ── */
    .s-slider-content h2,
    .slider-content h2 {
        font-size:   clamp(22px, 6.5vw, 36px) !important;
        line-height: 1.22 !important;
    }

    .s-slider-content p,
    .slider-content p {
        font-size:   14px !important;
        line-height: 1.65 !important;
    }

    /* ── Breadcrumb ── */
    .breadcrumb-area {
        padding:    36px 0 !important;
        min-height: 110px !important;
    }
    .breadcrumb-title h2 { font-size: 22px !important; }

    /* Breadcrumb items wrap nicely */
    .breadcrumb-wrap2 ol {
        flex-wrap: wrap;
    }

    /* ── Features boxes ── */
    .services-box07 {
        border-radius: 8px   !important;
        margin-bottom: 14px  !important;
    }
    .services-box07:hover {
        transform: translateY(-3px) !important;
    }

    /* ── Navigation underline — hide on mobile (menu is hidden anyway) ── */
    .header-three .main-menu ul li > a::after {
        display: none !important;
    }

    /* Glassmorphism fallback — almost opaque for small screens */
    .header-three .sticky-menu {
        background:              rgba(255, 255, 255, 0.97) !important;
        -webkit-backdrop-filter: blur(8px);
        backdrop-filter:         blur(8px);
    }

    /* ── Scroll-to-top ── */
    #scrollUp {
        right:       15px  !important;
        bottom:      18px  !important;
        width:       40px  !important;
        height:      40px  !important;
        line-height: 40px  !important;
        font-size:   17px  !important;
    }

    /* ── Footer social ── keep touch targets comfortable */
    .footer-social a {
        width:        44px !important;
        height:       44px !important;
        line-height:  44px !important;
        font-size:    17px !important;
        margin-bottom: 6px !important;
    }

    /* ── Gallery overlay ──
       On touch devices the ::after overlay slides up on tap because CSS
       :hover fires on the first tap.  Keep it permanently visible at low
       opacity so users know items are tappable.                          */
    .portfolio .col3 .grid-item .box a::after {
        transform: translateY(0)   !important;
        opacity:   0.72            !important;
        transition: none           !important;
    }
    .portfolio .col3 .grid-item .box a::before {
        opacity:   1 !important;
        transform: translate(-50%, -50%) !important;
    }

    /* ── Ticker — slightly faster on small screens ── */
    .ums-ticker-inner {
        animation-duration: 24s !important;
    }

    /* ── Button padding ── */
    .btn {
        padding: 16px 24px !important;
        font-size: 15px    !important;
    }

    /* Copyright language dropdown */
    .copyright-wrap .dropdown .btn {
        padding: 7px 11px !important;
        font-size: 13px   !important;
    }
}


/* ── Large mobile: 480px – 767px ───────────────────────────────────── */
@media (min-width: 480px) and (max-width: 767px) {
    .s-slider-content h2,
    .slider-content h2 {
        font-size: clamp(26px, 5.5vw, 36px) !important;
    }
}


/* ── Large desktop: > 1500px ─────────────────────────────────────────── */
@media (min-width: 1500px) {
    /* Slightly taller hero on very large displays */
    .slider-area .single-slider {
        min-height: 680px !important;
    }
}


/* ── High-DPI / Retina display ──────────────────────────────────────── */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Ensure box-shadows look crisp on retina */
    .courses-item,
    .event-item,
    .single-post2 {
        box-shadow: 0 1px 8px rgba(0, 0, 0, 0.06) !important;
    }
}


/* ── Mobile: pill buttons in navbar ────────────────────────────────── */
@media (max-width: 991px) {
    .d-flex.d-lg-none .btn {
        border-radius: 50px !important;
    }
}

/* ── Slider CTA row — stack on phones ────────────────────────────── */
@media (max-width: 575px) {
    .slider-cta-row {
        flex-direction: column !important;
        gap: 12px !important;
    }
    .slider-cta-row .slider-btn .btn {
        width: 100%;
        text-align: center;
    }
}

/* ── Testimonial cards — comfortable on small screens ───────────── */
@media (max-width: 767px) {
    .single-testimonial {
        padding: 24px 18px !important;
        margin: 0 8px !important;
    }
}
