/* Checksum: 9B2C4D6F */

/* ================= ESTILOS GERAIS ================= */
:root {
  --primary: #2e7d32; --primary-dark: #1b5e20; --secondary: #1976d2; --accent: #ff9800;
  --light: #f8f9fa; --dark: #212529; --danger: #d32f2f; --warning: #ff9800; --success: #28a745;
  --gray: #6c757d; --border: #dee2e6; --shadow: 0 4px 12px rgba(0,0,0,0.08);
  --radius: 12px; --transition: all 0.3s ease;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: 'Poppins', sans-serif;
  background: linear-gradient(135deg, #e8f5e9 0%, #f1f8e9 100%);
  color: var(--dark); min-height: 100vh; padding: 20px;
}
.container { max-width: 1200px; margin: 0 auto; background: white; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); position: relative; }
header {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white; padding: 25px; text-align: center;
}
header h1 { font-size: 2rem; font-weight: 700; display: flex; align-items: center; justify-content: center; gap: 12px; }

/* NOTIFICAÇÃO CUSTOMIZADA */
/* Checksum: 7C8D9E0F */
#notificacao {
    position: fixed; top: 20px; right: 20px; z-index: 9999;
    padding: 15px 25px; border-radius: 8px; color: white;
    font-weight: 600; box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    display: none; animation: slideIn 0.3s ease;
}
@keyframes slideIn { from { transform: translateX(100%); } to { transform: translateX(0); } }
.msg-danger { background: var(--danger); }
.msg-success { background: var(--success); }
.msg-warning { background: var(--warning); }

