:root{
  --bg: #070A12;
  --panel: rgba(255,255,255,.06);
  --panel2: rgba(255,255,255,.08);
  --stroke: rgba(255,255,255,.14);
  --text: rgba(255,255,255,.92);
  --muted: rgba(255,255,255,.65);

  --p1: #00D4FF;
  --p2: #7C3AED;
  --p3: #22C55E;
  --danger: #FF4D6D;
  --warn: #FBBF24;

  --shadow: 0 12px 40px rgba(0,0,0,.45);
  --r: 18px;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
  color:var(--text);
  background:
    radial-gradient(1200px 600px at 20% -10%, rgba(0,212,255,.22), transparent 60%),
    radial-gradient(900px 500px at 90% 10%, rgba(124,58,237,.20), transparent 60%),
    radial-gradient(800px 500px at 60% 110%, rgba(34,197,94,.14), transparent 60%),
    var(--bg);
}

a{color:inherit; text-decoration:none}

.topbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:16px 18px;
  border-bottom:1px solid var(--stroke);
  position:sticky;
  top:0;
  backdrop-filter: blur(10px);
  background: rgba(7,10,18,.65);
  z-index:10;
}

.brand{display:flex; gap:12px; align-items:center}
.logo{
  width:38px; height:38px;
  border-radius:12px;
  display:grid; place-items:center;
  font-weight:800;
  background: linear-gradient(135deg, var(--p1), var(--p2));
  box-shadow: var(--shadow);
}
.brand-text{display:flex; flex-direction:column; line-height:1.1}
.brand-text span{color:var(--muted); font-size:12px}

.pill{
  display:flex; align-items:center; gap:10px;
  padding:10px 12px;
  border:1px solid var(--stroke);
  background: var(--panel);
  border-radius:999px;
}
.dot{
  width:10px; height:10px; border-radius:50%;
  background: var(--warn);
  box-shadow: 0 0 0 4px rgba(251,191,36,.14);
}

.layout{
  display:grid;
  grid-template-columns: 280px 1fr 360px;
  gap:14px;
  padding:14px;
  max-width: 1400px;
  margin: 0 auto;
}

.panel{
  border:1px solid var(--stroke);
  background: var(--panel);
  border-radius: var(--r);
  box-shadow: var(--shadow);
  overflow:hidden;
}

.panel-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding:14px;
  border-bottom:1px solid var(--stroke);
  background: rgba(255,255,255,.03);
}

.panel-title{margin:0; font-size:16px; letter-spacing:.2px}
.stack{display:flex; flex-direction:column; gap:10px; padding:14px}

.card{
  margin:14px;
  padding:14px;
  border:1px solid var(--stroke);
  border-radius: 14px;
  background: rgba(255,255,255,.04);
}
.card.subtle{margin-top:12px; background: rgba(255,255,255,.03)}
.card.hint h4{margin:0 0 6px 0}
.card h4{margin:0 0 8px 0}
.card p{margin:0; color:var(--muted); font-size:13px; line-height:1.45}

/* ===== Hover preview na "Dica" ===== */
.card.hint.hovering{
  background: rgba(255,0,0,.20);
  border-color: rgba(255,0,0,.45);
}
.card.hint.hovering h4{ color: #FFD84D; }
.card.hint.hovering p{
  color: #FFD84D;
  font-weight: 800;
}

.btn{
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.04);
  color:var(--text);
  padding:12px 14px;
  border-radius: 14px;
  cursor:pointer;
  font-weight:650;
  transition: transform .06s ease, background .2s ease, border-color .2s ease;
  line-height: 1.1;
  white-space: nowrap;
}
.btn:hover{background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.22)}
.btn:active{transform: translateY(1px)}
.btn-primary{
  background: linear-gradient(135deg, rgba(0,212,255,.22), rgba(124,58,237,.22));
  border-color: rgba(0,212,255,.35);
}
.btn-ghost{background: rgba(255,255,255,.02)}
.btn-small{padding:10px 12px; border-radius:12px}
.btn-wide{width:100%}

.badge{
  display:inline-flex;
  align-items:center;
  padding:8px 10px;
  border-radius: 999px;
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.04);
  color: var(--text);
  font-size: 12px;
}

.searchbar{
  display:flex; gap:10px; align-items:center;
}
.searchbar input{
  width:min(520px, 100%);
  padding:12px 12px;
  border-radius: 14px;
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.03);
  color: var(--text);
  outline:none;
}
.searchbar input::placeholder{color: rgba(255,255,255,.45)}

.filters{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:14px;
  padding:14px;
  border-bottom:1px solid var(--stroke);
}

