/* Footer templates must not hardcode brand colors.
       We keep existing markup but override blue/purple Tailwind utilities inside this scope
       to always use the dynamic theme variables from settings (e.g. --color-primary/secondary). */
    .mk-hf-scope {
        --mk-primary: var(--color-primary);
        --mk-secondary: var(--color-secondary);
        --mk-primary-tint: color-mix(in srgb, var(--color-primary) 10%, white);
        --mk-primary-tint-2: color-mix(in srgb, var(--color-primary) 16%, white);

        --mk-bg: var(--color-bg);
        --mk-bg-soft: var(--color-bg-soft);
        --mk-card: var(--color-card);
        --mk-border: var(--color-border);
        --mk-text: var(--color-text);
        --mk-text-muted: var(--color-text-muted);

        /* Inverse surface (for “dark” footer template) derived from theme + primary */
        --mk-inverse-bg: color-mix(in srgb, var(--color-theme) 88%, var(--mk-primary));
        --mk-inverse-card: color-mix(in srgb, var(--mk-inverse-bg) 88%, var(--mk-primary));
        --mk-inverse-border: color-mix(in srgb, white 18%, transparent);
        --mk-inverse-text: color-mix(in srgb, white 86%, transparent);
        --mk-inverse-muted: color-mix(in srgb, white 66%, transparent);
    }

    /* Neutral (slate) overrides inside footer scope */
    .mk-hf-scope .bg-white { background-color: var(--mk-card) !important; }
    .mk-hf-scope .bg-slate-50 { background-color: var(--mk-bg) !important; }
    .mk-hf-scope .bg-slate-100 { background-color: var(--mk-bg-soft) !important; }
    .mk-hf-scope .border-slate-100,
    .mk-hf-scope .border-slate-200 { border-color: var(--mk-border) !important; }
    .mk-hf-scope .text-slate-900 { color: var(--mk-text) !important; }
    .mk-hf-scope .text-slate-600,
    .mk-hf-scope .text-slate-500,
    .mk-hf-scope .text-slate-400 { color: var(--mk-text-muted) !important; }

    /* Dark template mapping (slate-950 / slate-900 / slate-800 / slate-700) */
    .mk-hf-scope .bg-slate-950 { background-color: var(--mk-inverse-bg) !important; }
    .mk-hf-scope .bg-slate-900 { background-color: var(--mk-inverse-card) !important; }
    .mk-hf-scope .border-slate-900,
    .mk-hf-scope .border-slate-800 { border-color: var(--mk-inverse-border) !important; }

    .mk-hf-scope .text-white { color: var(--mk-inverse-text) !important; }
    .mk-hf-scope .text-slate-300,
    .mk-hf-scope .text-slate-400 { color: var(--mk-inverse-muted) !important; }
    .mk-hf-scope .text-slate-500 { color: color-mix(in srgb, var(--mk-inverse-muted) 85%, transparent) !important; }

    .mk-hf-scope .text-blue-600,
    .mk-hf-scope .text-blue-500,
    .mk-hf-scope .text-blue-400 {
        color: var(--mk-primary) !important;
    }
    .mk-hf-scope .bg-blue-600,
    .mk-hf-scope .bg-blue-500 {
        background-color: var(--mk-primary) !important;
    }
    .mk-hf-scope .bg-blue-50,
    .mk-hf-scope .bg-blue-100 {
        background-color: var(--mk-primary-tint) !important;
    }
    .mk-hf-scope .border-blue-500,
    .mk-hf-scope .border-blue-100,
    .mk-hf-scope .border-blue-200 {
        border-color: color-mix(in srgb, var(--mk-primary) 22%, transparent) !important;
    }
    .mk-hf-scope .hover\:text-blue-600:hover,
    .mk-hf-scope .hover\:text-blue-500:hover,
    .mk-hf-scope .hover\:text-blue-400:hover {
        color: var(--mk-primary) !important;
    }
    .mk-hf-scope .hover\:bg-blue-50:hover,
    .mk-hf-scope .hover\:bg-blue-100:hover,
    .mk-hf-scope .hover\:bg-blue-500:hover,
    .mk-hf-scope .hover\:bg-blue-600:hover {
        background-color: var(--mk-primary-tint-2) !important;
    }
    .mk-hf-scope .focus\:border-blue-500:focus {
        border-color: var(--mk-primary) !important;
    }
    .mk-hf-scope .bg-purple-600,
    .mk-hf-scope .bg-purple-500 {
        background-color: var(--mk-secondary) !important;
    }

    /* Safety overrides for other accent utilities (avoid fixed palettes drifting from brand vars). */
    .mk-hf-scope .text-green-700,
    .mk-hf-scope .text-green-600,
    .mk-hf-scope .text-green-500,
    .mk-hf-scope .text-emerald-600,
    .mk-hf-scope .text-teal-600,
    .mk-hf-scope .text-amber-500,
    .mk-hf-scope .text-pink-500,
    .mk-hf-scope .text-rose-500 {
        color: var(--mk-secondary) !important;
    }
    .mk-hf-scope .bg-green-600,
    .mk-hf-scope .bg-green-500,
    .mk-hf-scope .bg-emerald-500,
    .mk-hf-scope .bg-teal-500,
    .mk-hf-scope .bg-amber-500,
    .mk-hf-scope .bg-pink-500,
    .mk-hf-scope .bg-rose-500 {
        background-color: var(--mk-secondary) !important;
    }
    .mk-hf-scope .bg-green-50,
    .mk-hf-scope .bg-green-100,
    .mk-hf-scope .bg-emerald-50,
    .mk-hf-scope .bg-emerald-100,
    .mk-hf-scope .bg-amber-50,
    .mk-hf-scope .bg-pink-50,
    .mk-hf-scope .bg-rose-50 {
        background-color: color-mix(in srgb, var(--mk-secondary) 12%, white) !important;
    }
    .mk-hf-scope .border-green-100,
    .mk-hf-scope .border-green-200,
    .mk-hf-scope .border-emerald-100,
    .mk-hf-scope .border-emerald-200,
    .mk-hf-scope .border-amber-500 {
        border-color: color-mix(in srgb, var(--mk-secondary) 22%, transparent) !important;
    }


