/* ============================================================
   LOCAÇÃO - PESQUISA
   ============================================================ */

#search-panel-locacao {
    width: 100%;
}


/* ============================================================
   CABEÇALHO
   ============================================================ */

#search-panel-locacao .search-header {
    margin-bottom: 16px;
}

#search-panel-locacao .search-eyebrow {
    display: block;

    margin-bottom: 4px;

    color: var(--accent);

    font-size: 11px;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.06em;
}

#search-panel-locacao .search-header h1 {
    margin: 0;

    color: var(--primary);

    font-size: 24px;
    font-weight: 800;
    line-height: 1.2;
}

#search-panel-locacao .search-header p {
    margin: 6px 0 0;

    color: var(--text-muted);

    font-size: 13px;
}


/* ============================================================
   DEVOLUÇÃO EM OUTRO LOCAL
   ============================================================ */

#search-panel-locacao .rental-options {
    margin-bottom: 15px;
}

#search-panel-locacao .filter-check {
    display: inline-flex;
    align-items: center;

    gap: 8px;

    color: #5f7082;

    font-size: 12px;
    font-weight: 600;

    cursor: pointer;
}

#search-panel-locacao .filter-check input {
    width: 15px;
    height: 15px;

    margin: 0;

    accent-color: var(--accent);

    cursor: pointer;
}


/* ============================================================
   GRID
   ============================================================ */

#search-panel-locacao .rental-search-fields {
    display: grid;

    grid-template-columns:
        minmax(260px, 1.8fr) minmax(140px, 0.9fr) minmax(105px, 0.65fr) minmax(140px, 0.9fr) minmax(105px, 0.65fr);

    gap: 12px;

    align-items: end;

    width: 100%;
}


/* Quando aparece outro local de devolução */

#search-panel-locacao .rental-search-fields:has(#locacao-return-location-group:not([hidden])) {
    grid-template-columns:
        minmax(200px, 1.4fr) minmax(125px, 0.8fr) minmax(95px, 0.6fr) minmax(200px, 1.4fr) minmax(125px, 0.8fr) minmax(95px, 0.6fr);
}


/* ============================================================
   CAMPOS
   ============================================================ */

#search-panel-locacao .form-group {
    min-width: 0;
}

#search-panel-locacao .form-group label {
    display: block;

    margin-bottom: 7px;

    color: var(--text-muted);

    font-size: 11px;
    font-weight: 700;
}


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

#search-panel-locacao .input-wrapper {
    position: relative;

    display: flex;
    align-items: center;

    width: 100%;
}

#search-panel-locacao .input-wrapper>i {
    position: absolute;

    left: 14px;

    z-index: 2;

    color: #93a4b8;

    font-size: 14px;

    pointer-events: none;
}


/* ============================================================
   INPUTS
   ============================================================ */

#search-panel-locacao .input-wrapper input,
#search-panel-locacao .input-wrapper select {
    width: 100%;
    height: 46px;

    padding: 0 12px 0 40px;

    border: 1px solid #d7e1eb;
    border-radius: 9px;

    background: #f8fafc;

    color: var(--text);

    font: inherit;
    font-size: 12px;

    outline: none;

    box-sizing: border-box;

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

#search-panel-locacao .input-wrapper input:hover,
#search-panel-locacao .input-wrapper select:hover {
    border-color: #c4d2df;
}

#search-panel-locacao .input-wrapper input:focus,
#search-panel-locacao .input-wrapper select:focus {
    border-color: var(--accent);

    background: #ffffff;

    box-shadow:
        0 0 0 3px rgba(22, 131, 229, 0.10);
}


/* ============================================================
   AÇÕES
   ============================================================ */

#search-panel-locacao .search-actions {
    display: flex;
    justify-content: flex-end;

    margin-top: 16px;
}

#search-panel-locacao .btn-search {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;

    min-width: 175px;
    height: 44px;

    padding: 0 20px;

    border: 0;
    border-radius: 9px;

    background: var(--accent);

    color: #ffffff;

    font: inherit;
    font-size: 12px;
    font-weight: 700;

    cursor: pointer;

    box-shadow:
        0 6px 16px rgba(22, 131, 229, 0.16);

    transition:
        background 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

#search-panel-locacao .btn-search:hover {
    transform: translateY(-1px);

    background: var(--accent-hover);

    box-shadow:
        0 8px 20px rgba(22, 131, 229, 0.22);
}


/* ============================================================
   RESPONSIVO
   ============================================================ */

