/* SpeedyBook Modern Public Layout Skeleton
   Scope: public_layout.modern
   Namespace: .sb-layout-modern
*/

.sb-layout-modern {
    --sb-layout-header-height: 72px;
    --sb-layout-container-gap: 16px;
    --sb-layout-panel-width: min(85vw, 350px);
    min-height: 100vh;
    background: var(--sb-bg-soft, #f8f9fa);
    color: var(--sb-text-main, #2d3436);
    overflow-x: clip !important;
    overflow-y: visible !important;
}

.sb-layout-modern a {
    text-decoration: none;
}

.sb-header-modern {
    position: sticky;
    top: 0;
    z-index: 9999;
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid transparent;
    transition: box-shadow 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

@supports (backdrop-filter: blur(8px)) {
    .sb-header-modern {
        background: rgba(255, 255, 255, 0.85);
        backdrop-filter: blur(8px);
    }
}

.sb-header-modern--scrolled {
    border-bottom-color: rgba(0, 0, 0, 0.05);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
}

.sb-header-modern--fixed {
    position: sticky;
    top: 0;
}

@media (max-width: 991px) {
    .sb-header-modern--static-mobile {
        position: static !important;
    }
}

.sb-header-modern__bar {
    min-height: var(--sb-layout-header-height);
}

.sb-header-modern__inner {
    min-height: var(--sb-layout-header-height);
    display: flex;
    align-items: center;
    gap: var(--sb-layout-container-gap);
    padding: 0 16px;
}

.sb-header-modern__brand {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
}

.sb-header-modern__logo-link,
.sb-mobile-menu__logo-link,
.sb-footer-modern__logo-link {
    display: inline-flex;
    align-items: center;
}

.sb-header-modern__logo,
.sb-mobile-menu__logo,
.sb-footer-modern__logo {
    display: block;
    max-width: 176px;
    height: auto;
}

.sb-header-modern__desktop-nav {
    display: none;
    flex: 1 1 auto;
    min-width: 0;
}

.sb-header-modern__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-left: auto;
}

.sb-header-modern__lang,
.sb-header-modern__user,
.sb-header-modern__cta {
    display: none;
}

.sb-header-modern__mobile-toggle,
.sb-mobile-menu__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: var(--sb-radius, 12px);
    background: var(--sb-bg-soft, #f8f9fa);
    color: var(--sb-text-main, #2d3436);
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.sb-header-modern__mobile-toggle:active,
.sb-mobile-menu__close:active {
    transform: scale(0.95);
    background: #e9ecef;
}

.sb-header-modern__mobile-toggle svg {
    width: 22px;
    height: 16px;
    fill: currentColor;
}

.sb-mobile-menu__close svg {
    width: 14px;
    height: 14px;
    fill: currentColor;
}

.sb-desktop-menu,
.sb-desktop-menu__list,
.sb-mobile-menu__list,
.sb-footer-modern__nav-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.sb-desktop-menu__list {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.sb-desktop-menu__link,
.sb-header-modern__cta-link,
.sb-mobile-menu__link,
.sb-mobile-menu__cta-link,
.sb-footer-modern__nav-link {
    display: inline-flex;
    align-items: center;
    border-radius: var(--sb-radius, 12px);
    transition: background-color .2s ease, color .2s ease, box-shadow .2s ease, transform .2s ease;
    white-space: nowrap;
}

.sb-desktop-menu__link {
    position: relative;
    min-height: 44px;
    padding: 0 16px;
    color: #334155;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: normal;
}

.sb-desktop-menu__link:hover {
    background: rgba(37, 99, 235, 0.06);
    color: #2563eb;
}

.sb-desktop-menu__item.active .sb-desktop-menu__link,
.sb-desktop-menu__link.active {
    background: transparent;
    color: #1e293b;
}

.sb-desktop-menu__item.active .sb-desktop-menu__link::after,
.sb-desktop-menu__link.active::after {
    content: '';
    position: absolute;
    bottom: 6px;
    left: 16px;
    right: 16px;
    height: 2px;
    background-color: #2563eb;
    border-radius: 2px;
}

.sb-header-modern__cta-link,
.sb-mobile-menu__cta-link {
    justify-content: center;
    min-height: 44px;
    padding: 0 16px;
    background: var(--sb-primary, #45b150);
    color: var(--sb-white, #ffffff) !important;
    font-weight: 700;
    box-shadow: var(--sb-shadow-sm, 0 2px 4px rgba(0,0,0,0.05));
}

.sb-header-modern__cta-link:hover,
.sb-mobile-menu__cta-link:hover {
    background: var(--sb-primary-hover, #3ca046);
    color: var(--sb-white, #ffffff) !important;
    transform: translateY(-1px);
}

.sb-lang-modern,
.sb-user-modern {
    position: relative;
}

.sb-lang-modern__summary,
.sb-user-modern__summary,
.sb-user-modern__login {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid var(--sb-border, #dfe6e9);
    border-radius: var(--sb-radius, 12px);
    background: var(--sb-white, #ffffff);
    color: var(--sb-text-main, #2d3436);
    cursor: pointer;
    white-space: nowrap;
}

.sb-lang-modern__summary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 40px;
    padding: 0 8px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.sb-lang-modern__summary:hover {
    color: #17315f;
    background-color: rgba(15, 23, 42, 0.04);
}

/* Unify Desktop Arrows (Language, Currency, Location) */
.sb-lang-modern__summary::after,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector > .default::after,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector > .default::after,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector > .default::after {
    content: '' !important;
    display: inline-block !important;
    width: 6px !important;
    height: 6px !important;
    margin-left: 6px !important;
    background: none !important;
    border-right: 1.5px solid currentColor !important;
    border-bottom: 1.5px solid currentColor !important;
    border-top: none !important;
    border-left: none !important;
    transform: rotate(45deg) translateY(-2px) !important;
    transition: transform 0.2s ease !important;
    vertical-align: middle !important;
    opacity: 0.7 !important;
}

.sb-lang-modern__details[open] > .sb-lang-modern__summary::after,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector.circle_opened > .default::after,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector.circle_opened > .default::after,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector.circle_opened > .default::after {
    transform: rotate(225deg) translateY(-2px) !important;
}

/* Hide Flynax Native Desktop Arrows / Carets */
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector::after,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector::after,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector::after,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector > .default::before,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector > .default::before,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector > .default::before {
    display: none !important;
}

/* Remove Flynax Native Blue Background on Open */
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector.circle_opened,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector.circle_opened,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector.circle_opened,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector.circle_opened > .default,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector.circle_opened > .default,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector.circle_opened > .default {
    background: transparent !important;
    background-color: transparent !important;
    color: #0f172a !important;
}

.sb-lang-modern__summary::-webkit-details-marker,
.sb-user-modern__summary::-webkit-details-marker {
    display: none;
}

.sb-lang-modern__current {
    text-transform: uppercase;
    font-weight: 500;
}

/* Unified Dropdown Shell */
.sb-lang-modern__list,
.sb-user-modern__dropdown,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector .content,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector .content,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector .content {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    z-index: 9999;
    min-width: 200px;
    width: auto !important;
    margin: 0;
    padding: 8px !important;
    list-style: none;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    background: #ffffff !important;
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.08), 0 8px 10px -6px rgba(0,0,0,0.04) !important;
}

/* Remove internal container restrictions for Flynax plugins on desktop */
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector .content > div,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector .content > div,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector .content > div {
    max-height: none !important;
    width: 100% !important;
    display: block !important;
    box-sizing: border-box !important;
}

/* Rows Styling */
.sb-lang-modern__link,
.sb-user-modern__dropdown a,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul > li > a,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul > li > a,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector ul > li > a {
    display: flex !important;
    align-items: center;
    min-height: 40px;
    padding: 0 12px !important;
    border-radius: 10px !important;
    color: #475569 !important; /* muted/navy */
    font-size: 14px !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    width: 100% !important;
    box-sizing: border-box !important;
    transition: background-color 0.15s ease, color 0.15s ease !important;
}

/* Unify Flynax list items on desktop */
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector ul {
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    display: block !important;
    border: none !important;
    background: transparent !important;
}

.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul > li,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul > li,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector ul > li {
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    border-radius: 10px !important;
    height: auto !important;
    cursor: pointer !important;
    display: block !important;
}

/* Hide separators (override old styles) */
.sb-lang-modern__item + .sb-lang-modern__item,
.sb-user-modern__dropdown li + li,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul > li + li,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul > li + li,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector ul > li + li {
    border-top: none !important;
    border-radius: 0 !important;
    margin-top: 2px !important;
}

/* Hover State */
.sb-lang-modern__link:hover,
.sb-user-modern__dropdown a:hover,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul > li > a:hover,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul > li > a:hover,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector ul > li > a:hover {
    background: #f1f5f9 !important; /* soft slate */
    color: #0f172a !important;
}

/* Active State */
.sb-lang-modern__link.active,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul > li.active > a,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul > li.active > a {
    background: #f8fafc !important;
    color: #0f172a !important;
    font-weight: 600 !important;
}

/* Custom Checkmark for Active States */
.sb-lang-modern__link.active::after,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul > li.active > a::after,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul > li.active > a::after {
    content: '';
    margin-left: auto;
    width: 16px;
    height: 16px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2310b981' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

/* Language Code styles */
.sb-lang-modern__code {
    margin-left: auto;
    font-size: 13px;
    font-weight: 600;
    color: #94a3b8;
}
.sb-lang-modern__link.active .sb-lang-modern__code {
    color: #64748b;
    margin-right: 8px; /* gap from checkmark */
}

/* Hide Flynax Native checkmarks & pseudo elements */
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul > li.active::before,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul > li.active::before,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector ul > li.active::after,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector ul > li.active::after {
    display: none !important;
}

.sb-user-modern__icon {
    display: inline-flex;
    width: 22px;
    height: 22px;
}

.sb-user-modern__icon svg {
    width: 22px;
    height: 22px;
}

.sb-user-modern__caret {
    width: 8px;
    height: 5px;
    margin-left: 6px;
    color: currentColor;
    opacity: 0.7;
    transition: transform 0.2s ease, opacity 0.2s ease;
    transform-origin: center;
}

.sb-user-modern__caret path {
    stroke-width: 1.5px !important;
}

.sb-user-modern__details[open] .sb-user-modern__caret {
    transform: rotate(-180deg);
    opacity: 1;
}

.sb-user-modern__summary:hover .sb-user-modern__caret {
    opacity: 1;
}


.sb-mobile-menu .sb-user-modern__header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 12px 16px;
    margin-bottom: 8px;
    border-bottom: 1px solid var(--sb-border, #dfe6e9);
    font-weight: 700;
    color: var(--sb-text-main, #2d3436);
}

.sb-mobile-menu .sb-user-modern__flat-list ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sb-mobile-menu .sb-user-modern__flat-list li {
    margin-bottom: 4px;
}

.sb-mobile-menu .sb-user-modern__flat-list a {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 46px;
    padding: 0 12px;
    color: var(--sb-text-main, #2d3436);
    font-weight: 600;
    border-radius: var(--sb-radius, 12px);
    transition: background-color .2s ease, color .2s ease;
}

.sb-mobile-menu .sb-user-modern__flat-list a:hover {
    background: rgba(37, 99, 235, 0.06);
    color: #2563eb;
}

.sb-mobile-menu .sb-user-modern__flat-list a.active {
    background: rgba(37, 99, 235, 0.1);
    color: #1d4ed8;
}

.sb-user-modern__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--sb-primary, #45b150);
    color: var(--sb-white, #ffffff);
    font-size: 12px;
    font-weight: 700;
}

.sb-user-modern__name,
.sb-user-modern__login-text {
    display: block;
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sb-mobile-menu[hidden] {
    display: none !important;
}

.sb-mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 99999;
}

html.sb-mobile-menu-open,
html.sb-mobile-menu-open body {
    overflow: hidden !important;
}

.sb-mobile-menu__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.42);
}

.sb-mobile-menu__panel {
    position: absolute;
    top: 0;
    right: 0;
    width: var(--sb-layout-panel-width);
    height: 100%;
    display: flex;
    flex-direction: column;
    background: var(--sb-white, #ffffff);
    box-shadow: var(--sb-shadow-md, 0 8px 24px rgba(0,0,0,0.12));
}

.sb-mobile-menu__header {
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--sb-border, #dfe6e9);
}

.sb-mobile-menu__content {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 16px;
}

.sb-mobile-menu__item + .sb-mobile-menu__item {
    margin-top: 4px;
}

.sb-mobile-menu__link {
    width: 100%;
    min-height: 46px;
    padding: 0 12px;
    color: #334155;
    font-weight: 600;
}

.sb-mobile-menu__link:hover {
    background: rgba(37, 99, 235, 0.06);
    color: #2563eb;
}

.sb-mobile-menu__item.active .sb-mobile-menu__link,
.sb-mobile-menu__link.active {
    background: rgba(37, 99, 235, 0.1);
    color: #1d4ed8;
}

.sb-mobile-menu__cta {
    margin-top: 16px;
}

.sb-mobile-menu__cta-link {
    width: 100%;
}

.sb-mobile-menu__settings {
    display: flex;
    flex-direction: column;
    margin-top: 24px;
    border-top: 1px solid var(--sb-border, #dfe6e9);
    border-bottom: 1px solid var(--sb-border, #dfe6e9);
    background: var(--sb-white, #ffffff);
}

.sb-mobile-menu .sb-lang-modern__list,
.sb-mobile-menu .sb-user-modern__dropdown {
    position: static;
    margin-top: 8px;
    box-shadow: none;
}

.sb-mobile-menu .sb-user-modern__summary,
.sb-mobile-menu .sb-user-modern__login {
    width: 100%;
    justify-content: flex-start;
}

.sb-mobile-menu .sb-lang-modern {
    display: flex;
    align-items: center;
    width: 100%;
}

.sb-layout-modern .sb-mobile-menu #currency_selector,
.sb-layout-modern .sb-mobile-menu #mf-location-selector,
.sb-layout-modern .sb-mobile-menu #gf-location-selector,
.sb-layout-modern .sb-mobile-menu .sb-lang-modern__details {
    width: 100%;
}

.sb-layout-modern .sb-mobile-menu #currency_selector > .default,
.sb-layout-modern .sb-mobile-menu #mf-location-selector > .default,
.sb-layout-modern .sb-mobile-menu #gf-location-selector > .default,
.sb-layout-modern .sb-mobile-menu .sb-lang-modern__summary {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    width: 100% !important;
    min-height: 48px !important;
    padding: 0 16px !important;
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    cursor: pointer;
    color: var(--sb-text-muted, #636e72);
    font-size: 15px;
    font-weight: 500;
    text-transform: none !important;
}

.sb-layout-modern .sb-mobile-menu #currency_selector > .default *,
.sb-layout-modern .sb-mobile-menu #mf-location-selector > .default *,
.sb-layout-modern .sb-mobile-menu #gf-location-selector > .default *,
.sb-layout-modern .sb-mobile-menu .sb-lang-modern__current {
    text-transform: none !important;
    font-weight: 500 !important;
}

.sb-layout-modern .sb-mobile-menu #currency_selector > .default:hover,
.sb-layout-modern .sb-mobile-menu #mf-location-selector > .default:hover,
.sb-layout-modern .sb-mobile-menu #gf-location-selector > .default:hover,
.sb-layout-modern .sb-mobile-menu .sb-lang-modern__summary:hover,
.sb-layout-modern .sb-mobile-menu .sb-lang-modern__details[open] > .sb-lang-modern__summary {
    background: var(--sb-bg-soft, #f8f9fa) !important;
}


/* Mobile Auth Block */
.sb-mobile-auth {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin-top: 24px;
}

.sb-mobile-auth__title {
    font-size: 13px;
    font-weight: 600;
    color: var(--sb-text-muted, #636e72);
    text-transform: none;
    padding-left: 16px;
    margin-bottom: 8px;
}

.sb-mobile-auth__actions {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--sb-border, #dfe6e9);
    border-bottom: 1px solid var(--sb-border, #dfe6e9);
    background: var(--sb-white, #ffffff);
}

.sb-mobile-auth__login,
.sb-mobile-auth__register {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 48px;
    padding: 0 16px;
    background: transparent;
    border: none;
    border-radius: 0;
    font-size: 15px;
    font-weight: 500;
    color: var(--sb-text-main, #2d3436);
    text-decoration: none;
}

.sb-mobile-auth__login:hover,
.sb-mobile-auth__register:hover {
    background: var(--sb-bg-soft, #f8f9fa);
}

.sb-mobile-auth__login + .sb-mobile-auth__register {
    border-top: 1px solid var(--sb-border, #dfe6e9);
}

.sb-mobile-auth__login::after,
.sb-mobile-auth__register::after {
    content: '';
    display: block;
    width: 6px;
    height: 6px;
    border-right: 2px solid var(--sb-text-muted, #b2bec3);
    border-bottom: 2px solid var(--sb-text-muted, #b2bec3);
    transform: rotate(-45deg); /* Right chevron */
}

/* Mobile Logged-in Account Section */
.sb-mobile-account-section {
    display: flex;
    flex-direction: column;
    width: 100%;
    margin-top: 24px;
}

.sb-mobile-account-section__title {
    font-size: 13px;
    font-weight: 600;
    color: var(--sb-text-muted, #636e72);
    text-transform: none;
    margin-bottom: 8px;
}

.sb-mobile-account-section__card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    margin-bottom: 16px;
    text-decoration: none !important;
}

.sb-mobile-account-section__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #64748b;
    flex: 0 0 auto;
}

.sb-mobile-account-section__icon svg {
    width: 20px;
    height: 20px;
}

.sb-mobile-account-section__info {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
}

.sb-mobile-account-section__name {
    font-size: 16px;
    font-weight: 700;
    color: #0f172a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sb-mobile-account-section__hint {
    font-size: 13px;
    color: #64748b;
    margin-top: 2px;
}

.sb-mobile-account-section__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 10px;
    background: var(--sb-danger, #d63031);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    flex: 0 0 auto;
}

/* Mobile Account Menu List */
.sb-mobile-account-section__menu ul.account-menu-content {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--sb-border, #dfe6e9);
    border-bottom: 1px solid var(--sb-border, #dfe6e9);
    background: var(--sb-white, #ffffff);
}

.sb-mobile-account-section__menu ul.account-menu-content > li {
    margin: 0;
    padding: 0;
}

.sb-mobile-account-section__menu ul.account-menu-content > li > a {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 46px;
    padding: 0 16px;
    font-size: 15px;
    font-weight: 500;
    color: var(--sb-text-main, #2d3436);
    background: transparent;
    text-decoration: none !important;
}

.sb-mobile-account-section__menu ul.account-menu-content > li > a:hover {
    background: var(--sb-bg-soft, #f8f9fa);
}

.sb-mobile-account-section__menu ul.account-menu-content > li + li {
    border-top: 1px solid var(--sb-border, #dfe6e9);
}

/* Hide duplicated My Profile item in mobile drawer and fix borders */
.sb-mobile-account-section__menu ul.account-menu-content > li.sb-account-menu-item-my_profile {
    display: none !important;
}

.sb-mobile-account-section__menu ul.account-menu-content > li:first-child.sb-account-menu-item-my_profile + li {
    border-top: none;
}

/* Logout row styling */
.sb-mobile-account-section__menu ul.account-menu-content > li > a.logout {
    color: var(--sb-danger, #d63031);
    font-weight: 600;
}

.sb-layout-modern .sb-footer-modern {
    margin-top: auto;
    background: #0f172a;
    color: #94a3b8;
    border-top: none;
}

.sb-layout-modern .sb-footer-modern__inner {
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 48px 24px 24px;
}

.sb-layout-modern .sb-footer-modern__grid {
    display: grid;
    gap: 40px;
}

.sb-layout-modern .sb-footer-modern__brand-col {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.sb-layout-modern .sb-footer-modern__logo-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: flex-start;
}

.sb-layout-modern .sb-footer-modern__logo {
    display: block;
    max-width: 176px;
    height: auto;
}

.sb-layout-modern .sb-footer-modern__brand-desc {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
}

.sb-layout-modern .sb-footer-modern__newsletter-row {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding-bottom: 32px;
    margin-bottom: 32px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 992px) {
    .sb-layout-modern .sb-footer-modern__newsletter-row {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 32px;
    }
}

.sb-layout-modern .sb-footer-modern__newsletter-info {
    flex: 1;
    max-width: 600px;
}

.sb-layout-modern .sb-footer-modern__newsletter-title {
    margin: 0;
    color: #cbd5e1;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.45;
}

.sb-layout-modern .sb-footer-modern__newsletter-form {
    flex: 1;
    max-width: 400px;
    width: 100%;
}

.sb-layout-modern .sb-footer-modern__newsletter-form input[type="text"],
.sb-layout-modern .sb-footer-modern__newsletter-form input[type="email"] {
    display: block;
    width: 100%;
    box-sizing: border-box;
    height: 44px;
    padding: 0 16px;
    border-radius: 10px !important;
    border: 1px solid #334155;
    background-color: #0f172a;
    color: #ffffff;
    font-size: 15px;
    outline: none;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.sb-layout-modern .sb-footer-modern__newsletter-form input[type="text"]:focus,
.sb-layout-modern .sb-footer-modern__newsletter-form input[type="email"]:focus {
    border-color: #475569;
    background-color: #1e293b;
}

.sb-layout-modern .sb-footer-modern__newsletter-form input[type="button"],
.sb-layout-modern .sb-footer-modern__newsletter-form input[type="submit"] {
    display: block;
    width: 100%;
    box-sizing: border-box;
    height: 44px;
    padding: 0 24px;
    background-color: #0284c7;
    color: #ffffff;
    border: none;
    border-radius: 10px !important;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.sb-layout-modern .sb-footer-modern__newsletter-form input[type="button"]:hover,
.sb-layout-modern .sb-footer-modern__newsletter-form input[type="submit"]:hover {
    background-color: #0369a1;
}

.sb-layout-modern .sb-footer-modern__newsletter-form input[type="button"]:active,
.sb-layout-modern .sb-footer-modern__newsletter-form input[type="submit"]:active {
    transform: translateY(1px);
}

.sb-layout-modern .sb-footer-modern__newsletter-form .newsletter_cont {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

@media (min-width: 576px) {
    .sb-layout-modern .sb-footer-modern__newsletter-form .newsletter_cont {
        flex-direction: row;
        align-items: center;
    }
    
    .sb-layout-modern .sb-footer-modern__newsletter-form input[type="text"],
    .sb-layout-modern .sb-footer-modern__newsletter-form input[type="email"] {
        flex: 1;
    }
    
    .sb-layout-modern .sb-footer-modern__newsletter-form input[type="button"],
    .sb-layout-modern .sb-footer-modern__newsletter-form input[type="submit"] {
        width: auto;
    }
}

.sb-layout-modern .sb-footer-modern__nav {
    display: grid;
    gap: 32px;
}

.sb-layout-modern .sb-footer-modern__nav-title {
    margin: 0 0 16px;
    color: #f8fafc;
    font-size: 16px;
    font-weight: 700;
}

.sb-layout-modern .sb-footer-modern__nav-item + .sb-footer-modern__nav-item {
    margin-top: 12px;
}

.sb-layout-modern .sb-footer-modern__nav-link {
    color: #94a3b8;
    font-size: 15px;
    transition: color 0.2s ease;
    white-space: normal;
    word-break: break-word;
    line-height: 1.4;
    display: inline-block;
}

.sb-layout-modern .sb-footer-modern__nav-link:hover {
    color: #ffffff;
}

.sb-layout-modern .sb-footer-modern__apps {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.sb-layout-modern .sb-footer-modern__apps-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.sb-layout-modern .sb-footer-modern__app-link img {
    display: block;
    max-height: 40px;
    width: auto;
}

.sb-layout-modern .sb-footer-modern__bottom {
    display: flex;
    flex-direction: column-reverse;
    gap: 20px;
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 14px;
    align-items: center;
    text-align: center;
}

@media (min-width: 768px) {
    .sb-layout-modern .sb-footer-modern__bottom {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
}

.sb-layout-modern .sb-footer-modern__copyright {
    color: #94a3b8;
}

.sb-layout-modern .sb-footer-modern__copyright a {
    color: #cbd5e1;
}

.sb-layout-modern .sb-footer-modern__copyright a:hover {
    color: #ffffff;
}

.sb-layout-modern .sb-footer-modern__social {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.sb-layout-modern .sb-footer-modern__social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #f1f5f9;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.sb-layout-modern .sb-footer-modern__social-link:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    color: #ffffff;
    transform: translateY(-2px);
}

.sb-layout-modern .sb-footer-modern__social-link svg {
    width: 18px;
    height: 18px;
}

@media (min-width: 768px) {
    .sb-header-modern__desktop-nav,
    .sb-header-modern__lang,
    .sb-header-modern__user,
    .sb-header-modern__cta {
        display: flex;
        align-items: center;
    }

    .sb-header-modern__mobile-toggle {
        display: none;
    }

    .sb-layout-modern .sb-footer-modern__grid {
        grid-template-columns: 360px minmax(0, 1fr);
        gap: 64px;
    }

    .sb-layout-modern .sb-footer-modern__nav {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .sb-layout-modern .sb-footer-modern__bottom {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

@media (min-width: 1200px) {
    .sb-header-modern__inner {
        gap: 24px;
        padding: 0 24px;
    }

    .sb-desktop-menu__link {
        padding-left: 14px;
        padding-right: 14px;
    }
}


/* Compatibility: plugin controls injected by tplHeaderUserNav
   Keep these selectors scoped by .sb-layout-modern so legacy templates stay untouched.
   Plugin-generated IDs are preserved intentionally:
   - #currency_selector from currencyConverter
   - #mf-location-selector from multiField/GeoFilter
*/
.sb-layout-modern .sb-header-modern__plugin-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.sb-mobile-menu .sb-header-modern__plugin-nav {
    flex-direction: column;
    align-items: stretch !important;
    width: 100% !important;
    gap: 12px;
}

.sb-layout-modern .sb-header-modern__plugin-nav:empty {
    display: none;
}

.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector > .default,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector > .default,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector > .default {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 8px;
    border-radius: 8px;
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector > .default:hover,
.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector > .default:hover,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector > .default:hover {
    color: #17315f;
    background-color: rgba(15, 23, 42, 0.04);
}

.sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector > .default > span,
.sb-layout-modern .sb-header-modern__plugin-nav #currency_selector > .default > span,
.sb-layout-modern .sb-header-modern__plugin-nav #gf-location-selector > .default > span {
    min-width: 0;
    color: inherit;
    font-weight: inherit;
    font-size: inherit;
    text-transform: none !important;
}

/* Compatibility: massmailer newsletter expects .newsletter and #nova-newsletter-cont. */
.sb-layout-modern .newsletter.sb-footer-modern__newsletter {
    width: 100%;
}

/* Compatibility: desktop account scripts may target #user-navbar. */
.sb-layout-modern #user-navbar.sb-user-modern {
    display: flex;
    align-items: center;
}

@media (max-width: 991px) {
    .sb-layout-modern .sb-header-modern__plugin-nav {
        gap: 4px;
    }

    .sb-layout-modern .sb-header-modern__plugin-nav #mf-location-selector .default > span {
        max-width: 90px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
}

@media (max-width: 767px) {
    #sb-desktop-plugin-nav-target {
        display: none !important;
    }
}

/* ==========================================================================
   Search Map Plugin Minimal Footer
   ========================================================================== */

.sb-search-map-footer {
    background: var(--sb-white, #ffffff);
    color: var(--sb-text-muted, #636e72);
    padding: 16px 24px;
    border-top: 1px solid var(--sb-border, #dfe6e9);
    margin-top: auto;
    flex-shrink: 0;
    min-height: 54px;
    z-index: 10;
    box-sizing: border-box;
    width: 100%;
}

.sb-search-map-footer__copyright {
    font-size: 13px;
    font-weight: 400;
    line-height: 1.4;
}

.sb-search-map-footer__copyright a {
    color: var(--sb-text-main, #2d3436);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.sb-search-map-footer__copyright a:hover {
    color: var(--sb-primary, #45b150);
}

.sb-search-map-footer__social {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.sb-search-map-footer__social-link {
    display: inline-flex;
    color: var(--sb-text-muted, #636e72);
    transition: color 0.2s ease, transform 0.2s ease;
}

.sb-search-map-footer__social-link:hover {
    color: var(--sb-primary, #45b150);
    transform: translateY(-2px);
}

.sb-search-map-footer__social-link svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

/* --- Modern Modals (Overrides) --- */
body .popup {
    background: rgba(15, 23, 42, 0.4) !important;
    backdrop-filter: blur(2px) !important;
}

body .popup > div {
    background: transparent !important;
    padding: 0 !important;
}

body .popup > div > div {
    position: relative !important;
    border-radius: 16px !important;
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.15) !important;
    border: none !important;
    background: #ffffff !important;
    padding: 0 !important;
    overflow: hidden;
}

@media screen and (max-width: 767px) {
    body .popup > div > div {
        max-width: calc(100vw - 32px) !important;
        box-sizing: border-box !important;
    }
    body .popup {
        top: 50% !important;
        margin-top: 0 !important;
        bottom: auto !important;
        transform: translateY(-50%) !important;
    }
}

body .popup > div > div > div.caption {
    font-family: 'Roboto', sans-serif !important;
    font-size: 20px !important;
    font-weight: 700 !important;
    color: #1e293b !important;
    border-bottom: 1px solid #e2e8f0 !important;
    padding: 20px 24px !important;
    background: transparent !important;
    margin: 0 !important;
}

body .popup > div > div > div.caption .close.small {
    position: absolute !important;
    top: 20px !important;
    right: 20px !important;
    background: #f1f5f9 !important;
    border-radius: 50% !important;
    width: 32px !important;
    height: 32px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: background-color 0.2s ease !important;
    z-index: 10 !important;
}

body .popup > div > div > div.caption .close.small:hover {
    background: #e2e8f0 !important;
}

body .popup > div > div > div.caption .close.small::before {
    background: none !important;
    content: '' !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 14px !important;
    height: 2px !important;
    background-color: #64748b !important;
    border-radius: 2px !important;
    transform: translate(-50%, -50%) rotate(45deg) !important;
    opacity: 1 !important;
}

body .popup > div > div > div.caption .close.small::after {
    content: '' !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 14px !important;
    height: 2px !important;
    background-color: #64748b !important;
    border-radius: 2px !important;
    transform: translate(-50%, -50%) rotate(-45deg) !important;
}

body .popup > div > div > div.body {
    padding: 24px !important;
    background: #ffffff !important;
}

/* --- Old flModal Overrides (flModal plugin) --- */
#modal_block {
    background: transparent !important;
}

#modal_block > .inner {
    background: #ffffff !important;
    border-radius: 16px !important;
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.15) !important;
    border: none !important;
    padding: 24px !important;
    overflow: hidden;
}

#modal_block > .inner > .close {
    position: absolute !important;
    top: 12px !important;
    right: 12px !important;
    background: #f1f5f9 !important;
    border-radius: 50% !important;
    width: 32px !important;
    height: 32px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: background-color 0.2s ease !important;
    z-index: 10 !important;
    margin: 0 !important;
}

#modal_block > .inner > .close:hover {
    background: #e2e8f0 !important;
}

#modal_block > .inner > .close > div {
    display: none !important; /* Hide old icon */
}

#modal_block > .inner > .close::before {
    content: '' !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 14px !important;
    height: 2px !important;
    background-color: #64748b !important;
    border-radius: 2px !important;
    transform: translate(-50%, -50%) rotate(45deg) !important;
}

#modal_block > .inner > .close::after {
    content: '' !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    width: 14px !important;
    height: 2px !important;
    background-color: #64748b !important;
    border-radius: 2px !important;
    transform: translate(-50%, -50%) rotate(-45deg) !important;
}

#modal_block .modal_content .prompt {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    margin-top: 24px !important;
    padding-top: 16px !important;
    border-top: 1px solid #e2e8f0 !important;
}

#modal_block .modal_content .prompt input[name="ok"] {
    flex: 1 !important;
    padding: 10px 24px !important;
    background-color: #2563eb !important;
    color: #ffffff !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    border: none !important;
    border-radius: 12px !important;
    cursor: pointer !important;
    transition: background-color 0.2s ease !important;
    height: auto !important;
    text-align: center !important;
}

#modal_block .modal_content .prompt input[name="ok"]:hover {
    background-color: #1d4ed8 !important;
}

#modal_block .modal_content .prompt a.close {
    flex: 1 !important;
    padding: 10px 24px !important;
    background-color: #f1f5f9 !important;
    color: #475569 !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    border-radius: 12px !important;
    text-decoration: none !important;
    display: inline-block !important;
    transition: background-color 0.2s ease !important;
    text-align: center !important;
    position: static !important;
    width: auto !important;
    height: auto !important;
}

#modal_block .modal_content .prompt a.close:hover {
    background-color: #e2e8f0 !important;
    text-decoration: none !important;
}

body .popup > div > div > div.body {
    padding: 24px !important;
    font-family: 'Roboto', sans-serif !important;
    color: #475569 !important;
}

/* Modal Inputs */
body .popup > div > div > div.body input[type="text"],
body .popup > div > div > div.body input[type="password"],
body .popup > div > div > div.body input[type="email"],
body .popup > div > div > div.body input[type="number"],
body .popup > div > div > div.body textarea {
    width: 100% !important;
    padding: 14px 16px !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 12px !important;
    font-size: 15px !important;
    color: #1e293b !important;
    background-color: #ffffff !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease !important;
    box-shadow: none !important;
    box-sizing: border-box !important;
}

body .popup > div > div > div.body input[type="text"]:focus,
body .popup > div > div > div.body input[type="password"]:focus,
body .popup > div > div > div.body input[type="email"]:focus,
body .popup > div > div > div.body input[type="number"]:focus,
body .popup > div > div > div.body textarea:focus {
    background-color: #ffffff !important;
    border-color: #2563eb !important;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1) !important;
    outline: none !important;
}

/* Modal Buttons */
body .popup > div > div > div.body input[type="submit"],
body .popup > div > div > div.body input[type="button"],
body .popup > div > div > div.body button,
body .popup > div > div > div.body .button,
body .popup > div > div > nav button,
body .popup > div > div > nav input[type="button"] {
    width: 100% !important;
    padding: 14px 24px !important;
    background-color: #2563eb !important;
    color: #ffffff !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    border: none !important;
    border-radius: 12px !important;
    cursor: pointer !important;
    transition: background-color 0.2s ease, transform 0.2s ease !important;
    text-shadow: none !important;
    box-shadow: 0 4px 6px -1px rgba(37, 99, 235, 0.2) !important;
    margin-top: 8px !important;
    text-align: center !important;
    box-sizing: border-box !important;
}

body .popup > div > div > nav {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    padding: 0 24px 24px !important;
}

body .popup > div > div > nav button,
body .popup > div > div > nav input[type="button"] {
    width: 100% !important;
    flex: none !important;
    margin-top: 0 !important;
}

body .popup > div > div > nav input.cancel,
body .popup > div > div > nav button.cancel,
body .popup > div > div > div.body input.cancel,
body .popup > div > div > div.body button.cancel {
    background-color: #f1f5f9 !important;
    color: #475569 !important;
    box-shadow: none !important;
}

body .popup > div > div > nav input.warning,
body .popup > div > div > nav button.warning,
body .popup > div > div > div.body input.warning,
body .popup > div > div > div.body button.warning {
    background-color: #ef4444 !important;
    color: #ffffff !important;
    box-shadow: 0 4px 6px -1px rgba(239, 68, 68, 0.2) !important;
}

/* Hybrid Auth SSO overrides */
body .popup > div > div > div.body .ha-or {
    display: none !important;
}

body .popup > div > div > div.body .ha-social-icons {
    display: flex !important;
    justify-content: center !important;
    gap: 16px !important;
    margin-top: 16px !important;
}

body .popup > div > div > div.body .ha-social-icon-svg {
    width: 44px !important;
    height: 44px !important;
    background: transparent !important;
    border-radius: 50% !important;
    margin: 0 !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06) !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}

body .popup > div > div > div.body .ha-social-icon-svg:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05) !important;
    filter: none !important;
}

body .popup > div > div > div.body input[type="submit"]:hover,
body .popup > div > div > div.body input[type="button"]:hover,
body .popup > div > div > div.body button:hover,
body .popup > div > div > div.body .button:hover,
body .popup > div > div > nav button:hover,
body .popup > div > div > nav input[type="button"]:hover {
    background-color: #1d4ed8 !important;
    color: #ffffff !important;
    transform: translateY(-1px) !important;
    text-decoration: none !important;
}

body .popup > div > div > nav input.cancel:hover,
body .popup > div > div > nav button.cancel:hover,
body .popup > div > div > div.body input.cancel:hover,
body .popup > div > div > div.body button.cancel:hover {
    background-color: #e2e8f0 !important;
    color: #334155 !important;
}

body .popup > div > div > nav input.warning:hover,
body .popup > div > div > nav button.warning:hover,
body .popup > div > div > div.body input.warning:hover,
body .popup > div > div > div.body button.warning:hover {
    background-color: #dc2626 !important;
    box-shadow: 0 4px 6px -1px rgba(220, 38, 38, 0.3) !important;
}

body .popup > div > div > div.body input[type="submit"]:active,
body .popup > div > div > div.body input[type="button"]:active,
body .popup > div > div > div.body button:active,
body .popup > div > div > div.body .button:active,
body .popup > div > div > nav button:active,
body .popup > div > div > nav input[type="button"]:active {
    transform: translateY(0) !important;
}



/* Modal Links */
body .popup > div > div > div.body a {
    color: #2563eb !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    transition: color 0.2s ease !important;
}

body .popup > div > div > div.body a:hover {
    color: #1d4ed8 !important;
    text-decoration: underline !important;
}

/* Modern Checkboxes */
.modern-checkbox-label {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    font-size: 14px !important;
    color: #475569 !important;
    cursor: pointer !important;
    user-select: none !important;
    position: relative !important;
    margin: 0 !important;
}

/* Modern Checkboxes via JS Wrapper */
.modern-checkbox-wrapper {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    cursor: pointer !important;
    user-select: none !important;
}

.modern-checkbox-box {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 20px !important;
    height: 20px !important;
    background-color: #ffffff !important;
    border: 2px solid #cbd5e1 !important;
    border-radius: 4px !important;
    transition: all 0.2s ease !important;
    position: relative !important;
    flex-shrink: 0 !important;
}

.modern-checkbox-wrapper:hover .modern-checkbox-box {
    border-color: #94a3b8 !important;
}

.modern-checkbox-wrapper input[type="checkbox"]:checked ~ .modern-checkbox-box {
    background-color: #2563eb !important;
    border-color: #2563eb !important;
}

.modern-checkbox-wrapper input[type="checkbox"]:checked ~ .modern-checkbox-box::after {
    content: '' !important;
    position: absolute !important;
    width: 5px !important;
    height: 10px !important;
    border: solid white !important;
    border-width: 0 2px 2px 0 !important;
    transform: rotate(45deg) !important;
    margin-top: -2px !important;
}

.modern-checkbox-text {
    font-size: 14px !important;
    color: #475569 !important;
}

/* Force show contact phone */
input.force-visible-phone {
    display: block !important;
    visibility: visible !important;
    pointer-events: auto !important;
    height: 40px !important;
    padding: 0 15px !important;
    border: 1px solid #dee2e6 !important;
    border-radius: 12px !important;
    background-color: #ffffff !important;
    box-sizing: border-box !important;
}

/* === Mobile Fullscreen Map Overlay Override === */
@media screen and (max-width: 767px) {
    body .popup:has(#sb_map_fullscreen) {
        top: 0 !important;
        left: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        height: 100dvh !important;
        transform: none !important;
        background: #ffffff !important;
        z-index: 999999 !important;
        margin: 0 !important;
        border-radius: 0 !important;
    }
    body .popup:has(#sb_map_fullscreen) > div,
    body .popup:has(#sb_map_fullscreen) > div > div {
        max-width: 100vw !important;
        width: 100vw !important;
        height: 100% !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    body .popup:has(#sb_map_fullscreen) > div > div > div.body {
        padding: 0 !important;
        height: 100% !important;
        display: flex !important;
        flex-direction: column !important;
    }
    /* Move close button to hover over the map */
    body .popup:has(#sb_map_fullscreen) > div > div > div.caption {
        position: absolute !important;
        top: 0 !important;
        right: 0 !important;
        width: 100% !important;
        z-index: 1000 !important;
        border: none !important;
        background: transparent !important;
        pointer-events: none !important; /* Let clicks pass to map */
    }
    body .popup:has(#sb_map_fullscreen) > div > div > div.caption .close {
        pointer-events: auto !important;
        background: #ffffff !important;
        box-shadow: 0 4px 12px rgba(0,0,0,0.15) !important;
        top: 16px !important;
        right: 16px !important;
    }
}
