/* =====================================================================
   Stocuri Depozite
   1. butonul rosu din meniul de sus (apare pe toate paginile)
   2. pagina de cautare a stocurilor
   ===================================================================== */

/* ---------- 1. Butonul din meniu ---------- */

.navbar .sd-nav-btn {
    font-weight: 600;
    white-space: nowrap;
    border-radius: 999px;
    padding: .38rem 1rem;
    margin-left: .5rem;
    box-shadow: 0 2px 8px rgba(220, 53, 69, .35);
}

.navbar .sd-nav-btn:hover,
.navbar .sd-nav-btn:focus {
    box-shadow: 0 3px 12px rgba(220, 53, 69, .5);
}

.sd-nav-nou {
    display: inline-block;
    margin-left: 6px;
    padding: 0 7px;
    font-family: -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .6px;
    line-height: 16px;
    color: #dc3545;
    background: #fff;
    border-radius: 999px;
    vertical-align: 1px;
    animation: sd-puls 1.8s ease-out infinite;
}

@keyframes sd-puls {
    0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, .8); }
    70% { box-shadow: 0 0 0 8px rgba(255, 255, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

@media (max-width: 767.98px) {
    .navbar .sd-nav-btn {
        margin: .5rem 0;
    }
}

/* Meniul are acum un buton in plus: pe ecranele late ii dam mai mult loc,
   ca linkurile din dreapta sa nu se rupa pe doua randuri. */
@media (min-width: 768px) {
    .navbar-laravel > .container {
        max-width: 1320px;
    }
}

/* ---------- 2. Pagina de cautare ---------- */

.sd-pagina {
    max-width: 980px;
}

.sd-antet {
    margin-bottom: 14px;
}

.sd-titlu {
    margin: 0;
    font-size: 26px;
    font-weight: 600;
    color: #1f2933;
}

.sd-nou {
    display: inline-block;
    margin-left: 8px;
    padding: 0 9px;
    font-family: -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .6px;
    line-height: 20px;
    color: #fff;
    background: #dc3545;
    border-radius: 999px;
    vertical-align: 5px;
}

.sd-subtitlu {
    margin: 2px 0 0;
    font-size: 14px;
    color: #66727f;
}

/* bara de cautare ramane sus cand derulezi rezultatele */
.sd-bara {
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    flex-wrap: wrap;
    margin: 0 -6px;
    padding: 10px 0 4px;
    background: #f5f8fa;
}

.sd-cautare,
.sd-depozit {
    position: relative;
    margin: 0 6px 8px;
}

.sd-cautare {
    flex: 1 1 380px;
}

.sd-depozit {
    flex: 0 1 330px;
}

.sd-input,
.sd-select {
    display: block;
    width: 100%;
    height: 56px;
    color: #1f2933;
    background-color: #fff;
    border: 2px solid #dbe2ea;
    border-radius: 14px;
    outline: 0;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .05);
    transition: border-color .15s ease, box-shadow .15s ease;
}

.sd-input {
    padding: 0 82px 0 50px;
    font-size: 17px;
}

.sd-input::placeholder {
    color: #9aa5b1;
}

.sd-input::-ms-clear {
    display: none;
}

.sd-input:focus,
.sd-select:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 4px rgba(220, 53, 69, .13);
}

.sd-lupa {
    position: absolute;
    top: 50%;
    left: 17px;
    width: 21px;
    height: 21px;
    margin-top: -10px;
    color: #8a94a0;
    pointer-events: none;
}

.sd-sterge {
    position: absolute;
    top: 50%;
    right: 11px;
    display: none;
    width: 32px;
    height: 32px;
    margin-top: -16px;
    padding: 0;
    font-size: 22px;
    line-height: 30px;
    color: #52606d;
    cursor: pointer;
    background: #eef1f5;
    border: 0;
    border-radius: 50%;
}

.sd-sterge:hover {
    color: #fff;
    background: #dc3545;
}

.sd-spinner {
    position: absolute;
    top: 50%;
    right: 52px;
    display: none;
    width: 18px;
    height: 18px;
    margin-top: -9px;
    border: 2px solid #e3e8ee;
    border-top-color: #dc3545;
    border-radius: 50%;
    animation: sd-rotire .6s linear infinite;
}

@keyframes sd-rotire {
    to { transform: rotate(360deg); }
}

.sd-eticheta {
    position: absolute;
    top: 8px;
    left: 17px;
    margin: 0;
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: .7px;
    line-height: 1;
    color: #8a94a0;
    text-transform: uppercase;
    pointer-events: none;
}

.sd-eticheta--al-meu {
    color: #dc3545;
}

