/* ============================================================
   style.css - Design responsivo com temas claro e escuro
   ============================================================ */
/* ── Reset & Base ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body { font-family: 'Segoe UI', system-ui, -apple-system, sans-serif; min-height: 100vh; transition: background 0.3s, color 0.3s; }

/* ── TEMA CLARO (default) ─────────────────────────────────── */
.tema-claro {
	background-image: linear-gradient(rgba(15, 23, 42, 0.6);
	rgba(15, 23, 42, 0.6));
	background-image: url('fundoClaro.jpg') !important; 
	background-size: contain !important; 
	background-size: cover !important; 
	background-position: center center !important; 
	background-attachment: fixed !important;
  --bg:          #f0f7f4;
  --bg-card:     #DDDDDD66;
  --bg-header:   #1a8c5b;
  --bg-comprado: #e8f5e9;
  --nav_bg:		 rgba(222,222,222,0.97);
  --nav_botao:   #8db38b;
  --primary:     #1a8c5b;
  --primary-h:   #15744a;
  --secondary:   #4a90d9;
  --secondary-h: #3a7abf;
  --duo:  		 #007700;
  --duo-h:       #1a331a;
  --danger:      #e53935;
  --danger-h:    #c62828;
  --success:     #43a047;
  --text:        #333333;
  --title:       #111111;
  --text-muted:  #555c6e;
  --text-inv:    #ffffff;
  --border:      #cde4d8;
  --shadow:      0 2px 8px rgba(26,140,91,.12);
  --categoria-bg:#e3f2fd;
  --categoria-txt:#1565c0;
  background: var(--bg);
  color: var(--text);
}

/* ── TEMA ESCURO ──────────────────────────────────────────── */
.tema-escuro {
	background-image: linear-gradient(rgba(15, 23, 42, 0.6);
	rgba(15, 23, 42, 0.6));
	background-image: url('fundoEscuro.jpg') !important; 
	background-size: contain !important; 
	background-size: cover !important; 
	background-position: center center !important; 
	background-attachment: fixed !important;
/*  --bg:          #121212; 
    --bg-card:     #1a2e1a;
    --bg-header:   #1e1e1e;
	--primary:     #4caf73;		*/
  --bg-card:     #101a2598;
  --bg-card2:    #101a25;
  --bg-header:   #101a25;
  --bg-comprado: #1e1e1e;
  --nav_bg:		 rgba(16,26,37,0.97);
  --nav_botao:   #3a4149;
  --focus:       #EEEEEE;
  --primary:     #1b2533;
  --primary-h:   #66bb8a;
  --secondary:   #5c9bd6;
  --secondary-h: #79aee0;
  --duo:  		 #007700;
  --duo-h:       #1a331a;
  --danger:      #ef5350;
  --danger-h:    #e53935;
  --success:     #66bb6a;
  --text:        #e0e0e0;
  --title:       #FFFFFF;      
  --text-muted:  #9e9e9e;
  --text-inv:    #121212;
  --border:      #333333;
  --shadow:      0 2px 8px rgba(255,255,255,.1);
  --categoria-bg:#263238;
  --categoria-txt:#80cbc4;
  --cat-verde:#CCFF66;
  background: var(--bg);
  color: var(--text);
input::placeholder{
display: none;}
}

/* ── Header ───────────────────────────────────────────────── */
.app-header {
  background: var(--bg-header);
  color: var(--text-inv);
  padding: 0.75rem 1rem;
  position: sticky; top: 0; z-index: 100; right: 0;
  border-bottom: 1.5px solid var(--border);
  box-shadow: 0 3px 7px rgba(0,0,0,.25);
}
.header-inner {
  max-width: 960px; 
  right: 0.3rem;
  display: flex; 
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
}

.header-inner img {
	padding: 1px;
	border-radius: 100%;
    width: 2rem;
	height: auto;
}
.app-title {
  color: var(--title);
  font-size: 1.3rem; 
  font-weight: 700; 
  /* white-space: nowrap; align-items: center; text-align: center; */

}

.header-nav { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-left: auto;}

/* ── Container ────────────────────────────────────────────── */
.container { max-width: 960px; margin: 0 auto; padding: 1rem; }

