/* =========================================================
   LM-ARTICLE-LOCATION-SEARCH-V3
   Pesquisa universal — artigos
   Desktop + mobile
   ========================================================= */

body.single #lm-article-location-search {
    position: relative;
    z-index: 500;
    width: 100%;
    box-sizing: border-box;

    padding: 15px 18px;

    background: #f4f7f9;
    border-bottom: 1px solid #e2e7eb;
}

body.single #lm-article-location-search
.lm-article-location-search-inner {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

body.single #lm-article-location-search
.lm-article-location-field {
    position: relative;

    width: 100%;
    max-width: 620px;

    margin: 0 auto;
}


/* =========================================================
   INPUT
   ========================================================= */

body.single #lm-article-location-input {
    display: block;

    width: 100%;
    height: 48px;

    box-sizing: border-box;

    margin: 0;
    padding: 0 48px 0 48px;

    appearance: none;
    -webkit-appearance: none;

    border: 1px solid #cbd6df;
    border-radius: 14px;

    outline: none;

    background: #fff;
    color: #17212b;

    font-family: inherit;
    font-size: 15px;
    font-weight: 500;
    line-height: 48px;

    box-shadow:
        0 2px 10px rgba(20,40,60,.05);

    transition:
        border-color .15s ease,
        box-shadow .15s ease,
        background .15s ease;
}

body.single #lm-article-location-input::placeholder {
    color: #74818b;
    opacity: 1;
}

body.single #lm-article-location-input:focus {
    border-color: #3994e6;

    box-shadow:
        0 0 0 3px rgba(57,148,230,.15),
        0 3px 12px rgba(20,40,60,.07);
}


/* LUPA */

body.single #lm-article-location-search
.lm-article-location-icon {
    position: absolute;
    z-index: 3;

    top: 50%;
    left: 17px;

    width: 19px;
    height: 19px;

    transform: translateY(-50%);

    font-size: 0;

    pointer-events: none;
}

body.single #lm-article-location-search
.lm-article-location-icon::before {
    content: "";

    position: absolute;

    width: 12px;
    height: 12px;

    top: 0;
    left: 0;

    border: 2px solid #536574;
    border-radius: 50%;
}

body.single #lm-article-location-search
.lm-article-location-icon::after {
    content: "";

    position: absolute;

    width: 8px;
    height: 2px;

    left: 11px;
    top: 14px;

    border-radius: 2px;

    background: #536574;

    transform: rotate(45deg);
    transform-origin: left center;
}


/* LIMPAR */

body.single #lm-article-location-clear {
    position: absolute;
    z-index: 4;

    top: 8px;
    right: 8px;

    display: none;

    width: 32px;
    height: 32px;

    margin: 0;
    padding: 0;

    border: 0;
    border-radius: 50%;

    background: #eef2f5;
    color: #52616d;

    font-family: inherit;
    font-size: 20px;
    font-weight: 400;
    line-height: 30px;

    cursor: pointer;
}

body.single #lm-article-location-clear:hover {
    background: #e2e8ed;
}


/* =========================================================
   DROPDOWN
   ========================================================= */

body.single #lm-article-location-results {
    position: absolute;
    z-index: 10000;

    top: calc(100% + 7px);
    left: 0;
    right: 0;

    display: none;

    width: 100%;
    max-height: 410px;

    box-sizing: border-box;

    margin: 0;
    padding: 5px 0;

    overflow-x: hidden;
    overflow-y: auto;

    border: 1px solid #d6dde3;
    border-radius: 15px;

    background: #fff;
    color: #17212b;

    box-shadow:
        0 14px 38px rgba(0,0,0,.18);
}

body.single #lm-article-location-results.active {
    display: block;
}


/* RESULTADO */

body.single #lm-article-location-results
.lm-article-location-result {
    display: grid;

    grid-template-columns:
        38px
        minmax(0,1fr)
        auto;

    grid-template-areas:
        "icon name badge"
        "icon meta badge";

    column-gap: 11px;

    align-items: center;

    width: 100%;
    min-height: 61px;

    box-sizing: border-box;

    margin: 0;
    padding: 9px 14px;

    border: 0;
    border-bottom: 1px solid #edf0f2;
    border-radius: 0;

    background: #fff;
    color: #17212b;

    text-align: left;
    font-family: inherit;

    cursor: pointer;

    box-shadow: none;
    transform: none;
}

