/* =====================================================
   RANSARA QUANTITY
===================================================== */

.rs-quantity-section {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-top: 18px;
    padding-top: 14px;

    border-top: 1px solid
        rgba(43, 33, 26, 0.12);
}


.rs-quantity-label {
    color: #776b5f;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 8px;

    letter-spacing: 0.2em;
}


.rs-quantity-control {
    display: flex;

    align-items: center;

    border:
        1px solid rgba(43, 33, 26, 0.22);

    background: transparent;
}


.rs-quantity-btn {
    width: 36px;
    height: 34px;

    border: 0;

    background: transparent;

    color: #2b211a;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 17px;

    cursor: pointer;

    transition:
        background 0.25s ease,
        color 0.25s ease;
}


.rs-quantity-btn:hover {
    background: #2b211a;

    color: white;
}


.rs-quantity-value {
    min-width: 34px;

    text-align: center;

    color: #2b211a;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 12px;
}


/* =====================================================
   ORDER MODAL
===================================================== */

.rs-order-modal {
    position: fixed;

    inset: 0;

    display: flex;

    align-items: center;

    justify-content: center;

    padding: 15px;

    visibility: hidden;

    opacity: 0;

    pointer-events: none;

    z-index: 110000;

    transition:
        opacity 0.3s ease,
        visibility 0.3s ease;
}


/* Support both classes */

.rs-order-modal.open,
.rs-order-modal.active {
    visibility: visible;

    opacity: 1;

    pointer-events: auto;
}


/* =====================================================
   BACKDROP
===================================================== */

.rs-order-backdrop {
    position: absolute;

    inset: 0;

    background:
        rgba(18, 13, 9, 0.78);

    backdrop-filter: blur(12px);

    -webkit-backdrop-filter: blur(12px);
}


/* =====================================================
   CONTAINER
===================================================== */

.rs-order-container {
    position: relative;

    display: grid;

    grid-template-columns:
        0.78fr 1.22fr;

    width: min(880px, 94vw);

    height: min(650px, calc(100vh - 30px));

    max-height: calc(100vh - 30px);

    overflow: hidden;

    background: #f4eee4;

    box-shadow:
        0 30px 90px
        rgba(0, 0, 0, 0.45);

    transform:
        translateY(25px)
        scale(0.97);

    transition:
        transform 0.4s
        cubic-bezier(.2,.8,.2,1);
}


.rs-order-modal.open
.rs-order-container,

.rs-order-modal.active
.rs-order-container {

    transform:
        translateY(0)
        scale(1);
}


/* =====================================================
   CLOSE
===================================================== */

.rs-order-close {
    position: absolute;

    top: 14px;
    right: 14px;

    width: 38px;
    height: 38px;

    border:
        1px solid rgba(255,255,255,0.55);

    border-radius: 50%;

    background:
        rgba(25,20,16,0.45);

    backdrop-filter: blur(8px);

    cursor: pointer;

    z-index: 20;

    transition:
        background 0.25s ease,
        transform 0.25s ease;
}


.rs-order-close:hover {
    background: rgba(25,20,16,0.75);

    transform: rotate(90deg);
}


.rs-order-close span {
    position: absolute;

    top: 50%;
    left: 50%;

    width: 16px;
    height: 1px;

    background: white;
}


.rs-order-close span:first-child {
    transform:
        translate(-50%, -50%)
        rotate(45deg);
}


.rs-order-close span:last-child {
    transform:
        translate(-50%, -50%)
        rotate(-45deg);
}


/* =====================================================
   PRODUCT PREVIEW
===================================================== */

.rs-order-preview {
    position: relative;

    min-height: 0;

    height: 100%;

    background: #211a15;

    color: white;

    overflow: hidden;
}


.rs-order-image {
    position: absolute;

    inset: 0;

    overflow: hidden;
}


.rs-order-image img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;

    transition:
        transform 1s ease;
}


.rs-order-image:hover img {
    transform: scale(1.03);
}


.rs-order-image-overlay {
    position: absolute;

    inset: 0;

    background:
        linear-gradient(
            180deg,
            rgba(20,15,10,0.08),
            rgba(20,15,10,0.82)
        );
}


.rs-order-image > span {
    position: absolute;

    left: 24px;
    bottom: 24px;

    color: white;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 8px;

    letter-spacing: 0.3em;
}


/* =====================================================
   PREVIEW INFO
===================================================== */

.rs-order-preview-info {
    position: absolute;

    left: 24px;
    right: 24px;
    bottom: 48px;

    z-index: 3;
}