/* =========================================================================
   MoikoRent Unified Minimalist Modern Footer (Template 28 - Midnight Navy)
   Self-contained styles for consistent rendering across Home & all 41+ Cities
   ========================================================================= */
.mk-footer-navy {
    position: relative;
    margin-top: 4rem;
    background-color: #0b1220;
    background-image:
        radial-gradient(640px 240px at 10% 0%, rgba(6, 89, 252, 0.14), transparent 70%),
        radial-gradient(540px 220px at 90% 0%, rgba(255, 146, 61, 0.10), transparent 70%);
    color: #cbd5e1;
    overflow: hidden;
}
.mk-footer-navy::before {
    content: '';
    display: block;
    height: 2px;
    width: 100%;
    background: linear-gradient(90deg, #0659fc 0%, #3b82f6 52%, #ff923d 100%);
}
.mk-footer-navy__inner {
    max-width: 80rem;
    margin: 0 auto;
    padding: 2.75rem 1.25rem 2rem;
}
.mk-footer-navy__top {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
    padding-bottom: 1.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
@media (min-width: 1024px) {
    .mk-footer-navy__top {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 2rem;
    }
}
.mk-footer-navy__brand {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-width: 22rem;
}
.mk-footer-navy__brand-row {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}
.mk-footer-navy__brand-logo {
    height: 30px;
    width: auto;
    object-fit: contain;
    display: block;
}
.mk-footer-navy__brand-name {
    color: #ffffff !important;
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}
.mk-footer-navy__tagline {
    color: #94a3b8 !important;
    font-size: 0.8125rem;
    line-height: 1.5;
    margin: 0;
}
.mk-footer-navy__nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}
.mk-footer-navy__nav a {
    color: #cbd5e1 !important;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.18s ease;
}
.mk-footer-navy__nav a:hover {
    color: #ffffff !important;
}
.mk-footer-navy__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.625rem;
}
.mk-footer-navy__wa {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 1rem;
    border-radius: 9999px;
    background: rgba(6, 89, 252, 0.16);
    border: 1px solid rgba(59, 130, 246, 0.35);
    color: #ffffff !important;
    font-size: 0.8125rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.mk-footer-navy__wa:hover {
    background: #0659fc;
    border-color: #0659fc;
    transform: translateY(-1px);
}
.mk-footer-navy__social {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.10);
    color: #94a3b8 !important;
    text-decoration: none;
    transition: color 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}
