/* Вкладка «Подборка» кабинета сотрудника (resources/views/cabinet/staff/picks.blade.php) */

.spicks__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.spicks__actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.spicks__actions form,
.spick__side form {
    margin: 0;
}

.spicks__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 36px;
    padding: 0 14px;
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
    color: #282828;
    text-decoration: none;
    background: #fff;
    border: 1px solid #d9d9d9;
    border-radius: 8px;
    cursor: pointer;
    transition: background .15s, color .15s, border-color .15s;
}
.spicks__btn:hover {
    border-color: #282828;
}
.spicks__btn--main {
    color: #fff;
    background: #ef533f;
    border-color: #ef533f;
}
.spicks__btn--main:hover {
    color: #fff;
    background: #d8412e;
    border-color: #d8412e;
}
.spicks__btn--muted {
    color: #6b717c;
}

.spicks__count {
    margin: 14px 0 0;
    font-size: 14px;
    color: #6b717c;
}
/* «В подборке пока нет туров»: отдельный блок с отступом от кнопок */
.spicks__noresult {
    margin-top: 24px;
}
.spicks__empty {
    margin: 8px 0 0;
    font-size: 14px;
    color: #6b717c;
}

.spicks {
    display: grid;
    gap: 12px;
    margin-top: 14px;
}

.spick {
    display: grid;
    grid-template-columns: 160px 1fr 190px;
    gap: 16px;
    padding: 14px;
    background: #f7f7f7;
    border: 1px solid #ececec;
    border-radius: 12px;
}

.spick__photo {
    width: 160px;
    height: 120px;
    overflow: hidden;
    background: #e9e9e9;
    border-radius: 8px;
}
.spick__photo img {
    display: block;
    width: 160px;
    height: 120px;
    object-fit: cover;
}

.spick__body {
    min-width: 0;
}
.spick__title {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 4px 8px;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.3;
}
.spick__title a {
    color: #282828;
    text-decoration: none;
}
.spick__title a:hover {
    color: #ef533f;
}
.spick__stars {
    font-size: 13px;
    color: #f5a623;
    white-space: nowrap;
}
.spick__rating {
    padding: 1px 6px;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    background: #1f9d55;
    border-radius: 5px;
}
.spick__place {
    margin-top: 2px;
    font-size: 13px;
    color: #6b717c;
}

.spick__facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 16px;
    margin: 10px 0 0;
}
.spick__facts > div {
    min-width: 0;
}
.spick__facts dt {
    font-size: 11px;
    letter-spacing: .03em;
    text-transform: uppercase;
    color: #8a8f98;
}
.spick__facts dd {
    margin: 0;
    font-size: 14px;
    color: #282828;
    overflow-wrap: anywhere;
}

.spick__side {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    text-align: right;
}
.spick__side .spicks__btn {
    width: 100%;
}
.spick__price {
    font-size: 20px;
    font-weight: 700;
    white-space: nowrap;
    color: #282828;
}
.spick__added {
    margin-top: -4px;
    margin-bottom: 4px;
    font-size: 12px;
    color: #8a8f98;
}

@media (max-width: 900px) {
    .spick {
        grid-template-columns: 120px 1fr;
    }
    .spick__photo,
    .spick__photo img {
        width: 120px;
        height: 90px;
    }
    .spick__side {
        grid-column: 1 / -1;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        text-align: left;
    }
    .spick__side .spicks__btn {
        width: auto;
    }
    .spick__added {
        margin: 0 auto 0 0;
    }
}

@media (max-width: 560px) {
    .spick {
        grid-template-columns: 1fr;
    }
    .spick__photo,
    .spick__photo img {
        width: 100%;
        height: 180px;
    }
    .spick__facts {
        grid-template-columns: 1fr;
    }
}

