/* ==========================================================================
   RESTAURANT MENU - MAIN LAYOUT & STYLES (INTEGRATED & CLEANED)
   ========================================================================== */

.rm-order-panel {
    max-width: 1200px;
    margin: 0 auto;
    box-sizing: border-box;
}

/* STATUS */
.rm-status-bar {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    border: 1px solid #e5e5e5;
    border-radius: 50px;
    background: #fff;
    margin-bottom: 30px;
    font-size: 16px;
}

.rm-open-dot,
.rm-close-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: block;
}

.rm-open-dot {
    background: #32c24d;
}

.rm-close-dot {
    background: #ff3b30;
}

/* PICKUP DELIVERY */
.rm-order-type {
    display: flex;
    max-width: 560px;
    margin-bottom: 30px;
}

.rm-order-btn {
    flex: 1;
    height: 60px;
    border: 1px solid #666;
    background: #fff;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all .3s ease;
}

.rm-order-btn.rm-active {
    background: #efb0b0;
}

/* INFO */
.rm-pickup-delivery-info {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

.rm-info-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 15px;
}

.rm-icon {
    font-size: 20px;
}

/* FILTERS & DROPDOWNS */
.rm-category-dropdown {
    position: relative;
    width: 300px;
    margin: 0;
}

.rm-dropdown-btn {
    width: 100%;
    height: 60px;
    border: 1px solid #d9d9d9;
    background: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    font-size: 16px;
    cursor: pointer;
}

.rm-dropdown-list {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #fff;
    z-index: 999;
    border: 1px solid #ddd;
    border-top: none;
}

.rm-category-item {
    padding: 14px 20px;
    font-size: 16px;
    cursor: pointer;
}

.rm-category-item:hover {
    background: #f5f5f5;
}

.rm-category-item.active {
    background: #f5f5f5;
    font-weight: 600;
}

.rm-divider {
    width: 1px;
    height: 60px;
    background: #d9d9d9;
}

.rm-food-tabs {
    display: flex;
    gap: 40px;
}

.rm-food-tab {
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    padding-bottom: 8px;
}

.rm-food-tab.active {
    color: #efb0b0;
    border-bottom: 3px solid #efb0b0;
}

/* PRODUCTS GRID */
#rm-products-container {
    margin-top: 40px;
}

.rm-products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.rm-product-card {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    background: #fff;
    padding: 18px;
    min-height: 220px !important;
    box-sizing: border-box;
    cursor: pointer;
    transition: all .3s ease;
}

.rm-product-card:hover {
    box-shadow: 0 8px 20px rgba(0,0,0,.08);
    transform: translateY(-2px);
}

.rm-product-content {
    flex: 1;
    padding-right: 15px;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.rm-product-title {
    margin: 0 0 10px;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    text-transform: uppercase;
    text-align: left;
}

.rm-product-description {
    font-size: 14px;
    line-height: 1.6;
    color: #555;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.rm-product-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 15px;
}

.rm-tag {
    display: inline-flex;
    align-items: center;
    background: #f7f7f7;
    border: 1px solid #e5e5e5;
    border-radius: 20px;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    color: #555;
}

.rm-product-price {
    margin-top: auto;
    font-size: 20px;
    font-weight: 700;
    color: #111;
}

.rm-product-price del {
    opacity: .5;
    margin-right: 6px;
}

/* PRODUCT IMAGES */
.rm-product-image {
    width: 200px !important;
    min-width: 200px !important;
    flex-shrink: 0;
}

.rm-product-image img {
    width: 200px !important;
    height: 220px !important;
    object-fit: cover !important;
    display: block;
}

.rm-loading,
.rm-no-products {
    text-align: center;
    padding: 40px;
}

/* DELIVERY MODAL */
#rm-delivery-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.65);
    z-index: 99999;
    justify-content: center;
    align-items: center;
}

.rm-delivery-modal-box {
    width: 90%;
    max-width: 650px;
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    position: relative;
    box-sizing: border-box;
}