body.single #lm-article-location-results
.lm-article-location-result:last-child {
    border-bottom: 0;
}

body.single #lm-article-location-results
.lm-article-location-result:hover,

body.single #lm-article-location-results
.lm-article-location-result.active {
    background: #f0f6fb;
}


/* ÍCONE */

body.single #lm-article-location-results
.lm-location-type-icon {
    grid-area: icon;

    display: flex;

    width: 38px;
    height: 38px;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #edf4fa;
    color: #315b7b;
}

body.single #lm-article-location-results
.lm-location-type-icon svg {
    display: block;

    width: 19px;
    height: 19px;

    fill: none;
    stroke: currentColor;

    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}


/* NOMES */

body.single #lm-article-location-results
.lm-article-location-name {
    grid-area: name;

    display: block;

    min-width: 0;

    margin: 0;
    padding: 0;

    overflow: hidden;

    color: #17212b;

    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.25;

    text-overflow: ellipsis;
    white-space: nowrap;
}

body.single #lm-article-location-results
.lm-article-location-meta {
    grid-area: meta;

    display: block;

    min-width: 0;

    margin-top: 2px;

    overflow: hidden;

    color: #65737e;

    font-family: inherit;
    font-size: 11.5px;
    font-weight: 400;
    line-height: 1.25;

    text-overflow: ellipsis;
    white-space: nowrap;
}


/* BADGE */

body.single #lm-article-location-results
.lm-location-type-badge {
    grid-area: badge;

    display: inline-flex;

    align-items: center;
    justify-content: center;

    min-height: 25px;

    padding: 3px 10px;

    border-radius: 999px;

    background: #edf3f8;
    color: #536a7c;

    font-size: 11px;
    font-weight: 650;
    line-height: 1;

    white-space: nowrap;
}

body.single #lm-article-location-results
.lm-location-type-concelho
.lm-location-type-badge {
    background: #e9f3ff;
    color: #2564a0;
}

body.single #lm-article-location-results
.lm-location-type-concelho
.lm-location-type-icon {
    background: #e7f2ff;
    color: #27689e;
}

body.single #lm-article-location-results
.lm-location-type-praia
.lm-location-type-badge {
    background: #e7f6fb;
    color: #23718a;
}

body.single #lm-article-location-results
.lm-location-type-praia
.lm-location-type-icon {
    background: #e6f6fb;
    color: #27758c;
}

body.single #lm-article-location-results
.lm-location-type-montanha
.lm-location-type-badge {
    background: #e8f5ef;
    color: #267259;
}

body.single #lm-article-location-results
.lm-location-type-montanha
.lm-location-type-icon {
    background: #f6f1d9;
    color: #75651e;
}


/* VAZIO */

body.single #lm-article-location-results
.lm-article-location-empty {
    padding: 14px 16px;

    color: #687681;

    font-size: 13px;
}


/* =========================================================
   DARK MODE
   SmartMag + preferências do sistema LM
   ========================================================= */

body.s-dark.single #lm-article-location-search,
body.single.s-dark #lm-article-location-search {
    background: #151d24;
    border-bottom-color: #28343e;
}

body.s-dark.single #lm-article-location-input,
body.single.s-dark #lm-article-location-input {
    border-color: #3a4955;

    background: #202a32;
    color: #f1f5f8;

    box-shadow:
        0 2px 10px rgba(0,0,0,.16);
}

body.s-dark.single #lm-article-location-input::placeholder,
body.single.s-dark #lm-article-location-input::placeholder {
    color: #a5b0b9;
}

body.s-dark.single #lm-article-location-input:focus,
body.single.s-dark #lm-article-location-input:focus {
    border-color: #429ce8;

    box-shadow:
        0 0 0 3px rgba(66,156,232,.18);
}

body.s-dark.single #lm-article-location-search
.lm-article-location-icon::before,
body.single.s-dark #lm-article-location-search
.lm-article-location-icon::before {
    border-color: #c4ced6;
}

