/* =========================================================
   OHOMMER — common cart styles (all service pages)
   ========================================================= */

/* ---------- Add to Cart states ---------- */
.oh-cart-loading {
    opacity: .8;
    cursor: wait !important;
}

.oh-cart-added,
a.oh-cart-added,
button.oh-cart-added {
    background: #198754 !important;
    background-color: #198754 !important;
    border-color: #198754 !important;
    color: #fff !important;
}

.oh-cart-added:hover {
    background: #157347 !important;
}

/* Header cart number */
.header-cart-link .cart-count[data-count="0"] {
    opacity: .85;
}

/* ---------- Description: 3 lines + Read more ---------- */
.oh-desc-clamp {
    display: -webkit-box !important;
    -webkit-box-orient: vertical !important;
    -webkit-line-clamp: 3 !important;
    line-clamp: 3;
    overflow: hidden !important;
    text-overflow: ellipsis;
    margin-bottom: 4px !important;
    max-height: none !important;
}

.oh-desc-clamp.is-expanded {
    display: block !important;
    -webkit-line-clamp: unset !important;
    line-clamp: none;
    overflow: visible !important;
}

.oh-read-more {
    display: inline-block;
    align-self: flex-start;
    margin: 0 0 10px;
    padding: 0;
    border: 0;
    background: none;
    color: #f36c21;
    font: inherit;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.5;
    text-align: left;
    cursor: pointer;
}

.oh-read-more:hover,
.oh-read-more:focus-visible {
    text-decoration: underline;
}

/* Keeps the same space so all cards stay at the same level */
.oh-read-more.is-hidden {
    visibility: hidden;
    pointer-events: none;
}

/* ---------- "Added to cart" popup ---------- */
body.oh-cart-popup-open {
    overflow: hidden;
}

.oh-cart-popup {
    position: fixed;
    inset: 0;
    z-index: 1000000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
}

.oh-cart-popup[hidden] {
    display: none !important;
}

.oh-cart-popup__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(7, 30, 59, .55);
    opacity: 0;
    transition: opacity .2s ease;
}

.oh-cart-popup__box {
    position: relative;
    width: min(420px, 100%);
    padding: 30px 26px 24px;
    border-radius: 16px;
    background: #fff;
    color: #172033;
    text-align: center;
    box-shadow: 0 25px 60px rgba(7, 30, 59, .3);
    transform: translateY(16px) scale(.97);
    opacity: 0;
    transition: transform .2s ease, opacity .2s ease;
    font-family: Arial, Helvetica, sans-serif;
}

.oh-cart-popup.is-open .oh-cart-popup__backdrop {
    opacity: 1;
}

.oh-cart-popup.is-open .oh-cart-popup__box {
    transform: none;
    opacity: 1;
}

.oh-cart-popup__close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: #f3f5f8;
    color: #172033;
    font-size: 22px;
    line-height: 34px;
    cursor: pointer;
}

.oh-cart-popup__icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #e8f6ee;
    color: #198754;
    font-size: 28px;
    font-weight: 800;
}

.oh-cart-popup.is-error .oh-cart-popup__icon {
    background: #fdecec;
    color: #c62828;
}

.oh-cart-popup__title {
    margin: 0 0 6px;
    color: #172033;
    font-size: 21px;
    font-weight: 800;
}

.oh-cart-popup__name {
    margin: 0 0 4px;
    color: #30394a;
    font-size: 14px;
    font-weight: 700;
}

.oh-cart-popup__count {
    margin: 0 0 18px;
    color: #687181;
    font-size: 13px;
}

.oh-cart-popup__actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.oh-cart-popup__view,
.oh-cart-popup__continue {
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 14px;
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none !important;
    cursor: pointer;
}

.oh-cart-popup__view {
    border: 1px solid #f36c21;
    background: #f36c21;
    color: #fff !important;
}

.oh-cart-popup__view:hover {
    background: #d9550d;
}

.oh-cart-popup__continue {
    border: 1px solid #d9dee6;
    background: #fff;
    color: #172033;
}

.oh-cart-popup__continue:hover {
    background: #f6f8fb;
}

.oh-cart-popup.is-error .oh-cart-popup__view {
    display: none;
}

.oh-cart-popup.is-error .oh-cart-popup__actions {
    grid-template-columns: 1fr;
}

@media (max-width: 420px) {
    .oh-cart-popup__actions {
        grid-template-columns: 1fr;
    }
}
