/**
 * MR Restaurant - Frontend Styles
 * Clean, Professional, Compact Design
 *
 * @package MR_Restaurant
 */

/* ========================================
   GLOBAL SHORTCODE STYLES
======================================== */

.mr-restaurant-menu,
.mr-restaurant-cart,
.mr-restaurant-checkout,
.mr-restaurant-account {
    max-width: 1200px;
    margin: 0 auto 40px;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #1e1e1e;
}

/* ========================================
   MENU SHORTCODE
======================================== */

.mr-restaurant-menu {
    padding: 20px;
}

/* Menu Header */
.mr-menu-header {
    margin-bottom: 30px;
    text-align: center;
}

.mr-menu-header h2 {
    margin: 0 0 12px;
    font-size: 32px;
    font-weight: 700;
    color: #1e1e1e;
}

.mr-menu-header p {
    margin: 0;
    font-size: 16px;
    color: #646970;
}

/* Menu Filters */
.mr-menu-filters {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.mr-menu-filter {
    padding: 8px 20px;
    background: #fff;
    border: 2px solid #ddd;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    color: #646970;
    cursor: pointer;
    transition: all 0.2s;
}

.mr-menu-filter:hover,
.mr-menu-filter.active {
    background: #2271b1;
    border-color: #2271b1;
    color: #fff;
}

/* Menu Grid */
.mr-menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.mr-menu-item {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
}

.mr-menu-item:hover {
    border-color: #2271b1;
    box-shadow: 0 4px 12px rgba(34, 113, 177, 0.15);
    transform: translateY(-2px);
}

.mr-menu-item-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    background: #f6f7f7;
}

.mr-menu-item-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.mr-menu-item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
}

.mr-menu-item-title {
    flex: 1;
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #1e1e1e;
    line-height: 1.3;
}

.mr-menu-item-price {
    flex-shrink: 0;
    font-size: 20px;
    font-weight: 700;
    color: #2271b1;
}

.mr-menu-item-category {
    display: inline-block;
    padding: 4px 10px;
    background: #f0f6fc;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    color: #2271b1;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.mr-menu-item-description {
    margin: 0 0 16px;
    font-size: 14px;
    color: #646970;
    line-height: 1.5;
    flex: 1;
}

.mr-menu-item-footer {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mr-quantity-selector {
    display: flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.mr-qty-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f6f7f7;
    border: none;
    cursor: pointer;
    font-size: 18px;
    color: #646970;
    transition: all 0.2s;
}

.mr-qty-btn:hover {
    background: #2271b1;
    color: #fff;
}

.mr-qty-input {
    width: 40px;
    height: 32px;
    border: none;
    border-left: 1px solid #ddd;
    border-right: 1px solid #ddd;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
}

.mr-btn-add-to-cart {
    flex: 1;
    padding: 8px 16px;
    background: #2271b1;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.mr-btn-add-to-cart:hover {
    background: #135e96;
}

.mr-btn-add-to-cart:active {
    transform: scale(0.98);
}

/* ========================================
   CART SHORTCODE
======================================== */

.mr-restaurant-cart {
    padding: 30px;
    background: #fff;
    border-radius: 8px;
}

.mr-cart-header h2 {
    margin: 0 0 24px;
    font-size: 28px;
    font-weight: 700;
    color: #1e1e1e;
}

.mr-cart-empty {
    padding: 60px 20px;
    text-align: center;
    color: #646970;
}

.mr-cart-empty-icon {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.3;
}

.mr-cart-empty p {
    margin: 0 0 20px;
    font-size: 18px;
}

.mr-cart-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
}

.mr-cart-table thead th {
    padding: 12px;
    background: #f6f7f7;
    border-bottom: 2px solid #ddd;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: #646970;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mr-cart-table tbody td {
    padding: 16px 12px;
    border-bottom: 1px solid #e5e7eb;
}

.mr-cart-item-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
}

.mr-cart-item-name {
    font-size: 16px;
    font-weight: 600;
    color: #1e1e1e;
    margin: 0 0 4px;
}

.mr-cart-item-details {
    font-size: 13px;
    color: #646970;
}

.mr-cart-item-price {
    font-size: 16px;
    font-weight: 600;
    color: #1e1e1e;
}

.mr-cart-remove-btn {
    padding: 6px 12px;
    background: transparent;
    border: 1px solid #d63638;
    border-radius: 4px;
    color: #d63638;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.mr-cart-remove-btn:hover {
    background: #d63638;
    color: #fff;
}

.mr-cart-totals {
    max-width: 400px;
    margin-left: auto;
    padding: 20px;
    background: #f6f7f7;
    border-radius: 8px;
}

.mr-cart-totals h3 {
    margin: 0 0 16px;
    font-size: 20px;
    font-weight: 700;
}

.mr-cart-total-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #ddd;
}