.select{display:flex; flex-direction:column; gap:6px; color:var(--muted); font-size:12px}
.select select{
  padding:12px 12px;
  border-radius: 14px;
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.03);
  color: var(--text);
  outline:none;
  min-width: 220px;
}
.select select option{
  background: #0b1020;
  color: #fff;
}

.summary{color:var(--muted); font-size:13px}

.grid{
  padding:14px;
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:14px;
}

/* ======= PRODUTO — novo layout ======= */
.product{
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.03);
  border-radius: 16px;
  overflow: visible;
  padding:10px;
}

/* Coluna esquerda: tudo empilhado, alinhado à esquerda */
.product .leftCol{
  display: flex;
  flex-direction: column;
  align-items: flex-start;   /* ← alinha tudo à esquerda */
  gap: 6px;
}

/* Imagem: alinhada à esquerda, sem centralizar */
.product img{
  width: 92px;
  height: 92px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.10);
  /* sem margin:auto — fica na esquerda */
}

/* Nome do produto: colado abaixo da imagem, quebra linha se necessário */
.product-name{
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text);
  word-break: break-word;     /* quebra palavras longas */
  white-space: normal;        /* permite múltiplas linhas */
  max-width: 100%;
}

/* Linha: preço + qty + botão */
.priceRow{
  width: 100%;
  display: flex;
  align-items: center;
  flex-wrap: wrap;            /* evita overflow em telas pequenas */
  gap: 6px;
  margin-top: 2px;
}

.product .price{
  font-weight: 800;
  font-size: 13px;
  white-space: nowrap;
}

/* Campo qty compacto */
.priceRow .qty-inline input{
  width: 52px;
  padding: 7px 6px;
  font-size: 12px;
  border-radius: 10px;
  border: 1px solid var(--stroke);
  background: rgba(255,255,255,.03);
  color: var(--text);
  outline: none;
  text-align: center;
}

/* Botão adicionar compacto */
.priceRow .btn-add{
  padding: 7px 10px;
  font-size: 11px;
  border-radius: 10px;
  white-space: nowrap;
}

/* ======= Carrinho ======= */
.cart{
  padding:14px;
  display:flex;
  flex-direction:column;
  gap:10px;
  max-height: calc(100vh - 260px);
  overflow:auto;
}
.cart-item{
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.03);
  border-radius: 16px;
  padding:12px;
}
.cart-item .top{
  display:flex;
  justify-content:space-between;
  gap:10px;
}
.cart-item .name{font-weight:750}
.cart-item .sub{color:var(--muted); font-size:12px; margin-top:6px}
.cart-item .actions{
  margin-top:10px;
  display:flex;
  gap:10px;
  justify-content:space-between;
}
.cart-item .actions button{padding:10px 12px}

.cart-footer{
  border-top:1px solid var(--stroke);
  padding:14px;
  background: rgba(255,255,255,.03);
}
.totals{display:flex; flex-direction:column; gap:6px; margin-bottom:12px}
.line{display:flex; justify-content:space-between; color:var(--muted)}
.line strong{color:var(--text)}
.line.total{font-size:16px; color:var(--text)}
.mini{margin-top:10px; font-size:12px; color:var(--muted)}

/* ======= Modal ======= */
.modal{
  width:min(720px, 92vw);
  border:1px solid var(--stroke);
  border-radius: 18px;
  padding:0;
  background: rgba(10,14,24,.92);
  color:var(--text);
  box-shadow: var(--shadow);
}
.modal::backdrop{
  background: rgba(0,0,0,.62);
  backdrop-filter: blur(6px);
}
.modal-card{padding:0; margin:0}
.modal-head{
  padding:14px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  border-bottom:1px solid var(--stroke);
}
.modal-body{padding:14px; color:var(--text)}
.modal-actions{
  padding:14px;
  display:flex;
  justify-content:flex-end;
  gap:10px;
  border-top:1px solid var(--stroke);
}
.iconbtn{
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.04);
  color: var(--text);
  border-radius: 12px;
  padding:8px 10px;
  cursor:pointer;
}

/* ======= Páginas internas (config, vendedor…) ======= */
.single{
  max-width: 820px;
  margin: 0 auto;
  padding: 14px;
}
.form-card h2{margin:0 0 6px 0}
.muted{color:var(--muted); margin:0 0 14px 0}
.form{display:flex; flex-direction:column; gap:12px}
.form label{display:flex; flex-direction:column; gap:6px; color:var(--muted); font-size:12px}
.form input{
  padding:12px 12px;
  border-radius: 14px;
  border:1px solid var(--stroke);
  background: rgba(255,255,255,.03);
  color: var(--text);
  outline:none;
}

/* ======= Responsivo ======= */
@media (max-width: 1100px){
  .layout{grid-template-columns: 1fr;}
  .grid{grid-template-columns: 1fr;}
  .cart{max-height:none}
}