/* название номера — кнопка: открывает окно «о номере» (как в выдаче поиска) */
.spick__room {
    padding: 0;
    font: inherit;
    color: inherit;
    text-align: left;
    background: none;
    border: 0;
    border-bottom: 1px dashed #8a8f98;
    cursor: pointer;
}
.spick__room:hover {
    color: #ef533f;
    border-bottom-color: #ef533f;
}
.spick__room.is-loading {
    opacity: .5;
    cursor: progress;
}

/* ---------- несколько подборок: список, метка автора, новое название ---------- */
.spicks__new,
.spicks__rename {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 0;
}
.spicks__rename {
    margin-top: 14px;
}
.spicks__input {
    flex: 1 1 220px;
    min-width: 0;
    height: 36px;
    padding: 0 12px;
    font: inherit;
    font-size: 14px;
    color: #282828;
    background: #fff;
    border: 1px solid #d9d9d9;
    border-radius: 8px;
}
.spicks__input:focus {
    outline: none;
    border-color: #282828;
}
/* панель «Новая подборка»: выделена фоном и рамкой, поле и кнопка — в одну строку */
.spicks__new {
    display: block;
    margin-top: 16px;
    padding: 17px 16px 22px;
    background: #fff4f1;
    border: none;
    border-radius: 12px;
}
.spicks__new-title {
    display: block;
    margin-bottom: 8px;
    font-size: 15px;
    text-transform: uppercase;
    font-weight: 400;
    color: #282828;
    letter-spacing: .7px;
}
.spicks__new-row {
    display: flex;
    gap: 8px;
}
.spicks__new .spicks__input,
.spicks__new .spicks__btn {
    height: 42px;
}
.spicks__new .spicks__input {
    flex: 1 1 auto;
    font-size: 15px;
}
.spicks__new .spicks__btn {
    flex: none;
    padding: 0 22px;
}

.splists {
    display: grid;
    gap: 6px;
    margin-top: 14px;
    max-height: 320px;
    overflow-y: auto;
}
.splist {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 10px 14px;
    color: #282828;
    background: #f7f7f7;
    border: 1px solid #ececec;
    border-radius: 10px;
    transition: border-color .15s, background .15s;
}
.splist:hover {
    border-color: #282828;
}
.splist.is-open {
    background: #fff;
    border-color: #ef533f;
}
.splist form {
    margin: 0;
}
.splist__link {
    flex: 1 1 auto;
    min-width: 0;
    display: grid;
    gap: 2px;
    color: #282828;
    text-decoration: none;
}
/* «Удалить подборку» в строке списка */
.splist__del {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    color: #8a8f98;
    background: #fff;
    border: 1px solid #e2e0da;
    border-radius: 8px;
    cursor: pointer;
    transition: color .15s, border-color .15s;
}
.splist__del:hover {
    color: #d8412e;
    border-color: #d8412e;
}
.spicks__actions--row {
    margin-top: 14px;
}
.spicks__btn--danger {
    color: #d8412e;
    border-color: #f1b8ae;
}
.spicks__btn--danger:hover {
    color: #fff;
    background: #d8412e;
    border-color: #d8412e;
}
.splist__title {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px 8px;
    min-width: 0;
    font-size: 15px;
}
.splist__title b {
    font-weight: 700;
    overflow-wrap: anywhere;
}
.splist__badge {
    padding: 2px 7px;
    font-size: 11px;
    font-style: normal;
    font-weight: 700;
    color: #fff;
    background: #1f9d55;
    border-radius: 5px;
}
.splist__meta {
    font-size: 12px;
    color: #6b717c;
}
.splist__count {
    flex: none;
    min-width: 30px;
    padding: 4px 8px;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    background: #fff;
    border: 1px solid #e2e0da;
    border-radius: 8px;
}

.spicks__label {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 18px;
    margin-top: 8px;
    padding: 8px 12px;
    font-size: 13px;
    color: #4a4f57;
    background: #f7f7f7;
    border: 1px solid #ececec;
    border-radius: 8px;
}
.spicks__label b {
    color: #282828;
}