.mk-footer-navy__social:hover {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.10);
    border-color: rgba(255, 255, 255, 0.24);
}
/* Collapsible 41+ City SEO Directory (100% crawlable in DOM, visually sleek) */
.mk-footer-navy__cities {
    padding: 1.15rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.mk-footer-navy__cities summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    color: #94a3b8;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    user-select: none;
    transition: color 0.18s ease;
}
.mk-footer-navy__cities summary::-webkit-details-marker {
    display: none;
}
.mk-footer-navy__cities summary:hover {
    color: #e2e8f0;
}
.mk-footer-navy__cities-chevron {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    transition: transform 0.22s ease;
}
.mk-footer-navy__cities[open] .mk-footer-navy__cities-chevron {
    transform: rotate(180deg);
}
.mk-footer-navy__cities-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem 0.55rem;
    margin-top: 1rem;
}
.mk-footer-navy__city-link {
    display: inline-block;
    padding: 0.28rem 0.65rem;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.07);
    color: #94a3b8 !important;
    font-size: 0.75rem;
    line-height: 1.3;
    text-decoration: none;
    transition: color 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}
.mk-footer-navy__city-link:hover,
.mk-footer-navy__city-link.is-active {
    color: #ffffff !important;
    background: rgba(6, 89, 252, 0.18);
    border-color: rgba(59, 130, 246, 0.42);
}
.mk-footer-navy__bottom {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding-top: 1.25rem;
    font-size: 0.75rem;
    color: #64748b !important;
}
@media (min-width: 768px) {
    .mk-footer-navy__bottom {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
}
.mk-footer-navy__trust {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1rem;
    color: #64748b !important;
}
.mk-footer-navy__dot {
    width: 3px;
    height: 3px;
    border-radius: 9999px;
    background: rgba(148, 163, 184, 0.45);
    display: inline-block;
}


/* =========================================================================
   MoikoRent Floating Liquid-Glass Curved-Notch Mobile Bottom Nav (<= 1023px)
   Brand-locked to Midnight Navy Glass + Royal Blue (#0659fc) + Vibrant Orange (#ff923d)
   ========================================================================= */
.mk-mobile-bnav {
    display: none;
}

@media (max-width: 1023px) {
    .mk-mobile-bnav {
        display: block;
        position: fixed;
        left: 0;
        right: 0;
        bottom: calc(10px + env(safe-area-inset-bottom, 0px));
        z-index: 8800;
        pointer-events: none;
        padding: 0 12px;
        transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.22s ease;
    }

    /* Hide smoothly whenever a fullscreen modal/sheet/drawer is open */
    html.modal-open .mk-mobile-bnav,
    body.modal-open .mk-mobile-bnav,
    html.mk-drawer-open .mk-mobile-bnav {
        transform: translateY(140%);
        opacity: 0;
        pointer-events: none;
    }

    /* Lift collapsed/floating mobile sticky search bar cleanly above floating curved-notch dock */
    .sticky-search-wrapper:not(.ss-expanded) {
        bottom: calc(98px + env(safe-area-inset-bottom, 0px)) !important;
    }

    /* Give mobile footer generous bottom breathing room above the floating dock */
    .mk-footer-navy__inner {
        padding-bottom: calc(8.75rem + env(safe-area-inset-bottom, 0px));
    }

    .mk-mobile-bnav__dock {
        position: relative;
        width: min(calc(100vw - 24px), 440px);
        height: 86px;
        margin: 0 auto;
        pointer-events: auto;
        filter: drop-shadow(0 14px 26px rgba(11, 18, 32, 0.32));
        opacity: 0;
        transform: translateY(10px);
        transition: opacity 0.24s ease, transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
    }

    .mk-mobile-bnav__dock.is-ready {
        opacity: 1;
        transform: translateY(0);
    }

    /* Real translucent frosted-glass surface clipped to the live SVG curved-notch path */
    .mk-mobile-bnav__glass {
        position: absolute;
        left: 0;
        right: 0;
        top: 24px;
        height: 62px;
        z-index: 1;
        overflow: hidden;
        background: linear-gradient(
            180deg,
            rgba(15, 23, 42, 0.74) 0%,
            rgba(11, 18, 32, 0.86) 100%
        );
        -webkit-backdrop-filter: blur(22px) saturate(185%);
        backdrop-filter: blur(22px) saturate(185%);
        pointer-events: none;
        display: none;
    }

    .mk-mobile-bnav__dock.has-css-clip .mk-mobile-bnav__glass {
        display: block;
    }

    /* Subtle moving MoikoRent ambient reflection directly beneath the curved cradle */
    .mk-mobile-bnav__glow {
        position: absolute;
        top: -8px;
        left: 0;
        width: 112px;
        height: 56px;
        margin-left: -56px;
        border-radius: 999px;
        background: radial-gradient(
            ellipse at center,
            color-mix(in srgb, var(--color-primary, #0659fc) 44%, transparent) 0%,
            color-mix(in srgb, var(--color-secondary, #ff923d) 24%, transparent) 52%,
            transparent 76%
        );
        pointer-events: none;
        will-change: transform;
    }

    /* SVG luminous glass rim outline + non-clip-path progressive fallback fill */
    .mk-mobile-bnav__svg {
        position: absolute;
        left: 0;
        top: 24px;
        width: 100%;
        height: 62px;
        z-index: 2;
        overflow: visible;
        pointer-events: none;
    }

    .mk-mobile-bnav__fallback {
        fill: rgba(11, 18, 32, 0.90);
    }

    .mk-mobile-bnav__dock.has-css-clip .mk-mobile-bnav__fallback {
        fill: transparent;
    }

    .mk-mobile-bnav__rim {
        filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.22));
    }

    /* Floating MoikoRent Brand Orb nestled cleanly inside the curved notch */
    .mk-mobile-bnav__orb {
        position: absolute;
        top: 1px;
        left: 0;
        width: 48px;
        height: 48px;
        margin-left: -24px;
        border-radius: 999px;
        z-index: 3;
        pointer-events: none;
        background: linear-gradient(
            135deg,
            var(--color-primary, #0659fc) 0%,
            #2563eb 54%,
            var(--color-secondary, #ff923d) 100%
        );
        border: 1.5px solid rgba(255, 255, 255, 0.56);
        box-shadow:
            0 10px 22px color-mix(in srgb, var(--color-primary, #0659fc) 46%, transparent),
            0 0 14px color-mix(in srgb, var(--color-secondary, #ff923d) 30%, transparent),
            inset 0 1.5px 2px rgba(255, 255, 255, 0.52);
        will-change: transform;
        transition: box-shadow 0.24s ease;
    }

    /* Top glass specular sheen inside the floating orb */
    .mk-mobile-bnav__orb::before {
        content: '';
        position: absolute;
        inset: 2px;
        border-radius: 999px;
        background: radial-gradient(
            circle at 32% 22%,
            rgba(255, 255, 255, 0.44) 0%,
            rgba(255, 255, 255, 0.08) 42%,
            transparent 68%
        );
        pointer-events: none;
    }

    .mk-mobile-bnav__orb.is-moving {
        box-shadow:
            0 12px 26px color-mix(in srgb, var(--color-primary, #0659fc) 55%, transparent),
            0 0 18px color-mix(in srgb, var(--color-secondary, #ff923d) 42%, transparent),
            inset 0 1.5px 2px rgba(255, 255, 255, 0.62);
    }

    /* Subtle sleek horizontal bottom highlight bar inside the floating pill */
    .mk-mobile-bnav__homebar {
        position: absolute;
        left: 50%;
        bottom: 4px;
        width: 58px;
        height: 2.5px;
        border-radius: 999px;
        transform: translateX(-50%);
        background: linear-gradient(
            90deg,
            rgba(255, 255, 255, 0.14) 0%,
            rgba(255, 255, 255, 0.42) 50%,
            rgba(255, 255, 255, 0.14) 100%
        );
        z-index: 3;
        pointer-events: none;
    }

    /* 5-Column Interactive Items Overlay */
    .mk-mobile-bnav__items {
        position: relative;
        z-index: 4;
        display: grid;
        grid-template-columns: repeat(5, minmax(0, 1fr));
        height: 86px;
        padding: 0 10px;
    }

    .mk-mobile-bnav__item {
        position: relative;
        display: block;
        height: 86px;
        padding: 0;
        color: rgba(226, 232, 240, 0.80) !important;
        text-decoration: none;
        background: transparent;
        border: 0;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
        user-select: none;
    }

    .mk-mobile-bnav__icon {
        position: absolute;
        top: 34px;
        left: 50%;
        width: 24px;
        height: 24px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        color: rgba(241, 245, 249, 0.84);
        transform: translate(-50%, 0) scale(1);
        transition:
            transform 0.34s cubic-bezier(0.34, 1.48, 0.64, 1),
            color 0.22s ease,
            filter 0.22s ease;
        will-change: transform;
    }

    .mk-mobile-bnav__icon svg {
        width: 21px;
        height: 21px;
    }

    .mk-mobile-bnav__label {
        position: absolute;
        left: 0;
        right: 0;
        bottom: 11px;
        text-align: center;
        font-size: 10px;
        font-weight: 600;
        line-height: 1;
        letter-spacing: 0.01em;
        color: rgba(203, 213, 225, 0.74);
        transition: color 0.22s ease, transform 0.22s ease, opacity 0.22s ease;
    }

    /* Active tab: icon glides smoothly UP into the exact center of the floating orb */
    .mk-mobile-bnav__item.is-active .mk-mobile-bnav__icon {
        color: #ffffff !important;
        transform: translate(-50%, -21px) scale(1.08);
        filter: drop-shadow(0 2px 6px rgba(11, 18, 32, 0.28));
    }

    .mk-mobile-bnav__item.is-active .mk-mobile-bnav__label {
        color: #ffffff !important;
        font-weight: 700;
        text-shadow: 0 0 10px color-mix(in srgb, var(--color-secondary, #ff923d) 55%, transparent);
    }

    /* Tactile spring press micro-interaction */
    .mk-mobile-bnav__item:active:not(.is-active) .mk-mobile-bnav__icon {
        transform: translate(-50%, 2px) scale(0.88);
        color: var(--color-secondary, #ff923d);
    }

    .mk-mobile-bnav__item.is-active:active .mk-mobile-bnav__icon {
        transform: translate(-50%, -19px) scale(0.96);
    }

    @media (prefers-reduced-motion: reduce) {
        .mk-mobile-bnav,
        .mk-mobile-bnav__dock,
        .mk-mobile-bnav__icon,
        .mk-mobile-bnav__label {
            transition: none !important;
        }
    }
}
