/* Селекторы типа транспорта (тент/борт/манипулятор/вездеход) */
.piramida-card__vehicle-selector {
    position: relative;
    margin-bottom: 0.2rem;
}

.piramida-vehicle-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.4rem;
    padding: 0.3rem 0.65rem;
    background: var(--white);
    border: 2px solid var(--gray-300);
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    height: 30px;
}

.piramida-card__vehicle-selector.active .piramida-vehicle-display {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.piramida-vehicle-display__label {
    color: var(--gray-600);
    font-weight: 500;
    font-size: 0.78rem;
    white-space: nowrap;
}

.piramida-vehicle-display__value {
    color: var(--primary-blue);
    font-weight: 700;
    flex-grow: 1;
    text-align: center;
    white-space: nowrap;
    font-size: 0.85rem;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0 0.2rem;
}

.piramida-vehicle-display i {
    font-size: 0.68rem;
    color: var(--gray-500);
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.piramida-card__vehicle-selector.active .piramida-vehicle-display i {
    transform: rotate(180deg);
    color: var(--primary-blue);
}

.piramida-vehicle-dropdown {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    right: 0;
    background: var(--white);
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--gray-200);
    padding: 0.3rem;
    z-index: 1002;
    display: none;
    max-height: 100px;
    overflow-y: auto;
}

.piramida-card__vehicle-selector.active .piramida-vehicle-dropdown {
    display: block;
    animation: fadeIn 0.2s ease;
}

.piramida-vehicle-option {
    padding: 0.3rem;
    text-align: center;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 0.82rem;
    min-height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    margin-bottom: 0.2rem;
}

.piramida-vehicle-option:last-child {
    margin-bottom: 0;
}

.piramida-vehicle-option:hover {
    background: var(--gray-100);
    border-color: var(--gray-300);
}

.piramida-vehicle-option.selected {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: var(--white);
}

.piramida-vehicle-option__text {
    display: inline-block;
    text-align: center;
    width: 100%;
    font-weight: 700;
    font-size: 0.82rem;
    line-height: 1.1;
}

/* Селекторы тоннажа */
.piramida-card__tonnage-selector {
    position: relative;
    margin-bottom: 0.2rem;
}

.piramida-tonnage-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.4rem;
    padding: 0.3rem 0.65rem;
    background: var(--white);
    border: 2px solid var(--gray-300);
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    height: 30px;
}

.piramida-card__tonnage-selector.active .piramida-tonnage-display {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.piramida-tonnage-display__label {
    color: var(--gray-600);
    font-weight: 500;
    font-size: 0.78rem;
    white-space: nowrap;
}

.piramida-tonnage-display__value {
    color: var(--primary-blue);
    font-weight: 700;
    flex-grow: 1;
    text-align: center;
    white-space: nowrap;
    font-size: 0.85rem;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0 0.2rem;
}

.piramida-tonnage-display i {
    font-size: 0.68rem;
    color: var(--gray-500);
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.piramida-card__tonnage-selector.active .piramida-tonnage-display i {
    transform: rotate(180deg);
    color: var(--primary-blue);
}

.piramida-tonnage-dropdown {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    right: 0;
    background: var(--white);
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--gray-200);
    padding: 0.3rem;
    z-index: 1001;
    display: none;
    max-height: 130px;
    overflow-y: auto;
}

.piramida-card__tonnage-selector.active .piramida-tonnage-dropdown {
    display: block;
    animation: fadeIn 0.2s ease;
}

.piramida-tonnage-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.2rem;
}

.piramida-tonnage-option {
    padding: 0.2rem 0.1rem;
    text-align: center;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 0.82rem;
    min-height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    gap: 1px;
}

.piramida-tonnage-option:hover {
    background: var(--gray-100);
    border-color: var(--gray-300);
}

.piramida-tonnage-option.selected {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: var(--white);
}

.piramida-tonnage-option__text {
    display: inline-block;
    text-align: center;
    width: 100%;
    font-weight: 700;
    font-size: 0.82rem;
    line-height: 1;
}

.piramida-tonnage-option__unit {
    font-size: 0.72em;
    font-weight: 600;
}

/* Селекторы количества пирамид */
.piramida-card__pyramids-selector {
    position: relative;
    margin-bottom: 0.45rem;
}

.piramida-pyramids-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.4rem;
    padding: 0.3rem 0.65rem;
    background: var(--white);
    border: 2px solid var(--gray-300);
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    height: 30px;
}