.rs-order-preview-info small {
    color: #d5b77b;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 7px;

    letter-spacing: 0.22em;
}


.rs-order-preview-info h3 {
    max-width: 280px;

    margin:
        9px 0;

    font-family:
        "Cormorant Garamond",
        serif;

    font-size: 40px;

    font-weight: 400;

    line-height: 0.9;

    letter-spacing: -0.02em;
}


.rs-order-preview-price {
    display: flex;

    align-items: baseline;

    gap: 8px;
}


.rs-order-preview-price del {
    color:
        rgba(255,255,255,0.48);

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 10px;
}


.rs-order-preview-price strong {
    color: white;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 15px;
}


/* =====================================================
   FORM AREA
===================================================== */

.rs-order-form-area {
    min-width: 0;

    height: 100%;

    overflow-y: auto;

    overflow-x: hidden;

    padding:
        30px
        34px
        25px;

    box-sizing: border-box;

    scrollbar-width: thin;

    scrollbar-color:
        rgba(170,133,75,0.45)
        transparent;
}


/* Chrome scrollbar */

.rs-order-form-area::-webkit-scrollbar {
    width: 4px;
}


.rs-order-form-area::-webkit-scrollbar-track {
    background: transparent;
}


.rs-order-form-area::-webkit-scrollbar-thumb {
    background: rgba(170,133,75,0.45);

    border-radius: 10px;
}


/* =====================================================
   HEADING
===================================================== */

.rs-order-heading > span {
    color: #aa854b;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 8px;

    letter-spacing: 0.23em;
}


.rs-order-heading h2 {
    margin:
        8px
        0
        8px;

    color: #2b211a;

    font-family:
        "Cormorant Garamond",
        serif;

    font-size: 46px;

    font-weight: 400;

    line-height: 0.85;

    letter-spacing: -0.04em;
}


.rs-order-heading h2 em {
    color: #aa854b;

    font-weight: 400;
}


.rs-order-heading p {
    max-width: 380px;

    margin:
        0
        0
        15px;

    color: #776b5f;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 11px;

    line-height: 1.5;
}


/* =====================================================
   FORM FIELD
===================================================== */

.rs-form-field {
    margin-top: 12px;
}


.rs-form-field label {
    display: block;

    margin-bottom: 5px;

    color:
        rgba(43,33,26,0.55);

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 7px;

    letter-spacing: 0.2em;
}


.rs-form-field input,
.rs-form-field textarea {
    width: 100%;

    box-sizing: border-box;

    padding:
        9px 0;

    border: 0;

    border-bottom:
        1px solid
        rgba(43,33,26,0.22);

    outline: none;

    resize: vertical;

    background: transparent;

    color: #2b211a;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 12px;

    transition:
        border-color 0.3s ease;
}


.rs-form-field input {
    height: 34px;
}


.rs-form-field textarea {
    min-height: 52px;

    max-height: 80px;
}


.rs-form-field input::placeholder,
.rs-form-field textarea::placeholder {
    color:
        rgba(43,33,26,0.32);
}


.rs-form-field input:focus,
.rs-form-field textarea:focus {
    border-color: #aa854b;
}


/* =====================================================
   ORDER QUANTITY
===================================================== */

.rs-order-quantity {
    display: inline-flex;

    align-items: center;

    border:
        1px solid rgba(43,33,26,0.22);

    margin-top: 4px;
}


.rs-order-quantity button {
    width: 34px;
    height: 32px;

    border: 0;

    background: transparent;

    color: #2b211a;

    font-size: 17px;

    cursor: pointer;

    transition:
        background 0.25s ease,
        color 0.25s ease;
}


.rs-order-quantity button:hover {
    background: #2b211a;

    color: white;
}


.rs-order-quantity span {
    min-width: 38px;

    text-align: center;

    color: #2b211a;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 12px;
}


/* =====================================================
   SUMMARY
===================================================== */

.rs-order-summary {
    display: grid;

    grid-template-columns:
        1fr
        0.5fr
        auto;

    align-items: center;

    gap: 12px;

    margin-top: 14px;

    padding:
        11px 0;

    border-top:
        1px solid
        rgba(43,33,26,0.12);

    border-bottom:
        1px solid
        rgba(43,33,26,0.12);
}


.rs-order-summary div {
    display: flex;

    flex-direction: column;

    gap: 3px;
}