/* ---------- туры сгруппированы по отелям: отель один раз, под ним варианты ---------- */
.spick {
    grid-template-columns: 160px minmax(0, 1fr);
    align-items: start;
}
/* варианты — справа от фото, сразу под названием отеля; фото занимает обе строки слева */
.spick__photo {
    grid-row: 1 / span 2;
}
.spick__tours {
    grid-column: 2;
    display: grid;
    gap: 6px;
}
.sptour {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto auto;
    gap: 12px;
    align-items: center;
    padding: 10px 12px;
    background: #fff;
    border: 1px solid #e6e6e6;
    border-radius: 10px;
}
.sptour form {
    margin: 0;
}
.sptour__facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px 14px;
    margin: 0;
}
.sptour__facts > div {
    min-width: 0;
}
.sptour__facts dt {
    font-size: 11px;
    letter-spacing: .03em;
    text-transform: uppercase;
    color: #8a8f98;
}
.sptour__facts dd {
    margin: 0;
    font-size: 14px;
    color: #282828;
    overflow-wrap: anywhere;
}
.sptour__price {
    font-size: 18px;
    font-weight: 700;
    white-space: nowrap;
    color: #282828;
}
/* убрать вариант — крестик */
.sptour__del {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    color: #8a8f98;
    background: #fff;
    border: 1px solid #d9d9d9;
    border-radius: 8px;
    cursor: pointer;
    transition: color .15s, border-color .15s;
}
.sptour__del:hover {
    color: #d8412e;
    border-color: #d8412e;
}