@media (max-width: 1050px) {

    #search-panel-locacao .rental-search-fields,
    #search-panel-locacao .rental-search-fields:has(#locacao-return-location-group:not([hidden])) {
        grid-template-columns:
            2fr 1fr 1fr;
    }
}


@media (max-width: 760px) {

    #search-panel-locacao .rental-search-fields,
    #search-panel-locacao .rental-search-fields:has(#locacao-return-location-group:not([hidden])) {
        grid-template-columns:
            1fr 1fr;
    }

    #search-panel-locacao .rental-location {
        grid-column: 1 / -1;
    }
}


@media (max-width: 520px) {

    #search-panel-locacao .rental-search-fields,
    #search-panel-locacao .rental-search-fields:has(#locacao-return-location-group:not([hidden])) {
        grid-template-columns: 1fr;
    }

    #search-panel-locacao .rental-location {
        grid-column: auto;
    }

    #search-panel-locacao .btn-search {
        width: 100%;
    }
}

/* ============================================================
   LOCAÇÃO - RESULTADOS
   ============================================================ */

#locacao-results {
    width: 100%;
}


/* ============================================================
   CABEÇALHO
   ============================================================ */

.locacao-results-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    gap: 24px;

    margin-bottom: 22px;
}

.locacao-results-eyebrow {
    display: block;

    margin-bottom: 4px;

    color: var(--accent);

    font-size: 11px;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.locacao-results-header h2 {
    margin: 0;

    color: var(--primary);

    font-size: 24px;
    font-weight: 800;
    line-height: 1.2;
}

.locacao-results-header p {
    margin: 5px 0 0;

    color: var(--text-muted);

    font-size: 13px;
}


/* ============================================================
   ORDENAÇÃO
   ============================================================ */

.locacao-results-sort {
    display: flex;
    flex-direction: column;

    gap: 6px;

    min-width: 190px;
}

.locacao-results-sort label {
    color: var(--text-muted);

    font-size: 11px;
    font-weight: 700;
}

.locacao-results-sort select {
    width: 100%;
    height: 42px;

    padding: 0 36px 0 13px;

    border: 1px solid #d7e1eb;
    border-radius: 9px;

    background: #ffffff;

    color: var(--text);

    font: inherit;
    font-size: 13px;

    outline: none;
    cursor: pointer;
}

.locacao-results-sort select:focus {
    border-color: var(--accent);

    box-shadow:
        0 0 0 3px rgba(22, 131, 229, 0.10);
}


/* ============================================================
   LISTA
   ============================================================ */

.locacao-results-list {
    display: flex;
    flex-direction: column;

    gap: 16px;

    width: 100%;
}


/* ============================================================
   CARD
   ============================================================ */

.locacao-card {
    overflow: hidden;

    width: 100%;

    border: 1px solid #e0e7ef;
    border-radius: 16px;

    background: #ffffff;

    box-shadow:
        0 4px 12px rgba(5, 35, 61, 0.035),
        0 12px 30px rgba(5, 35, 61, 0.025);

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.locacao-card:hover {
    transform: translateY(-2px);

    border-color: #bddcf7;

    box-shadow:
        0 7px 18px rgba(5, 35, 61, 0.06),
        0 18px 38px rgba(5, 35, 61, 0.05);
}


/* ============================================================
   CONTEÚDO
   ============================================================ */

.locacao-card-main {
    display: grid;

    grid-template-columns:
        210px minmax(0, 1fr) 190px;

    align-items: center;

    gap: 26px;

    min-height: 175px;

    padding: 22px 24px;
}


/* ============================================================
   VEÍCULO
   ============================================================ */

.locacao-car-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 9px;

    min-height: 135px;

    border-radius: 13px;

    background:
        linear-gradient(145deg,
            #edf7ff,
            #dceefe);

    color: var(--accent);
}

.locacao-car-placeholder i {
    font-size: 43px;
}

.locacao-car-placeholder span {
    font-size: 10px;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.07em;
}


/* ============================================================
   INFORMAÇÕES
   ============================================================ */

.locacao-information {
    min-width: 0;
}

.locacao-company {
    margin-bottom: 7px;
}

.locacao-company span {
    color: var(--accent);

    font-size: 10px;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.07em;
}

.locacao-category {
    display: block;

    margin-bottom: 4px;

    color: #758698;

    font-size: 10px;
    font-weight: 700;
}

.locacao-information h3 {
    margin: 0;

    color: var(--primary);

    font-size: 21px;
    font-weight: 800;
    line-height: 1.2;
}

.locacao-similar {
    display: block;

    margin-top: 3px;

    color: #8b98a6;

    font-size: 10px;
}


/* ============================================================
   CARACTERÍSTICAS
   ============================================================ */

.locacao-features {
    display: flex;
    flex-wrap: wrap;

    gap: 8px;

    margin-top: 18px;
}

.locacao-features span {
    display: inline-flex;
    align-items: center;

    gap: 6px;

    padding: 6px 9px;

    border-radius: 7px;

    background: #f4f7fa;

    color: #5d6e80;

    font-size: 10px;
    font-weight: 600;
}

.locacao-features i {
    color: var(--accent);
}


/* ============================================================
   PREÇO
   ============================================================ */

.locacao-price {
    display: flex;
    flex-direction: column;
    align-items: flex-end;

    min-width: 0;

    padding-left: 24px;

    border-left: 1px solid #edf1f5;
}

.locacao-daily-label {
    color: #8492a1;

    font-size: 9px;
    font-weight: 600;

    text-transform: uppercase;
}

.locacao-daily-price {
    margin-top: 3px;

    color: var(--primary);

    font-size: 22px;
    font-weight: 800;
}


/* ============================================================
   TOTAL
   ============================================================ */

.locacao-total {
    display: flex;
    align-items: baseline;
    justify-content: flex-end;

    gap: 6px;

    width: 100%;

    margin-top: 9px;
    padding-top: 9px;

    border-top: 1px solid #edf1f5;
}

.locacao-total span {
    color: #8290a0;

    font-size: 9px;
}

.locacao-total strong {
    color: #4d6175;

    font-size: 12px;
    font-weight: 800;
}


/* ============================================================
   BOTÃO
   ============================================================ */

.locacao-select-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 125px;
    height: 39px;

    margin-top: 13px;
    padding: 0 15px;

    border: 0;
    border-radius: 8px;

    background: var(--accent);

    color: #ffffff;

    font: inherit;
    font-size: 11px;
    font-weight: 700;

    cursor: pointer;

    transition:
        background 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.locacao-select-button:hover {
    transform: translateY(-1px);

    background: var(--accent-hover);

    box-shadow:
        0 6px 14px rgba(22, 131, 229, 0.20);
}


/* ============================================================
   LOADING
   ============================================================ */

.locacao-loading {
    align-items: center;

    gap: 15px;

    margin-bottom: 18px;
    padding: 20px;

    border: 1px solid #e0e7ef;
    border-radius: 13px;

    background: #ffffff;
}

.locacao-loading:not([hidden]) {
    display: flex;
}

.locacao-loading>div:last-child {
    display: flex;
    flex-direction: column;

    gap: 3px;
}

.locacao-loading strong {
    color: var(--primary);

    font-size: 13px;
}

.locacao-loading span {
    color: var(--text-muted);

    font-size: 11px;
}

.locacao-loading-spinner {
    width: 27px;
    height: 27px;

    flex: 0 0 27px;

    border: 3px solid #e4edf5;
    border-top-color: var(--accent);
    border-radius: 50%;

    animation:
        locacao-spinner 0.7s linear infinite;
}

@keyframes locacao-spinner {

    to {
        transform: rotate(360deg);
    }
}


/* ============================================================
   SEM RESULTADOS
   ============================================================ */

.locacao-empty-results {
    padding: 46px 24px;

    border: 1px dashed #ccd8e5;
    border-radius: 15px;

    background: #ffffff;

    text-align: center;
}

.locacao-empty-results i {
    margin-bottom: 12px;

    color: #9aaabc;

    font-size: 32px;
}

.locacao-empty-results h3 {
    margin: 0 0 6px;

    color: var(--primary);

    font-size: 18px;
}

.locacao-empty-results p {
    margin: 0;

    color: var(--text-muted);

    font-size: 12px;
}


/* ============================================================
   RESPONSIVO
   ============================================================ */

@media (max-width: 900px) {

    .locacao-card-main {
        grid-template-columns:
            180px minmax(0, 1fr) 170px;

        gap: 18px;

        padding: 20px;
    }
}


@media (max-width: 760px) {

    .locacao-results-header {
        align-items: stretch;
        flex-direction: column;
    }

    .locacao-results-sort {
        width: 100%;
    }

    .locacao-card-main {
        grid-template-columns: 1fr;
    }

    .locacao-car-placeholder {
        min-height: 120px;
    }

    .locacao-price {
        align-items: flex-start;

        padding-top: 17px;
        padding-left: 0;

        border-top: 1px solid #edf1f5;
        border-left: 0;
    }

    .locacao-total {
        justify-content: flex-start;
    }

    .locacao-select-button {
        width: 100%;
    }
}