﻿/* wwwroot/styles/drug-card.css */

/* ============================================
   КАРТОЧКА ПРЕПАРАТА
   ============================================ */

.drug-card {
    background: #F4F6F7;
    border-radius: 24px;
    padding: 16px;
    width: 340px;
    flex-shrink: 0;
    flex-grow: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.drug-card__frame {
    background: #FCFCFC;
    border-radius: 16px;
    border: 4px solid #EC691F;
    padding: 8px;
    position: relative;
    display: flex;
    flex-direction: column;
}

.drug-card__logo-on-frame {
    position: absolute;
    top: -22px;
    left: 50%;
    transform: translateX(-50%);
    background: #FCFCFC;
    border-radius: 40px;
    padding: 4px 0px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

    .drug-card__logo-on-frame img {
        height: 28px;
        width: auto;
        max-width: 120px;
        object-fit: contain;
    }

.drug-card__image {
    width: 100%;
    height: 135px;
    object-fit: contain;
    border-radius: 4px;
}

.drug-card__tags {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    position: relative;
    z-index: 3;
}

.drug-card__tag {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 12px;
    border-radius: 16px;
    background: #F4F6F7;
}

    .drug-card__tag img {
        width: 20px;
        height: 20px;
    }

    .drug-card__tag span {
        font-family: 'OpenRunde-Regular', sans-serif;
        font-size: 12px;
        color: #77797D;
    }

.drug-card__badges {
    display: flex;
    gap: 4px;
}

.drug-card__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 12px;
    border-radius: 16px;
}

    .drug-card__badge img {
        width: 20px;
        height: 20px;
    }

    .drug-card__badge span {
        font-family: 'OpenRunde-Regular', sans-serif;
        font-size: 12px;
    }

.drug-card__badge--yellow {
    background: #EBB738;
}

    .drug-card__badge--yellow span {
        color: #1C1F26;
    }

.drug-card__badge--red {
    background: #B50042;
}

    .drug-card__badge--red span {
        color: #F4F4F4;
    }

.drug-card__product-info {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin: 4px 0;
}

.drug-card__left {
    flex: 1;
}

.drug-card__name {
    font-family: 'OpenRunde-Medium', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #1C1F26;
    margin-bottom: 4px;
}

.drug-card__dosage {
    font-family: 'OpenRunde-Regular', sans-serif;
    font-size: 14px;
    color: #77797D;
}

.drug-card__right {
    text-align: right;
}

.drug-card__price-current {
    font-family: 'OpenRunde-Bold', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: #1C1F26;
}

.drug-card__price-old-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: flex-end;
    margin-top: 4px;
}

.drug-card__price-old {
    font-family: 'OpenRunde-Regular', sans-serif;
    font-size: 14px;
    text-decoration: line-through;
    color: #77797D;
}

.drug-card__price-discount {
    background: #EBB738;
    border-radius: 16px;
    padding: 2px 8px;
    font-family: 'OpenRunde-Regular', sans-serif;
    font-size: 12px;
    color: #1C1F26;
}

.drug-card__availability {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #E3E7EA;
    border-radius: 16px;
    padding: 8px 12px;
    width: fit-content;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease;
}

    .drug-card__availability:hover {
        background: #D4DADE;
    }

    .drug-card__availability img {
        width: 20px;
        height: 20px;
    }

    .drug-card__availability span {
        font-family: 'OpenRunde-Regular', sans-serif;
        font-size: 14px;
        color: #77797D;
    }

.drug-card__actions {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-top: 4px;
}

.drug-card__btn-book {
    flex: 1;
    background: #26445C;
    border-radius: 16px;
    padding: 8px 16px;
    height: 44px;
    border: none;
    font-family: 'OpenRunde-Medium', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #F4F4F4;
    cursor: pointer;
    transition: background 0.2s ease;
}

    .drug-card__btn-book:hover {
        background: #51697D;
    }

.drug-card__btn-icon {
    width: 44px;
    height: 44px;
    background: #26445C;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease;
}

.drug-card__btn-icon-nonbackground {
    width: 44px;
    height: 44px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease;
}

.drug-card__btn-icon:hover {
    background: #51697D;
}

.drug-card__btn-icon-nonbackground:hover {
    background: #A8B4BE;
}

.drug-card__btn-icon img {
    width: 24px;
    height: 24px;
}

/* Адаптив */
@media (max-width: 1200px) {
    .drug-card {
        width: 300px;
    }
}

@media (max-width: 768px) {
    .drug-card {
        width: 280px;
    }
}

@media (max-width: 480px) {
    .drug-card {
        width: 260px;
    }
}