.piramida-card__pyramids-selector.active .piramida-pyramids-display {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.piramida-pyramids-label-section {
    display: flex;
    align-items: center;
    gap: 0.2rem;
    flex-grow: 1;
}

.piramida-pyramids-label {
    color: var(--gray-600);
    font-weight: 500;
    font-size: 0.78rem;
    white-space: nowrap;
}

.piramida-pyramids-value {
    color: var(--primary-blue);
    font-weight: 700;
    font-size: 0.85rem;
    min-width: 16px;
    text-align: center;
}

.piramida-max-label {
    color: var(--gray-500);
    font-weight: 500;
    font-size: 0.73rem;
    white-space: nowrap;
    margin-left: 0.2rem;
}

.piramida-pyramids-display i {
    font-size: 0.68rem;
    color: var(--gray-500);
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.piramida-card__pyramids-selector.active .piramida-pyramids-display i {
    transform: rotate(180deg);
    color: var(--primary-blue);
}

.piramida-pyramids-dropdown {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    right: 0;
    background: var(--white);
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--gray-200);
    padding: 0.3rem;
    z-index: 1000;
    display: none;
    max-height: 170px;
    overflow-y: auto;
}

.piramida-card__pyramids-selector.active .piramida-pyramids-dropdown {
    display: block;
    animation: fadeIn 0.2s ease;
}

/* ГОРИЗОНТАЛЬНОЕ РАСПОЛОЖЕНИЕ ПИРАМИД */
.piramida-pyramids-grid {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.piramida-pyramids-row {
    display: flex;
    gap: 0.25rem;
    justify-content: flex-start;
    width: 100%;
}

.piramida-pyramids-option {
    flex: 1;
    min-width: 0;
    max-width: calc(25% - 0.25rem);
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-dark);
    user-select: none;
    padding: 0.15rem 0.2rem;
    text-align: center;
}

.piramida-pyramids-option:hover {
    background: var(--gray-100);
    border-color: var(--gray-300);
}

.piramida-pyramids-option.selected {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: var(--white);
}

.piramida-pyramids-option__text {
    font-weight: 700;
    font-size: 0.8rem;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Информация о ценах */
.piramida-card__price-info {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05) 0%, rgba(147, 197, 253, 0.05) 100%);
    border-radius: 8px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    padding: 0.45rem;
    margin-bottom: 0.45rem;
}

.piramida-card__price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.15rem 0;
}

.piramida-card__price-row:first-child {
    padding-top: 0;
}

.piramida-card__price-row:last-child {
    padding-bottom: 0;
}

.piramida-card__price-label {
    font-size: 0.78rem;
    color: var(--gray-600);
    font-weight: 500;
    line-height: 1.1;
}

.piramida-card__price-value {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.1;
    text-align: right;
}

/* Секция итоговой цены */
.piramida-card__total-section {
    padding: 0.45rem;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.05) 0%, rgba(251, 191, 36, 0.05) 100%);
    border-radius: 8px;
    border: 1px solid rgba(245, 158, 11, 0.2);
    text-align: center;
    flex-shrink: 0;
    min-height: 48px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.piramida-card__total-label {
    font-size: 0.82rem;
    color: var(--gray-600);
    margin-bottom: 0.15rem;
    font-weight: 500;
    line-height: 1;
}

.piramida-card__total-value {
    font-size: 1.15rem;
    font-weight: 800;
    color: #d97706;
    line-height: 1.1;
    letter-spacing: -0.5px;
}

/* Стили для выбранной карточки пирамиды */
.transport-card.selected .piramida-card__vehicle-selector.active .piramida-vehicle-display,
.transport-card.selected .piramida-card__tonnage-selector.active .piramida-tonnage-display,
.transport-card.selected .piramida-card__pyramids-selector.active .piramida-pyramids-display {
    border-color: var(--primary-blue);
    background: var(--white);
}

/* Адаптация dropdown при вертикальном скролле */
.piramida-vehicle-dropdown,
.piramida-tonnage-dropdown,
.piramida-pyramids-dropdown {
    max-height: 30vh;
    overflow-y: auto;
}

.piramida-vehicle-dropdown::-webkit-scrollbar,
.piramida-tonnage-dropdown::-webkit-scrollbar,
.piramida-pyramids-dropdown::-webkit-scrollbar {
    width: 5px;
}

.piramida-vehicle-dropdown::-webkit-scrollbar-track,
.piramida-tonnage-dropdown::-webkit-scrollbar-track,
.piramida-pyramids-dropdown::-webkit-scrollbar-track {
    background: var(--gray-100);
    border-radius: 2.5px;
}

.piramida-vehicle-dropdown::-webkit-scrollbar-thumb,
.piramida-tonnage-dropdown::-webkit-scrollbar-thumb,
.piramida-pyramids-dropdown::-webkit-scrollbar-thumb {
    background: var(--gray-300);
    border-radius: 2.5px;
}

.piramida-vehicle-dropdown::-webkit-scrollbar-thumb:hover,
.piramida-tonnage-dropdown::-webkit-scrollbar-thumb:hover,
.piramida-pyramids-dropdown::-webkit-scrollbar-thumb:hover {
    background: var(--gray-400);
}