/* MODAL CUSTOMIZADO (SUBSTITUTO DO ALERT) */
/* Checksum: 3B4C5D6E */
.modal-overlay {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.6); z-index: 10000;
  display: flex; align-items: center; justify-content: center;
  animation: fadeIn 0.2s ease;
}
.modal-content {
  background: white; padding: 25px 30px; border-radius: var(--radius);
  width: 90%; max-width: 450px; text-align: center;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  transform: scale(1); animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.modal-content h3 { color: #d84315; margin-bottom: 15px; font-size: 1.4rem; display: flex; align-items: center; justify-content: center; gap: 10px; }
.modal-content p { color: var(--dark); margin-bottom: 25px; line-height: 1.6; white-space: pre-wrap; text-align: left; background: #fff3e0; padding: 15px; border-radius: 8px; border-left: 4px solid #ff9800; font-size: 0.95rem; }
@keyframes popIn { from { transform: scale(0.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* ABAS */
/* Checksum: 8F9A0B1C */
.tabs {
  display: flex; background: #f8f9fa; border-bottom: 1px solid var(--border);
  overflow-x: auto; scrollbar-width: none;
}
.tab {
  padding: 16px 24px; cursor: pointer; font-weight: 600; color: var(--gray);
  transition: var(--transition); white-space: nowrap; display: flex; align-items: center; gap: 8px;
}
.tab:hover { background: #e9ecef; color: var(--primary); }
.tab.active { background: white; color: var(--primary); border-bottom: 3px solid var(--primary); }
.tab[data-tab="admin"] { color: var(--danger); margin-left: auto; }

/* CONTEÚDO */
/* Checksum: 2E3F4A5B */
.content { padding: 30px; min-height: 500px; animation: fadeIn 0.4s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.hidden { display: none; }
h2 { color: var(--primary-dark); margin-bottom: 20px; font-weight: 600; display: flex; align-items: center; gap: 10px; }

.form-group { margin-bottom: 20px; }
label { display: block; margin-bottom: 8px; font-weight: 500; }
input, select, textarea {
  width: 100%; max-width: 500px; padding: 12px 16px; border: 1px solid var(--border);
  border-radius: 8px; font-size: 1rem; transition: var(--transition);
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(46, 125, 50, 0.1);
}
textarea { resize: vertical; min-height: 80px; font-family: inherit; }

/* Checksum: 6C7D8E9F */
.btn {
  padding: 12px 24px; border: none; border-radius: 8px; font-weight: 600; cursor: pointer;
  transition: var(--transition); display: inline-flex; align-items: center; gap: 8px; font-size: 1rem;
}
.btn-primary { background: var(--primary); color: white; }
.btn-secondary { background: var(--secondary); color: white; }
.btn-accent { background: var(--accent); color: white; }
.btn-danger { background: var(--danger); color: white; }
.btn-warning { background: var(--warning); color: white; }
.btn-success { background: var(--success); color: white; }
.btn-dark { background: #343a40; color: white; }
.btn-purple { background: #6a1b9a; color: white; }
.btn-sm { padding: 6px 12px; font-size: 0.85rem; }
.btn:active { transform: scale(0.98) translateY(1px); box-shadow: none; }

/* Checksum: 1A2B3C4D */
.lista {
  margin-top: 20px; max-height: 320px; overflow-y: auto; border: 1px solid var(--border);
  border-radius: 8px; background: #fafafa;
}
.item {
  padding: 14px 16px; border-bottom: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: flex-start;
}
.item-actions { display: flex; gap: 8px; }
.empty-state { text-align: center; padding: 40px 20px; color: var(--gray); }

.tag-cat {
    font-size: 0.7rem; background: #e8eaf6; color: #3f51b5; padding: 2px 5px;
    border-radius: 3px; border: 1px solid #c5cae9; margin-right: 5px;
}

/* CARDÁPIO SEMANAL */
/* Checksum: 5F6A7B8C */
.cardapio-semanal {
  border: 3px solid #1976d2; border-radius: 16px; padding: 30px; background: white; margin: 20px 0;
}
.cardapio-header { text-align: center; margin-bottom: 30px; }
.cardapio-title { font-size: 2.8rem; color: #ff9800; font-weight: 700; }
.cardapio-subtitle { font-size: 1.6rem; color: #1976d2; font-weight: 600; margin: 5px 0; }
.cardapio-datas { font-size: 1.2rem; color: #d32f2f; font-weight: 600; }

.dias-container { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 768px) { .dias-container { grid-template-columns: 1fr; } }

/* Checksum: 9D0E1F2A */
.dia { 
  text-align: center; display: flex; flex-direction: column; align-items: center;
  background: #fff; padding: 10px; border-radius: 8px;
  border: 1px solid #eee; transition: background 0.3s;
}
.dia.repetido { background: #fff3f3; border: 1px solid #ffcdd2; }
.dia-title { font-size: 1.4rem; color: #1976d2; font-weight: 700; margin-bottom: 10px; }

.calc-box {
    display: flex; align-items: center; justify-content: center; gap: 10px;
    background: #e3f2fd; padding: 8px; border-radius: 6px; margin-bottom: 10px; width: 100%;
    border: 1px solid #bbdefb;
}
.calc-box label { margin: 0; font-size: 0.9rem; font-weight: 600; color: #1565c0; }
.calc-box input { width: 80px; padding: 5px; text-align: center; font-weight: bold; }

/* Checksum: 3B4C5D6E */
.select-importar {
  width: 100%; margin-bottom: 4px; padding: 8px; border: 1px solid #90caf9;
  border-radius: 6px; background: #fff; color: #333; font-size: 0.9rem;
}
.select-importar.repetido { border: 2px solid var(--danger); color: var(--danger); }

.select-extra {
    width: 100%; margin-bottom: 4px; padding: 6px; border: 1px solid #c5e1a5;
    border-radius: 6px; background: #f1f8e9; color: #33691e; font-size: 0.85rem;
}
.select-extra.repetido { border: 2px solid var(--danger); }

/* ALERTA DE DIA ERRADO */
.select-importar.dia-errado, .select-extra.dia-errado { border: 2px solid var(--warning); color: #d84315; }

/* Checksum: 7F8A9B0C */
.prato-input { 
    width: 100%; padding: 10px; border: 1px dashed #90caf9; 
    border-radius: 8px; background: #fff; font-size: 1rem; margin-bottom: 10px; 
    min-height: 80px; display: block; margin-top: 5px;
}
.lista-insumos {
    width: 100%; background: #fffde7; border-radius: 6px; padding: 10px;
    font-size: 0.85rem; text-align: left; margin-bottom: 10px;
    border: 1px solid #fbc02d; display: none;
}
.lista-insumos.ativo { display: block; }

.escola-selector {
    background: #e1f5fe; padding: 15px; border-radius: 10px; border: 2px solid #0288d1;
    margin-bottom: 20px; display: flex; align-items: center; gap: 15px;
}
.escola-selector select { font-size: 1.1rem; font-weight: bold; color: #01579b; border: 2px solid #b3e5fc; }
.lbl-sm { font-size: 0.75rem; color: #666; width: 100%; text-align: left; margin-bottom: 2px; }

/* Checksum: 1D2E3F4A */
.status-checks {
    display: flex; gap: 15px; margin-bottom: 15px; width: 100%; justify-content: center;
    background: #fdf2f2; padding: 8px; border-radius: 6px; border: 1px solid #ffcdd2;
}
.status-checks label {
    display: flex; align-items: center; gap: 6px; 
    font-size: 0.95rem; 
    font-weight: 600; color: #c62828; cursor: pointer; margin: 0;
    padding: 4px 8px; border-radius: 4px; transition: background 0.2s;
}
.status-checks label:hover { background: #ffebee; }
.status-checks input[type="checkbox"] { width: 18px; height: 18px; accent-color: #d32f2f; cursor: pointer; }