.rm-delivery-modal-box h3 {
    margin: 0 0 25px;
    font-size: 28px;
}

#rm-close-modal {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 34px;
    cursor: pointer;
}

.rm-modal-field {
    margin-bottom: 20px;
}

.rm-modal-field label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
}

.rm-modal-field input {
    width: 100%;
    height: 60px;
    padding: 0 15px;
    font-size: 18px;
    box-sizing: border-box;
}

#rm-check-delivery,
#rm-save-delivery {
    height: 55px;
    padding: 0 30px;
    border: none;
    cursor: pointer;
    font-size: 18px;
}

#rm-check-delivery {
    background: #111;
    color: #fff;
}

#rm-save-delivery {
    background: #efb0b0;
    margin-top: 20px;
}

#rm-delivery-result {
    margin-top: 20px;
    font-size: 18px;
}


/* ==========================================================================
   PRODUCT ACTIONS - FINAL ULTRA-FORCE TAMARIND IBIZA RED THEME
   ========================================================================== */

/* Main Action Wrapper Layout Force */
.rm-product-actions {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 10px !important;
    margin-top: 15px !important;
    width: 100% !important;
    clear: both !important;
}

/* Quantity Box Design (- 1 +) */
.rm-quantity-wrapper,
.rm-qty-box {
    display: flex !important;
    align-items: center !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 6px !important;
    overflow: hidden !important;
    background-color: #f8fafc !important;
    height: 38px !important;
    width: 100px !important;
    flex-shrink: 0 !important;
}

/* Quantity Plus/Minus Buttons */
.rm-qty-minus, 
.rm-qty-plus {
    background: none !important;
    border: none !important;
    width: 32px !important;
    height: 100% !important;
    font-size: 16px !important;
    font-weight: bold !important;
    color: #334155 !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    margin: 0 !important;
    user-select: none !important;
    transition: background 0.2s, color 0.2s !important;
}

.rm-qty-minus:hover, 
.rm-qty-plus:hover {
    background-color: #f0f0f0 !important;
    color: #ff4237 !important;
}

/* Quantity Input Field */
.rm-qty-input {
    width: 36px !important;
    height: 100% !important;
    border: none !important;
    border-left: 1px solid #e2e8f0 !important;
    border-right: 1px solid #e2e8f0 !important;
    text-align: center !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    color: #1e293b !important;
    background: #ffffff !important;
    padding: 0 !important;
    margin: 0 !important;
    -moz-appearance: textfield !important;
}

.rm-qty-input::-webkit-outer-spin-button,
.rm-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    margin: 0 !important;
}

/* Add to Cart Button Strict Control */
.rm-add-cart {
    background-color: #ff4237 !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 6px !important;
    height: 38px !important;
    padding: 0 15px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    display: flex !important; 
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    margin: 0 !important; 
    flex-grow: 1 !important;
    max-width: 140px !important;
    text-align: center !important;
    box-shadow: 0 2px 5px rgba(255, 66, 55, 0.2) !important;
    transition: all 0.3s ease !important;
}

.rm-add-cart:hover {
    background-color: #d63328 !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 8px rgba(255, 66, 55, 0.3) !important;
}