.sd-select {
    padding: 19px 40px 3px 15px;
    font-size: 14.5px;
    font-weight: 600;
    cursor: pointer;
    background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%238a94a0' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 8l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 13px center;
    background-size: 18px 18px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.sd-select::-ms-expand {
    display: none;
}

.sd-optiuni {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    margin: 2px 2px 0;
    font-size: 13.5px;
}

.sd-bifa {
    margin: 0 16px 0 0;
    color: #52606d;
    cursor: pointer;
    user-select: none;
}

.sd-bifa input {
    margin-right: 5px;
    vertical-align: -1px;
}

.sd-revino {
    font-weight: 600;
    color: #dc3545;
}

.sd-revino:hover {
    color: #a71d2a;
}

.sd-status {
    min-height: 21px;
    margin: 16px 2px 10px;
    font-size: 13.5px;
    color: #52606d;
}

.sd-status b {
    color: #1f2933;
}

.sd-status .sd-atentie {
    color: #b45309;
}

.sd-rezultate {
    transition: opacity .15s ease;
}

.sd-rezultate.sd-se-incarca {
    opacity: .55;
}

/* un produs */
.sd-rand {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    padding: 12px 14px 12px 18px;
    background: #fff;
    border: 1px solid #e3e8ef;
    border-radius: 12px;
    transition: border-color .15s ease, box-shadow .15s ease;
}

.sd-rand:hover {
    border-color: #cdd6e1;
    box-shadow: 0 3px 12px rgba(31, 41, 51, .07);
}

.sd-rand-info {
    flex: 1 1 auto;
    min-width: 0;
}

.sd-nume {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    color: #1f2933;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.sd-rand mark {
    padding: 0 1px;
    color: inherit;
    background: #ffe9a8;
    border-radius: 3px;
}

.sd-nume-depozit {
    margin-top: 1px;
    font-size: 12.5px;
    color: #66727f;
}

.sd-meta {
    margin-top: 4px;
    font-size: 12px;
    color: #7b8794;
}

.sd-meta span {
    display: inline-block;
    margin-right: 14px;
    white-space: nowrap;
}

.sd-meta b,
.sd-stoc-valoare,
.sd-chip b {
    /* cifre drepte, usor de citit (fontul site-ului deseneaza cifrele "vechi", pe inaltimi diferite) */
    font-family: -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-variant-numeric: tabular-nums lining-nums;
}

.sd-meta b {
    font-weight: 600;
    color: #52606d;
}

.sd-meta .sd-nota {
    font-style: italic;
    white-space: normal;
}

.sd-alte {
    margin-top: 6px;
    font-size: 12px;
    color: #7b8794;
}

.sd-chip {
    display: inline-block;
    margin: 2px 4px 2px 0;
    padding: 1px 9px;
    color: #2b5ea7;
    white-space: nowrap;
    background: #eaf2ff;
    border-radius: 999px;
}

.sd-chip b {
    margin-left: 3px;
    font-weight: 700;
}

.sd-rand-stoc {
    flex: 0 0 auto;
    min-width: 112px;
    margin-left: 16px;
    padding: 9px 12px 8px;
    color: #146c43;
    text-align: center;
    background: #e6f6ec;
    border-radius: 10px;
}

.sd-stoc-valoare {
    font-size: 23px;
    font-weight: 700;
    line-height: 1.1;
}

.sd-stoc-eticheta {
    margin-top: 2px;
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: .5px;
    text-transform: uppercase;
}

.sd-stoc-info {
    margin-top: 3px;
    font-size: 11px;
    line-height: 1.2;
    white-space: nowrap;
    opacity: .85;
}

/* produs fara stoc in depozitul ales */
.sd-rand--fara .sd-nume {
    font-weight: 400;
    color: #52606d;
}

.sd-rand--fara .sd-rand-stoc {
    color: #8a94a0;
    background: #f1f3f6;
}

/* mesaje: inceput, nimic gasit, eroare */
.sd-mesaj {
    padding: 34px 24px;
    color: #52606d;
    text-align: center;
    background: #fff;
    border: 1px dashed #d5dde6;
    border-radius: 14px;
}

.sd-mesaj-titlu {
    margin-bottom: 6px;
    font-size: 18px;
    font-weight: 600;
    color: #1f2933;
}

.sd-mesaj p {
    margin: 0 0 6px;
}

.sd-mesaj p:last-child {
    margin-bottom: 0;
}

.sd-mesaj kbd {
    padding: 2px 7px;
    font-size: 13px;
    color: #1f2933;
    background: #eef1f5;
    border-radius: 6px;
    box-shadow: none;
}

.sd-mesaj--eroare {
    border-color: #f1b0b7;
}

.sd-mai-multe {
    margin: 14px 0 30px;
    text-align: center;
}

@media (max-width: 575.98px) {
    .sd-titlu {
        font-size: 22px;
    }

    /* pe telefon bara ar ocupa prea mult din ecran daca ar ramane lipita sus */
    .sd-bara {
        position: static;
    }

    .sd-input {
        padding-left: 44px;
        font-size: 16px;
    }

    .sd-lupa {
        left: 14px;
    }

    .sd-depozit {
        flex-basis: 100%;
    }

    .sd-rand {
        padding: 10px 10px 10px 13px;
    }

    .sd-rand-stoc {
        min-width: 80px;
        margin-left: 10px;
        padding: 8px 8px 7px;
    }

    .sd-stoc-valoare {
        font-size: 19px;
    }

    .sd-meta span {
        white-space: normal;
    }
}

@media (prefers-reduced-motion: reduce) {
    .sd-nav-nou {
        animation: none;
    }
}