/* ── Cards ────────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.5rem;
  box-shadow: var(--shadow);
  margin-bottom: -1px;
}
/* Contêiner que segura os 3 cards e os centraliza */
.resumo-cards-container {
  display: flex;
  gap: 1rem;            /* Espaçamento entre os cards */
  justify-content: center; /* Centraliza os cards no meio da tela */
  align-items: stretch;
  margin-bottom: 1.5rem; /* Margem até a tabela de baixo */
  width: 100%;
}

/* O novo estilo do card específico para o painel */
.card-painel-resumo {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem 1rem;
  box-shadow: var(--shadow);
  text-align: center;
  flex: 1;               /* Faz os 3 cards terem exatamente o mesmo tamanho */
  min-width: 200px;      /* Impede que fiquem esmagados em telas menores */
  max-width: 350px;      /* Limita o tamanho máximo para não ficarem esticados demais */
}
/* O contêiner que envolve e centraliza os 3 blocos */
.card2_flex {
  display: flex;
  gap: 1.5rem;            /* Separação lateral entre as molduras */
  justify-content: center; /* Centraliza as 3 molduras no meio */
  align-items: stretch;
  width: 100%;
  margin-top: 1rem;       /* Espaço logo após o título Resumo */
}

/* A nova moldura individual e separada para cada um dos 3 itens */
.card2 {
  color: #FFFFFF !important;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem 1rem;
  box-shadow: var(--shadow);
  text-align: center;
  flex: 1;                /* Distribui o espaço igualmente */
  min-width: 25%;       /* Impede que fiquem esmagadas */
  max-width: 32%;       /* Limita a largura máxima para ficarem elegantes */
}


h1 { color: var(--text);}
/* ── Seletor de lista ─────────────────────────────────────── */

.selector-row {
  display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap;
}
.form-inline { display: flex; align-items: center; gap: 0.5rem; flex: 1; min-width: 200px; }
.label-inline { white-space: nowrap; font-weight: 600; font-size: 1rem; }

/*-----Tabelas -*/
table {
  border-collapse: collapse;
  border-spacing: 0;
  width: 100%;
  border: none;
  background-color: transparent;
}

th, td {
  border: none;
  background-color: transparent;
  border: none;
  padding: 0;
  margin: 0;
}
/* ── Inputs & Selects ─────────────────────────────────────── */
.select{
  width: 98%;
  padding: 0.43rem 0.52rem;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: #222222;
  color: var(--text);
  transition: border-color 0.2s;
}
.select option{
    background-color: #777777;
	font-weight: normal !mportant;
	color: #EEEEEE;
	font-size: 1rem !important;
 }
.input, .textarea {
  width: 98%;
  padding: 0.43rem 0.52rem;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: var(--bg-card);
  color: var(--text);
  font-size: 0.95rem;
  transition: border-color 0.2s;
}
.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--focus);
  box-shadow: 0 0 0 3px rgba(57,241,162,.15);
}
.input:focus::placeholder {
  color: transparent;
}
.select_focus{font-weight: bold;}
.select_focus:focus::placeholder {
  color: transparent;
}
.textarea:focus::placeholder {
  color: transparent;
}

.select { cursor: pointer; }
.textarea { resize: vertical; min-height: 80px; margin:0.4rem 0 0.4rem 0; }

/* ── Botões ───────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.50rem 1.1rem;
  border: none; border-radius: 8px;
  font-size: 0.95rem; font-weight: 600;
  cursor: pointer; text-decoration: none;
  transition: background 0.2s, transform 0.1s, opacity 0.2s;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-sm { padding: 0.34rem 1.2rem; font-size: 0.82rem; border-radius: 6px; position: relative; right: 1rem !important;}
.btn-sm-lp { padding: 0.1rem 0.6rem; font-size: 0.82rem; border-radius: 4px; position: relative;}
.btn-primary   { background: var(--primary);   color: #fff; border: 2px solid #777777;}
.btn-primary:hover { background: var(--primary-h); }
.btn-secondary { background: var(--secondary); color: #fff; }
.btn-secondary:hover { background: var(--secondary-h); }
.btn-duo { background: var(--duo); color: #fff; }
.btn-duo:hover { background: var(--duo-h); }
.btn-danger    { background: var(--danger);    color: #fff; }
.btn-danger:hover { background: var(--danger-h); }
.btn-success   { background: var(--success);  font-size: 2rem; color: #fff; }
.btn-ghost {
  background: var(--danger);    color: #fff;
  border: 1.5px solid var(--border);
  white-space: nowrap;
  margin-left: auto; /* Empurra o elemento para a direita */
}
.btn-ghost:hover { background: var(--border); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }

/* ── Lista header ─────────────────────────────────────────── */
.lista-header {
  display: flex; align-items: center;
  justify-content: space-between; gap: 1rem;
  flex-wrap: wrap;

}
.lista-nome { font-size: 1rem; font-weight: 400; }

/* ── Seções ───────────────────────────────────────────────── */
.secao-titulo {
  font-size: 1rem; font-weight: 700;
  margin-bottom: 0.75rem;
  display: flex; align-items: center; gap: 0.5rem;
}
.comprados-titulo { margin-top: 1.5rem; }

/* ── Badge ────────────────────────────────────────────────── */
.badge {
  background-color: #008080;
  color: #fff;
  border-radius: 99px;
  padding: 0.1rem 0.55rem;
  font-size: 1rem;
  font-weight: 700;
}
.badge-success { background: var(--success); }

/* ── Categoria grupo ──────────────────────────────────────── */
.categoria-grupo { margin-bottom: 0.7rem; }
.categoria-titulo {
  font-size: 0.8rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--categoria-bg);
  color: var(--cat-verde);
  padding: 0.3rem 0.75rem;
  border-radius: 6px;
  border: 2px solid var(--border);
  margin-bottom: 0.5rem;
  display: inline-block;
}

/* ── Grid de produtos ─────────────────────────────────────── */
.produtos-grid { display: flex; flex-direction: column; gap: 0.5rem; }

/* ── Item card ────────────────────────────────────────────── */
.item-card {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 0.04rem 1rem;
  display: flex; align-items: center; gap: 0.52rem;
  box-shadow: var(--shadow);
  transition: background 0.2s, opacity 0.2s;
  margin: 2px;
}
.item-card:hover { border-color: var(--primary); }
.item-comprado {
  background: var(--bg-comprado);
  opacity: 0.75;
}
.item-comprado .item-nome {
  text-decoration: line-through;
  color: var(--text-muted);
}

.item-label {
  display: flex; align-items: center; gap: 0.65rem;
  cursor: pointer; flex: 1;
}
.item-check {
  width: 1.3rem; height: 1.3rem;

  cursor: pointer; 
  background-color: #FFFFFF;
  color: #FFFFFF;
  flex-shrink: 0;
  border-radius: 7px;
  border: 2px solid var(--border);
}
.item-foto {
  width: 46px; height: 46px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
  border: 1.5px solid var(--border);
}
.item-info {
  display: flex; flex-direction: column; gap: 0.2rem;
}
.item-nome {
  font-weight: 600; font-size: 0.95rem;
  line-height: 1.25;
}
.item-qtd {
  font-size: 0.8rem; color: var(--text-muted);
}
.item-desc {
  font-size: 0.78rem; color: var(--text-muted);
}

.btn-remover {
  background: none; border: none;
  color: var(--danger);
  font-size: 1rem; cursor: pointer;
  padding: 0.3rem; border-radius: 6px;
  flex-shrink: 0;
  transition: background 0.15s;
}
.btn-remover:hover { background: rgba(229,57,53,.1); }

/* ── Mensagem vazia ───────────────────────────────────────── */
.empty-msg {
  color: var(--text-muted); font-size: 0.9rem;
  text-align: center; padding: 1.5rem 0;
}

/* ── Seção comprados ──────────────────────────────────────── */
.secao-comprados { margin-top: 1.5rem; }