body.s-dark.single #lm-article-location-search
.lm-article-location-icon::after,
body.single.s-dark #lm-article-location-search
.lm-article-location-icon::after {
    background: #c4ced6;
}

body.s-dark.single #lm-article-location-clear,
body.single.s-dark #lm-article-location-clear {
    background: #35414b;
    color: #dbe3e9;
}

body.s-dark.single #lm-article-location-results,
body.single.s-dark #lm-article-location-results {
    border-color: #36434d;

    background: #202930;
    color: #eef3f6;

    box-shadow:
        0 15px 40px rgba(0,0,0,.42);
}

body.s-dark.single #lm-article-location-results
.lm-article-location-result,
body.single.s-dark #lm-article-location-results
.lm-article-location-result {
    border-bottom-color: #34404a;

    background: #202930;
    color: #eef3f6;
}

body.s-dark.single #lm-article-location-results
.lm-article-location-result:hover,

body.s-dark.single #lm-article-location-results
.lm-article-location-result.active,

body.single.s-dark #lm-article-location-results
.lm-article-location-result:hover,

body.single.s-dark #lm-article-location-results
.lm-article-location-result.active {
    background: #293741;
}

body.s-dark.single #lm-article-location-results
.lm-article-location-name,
body.single.s-dark #lm-article-location-results
.lm-article-location-name {
    color: #f3f6f8;
}

body.s-dark.single #lm-article-location-results
.lm-article-location-meta,
body.single.s-dark #lm-article-location-results
.lm-article-location-meta {
    color: #aeb9c1;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 767px) {

    body.single #lm-article-location-search {
        display: block !important;

        padding: 10px 12px;

        z-index: 500;
    }

    body.single #lm-article-location-search
    .lm-article-location-field {
        max-width: none;
    }

    body.single #lm-article-location-input {
        height: 44px;

        padding-left: 44px;
        padding-right: 44px;

        border-radius: 12px;

        font-size: 14px;
        line-height: 44px;
    }

    body.single #lm-article-location-search
    .lm-article-location-icon {
        left: 15px;
    }

    body.single #lm-article-location-clear {
        top: 6px;
        right: 6px;
    }

    body.single #lm-article-location-results {
        top: calc(100% + 6px);

        max-height: min(
            390px,
            calc(100vh - 150px)
        );

        border-radius: 13px;
    }

    body.single #lm-article-location-results
    .lm-article-location-result {
        grid-template-columns:
            36px
            minmax(0,1fr)
            auto;

        column-gap: 9px;

        min-height: 58px;

        padding: 8px 10px;
    }

    body.single #lm-article-location-results
    .lm-location-type-icon {
        width: 36px;
        height: 36px;
    }

    body.single #lm-article-location-results
    .lm-location-type-badge {
        padding: 3px 8px;

        font-size: 10px;
    }

    body.single #lm-article-location-results
    .lm-article-location-name {
        font-size: 13.5px;
    }

    body.single #lm-article-location-results
    .lm-article-location-meta {
        font-size: 10.5px;
    }
}


/* =========================================================
   LM-ARTICLE-LOCATION-SEARCH-V4
   Título + lupa SVG + dark SmartMag real
   ========================================================= */


/* TÍTULO */

body.single #lm-article-location-search
.lm-article-location-heading {
    width: 100%;
    max-width: 620px;

    margin: 0 auto 9px;

    color: #263846;

    font-family: inherit;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.2;

    letter-spacing: .045em;
    text-align: left;
}

body.single #lm-article-location-search
.lm-article-location-heading span {
    color: #687782;
    font-weight: 650;
}


/* =========================================================
   LUPA SVG
   Anula a lupa CSS da V3
   ========================================================= */

body.single #lm-article-location-search
.lm-article-location-icon {
    display: flex;

    width: 22px;
    height: 22px;

    align-items: center;
    justify-content: center;

    top: 50%;
    left: 16px;

    color: #536574;
}

body.single #lm-article-location-search
.lm-article-location-icon::before,

body.single #lm-article-location-search
.lm-article-location-icon::after {
    content: none !important;
    display: none !important;
}