.rs-order-summary span {
    color:
        rgba(43,33,26,0.4);

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 6px;

    letter-spacing: 0.18em;
}


.rs-order-summary strong {
    color: #2b211a;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 10px;

    font-weight: 500;
}


.rs-order-summary div:last-child {
    text-align: right;
}


.rs-order-summary div:last-child strong {
    color: #aa854b;

    font-size: 15px;
}


/* =====================================================
   SUBMIT
===================================================== */

.rs-place-order {
    display: flex;

    align-items: center;

    justify-content: space-between;

    width: 100%;

    margin-top: 14px;

    padding:
        13px 16px;

    border:
        1px solid #2b211a;

    background: #2b211a;

    color: white;

    cursor: pointer;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 8px;

    letter-spacing: 0.16em;

    transition:
        background 0.3s ease,
        border-color 0.3s ease,
        transform 0.2s ease;
}


.rs-place-order i {
    font-size: 17px;

    font-style: normal;
}


.rs-place-order:hover {
    background: #aa854b;

    border-color: #aa854b;

    transform: translateY(-1px);
}


.rs-place-order:disabled {
    opacity: 0.6;

    cursor: wait;

    transform: none;
}


/* =====================================================
   NOTE
===================================================== */

.rs-order-note {
    margin:
        8px 0 0;

    color:
        rgba(43,33,26,0.4);

    text-align: center;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 7px;
}


/* =====================================================
   PRODUCT TOTAL
===================================================== */

.rs-modal-total {
    display: flex;

    align-items: center;

    justify-content: space-between;

    margin-top: 12px;

    padding:
        11px 0;

    border-top:
        1px solid
        rgba(43,33,26,0.10);

    border-bottom:
        1px solid
        rgba(43,33,26,0.10);
}


.rs-modal-total span {
    color: #776b5f;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 8px;

    letter-spacing: 0.2em;
}


.rs-modal-total strong {
    color: #aa854b;

    font-family:
        "DM Sans",
        sans-serif;

    font-size: 17px;

    font-weight: 600;
}


/* =====================================================
   TABLET
===================================================== */

@media (max-width: 850px) {

    .rs-order-container {

        width: min(
            760px,
            94vw
        );

        height:
            min(
                620px,
                calc(100vh - 24px)
            );
    }


    .rs-order-form-area {

        padding:
            25px
            28px
            20px;
    }


    .rs-order-heading h2 {

        font-size: 42px;
    }


    .rs-order-preview-info h3 {

        font-size: 36px;
    }

}


/* =====================================================
   MOBILE
===================================================== */