@media (max-width: 900px) {
    .spick {
        grid-template-columns: 120px minmax(0, 1fr);
    }
    .spick__photo {
        grid-row: auto;
    }
    .spick__tours {
        grid-column: 1 / -1;
    }
    .sptour {
        grid-template-columns: minmax(0, 1fr) auto auto;
    }
    .sptour__facts {
        grid-column: 1 / -1;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 560px) {
    .spick {
        grid-template-columns: 1fr;
    }
    .sptour__price {
        font-size: 16px;
    }
}

/* название подборки правится на месте (contenteditable) */
.spicks__title {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px 10px;
}
.spicks__title-text {
    min-width: 40px;
    padding: 2px 6px;
    margin-left: -6px;
    border: 1px dashed transparent;
    border-radius: 6px;
    outline: none;
    cursor: text;
    overflow-wrap: anywhere;
}
.spicks__title-text:hover {
    border-color: #c9c9c9;
}
.spicks__title-text:focus {
    background: #fff;
    border: 1px solid #282828;
}
.spicks__title-icon {
    flex: none;
    color: #8a8f98;
}
.spicks__title-note {
    font-size: 13px;
    font-weight: 400;
    color: #1f9d55;
}
.spicks__title-note.is-error {
    color: #d8412e;
}

/* ---------- порядок перетаскиванием: ручка (точки) у отеля и у варианта ---------- */
.spdrag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 32px;
    padding: 0;
    color: #b3b7be;
    background: none;
    border: 0;
    border-radius: 6px;
    cursor: grab;
    touch-action: none;
}
.spdrag:hover {
    color: #282828;
    background: #ececec;
}
.spdrag:active {
    cursor: grabbing;
}
/* ручки нет, когда переставлять нечего: один отель в подборке, один вариант у отеля */
.spick:only-of-type > .spdrag {
    display: none;
}
/* у единственного варианта ручка невидима, но место держит: колонки вариантов стоят ровно во всех карточках */
.sptour:only-child > .spdrag {
    visibility: hidden;
}
.spick {
    position: relative;
}
.spdrag--hotel {
    position: absolute;
    top: 8px;
    right: 8px;
}
/* цена — колонка постоянной ширины: при разной длине цены колонки соседних строк не разъезжаются */
.sptour {
    grid-template-columns: auto minmax(0, 1fr) 112px auto auto;
}
.sptour__price {
    text-align: right;
}
.sptour__facts {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, .8fr) minmax(0, 1.25fr);
}
.spick.is-dragging,
.sptour.is-dragging {
    opacity: .45;
}
@media (max-width: 900px) {
    .sptour {
        grid-template-columns: auto minmax(0, 1fr) auto auto;
    }
    .sptour > .spdrag {
        grid-row: 1 / span 2;
    }
    .sptour .sptour__facts {
        grid-column: 2 / -1;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .sptour__price {
        grid-column: 2;
        text-align: left;
    }
}

/* «Открыть тур» — значок ссылки вместо кнопки */
.sptour__open {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    color: #ef533f;
    background: #fff;
    border: 1px solid #ef533f;
    border-radius: 8px;
    transition: background .15s, color .15s;
}
.sptour__open:hover {
    color: #fff;
    background: #ef533f;
}
.sptour {
    gap: 8px 10px;
}
.sptour__facts {
    /* первая колонка (вылет, номер) шире: названия номеров бывают длинными */
    grid-template-columns: minmax(0, 1.75fr) minmax(0, .58fr) minmax(0, 1.42fr);
}
@media (max-width: 900px) {
    .sptour .sptour__facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* ---------- заметка сотрудника к отелю подборки ---------- */
.spick__notebox {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 14px;
}
.spick__note-btn {
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    color: #8a8f98;
    background: #fff;
    border: 1px solid #d9d9d9;
    border-radius: 8px;
    cursor: pointer;
    transition: color .15s, border-color .15s, background .15s;
}
.spick__note-btn:hover {
    color: #282828;
    border-color: #282828;
}
/* заметка есть — значок жёлтый */
.spick__note-btn.is-on {
    color: #8a6100;
    background: #fff3c4;
    border-color: #e8cf7a;
}
.spick__note {
    flex: 1 1 auto;
    min-width: 0;
    padding: 6px 10px;
    font-size: 14px;
    line-height: 1.4;
    color: #4a3a00;
    white-space: pre-line;
    overflow-wrap: anywhere;
    background: #fff8dc;
    border: 1px solid #f0dfa0;
    border-radius: 8px;
}
.spick__note[hidden] {
    display: none;
}

.spnote {
    /* по центру окна: общие стили сайта сбрасывают отступы, и окно уезжало в левый верхний угол */
    position: fixed;
    inset: 0;
    margin: auto;
    height: fit-content;
    max-height: calc(100vh - 32px);
    width: min(520px, calc(100vw - 32px));
    padding: 0;
    color: #282828;
    background: #fff;
    border: 0;
    border-radius: 14px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .25);
}
.spnote::backdrop {
    background: rgba(0, 0, 0, .45);
}
.spnote__form {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 18px 20px 20px;
}
.spnote__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.spnote__title {
    font-size: 18px;
    font-weight: 700;
}
.spnote__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    color: #6b717c;
    background: #f3f3f3;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
}
.spnote__close:hover {
    color: #282828;
}
.spnote__hotel {
    font-size: 14px;
    color: #6b717c;
}
.spnote__text {
    width: 100%;
    min-height: 130px;
    padding: 10px 12px;
    font: inherit;
    font-size: 15px;
    line-height: 1.4;
    color: #282828;
    resize: vertical;
    background: #fff;
    border: 1px solid #d9d9d9;
    border-radius: 8px;
    box-sizing: border-box;
}
.spnote__text:focus {
    outline: none;
    border-color: #282828;
}
.spnote__error {
    font-size: 13px;
    color: #d8412e;
}
.spnote__error:empty {
    display: none;
}
.spnote__foot {
    display: flex;
    justify-content: space-between;
    gap: 8px;
}
.spnote__foot [hidden] {
    display: none;
}
.spnote__foot .spicks__btn--main {
    margin-left: auto;
}