body.single #lm-article-location-search
.lm-article-location-icon svg {
    display: block;

    width: 21px;
    height: 21px;

    overflow: visible;

    fill: none;
    stroke: currentColor;

    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}


/* =========================================================
   DARK MODE REAL DO SMARTMAG

   SmartMag coloca:
   html.s-dark
   html.site-s-dark
   ========================================================= */

html.s-dark body.single #lm-article-location-search,
html.site-s-dark body.single #lm-article-location-search,
html[data-theme="dark"] body.single #lm-article-location-search {
    background: #151d24 !important;
    border-bottom-color: #293640 !important;
}

html.s-dark body.single #lm-article-location-search
.lm-article-location-heading,

html.site-s-dark body.single #lm-article-location-search
.lm-article-location-heading,

html[data-theme="dark"] body.single #lm-article-location-search
.lm-article-location-heading {
    color: #f0f5f8 !important;
}

html.s-dark body.single #lm-article-location-search
.lm-article-location-heading span,

html.site-s-dark body.single #lm-article-location-search
.lm-article-location-heading span,

html[data-theme="dark"] body.single #lm-article-location-search
.lm-article-location-heading span {
    color: #aab6bf !important;
}


/* INPUT */

html.s-dark body.single #lm-article-location-input,
html.site-s-dark body.single #lm-article-location-input,
html[data-theme="dark"] body.single #lm-article-location-input {
    background: #202a32 !important;
    color: #f2f6f8 !important;

    border-color: #3b4954 !important;

    box-shadow:
        0 2px 10px rgba(0,0,0,.20) !important;
}

html.s-dark body.single #lm-article-location-input::placeholder,
html.site-s-dark body.single #lm-article-location-input::placeholder,
html[data-theme="dark"] body.single #lm-article-location-input::placeholder {
    color: #a8b3bb !important;
}

html.s-dark body.single #lm-article-location-input:focus,
html.site-s-dark body.single #lm-article-location-input:focus,
html[data-theme="dark"] body.single #lm-article-location-input:focus {
    border-color: #429ce8 !important;

    box-shadow:
        0 0 0 3px rgba(66,156,232,.18) !important;
}


/* LUPA */

html.s-dark body.single #lm-article-location-search
.lm-article-location-icon,

html.site-s-dark body.single #lm-article-location-search
.lm-article-location-icon,

html[data-theme="dark"] body.single #lm-article-location-search
.lm-article-location-icon {
    color: #c6d0d7 !important;
}


/* BOTÃO X */

html.s-dark body.single #lm-article-location-clear,
html.site-s-dark body.single #lm-article-location-clear,
html[data-theme="dark"] body.single #lm-article-location-clear {
    background: #35424c !important;
    color: #dce4e9 !important;
}


/* DROPDOWN */

html.s-dark body.single #lm-article-location-results,
html.site-s-dark body.single #lm-article-location-results,
html[data-theme="dark"] body.single #lm-article-location-results {
    background: #202930 !important;
    color: #eef3f6 !important;

    border-color: #36434d !important;

    box-shadow:
        0 15px 40px rgba(0,0,0,.44) !important;
}


/* RESULTADOS */

html.s-dark body.single #lm-article-location-results
.lm-article-location-result,

html.site-s-dark body.single #lm-article-location-results
.lm-article-location-result,

html[data-theme="dark"] body.single #lm-article-location-results
.lm-article-location-result {
    background: #202930 !important;
    color: #eef3f6 !important;

    border-bottom-color: #34414a !important;
}

html.s-dark body.single #lm-article-location-results
.lm-article-location-result:hover,

html.s-dark body.single #lm-article-location-results
.lm-article-location-result.active,

html.site-s-dark body.single #lm-article-location-results
.lm-article-location-result:hover,

html.site-s-dark body.single #lm-article-location-results
.lm-article-location-result.active,

html[data-theme="dark"] body.single #lm-article-location-results
.lm-article-location-result:hover,

html[data-theme="dark"] body.single #lm-article-location-results
.lm-article-location-result.active {
    background: #293741 !important;
}


/* NOME */

html.s-dark body.single #lm-article-location-results
.lm-article-location-name,

html.site-s-dark body.single #lm-article-location-results
.lm-article-location-name,

