/* ===== IMPORTAÇÃO DE FONTES ===== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ===== VARIÁVEIS GLOBAIS ===== */
:root {
    /* Cores principais */
    --primary-color: #ea1d2c;
    --primary-dark: #C41E24;
    --primary-light: #FF5A5F;
    --secondary-color: #ff8a00;
    
    /* Cores de fundo e texto */
    --background-color: #f8f9fa;
    --text-color: #333333;
    --light-text: #717171;
    
    /* Cores de elementos */
    --card-color: #ffffff;
    --card-background: #fff;
    --icon-background: #FFE5E5;
    --border-color: #e8e8e8;
    --cor-borda: #e8e8e8;
    --cor-fundo: #f7f7f7;
    
    /* Cores de feedback */
    --success-color: #4CAF50;
    --warning-color: #FF9800;
    --danger-color: #f44336;
    --info-color: #2196F3;
    
    /* Estilos de elementos */
    --border-radius: 12px;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --sombra-padrao: 0 2px 4px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
    
    /* Fonte padrão */
    font-family: 'Inter', sans-serif;
    font-size: 16px;
}

/* ===== RESET E ESTILOS BÁSICOS ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif !important;
}

body {
    background-color: var(--background-color);
    color: var(--text-color);
    font-family: 'Inter', sans-serif !important;
    margin: 0;
    padding: 0;
}

h1, h2, h3, h4, h5, h6, p, span, div, a, button, input, textarea, select, option {
    font-family: 'Inter', sans-serif !important;
}

/* ===== ESTILOS DO HEADER ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.navbar-brand {
    font-weight: bold;
}

/* ===== ESTILOS DO CARDÁPIO ===== */
/* Estilos do grid de produtos */
.produtos-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 10px;
    margin-bottom: 80px;
}

/* Produto em destaque */
.produto-destaque-container {
    padding: 10px;
    margin-bottom: 10px;
    background-color: #fff9f9;
    border-radius: 12px;
    border: 2px solid var(--primary-color);
    display: none;
}

.produto-destaque-container .produto-card {
    box-shadow: 0 4px 12px rgba(234, 29, 44, 0.15);
    border: 1px solid var(--primary-color);
}

/* Estilos do card de produto */
.produto-card {
    background-color: var(--card-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
}

.produto-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12);
}

.produto-card.disabled {
    pointer-events: none;
    opacity: 0.6;
    cursor: not-allowed;
}

/* ===== ESTILOS DO CARRINHO ===== */
.carrinho-header {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 10px;
    position: relative;
    cursor: pointer;
    border-radius: 4px;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.carrinho-icon-container {
    position: relative;
    display: flex;
    align-items: center;
    background: #ffffff;
    padding: 8px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-right: 10px;
}

.carrinho-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50%;
    padding: 2px 6px;
    font-size: 12px;
    min-width: 20px;
    text-align: center;
    font-weight: bold;
}

.carrinho-info {
    background: #ffffff;
    padding: 8px 12px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
}

.carrinho-total {
    font-size: 14px;
    font-weight: bold;
    color: var(--primary-color);
}

/* ===== ESTILOS DO DASHBOARD ===== */
.dashboard-container {
    display: flex;
    min-height: 100vh;
}

.menu-lateral {
    width: 250px;
    background: linear-gradient(45deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 20px 0;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.conteudo-principal {
    margin-left: 250px;
    width: calc(100% - 250px);
    padding: 20px;
}

.card-header-principal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.card-header-principal h2 {
    margin: 0;
    color: var(--text-color);
    font-size: 1.8rem;
}

/* ===== ESTILOS DE AVALIAÇÃO ===== */
.rating-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 10px 0;
}

.stars {
    position: relative;
    width: 200px;
}

.stars i {
    font-size: 20px;
    color: #464646;
    cursor: pointer;
    transition: color 0.2s ease;
}

.stars i:hover,
.stars i.active {
    color: #ffd700;
}

.rating-average,
.rating-count {
    font-size: 0.9em;
    color: #666;
    margin: 2px 0;
}

/* ===== ESTILOS DE LOADING OVERLAY ===== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    flex-direction: column;
    transition: all 0.3s ease;
}

.loading-content {
    background-color: #fff;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    max-width: 90%;
    width: 400px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* ===== ESTILOS DE FEEDBACK ===== */
.feedback-info {
    color: #2196F3;
    margin: 5px 0;
    font-size: 14px;
    padding: 8px;
    border-radius: 4px;
    background-color: #E3F2FD;
}

.feedback-sucesso {
    color: #4CAF50;
    margin: 5px 0;
    font-size: 14px;
    padding: 8px;
    border-radius: 4px;
    background-color: #E8F5E9;
}

.feedback-erro {
    color: #F44336;
    margin: 5px 0;
    font-size: 14px;
    padding: 8px;
    border-radius: 4px;
    background-color: #FFEBEE;
}

/* ===== ESTILOS DE ÚLTIMOS PEDIDOS ===== */
.ultimos-pedidos-section {
    margin-bottom: 2rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.ultimos-pedidos-titulo {
    font-size: 1.2rem;
    color: #333;
    margin-bottom: 1rem;
    padding-left: 0.5rem;
    border-left: 4px solid #ff5722;
}

.ultimos-itens-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1rem;
    padding: 0.5rem;
}

.ultimo-pedido {
    position: relative;
    background: white;
    border: 1px solid #eee;
    transition: transform 0.2s;
}

.ultimo-pedido:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.ultimo-pedido-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(255, 87, 34, 0.9);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ===== ESTILOS DE MODAL ===== */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 5px;
    text-align: center;
}

.modal-content h2 {
    margin-bottom: 20px;
}

.modal-content input {
    width: 200px;
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.modal-content button {
    padding: 10px 20px;
    margin: 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

/* ===== ESTILOS DE QRCODE ===== */
.qrcode-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    width: 300px;
    margin: 0 auto;
}

.qrcode-image {
    position: relative;
    width: 300px;
    height: 300px;
    margin-bottom: 1px;
}

.qrcode-image img {
    width: 100%;
    height: 100%;
}

.qrcode-info {
    text-align: center;
    margin-top: 10px;
}

.qrcode-ticket {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 5px;
}

.qrcode-mesa {
    font-size: 14px;
    color: #666;
}

.qrcode-restaurante {
    font-size: 14px;
    color: #666;
    margin-bottom: 10px;
}

/* ===== MEDIA QUERIES ===== */
@media (max-width: 768px) {
    .produtos-grid {
        grid-template-columns: repeat(1, 1fr);
    }
    
    .ultimos-itens-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }
    
    .ultimo-pedido-badge {
        font-size: 0.7rem;
        padding: 3px 6px;
    }
    
    .conteudo-principal {
        margin-left: 0;
        width: 100%;
    }
    
    .menu-lateral {
        width: 100%;
        height: auto;
        position: relative;
    }
}