/* состояние автосохранения заметки */
.spnote__state {
    min-height: 18px;
    font-size: 13px;
    color: #6b717c;
}

/* ---------- краткое описание отеля ----------
   Сначала три строки в блоке ограниченной ширины; клик раскрывает целиком;
   «Изменить описание» — поле вместо текста */
.spick__descbox {
    max-width: 360px;
    margin-top: 8px;
}
.spick__desc-view {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    font-size: 14px;
    line-height: 1.45;
    color: #4a4f57;
    white-space: pre-line;
    overflow-wrap: anywhere;
    cursor: pointer;
}
.spick__desc-view:hover {
    color: #282828;
}
.spick__desc-view.is-open {
    display: block;
}
.spick__desc-view[hidden] {
    display: none;
}
.spick__desc-view.is-empty::before {
    content: attr(data-empty);
    color: #8a8f98;
}
.spick__desc {
    display: block;
    width: 100%;
    min-height: 70px;
    padding: 6px 10px;
    font: inherit;
    font-size: 14px;
    line-height: 1.45;
    color: #282828;
    resize: none;
    overflow: hidden;
    background: #fff;
    border: 1px solid #282828;
    border-radius: 8px;
    box-sizing: border-box;
}
.spick__desc[hidden] {
    display: none;
}
.spick__desc:focus {
    outline: none;
}
.spick__desc-foot {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 2px 12px;
    margin-top: 4px;
}
.spick__desc-edit {
    padding: 0;
    font: inherit;
    font-size: 13px;
    color: #282828;
    background: none;
    border: 0;
    border-bottom: 1px dashed #282828;
    cursor: pointer;
}
.spick__desc-edit:hover {
    color: #ef533f;
    border-bottom-color: #ef533f;
}
.spick__desc-state {
    font-size: 12px;
    color: #8a8f98;
}
.spick__desc-state.is-error {
    color: #d8412e;
}
/* ---------- цена тура правится на месте ---------- */
.sptour__price-value {
    padding: 2px 4px;
    border: 1px dashed transparent;
    border-radius: 6px;
    outline: none;
    cursor: text;
}
.sptour__price-value:hover {
    border-color: #c9c9c9;
}
.sptour__price-value:focus {
    background: #fff;
    border: 1px solid #282828;
}
/* цена изменена сотрудником */
.sptour__price.is-custom .sptour__price-value {
    color: #b45f06;
    text-decoration: underline dotted;
    text-underline-offset: 4px;
}

/* ---------- слева в карточке отеля: фото, под ним флаг и страна ---------- */
.spick__left {
    grid-row: 1 / span 2;
    min-width: 0;
}
.spick__left .spick__photo {
    grid-row: auto;
}
.spick__country {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    font-size: 14px;
    font-weight: 600;
    color: #282828;
}
.spick__country img {
    flex: none;
    width: 22px;
    height: 16px;
    object-fit: cover;
    border: 1px solid #e2e0da;
    border-radius: 3px;
}
@media (max-width: 900px) {
    .spick__left {
        grid-row: auto;
    }
}

/* ---------- действия с подборкой — значки с подсказками ---------- */
.spicks__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    color: #282828;
    background: #fff;
    border: 1px solid #d9d9d9;
    border-radius: 10px;
    cursor: pointer;
    transition: background .15s, color .15s, border-color .15s;
}
.spicks__icon:hover {
    border-color: #282828;
}
.spicks__icon--main {
    color: #fff;
    background: #ef533f;
    border-color: #ef533f;
}
.spicks__icon--main:hover {
    background: #d8412e;
    border-color: #d8412e;
}
.spicks__icon--danger {
    color: #d8412e;
    border-color: #f1b8ae;
}
.spicks__icon--danger:hover {
    color: #fff;
    background: #d8412e;
    border-color: #d8412e;
}