@media (max-width: 750px) {

    .rs-order-modal {

        padding: 8px;
    }


    .rs-order-container {

        display: flex;

        flex-direction: column;

        width: 100%;

        max-width: 440px;

        height:
            calc(100vh - 16px);

        max-height:
            calc(100vh - 16px);

        border-radius: 2px;

        overflow: hidden;
    }


    /* ---------------------------------------------
       MOBILE PRODUCT IMAGE
    --------------------------------------------- */

    .rs-order-preview {

        flex-shrink: 0;

        width: 100%;

        height: 125px;

        min-height: 125px;
    }


    .rs-order-image img {

        object-position:
            center center;
    }


    .rs-order-preview-info {

        left: 18px;

        right: 50px;

        bottom: 17px;
    }


    .rs-order-preview-info small {

        font-size: 6px;
    }


    .rs-order-preview-info h3 {

        max-width: 240px;

        margin: 5px 0;

        font-size: 25px;

        line-height: 0.9;
    }


    .rs-order-preview-price {

        gap: 6px;
    }


    .rs-order-preview-price del {

        font-size: 8px;
    }


    .rs-order-preview-price strong {

        font-size: 12px;
    }


    .rs-order-image > span {

        display: none;
    }


    /* ---------------------------------------------
       CLOSE BUTTON
    --------------------------------------------- */

    .rs-order-close {

        top: 9px;

        right: 9px;

        width: 32px;

        height: 32px;
    }


    /* ---------------------------------------------
       FORM AREA
    --------------------------------------------- */

    .rs-order-form-area {

        flex: 1;

        min-height: 0;

        height: auto;

        overflow-y: auto;

        padding:
            18px
            18px
            18px;
    }


    /* ---------------------------------------------
       HEADING
    --------------------------------------------- */

    .rs-order-heading > span {

        font-size: 7px;
    }


    .rs-order-heading h2 {

        margin:
            5px
            0
            5px;

        font-size: 32px;
    }


    .rs-order-heading p {

        margin-bottom: 9px;

        font-size: 9px;

        line-height: 1.4;
    }


    /* ---------------------------------------------
       FORM
    --------------------------------------------- */

    .rs-form-field {

        margin-top: 8px;
    }


    .rs-form-field label {

        margin-bottom: 3px;

        font-size: 6px;
    }


    .rs-form-field input {

        height: 32px;

        padding:
            7px 0;

        font-size: 11px;
    }


    .rs-form-field textarea {

        min-height: 45px;

        max-height: 65px;

        padding:
            7px 0;

        font-size: 11px;
    }


    /* ---------------------------------------------
       QUANTITY
    --------------------------------------------- */

    .rs-order-quantity {

        margin-top: 2px;
    }


    .rs-order-quantity button {

        width: 31px;

        height: 30px;

        font-size: 16px;
    }


    .rs-order-quantity span {

        min-width: 34px;

        font-size: 11px;
    }


    /* ---------------------------------------------
       SUMMARY
    --------------------------------------------- */

    .rs-order-summary {

        grid-template-columns:
            1fr
            0.45fr
            auto;

        gap: 8px;

        margin-top: 9px;

        padding:
            8px 0;
    }


    .rs-order-summary span {

        font-size: 5px;
    }


    .rs-order-summary strong {

        font-size: 9px;
    }


    .rs-order-summary div:last-child strong {

        font-size: 14px;
    }


    /* ---------------------------------------------
       TOTAL
    --------------------------------------------- */

    .rs-modal-total {

        margin-top: 8px;

        padding:
            8px 0;
    }


    .rs-modal-total span {

        font-size: 7px;
    }


    .rs-modal-total strong {

        font-size: 15px;
    }


    /* ---------------------------------------------
       SUBMIT BUTTON
    --------------------------------------------- */

    .rs-place-order {

        min-height: 43px;

        margin-top: 9px;

        padding:
            11px 14px;

        font-size: 7px;
    }


    .rs-order-note {

        margin-top: 5px;

        font-size: 6px;
    }

}


/* =====================================================
   SMALL MOBILE
===================================================== */

@media (max-width: 400px) {

    .rs-order-modal {

        padding: 5px;
    }


    .rs-order-container {

        max-width: 100%;

        height:
            calc(100vh - 10px);

        max-height:
            calc(100vh - 10px);
    }


    .rs-order-preview {

        height: 100px;

        min-height: 100px;
    }


    .rs-order-preview-info {

        left: 14px;

        bottom: 12px;
    }


    .rs-order-preview-info h3 {

        font-size: 21px;
    }


    .rs-order-form-area {

        padding:
            13px
            14px
            14px;
    }


    .rs-order-heading h2 {

        font-size: 28px;
    }


    .rs-order-heading p {

        font-size: 8px;

        margin-bottom: 6px;
    }


    .rs-form-field {

        margin-top: 6px;
    }


    .rs-form-field input {

        height: 29px;

        font-size: 10px;
    }


    .rs-form-field textarea {

        min-height: 40px;
    }


    .rs-order-summary {

        grid-template-columns:
            1fr
            0.4fr
            auto;
    }


    .rs-place-order {

        min-height: 40px;

        margin-top: 7px;
    }

}


/* =====================================================
   VERY SHORT SCREENS
   Example: small laptop / landscape phone
===================================================== */

@media (max-height: 650px) {

    .rs-order-container {

        height:
            calc(100vh - 16px);

        max-height:
            calc(100vh - 16px);
    }


    .rs-order-preview-info {

        bottom: 25px;
    }


    .rs-order-preview-info h3 {

        font-size: 32px;

        margin: 5px 0;
    }


    .rs-order-form-area {

        padding:
            18px
            25px
            15px;
    }


    .rs-order-heading h2 {

        font-size: 38px;

        margin:
            5px 0;
    }


    .rs-order-heading p {

        margin-bottom: 7px;

        line-height: 1.35;
    }


    .rs-form-field {

        margin-top: 7px;
    }


    .rs-form-field input {

        height: 30px;
    }


    .rs-form-field textarea {

        min-height: 42px;
    }


    .rs-order-summary {

        margin-top: 8px;

        padding: 8px 0;
    }


    .rs-place-order {

        margin-top: 8px;

        padding:
            10px 14px;
    }

}


/* =====================================================
   BODY LOCK WHEN MODAL OPEN
===================================================== */

body.rs-modal-open {

    overflow: hidden;
}