/* ── Modal ────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,.55);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}
.modal-overlay.hidden { display: none; }
.modal-box {
  top: 0.7rem !important;
  background: var(--bg-card2);
  border-radius: 14px;
  padding: 1.6rem;
  width: 100%; max-width: 430px;
  box-shadow: 0 8px 32px rgba(0,0,0,.3);
  display: flex; flex-direction: column; gap: 1rem;
}
.modal-box-lg { max-width: 600px; max-height: 80vh; overflow-y: auto; }
.modal-box h3 { font-size: 1.1rem; font-weight: 700; }
.modal-actions {
  display: flex; gap: 0.75rem; justify-content: flex-end; flex-wrap: wrap;
}
.modal-produtos-grid {
  display: flex; flex-direction: column; gap: 0.5rem;
  max-height: 50vh; overflow-y: auto;
}
.modal-produto-item {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.6rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg-card);
}
.modal-produto-item .item-info { flex: 1; }

/* ── Toast ────────────────────────────────────────────────── */
.toast {
  position: fixed; bottom: 1.5rem; left: 50%; transform: translateX(-50%);
  padding: 0.7rem 1.4rem;
  border-radius: 99px;
  font-size: 0.9rem; font-weight: 600;
  color: #fff;
  z-index: 300;
  box-shadow: 0 4px 16px rgba(0,0,0,.25);
  animation: fadeIn .25s ease;
  white-space: nowrap;
}
.toast.hidden { display: none; }
.toast-info    { background: #555; }
.toast-sucesso { background: var(--success); }
.toast-aviso   { background: #f59e0b; color: #1a1a1a; }
.toast-erro    { background: var(--danger); }
@keyframes fadeIn { from { opacity: 0; transform: translateX(-50%) translateY(8px); } }

/* ── Forms Admin ──────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: 0.3rem; margin-bottom: 0.4rem; }
.form-group label { font-weight: 600; font-size: 0.9rem; }
.form-row { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.form-row .form-group { flex: 1; min-width: 140px; }

/* ── Tabela admin ─────────────────────────────────────────── */
.table-wrap { overflow-x: auto; }
table {
  width: 100%; border-collapse: collapse;
  font-size: 0.9rem;
}
th, td {
  padding: 0.43rem 0.5rem;
  text-align: left;
}
th { font-weight: 700; background: var(--bg); color: var(--text-muted); }
tr:hover td { background: rgba(26,140,91,.04); }

/* ── Switch toggle ────────────────────────────────────────── */
.switch-row {
  display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap;
}
.switch-label { font-weight: 600; }
.switch {
  position: relative; display: inline-block;
  width: 48px; height: 26px;
}
.switch input { opacity: 0; width: 0; height: 0; }
.slider {
  position: absolute; inset: 0;
  background: #ccc; border-radius: 99px;
  cursor: pointer; transition: background .3s;
}
.slider::before {
  content: '';
  position: absolute;
  width: 20px; height: 20px;
  left: 3px; bottom: 3px;
  background: #fff; border-radius: 50%;
  transition: transform .3s;
}
input:checked + .slider { background: var(--primary); }
input:checked + .slider::before { transform: translateX(22px); }

/* ── Admin sidebar/nav ────────────────────────────────────── */
.admin-layout {
  display: flex; min-height: calc(100vh - 56px);
}

.admin-content { flex: 1; padding: 1.5rem; overflow-y: auto; }

/* ── Alert ────────────────────────────────────────────────── */
.alert {
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}
.alert-erro    { background: #fdecea; color: #c62828; border: 1px solid #ef9a9a; }
.alert-sucesso { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.tema-escuro .alert-erro    { background: #3b1212; color: #ef9a9a; border-color: #7f1d1d; }
.tema-escuro .alert-sucesso { background: #0f2e13; color: #a5d6a7; border-color: #1b5e20; }

/* ── Login page ───────────────────────────────────────────── */
.login-wrap {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}
.login-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
  width: 100%; max-width: 380px;
  box-shadow: var(--shadow);
}
.login-box h2 { text-align: center; margin-bottom: 1.5rem; font-size: 1.3rem; }

/* ── Foto preview ─────────────────────────────────────────── */
.foto-preview-wrap { display: flex; align-items: center; gap: 0.75rem; }
.foto-preview {
  width: 72px; height: 72px;
  object-fit: cover; border-radius: 8px;
  border: 1px solid var(--border);
}

/* ── Responsive CELULAR ───────────────────────────────────────────── */
@media (max-width: 640px) {
  .container {padding: 0.4rem; }
  .admin-layout { flex-direction: column; }
  .header-inner {
	  margin-right: 4px !important;
      justify-content: flex-end !important;
  }
   .ad_prod{
		 display: none !important; 
	  }
  .admin-content { padding: 0.3rem; }
  .form-row { flex-direction: column; }
  .selector-row { flex-direction: column; align-items: stretch; }
  .form-inline { flex-direction: column; align-items: stretch; }
  .lista-header { flex-direction: row; align-items: flex-start; }
  .modal-box { position: absolute; padding: 1rem; top: 0.7rem !important;font-size: 1rem;}
.card{padding:0.4rem;}
.card2_flex {
  display: flex;
  gap: 0.5rem;            /* Separação lateral entre as molduras */
  justify-content: center; /* Centraliza as 3 molduras no meio */
  align-items: stretch;
  width: 100%;
  margin-top: 1rem;      

 /* Espaço logo após o título Resumo */
}
  .card2 {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem 0.7rem;
  box-shadow: var(--shadow);
  text-align: center;
  flex: 1;                /* Distribui o espaço igualmente */
  min-width: 32%;       /* Impede que fiquem esmagadas */
  max-width: 250px;       /* Limita a largura máxima para ficarem elegantes */
}
.ocultar_celular{
  display: none !important;
   }
   
input::placeholder{
display: block;
color: var(--title) !important;
opacity: 1;
}
textarea::placeholder{
display: block;
color: var(--title) !important;
opacity: 1;
	}
}
.input:focus::placeholder {
  color: #00000000;
}
.select_focus{font-weight: bold;}
.select_focus:focus::placeholder {
  color: #00000000;
}
.textarea:focus::placeholder {
  color: #00000000;
}

/* vira emoji */

.vira_emoji{
  transform: scaleX(-1);
  display: inline-block;
  font-size: 1.3rem;
}

/* MENU LATERAL */
 
    /* Botão de toggle */
    .menu-toggle {
      display: none;
      position: fixed;
      top: 0rem;
      left: 15px;
      background: #00000000;
      color: var(--text);
	  border: none;
      padding: 1px 6px;
	  font-size: 2rem;
	  font-weight: bold;
      cursor: pointer;
      z-index: 1001;
    }

    /* Menu lateral */
    nav {
      position: fixed;
      top: 0;
      left: -100%; /* começa fora da tela */
      width: 16rem; /* largura inicial */
      height: 100%;
      background-color: var(--nav_bg);
      transition: left 0.5s ease, width 0.5s ease;
      /* ↑ Aqui você pode suavizar o movimento:
         - aumentar o tempo (ex: 0.6s ou 0.7s)
         - usar cubic-bezier(0.25, 0.8, 0.25, 1) para um efeito mais fluido */
      z-index: 1000;
      padding-top: 60px;
      overflow-y: auto;
    }

    nav.active {
      left: 0;
      width: 250px; /* expande suavemente para ocupar mais espaço */
	  
    }

    nav ul {
      list-style: none;
      padding: 0;
      margin: 0;
    }

    nav ul li {
      border-bottom: 1px solid #444;
    }

    nav ul li a {
      display: block;
      padding: 15px;
      color: var(--text);
	  font-weight:bold;
      text-decoration: none;
      background-color: var(--nav_botao);
      margin: 5px 10px;
      border-radius: 6px;
      transition: background 0.3s ease;
    }

    nav ul li a:hover {
      background: #505861;
    }
	.sair{
		position: relative;
		margin: 0 auto;
		
		
	}
iframe img{
	
	width: 98%;
	height: 98%;
}
    /* Desktop */
    @media (min-width: 768px) {
      .menu-toggle {
        display: none;
      }
      nav {
        position: static;
        width: 250px;
        height: auto;

        transition: none;
        padding: 0;
      }
	    nav.active {
      left: 0;
      width: 220px; /* expande suavemente para ocupar mais espaço */
	  
    }
      nav ul {
        display: block;
      }
      nav ul li {
        border: none;
      }
      nav ul li a {
		font-weight:bold;
        color: var(--text);
      }

    }

    /* Mostrar botão em mobile */
    @media (max-width: 767px) {
      .menu-toggle {
        display: block;
      }

    }
	
	
/* BOTÃO INSTALAR APP -----------------------*/
.installapp_botao {
  display: flex;
  justify-content: center; /* Centraliza horizontalmente */
  align-items: center;      /* Centraliza verticalmente */
  margin-bottom: 1rem;
}
.botao-instalar {
  background: linear-gradient(115deg, #006699, #33CC33);
  color: white;
  font-size: 1rem;
  font-weight: bold;
  padding: 12px 25px;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  box-shadow: 0px 8px 20px rgba(109, 182, 182, 0.4);
  transition: all 0.3s ease;
  text-transform: uppercase;
  display: none;
}
.botao-instalar:hover {
  background: linear-gradient(135deg, #00e676, #b9f6ca);
  transform: translateY(-3px);
  box-shadow: 0px 10px 25px rgba(109, 182, 182, 0.7);
}