/* ---------- окно «Поделиться» ---------- */
.spshare-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.spshare-tab {
    height: 38px;
    padding: 0 18px;
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    color: #4a4f57;
    background: #f1f1f1;
    border: 0;
    border-radius: 19px;
    cursor: pointer;
    transition: background .15s, color .15s;
}
.spshare-tab:hover {
    color: #282828;
    background: #e6e6e6;
}
.spshare-tab.is-active {
    color: #fff;
    background: #282828;
}
.spshare-text {
    min-height: 200px;
    font-size: 14px;
    color: #282828;
    background: #fafafa;
}
.spnote__state.is-error {
    color: #d8412e;
}
.spshare-copy {
    width: 100%;
    height: 44px;
    gap: 8px;
    background: #f1f1f1;
    border-color: #f1f1f1;
}
.spshare-copy:hover {
    background: #e6e6e6;
    border-color: #e6e6e6;
}

/* ---------- открытая страница подборки для клиента (pages/picks/share.blade.php) ---------- */
.spshare__manager {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px 18px;
}
.spshare__ava {
    flex: none;
    width: 64px;
    height: 64px;
    background: #e9e9e9 center / cover no-repeat;
    border-radius: 50%;
}
.spshare__who {
    flex: 1 1 260px;
    min-width: 0;
}
.spshare__role {
    font-size: 13px;
    color: #8a8f98;
}
.spshare__name {
    font-size: 18px;
    font-weight: 700;
    color: #282828;
}
.spshare__contacts {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 16px;
    margin-top: 4px;
    font-size: 14px;
}
.spshare__contacts a {
    color: #ef533f;
    text-decoration: none;
}
.spshare__contacts a:hover {
    text-decoration: underline;
}
.spshare__note {
    margin-bottom: 14px;
    font-size: 13px;
    line-height: 1.4;
    color: #6b717c;
}
.spshare__desc {
    max-width: 640px;
    margin-top: 8px;
    font-size: 14px;
    line-height: 1.45;
    color: #4a4f57;
    white-space: pre-line;
    overflow-wrap: anywhere;
}
.spicks--public {
    margin-top: 0;
}
/* у клиента в строке тура нет ручки и крестика: поля, цена, кнопка */
.sptour--public {
    grid-template-columns: minmax(0, 1fr) 112px auto;
}
.sptour--public .sptour__facts {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 900px) {
    .sptour--public {
        grid-template-columns: minmax(0, 1fr) auto;
    }
    .sptour--public .sptour__facts {
        grid-column: 1 / -1;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .sptour--public .sptour__price {
        grid-column: 1;
    }
}

/* ---------- строка тура: вылет · ночей · туристы / номер (на две колонки) · питание; туроператор — под ценой ---------- */
.sptour {
    grid-template-columns: auto minmax(0, 1fr) 132px auto auto;
}
.sptour__fact--wide {
    grid-column: 1 / span 2;
}
.sptour__operator {
    margin-top: 2px;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.3;
    color: #6b717c;
    white-space: normal;
    overflow-wrap: anywhere;
}
.sptour--public {
    grid-template-columns: minmax(0, 1fr) 132px auto;
}
.sptour--public .sptour__facts {
    grid-template-columns: minmax(0, 1.75fr) minmax(0, .58fr) minmax(0, 1.42fr);
}
@media (max-width: 900px) {
    .sptour {
        grid-template-columns: auto minmax(0, 1fr) auto auto;
    }
    .sptour--public {
        grid-template-columns: minmax(0, 1fr) auto;
    }
    .sptour .sptour__facts,
    .sptour--public .sptour__facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .sptour__fact--wide {
        grid-column: 1 / -1;
    }
}

/* ---------- строка тура: все поля в одну строку — вылет, ночей, номер, питание, туристы ---------- */
.sptour .sptour__facts,
.sptour--public .sptour__facts {
    /* вылет, ночей и туристы — по ширине своего текста и без переносов; номер и питание делят остальное */
    grid-template-columns: max-content max-content minmax(0, 1.25fr) minmax(0, 1fr) max-content;
    gap: 6px 14px;
}
.sptour__facts > div:nth-child(1) dd,
.sptour__facts > div:nth-child(2) dd,
.sptour__facts > div:nth-child(5) dd {
    white-space: nowrap;
}
.sptour__fact--wide {
    grid-column: auto;
}
@media (max-width: 1100px) {
    .sptour .sptour__facts,
    .sptour--public .sptour__facts {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
@media (max-width: 900px) {
    .sptour .sptour__facts,
    .sptour--public .sptour__facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .sptour__fact--wide {
        grid-column: 1 / -1;
    }
}

/* на узких экранах поля снова идут в несколько строк — переносы разрешены */
@media (max-width: 1100px) {
    .sptour__facts > div dd {
        white-space: normal !important;
    }
}

/* название номера на открытой странице — кнопка: окно «о номере» */
.sptour--public .spick__room {
    font-size: 14px;
}

/* поля в одну строку: цене — колонка поуже, номеру — больше места, чем питанию */
.sptour {
    grid-template-columns: auto minmax(0, 1fr) 118px auto auto;
    gap: 8px;
}
.sptour--public {
    grid-template-columns: minmax(0, 1fr) 118px auto;
}
.sptour .sptour__facts,
.sptour--public .sptour__facts {
    grid-template-columns: max-content max-content minmax(0, 1.35fr) minmax(0, 1fr) max-content;
    gap: 6px 12px;
}
@media (max-width: 1100px) {
    .sptour .sptour__facts,
    .sptour--public .sptour__facts {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
@media (max-width: 900px) {
    .sptour {
        grid-template-columns: auto minmax(0, 1fr) auto auto;
    }
    .sptour--public {
        grid-template-columns: minmax(0, 1fr) auto;
    }
    .sptour .sptour__facts,
    .sptour--public .sptour__facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Поля тура в одну строку (широкий экран): каждое поле — по ширине своего текста, текст внутри
   не ломается; что не поместилось, переносится на вторую строку целым полем, а не по словам. */
@media (min-width: 1101px) {
    .sptour .sptour__facts,
    .sptour--public .sptour__facts {
        display: flex;
        flex-wrap: wrap;
        gap: 6px 16px;
    }
    .sptour .sptour__facts > div,
    .sptour--public .sptour__facts > div {
        flex: 0 1 auto;
        min-width: 0;
        max-width: 100%;
    }
    .sptour .sptour__facts > div dd,
    .sptour--public .sptour__facts > div dd {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

/* ---------- поля тура: два столбца ----------
   слева — вылет, под ним номер; справа — ночей и туристы рядом, под ними питание.
   Это правило последнее и действует на любой ширине: прежние раскладки полей оно отменяет. */
.sptour .sptour__facts,
.sptour--public .sptour__facts {
    display: grid !important;
    grid-template-columns: minmax(0, 1.25fr) max-content minmax(0, 1fr) !important;
    grid-template-areas:
        "date nights people"
        "room meal   meal";
    gap: 10px 16px;
}
.sptour .sptour__facts > div,
.sptour--public .sptour__facts > div {
    min-width: 0;
    max-width: none;
}
.sptour .sptour__facts > div dd,
.sptour--public .sptour__facts > div dd {
    white-space: normal !important;
    overflow: visible;
    text-overflow: clip;
}
.sptour__fact--date { grid-area: date; }
.sptour__fact--nights { grid-area: nights; }
.sptour__fact--people { grid-area: people; }
.sptour__fact--room { grid-area: room; }
.sptour__fact--meal { grid-area: meal; }
.sptour__fact--nights dd,
.sptour__fact--people dd {
    white-space: nowrap !important;
}

/* пометка «регулярный рейс» у тура — только в кабинете сотрудника */
.sptour__regular {
    color: #b45f06;
}