.rm-add-cart:disabled {
    background-color: #cccccc !important;
    color: #666666 !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

.rm-product-actions a.added_to_cart,
.rm-product-actions .view-cart {
    display: none !important; 
}


/* ==========================================================================
   RESPONSIVE MEDIA QUERIES (TABLET & MOBILE BREAKPOINTS)
   ========================================================================== */

/* TABLET BREAKPOINT */
@media (max-width: 1200px) {
    .rm-products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* MOBILE BREAKPOINT (768px and below) */
@media (max-width: 768px) {
    .rm-order-type {
        display: flex;
        flex-direction: row;
        max-width: 100%;
    }

    .rm-order-btn {
        flex: 1;
        height: 50px;
        font-size: 16px;
    }

    .rm-pickup-delivery-info {
        flex-direction: column;
        gap: 15px;
    }

    .rm-divider {
        display: none;
    }

    .rm-category-dropdown {
        width: 100%;
    }

    .rm-food-tabs {
        gap: 20px;
        flex-wrap: wrap;
    }

    .rm-products-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .rm-product-card {
        display: flex;
        justify-content: space-between;
        align-items: stretch;
        gap: 12px;
        padding: 12px;
        min-height: 150px !important;
        overflow: hidden;
    }

    .rm-product-content {
        flex: 1;
        min-width: 0;
        padding-right: 0;
        display: flex;
        flex-direction: column;
    }

    .rm-product-image {
        width: 120px !important;
        min-width: 120px !important;
        align-self: stretch;
    }

    .rm-product-image img {
        width: 100% !important;
        height: 100% !important;
        min-height: 150px !important;
        object-fit: cover !important;
        display: block;
        border-radius: 6px;
    }

    .rm-product-title {
        font-size: 14px;
        line-height: 1.3;
        margin-bottom: 8px;
    }

    .rm-product-description {
        font-size: 12px;
        line-height: 1.5;
        -webkit-line-clamp: 2;
        overflow: hidden;
    }

    .rm-product-price {
        font-size: 16px;
        margin-top: auto;
    }
}

/* CRITICAL ULTRA-FORCE MOBILE VIEW RESIZE (Under 480px) */
@media screen and (max-width: 480px) {
    .rm-product-actions {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        width: 100% !important;
        gap: 8px !important;
    }

    .rm-quantity-wrapper,
    .rm-qty-box {
        height: 32px !important;
        width: 90px !important;
    }

    .rm-qty-minus,
    .rm-qty-plus {
        width: 28px !important;
    }

    .rm-qty-input {
        width: 30px !important;
        font-size: 13px !important;
    }

    .rm-add-cart {
        height: 32px !important;
        padding: 0 10px !important;
        font-size: 13px !important;
        flex-grow: 1 !important;
        max-width: 100% !important;
    }
}

.form-row.rm-hidden-checkout-field {
    display: none !important;
}

.rm-closed-box {
    text-align: center;
    padding: 80px 20px;
    border: 1px solid #eee;
    border-radius: 12px;
    background: #fff;
}

.rm-closed-box h2 {
    margin: 0 0 10px;
    font-size: 32px;
}

.rm-closed-box p {
    margin: 0;
    font-size: 18px;
    color: #666;
}

.rm-closed-products-message {
    max-width: 550px;
    margin: 40px auto;
    padding: 25px 20px;
    border: 1px solid #ececec;
    border-radius: 16px;
    background: #fafafa;
    text-align: center;
    box-sizing: border-box;
}

.rm-closed-icon {
    font-size: 42px;
    line-height: 1;
    margin-bottom: 12px;
}

.rm-closed-products-message h2 {
    margin: 0;
    font-size: 30px;
    font-weight: 700;
    line-height: 1.3;
}

.rm-countdown {
    display: inline-block;
    background: #efb0b0;
    color: #111;
    padding: 14px 28px;
    border-radius: 12px;
    font-size: 32px;
    font-weight: 700;
    letter-spacing: 1px;
    margin: 18px 0 10px;
    min-width: 220px;
}

.rm-opening-time {
    margin: 0;
    font-size: 16px;
    color: #666;
}

.rm-opening-time strong {
    color: #111;
}

/* Mobile Closed Message Styles */
@media (max-width: 768px) {
    .rm-closed-products-message {
        max-width: 100%;
        margin: 20px 0;
        padding: 20px 15px;
    }

    .rm-closed-products-message h2 {
        font-size: 24px;
    }

    .rm-countdown {
        font-size: 24px;
        min-width: 180px;
        padding: 12px 20px;
    }

    .rm-opening-time {
        font-size: 14px;
    }
}