html[data-theme="dark"] body.single #lm-article-location-results
.lm-article-location-name {
    color: #f4f7f9 !important;
}


/* META */

html.s-dark body.single #lm-article-location-results
.lm-article-location-meta,

html.site-s-dark body.single #lm-article-location-results
.lm-article-location-meta,

html[data-theme="dark"] body.single #lm-article-location-results
.lm-article-location-meta {
    color: #adb9c1 !important;
}


/* RESULTADO VAZIO */

html.s-dark body.single #lm-article-location-results
.lm-article-location-empty,

html.site-s-dark body.single #lm-article-location-results
.lm-article-location-empty,

html[data-theme="dark"] body.single #lm-article-location-results
.lm-article-location-empty {
    color: #adb9c1 !important;
}


/* ÍCONES NO DARK */

html.s-dark body.single #lm-article-location-results
.lm-location-type-icon,

html.site-s-dark body.single #lm-article-location-results
.lm-location-type-icon,

html[data-theme="dark"] body.single #lm-article-location-results
.lm-location-type-icon {
    background: #2b3944 !important;
    color: #b9d6eb !important;
}


/* BADGES DARK */

html.s-dark body.single #lm-article-location-results
.lm-location-type-badge,

html.site-s-dark body.single #lm-article-location-results
.lm-location-type-badge,

html[data-theme="dark"] body.single #lm-article-location-results
.lm-location-type-badge {
    background: #34434e !important;
    color: #d4dee5 !important;
}

html.s-dark body.single #lm-article-location-results
.lm-location-type-concelho
.lm-location-type-badge,

html.site-s-dark body.single #lm-article-location-results
.lm-location-type-concelho
.lm-location-type-badge {
    background: #203e58 !important;
    color: #9fd0f5 !important;
}

html.s-dark body.single #lm-article-location-results
.lm-location-type-montanha
.lm-location-type-badge,

html.site-s-dark body.single #lm-article-location-results
.lm-location-type-montanha
.lm-location-type-badge {
    background: #29463c !important;
    color: #a8dfca !important;
}

html.s-dark body.single #lm-article-location-results
.lm-location-type-praia
.lm-location-type-badge,

html.site-s-dark body.single #lm-article-location-results
.lm-location-type-praia
.lm-location-type-badge {
    background: #234653 !important;
    color: #a8dce9 !important;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 767px) {

    body.single #lm-article-location-search
    .lm-article-location-heading {
        margin-bottom: 7px;

        font-size: 10.5px;
        letter-spacing: .035em;
    }

    body.single #lm-article-location-search
    .lm-article-location-icon {
        left: 14px;

        width: 20px;
        height: 20px;
    }

    body.single #lm-article-location-search
    .lm-article-location-icon svg {
        width: 19px;
        height: 19px;
    }

}


/*
 * ==========================================================
 * LM-ARTICLE-SEARCH-BODY-BG-V1
 *
 * A área da pesquisa deixa de ter fundo próprio.
 * Mostra exatamente o fundo da página/artigo.
 * ==========================================================
 */

body.single #lm-article-location-search {
    background:
        transparent
        !important;
}

body.single #lm-article-location-search
.lm-article-location-search-inner {
    background:
        transparent
        !important;
}



/*
 * ==========================================================
 * LM-ARTICLE-SEARCH-EXACT-POST-BG-V2
 *
 * A faixa da pesquisa usa exatamente a mesma variável
 * de fundo definida para o corpo dos artigos.
 * ==========================================================
 */

html.s-dark body.single #lm-article-location-search,
html.site-s-dark body.single #lm-article-location-search,
html[data-theme="dark"] body.single #lm-article-location-search {
    background:
        var(--lm-post-bg)
        !important;

    background-color:
        var(--lm-post-bg)
        !important;
}


/*
 * O conteúdo interno não cria uma segunda camada.
 */
html.s-dark body.single #lm-article-location-search
.lm-article-location-search-inner,
html.site-s-dark body.single #lm-article-location-search
.lm-article-location-search-inner,
html[data-theme="dark"] body.single #lm-article-location-search
.lm-article-location-search-inner {
    background:
        transparent
        !important;
}