.mr-cart-total-row.grand-total {
    border-top: 2px solid #ddd;
    border-bottom: none;
    padding-top: 16px;
    margin-top: 8px;
    font-size: 18px;
    font-weight: 700;
}

.mr-cart-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.mr-btn-continue,
.mr-btn-checkout {
    flex: 1;
    padding: 14px 24px;
    border: 2px solid;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
    text-decoration: none;
    display: inline-block;
}

.mr-btn-continue {
    background: #fff;
    border-color: #2271b1;
    color: #2271b1;
}

.mr-btn-continue:hover {
    background: #f0f6fc;
}

.mr-btn-checkout {
    background: #2271b1;
    border-color: #2271b1;
    color: #fff;
}

.mr-btn-checkout:hover {
    background: #135e96;
    border-color: #135e96;
}

/* ========================================
   CHECKOUT SHORTCODE
======================================== */

.mr-restaurant-checkout {
    padding: 30px;
}

.mr-checkout-grid {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 30px;
}

.mr-checkout-section {
    background: #fff;
    padding: 24px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
}

.mr-checkout-section h3 {
    margin: 0 0 20px;
    font-size: 20px;
    font-weight: 700;
    color: #1e1e1e;
}

.mr-form-group {
    margin-bottom: 20px;
}

.mr-form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #1e1e1e;
}

.mr-form-group label .required {
    color: #d63638;
}

.mr-form-group input[type="text"],
.mr-form-group input[type="email"],
.mr-form-group input[type="tel"],
.mr-form-group select,
.mr-form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.mr-form-group input:focus,
.mr-form-group select:focus,
.mr-form-group textarea:focus {
    outline: none;
    border-color: #2271b1;
}

.mr-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.mr-payment-methods {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.mr-payment-method {
    padding: 16px;
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.mr-payment-method:hover,
.mr-payment-method.selected {
    border-color: #2271b1;
    background: #f0f6fc;
}

.mr-payment-method input[type="radio"] {
    margin-right: 10px;
}

.mr-order-summary {
    position: sticky;
    top: 20px;
}

.mr-order-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #e5e7eb;
}

.mr-btn-place-order {
    width: 100%;
    padding: 16px;
    background: #2271b1;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 20px;
}

.mr-btn-place-order:hover {
    background: #135e96;
}

/* ========================================
   ACCOUNT SHORTCODE
======================================== */

.mr-restaurant-account {
    padding: 30px;
}

.mr-account-nav {
    display: flex;
    gap: 12px;
    margin-bottom: 30px;
    border-bottom: 2px solid #e5e7eb;
    flex-wrap: wrap;
}

.mr-account-nav-item {
    padding: 12px 20px;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    font-size: 15px;
    font-weight: 600;
    color: #646970;
    cursor: pointer;
    transition: all 0.2s;
}

.mr-account-nav-item:hover,
.mr-account-nav-item.active {
    color: #2271b1;
    border-bottom-color: #2271b1;
}

.mr-account-section {
    display: none;
}

.mr-account-section.active {
    display: block;
}

.mr-orders-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
}

.mr-orders-table thead th {
    padding: 12px;
    background: #f6f7f7;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: #646970;
    text-transform: uppercase;
    border-bottom: 2px solid #ddd;
}

.mr-orders-table tbody td {
    padding: 16px 12px;
    border-bottom: 1px solid #e5e7eb;
}

.mr-order-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.mr-order-status.pending {
    background: #fff3cd;
    color: #856404;
}

.mr-order-status.confirmed {
    background: #d1ecf1;
    color: #0c5460;
}

.mr-order-status.completed {
    background: #d4edda;
    color: #155724;
}

.mr-order-status.cancelled {
    background: #f8d7da;
    color: #721c24;
}

/* ========================================
   RESPONSIVE
======================================== */

@media (max-width: 1024px) {
    .mr-checkout-grid {
        grid-template-columns: 1fr;
    }
    
    .mr-order-summary {
        position: static;
    }
}

@media (max-width: 768px) {
    .mr-menu-grid {
        grid-template-columns: 1fr;
    }
    
    .mr-form-row {
        grid-template-columns: 1fr;
    }
    
    .mr-cart-table {
        font-size: 14px;
    }
    
    .mr-cart-item-image {
        width: 60px;
        height: 60px;
    }
    
    .mr-cart-actions {
        flex-direction: column;
    }
    
    .mr-account-nav {
        flex-direction: column;
        border-bottom: none;
    }
    
    .mr-account-nav-item {
        border-bottom: 1px solid #e5e7eb;
        border-radius: 4px;
        margin-bottom: 0;
    }
}

/* ========================================
   UTILITY CLASSES
======================================== */

.mr-hidden {
    display: none !important;
}

.mr-loading {
    opacity: 0.6;
    pointer-events: none;
}

.mr-text-center {
    text-align: center;
}

.mr-mt-20 {
    margin-top: 20px;
}

.mr-mb-20 {
    margin-bottom: 20px;
}
