:root {
  --navy: #0b0c10;
  --navy2: #14161f;
  --navy3: #1c1f2b;
  --gold: #c59b27;
  --gold-hover: #b8860b;
  --gold-light: #ecd37a;
  --gold-dark: #8f6815;
  --gold-soft: #fcf6e8;
  --gold-border: #f0deb0;
  --gold-grad: linear-gradient(135deg, #c59b27 0%, #ecd37a 45%, #99751d 100%);
  --silver-grad: linear-gradient(135deg, #ffffff 0%, #cbd5e1 50%, #94a3b8 100%);
  --ink: #12131a;
  --muted: #666c7a;
  --line: #e8e5dc;
  --bg: #faf9f6;
  --white: #ffffff;
  --green: #108554;
  --shadow: 0 14px 40px rgba(18, 19, 26, 0.07);
}

* {
  box-sizing: border-box;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 14px;
}

.hidden {
  display: none !important;
}

/* Barra superior com textura e acabamento em preto ônix e filete dourado */
.topbar {
  height: 74px;
  background-color: #0b0c10;
  background-image: url('header-texture.png');
  background-repeat: repeat;
  background-position: center;
  border-bottom: 1px solid rgba(197, 155, 39, 0.35);
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 max(24px, calc((100% - 1200px) / 2));
  gap: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.65);
}

.brand {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.brand-logo {
  height: 50px;
  width: auto;
  max-width: 270px;
  object-fit: contain;
  display: block;
  transition: transform 0.2s ease, filter 0.2s ease;
}

.brand:hover .brand-logo {
  transform: scale(1.02);
  filter: drop-shadow(0 0 8px rgba(197, 155, 39, 0.35));
}

.userbar {
  display: flex;
  align-items: center;
  gap: 14px;
  color: #e2e8f0;
  font-weight: 600;
}

.topbar .btn-outline {
  background: rgba(197, 155, 39, 0.12);
  border: 1px solid rgba(197, 155, 39, 0.4);
  color: #f3e098;
  backdrop-filter: blur(8px);
  padding: 8px 18px;
  border-radius: 8px;
  font-weight: 700;
  transition: background 0.2s, border-color 0.2s;
}

.topbar .btn-outline:hover {
  background: rgba(197, 155, 39, 0.25);
  border-color: rgba(236, 211, 122, 0.8);
  color: #ffffff;
}

/* Moldura da Logo no Login */
.auth-brand {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 20px;
  padding: 16px 20px;
  border-radius: 14px;
  background: #090a0d;
  border: 1px solid rgba(197, 155, 39, 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.auth-logo {
  max-height: 48px;
  width: auto;
  object-fit: contain;
  display: block;
}

.shell {
  max-width: 1200px;
  margin: 34px auto;
  padding: 0 24px;
  min-height: calc(100vh - 160px);
}

.auth-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.8fr;
  gap: 70px;
  align-items: center;
  min-height: 70vh;
}

.hero {
  padding: 24px 0;
}

.eyebrow {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.15em;
  color: #8c7853;
  text-transform: uppercase;
}

.eyebrow.blue,
.eyebrow.gold {
  color: var(--gold-dark);
}

h1 {
  font-size: clamp(32px, 4vw, 49px);
  line-height: 1.15;
  letter-spacing: -0.04em;
  margin: 15px 0;
}

/* Destaque dourado metálico no título */
h1 span {
  background: var(--gold-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
  filter: drop-shadow(0 1px 1px rgba(0,0,0,0.05));
}

h2 {
  font-size: 24px;
  letter-spacing: -0.025em;
  margin: 8px 0;
}

h3 {
  margin: 0 0 16px;
  font-size: 17px;
}

.hero p {
  max-width: 530px;
  font-size: 17px;
  line-height: 1.7;
  color: var(--muted);
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.hero-points span {
  background: var(--gold-soft);
  color: var(--gold-dark);
  border: 1px solid var(--gold-border);
  border-radius: 30px;
  padding: 9px 14px;
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(197, 155, 39, 0.08);
}

.panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.auth-card {
  padding: 34px;
  max-width: 440px;
  width: 100%;
  justify-self: end;
  border: 1px solid #ebd9a7;
  box-shadow: 0 16px 48px rgba(18, 19, 26, 0.09);
}

.auth-card h2 {
  margin-top: 12px;
}

.muted {
  color: var(--muted);
}

.auth-card > p {
  line-height: 1.5;
}

label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 12px;
  font-weight: 750;
  color: #3b3f4d;
  margin: 16px 0;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #dcd7cc;
  border-radius: 9px;
  padding: 12px 13px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  outline: none;
  transition: border 0.15s, box-shadow 0.15s;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(197, 155, 39, 0.2);
}

textarea {
  resize: vertical;
}

/* Botões com acabamento Dourado Nobre */
.btn {
  border: 0;
  border-radius: 9px;
  padding: 11px 16px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, #d4af37 0%, #e2be52 40%, #b8860b 100%);
  color: #0b0c10;
  box-shadow: 0 6px 18px rgba(197, 155, 39, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.25);
  letter-spacing: 0.01em;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #dfbc45 0%, #edd16e 40%, #c49216 100%);
  box-shadow: 0 8px 24px rgba(197, 155, 39, 0.45);
}

.btn-outline {
  background: white;
  border: 1px solid #dcd7cc;
  color: #343846;
}

.btn-outline:hover {
  border-color: var(--gold);
  color: var(--gold-dark);
}

.full {
  width: 100%;
  padding: 14px;
}

.message {
  min-height: 18px;
  font-size: 12px;
  color: #b42318;
}

.welcome {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}

.welcome h1 {
  font-size: 34px;
  margin: 8px 0;
}

.quick-actions {
  display: flex;
  gap: 10px;
}

/* Abas de Navegação */
.tabs {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 26px;
  overflow: auto;
}

.tab {
  background: none;
  border: 0;
  padding: 14px 18px;
  color: #636b79;
  white-space: nowrap;
  font-weight: 750;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  transition: color 0.15s, border-color 0.15s;
}

.tab:hover {
  color: var(--gold-dark);
}

.tab.active {
  color: var(--gold-dark);
  border-color: var(--gold);
}

/* Cartões de Estatísticas */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin: 20px 0 34px;
}

.stat-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px;
  display: flex;
  gap: 16px;
  align-items: center;
  box-shadow: 0 5px 20px rgba(18, 19, 26, 0.05);
}

.stat-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--gold-soft);
  color: var(--gold-dark);
  border: 1px solid var(--gold-border);
  font-size: 24px;
}

.blue-icon {
  background: #fbf5e6;
  color: var(--gold-hover);
  border-color: var(--gold-border);
}

.green-icon {
  background: #e6f7ef;
  color: var(--green);
  border-color: #bee8d4;
}

.stat-card strong {
  display: block;
  font-size: 27px;
  margin-top: 4px;
  color: #0b0c10;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 26px 0 14px;
}

.section-head h2 {
  font-size: 21px;
  margin: 0;
}

.section-head p {
  margin: 5px 0 0;
}

.search {
  max-width: 260px;
}

.table-wrap {
  overflow: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  white-space: nowrap;
  font-size: 12px;
}

.data-table th {
  text-align: left;
  background: #fbfaf7;
  color: #555b68;
  font-weight: 800;
  border-bottom: 2px solid var(--line);
}

.data-table th,
.data-table td {
  padding: 14px 15px;
  border-bottom: 1px solid var(--line);
}

.data-table tr:last-child td {
  border-bottom: 0;
}

/* Status com tons dourados e prateados */
.status {
  display: inline-block;
  border-radius: 30px;
  padding: 5px 10px;
  background: #f0ede6;
  color: #4a4d57;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.status-green {
  background: #e6f7ef;
  color: #108554;
  border: 1px solid #bee8d4;
}

.status-blue {
  background: var(--gold-soft);
  color: var(--gold-dark);
  border: 1px solid var(--gold-border);
}

.status-red {
  background: #feeceb;
  color: #b42318;
  border: 1px solid #f9cdcb;
}

/* Filtros por Categorias */
.chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 16px 0 20px;
}

.chip {
  border: 1px solid var(--line);
  background: white;
  border-radius: 24px;
  padding: 8px 14px;
  cursor: pointer;
  color: #4c5361;
  font-weight: 700;
  transition: all 0.15s ease;
}

.chip:hover {
  border-color: var(--gold);
  color: var(--gold-dark);
}

.chip.active {
  background: #0b0c10;
  color: #ecd37a;
  border-color: var(--gold);
  box-shadow: 0 4px 12px rgba(11, 12, 16, 0.25);
}

/* Grade de Produtos */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.product-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 6px 22px rgba(18, 19, 26, 0.05);
  transition: transform 0.2s, box-shadow 0.2s;
}

.product-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(18, 19, 26, 0.09);
  border-color: var(--gold-border);
}

.product-visual {
  height: 114px;
  background: linear-gradient(135deg, #fbf7ee 0%, #f6eee0 100%);
  display: grid;
  place-items: center;
  color: var(--gold-hover);
  font-size: 32px;
  border-bottom: 1px solid #f0e8d8;
}

.product-visual span {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  background: white;
  border-radius: 18px;
  border: 1px solid var(--gold-border);
  box-shadow: 0 8px 20px rgba(197, 155, 39, 0.18);
}

.product-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-body h3 {
  font-size: 15px;
  margin: 0 0 8px;
  color: #0b0c10;
}

.product-body p {
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
  margin: 0 0 15px;
  flex: 1;
}

.product-price {
  font-size: 18px;
  font-weight: 850;
  margin-bottom: 13px;
  color: #0b0c10;
}

.product-price small {
  font-size: 10px;
  color: var(--muted);
  font-weight: 600;
}

.product-body .btn {
  width: 100%;
}

.admin-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 18px;
}

.form-panel {
  padding: 22px;
  margin-bottom: 16px;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.customer-form {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 12px;
  align-items: end;
  padding: 20px;
}

.customer-form label {
  margin: 0;
}

.customer-form button {
  margin-bottom: 16px;
}

.admin-status {
  display: flex;
  gap: 6px;
}

.admin-status select {
  min-width: 150px;
  padding: 8px;
}

.notice {
  padding: 12px 16px;
  border-radius: 10px;
  background: var(--gold-soft);
  color: var(--gold-dark);
  border: 1px solid var(--gold-border);
  margin-bottom: 18px;
  font-weight: 600;
}

.dialog {
  border: 0;
  border-radius: 18px;
  padding: 0;
  width: min(560px, calc(100% - 28px));
  box-shadow: 0 25px 90px rgba(11, 12, 16, 0.55);
}

.dialog::backdrop {
  background: rgba(11, 12, 16, 0.78);
  backdrop-filter: blur(4px);
}

.dialog-content {
  padding: 28px;
  position: relative;
}

.dialog-content h2 {
  padding-right: 26px;
}

.close {
  position: absolute;
  right: 18px;
  top: 15px;
  background: #f0ede6;
  border: 0;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 22px;
  cursor: pointer;
  color: #3b3f4d;
  transition: background 0.15s;
}

.close:hover {
  background: #e2ded5;
}

.order-total {
  font-size: 19px;
  font-weight: 850;
  padding: 14px;
  background: var(--gold-soft);
  border: 1px solid var(--gold-border);
  color: #0b0c10;
  border-radius: 8px;
}

.small {
  font-size: 11px;
}

footer {
  max-width: 1200px;
  margin: auto;
  padding: 24px;
  display: flex;
  justify-content: space-between;
  color: #7b8392;
  font-size: 11px;
  border-top: 1px solid var(--line);
}

/* Componentes complementares */
.btn-whatsapp {
  background: #25d366;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-weight: 750;
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp:hover {
  background: #1ebc57;
  color: #ffffff;
}

.hero-contact-card {
  margin-top: 28px;
  padding: 20px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 6px 20px rgba(18, 19, 26, 0.05);
}

.hero-contact-card p {
  margin: 0 0 10px;
}

.btn-google {
  background: #ffffff;
  color: #3c4043;
  border: 1px solid #dcd7cc;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 600;
  font-size: 14px;
  box-shadow: 0 1px 3px rgba(60, 64, 67, 0.08);
  transition: background 0.15s, box-shadow 0.15s;
}

.btn-google:hover {
  background: #faf8f4;
  box-shadow: 0 2px 6px rgba(60, 64, 67, 0.15);
}

.divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 18px 0;
  color: #949aab;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.divider::before,
.divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid #e5e0d4;
}

.divider:not(:empty)::before {
  margin-right: 10px;
}

.divider:not(:empty)::after {
  margin-left: 10px;
}

.auth-gate-info {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: var(--gold-soft);
  border: 1px solid var(--gold-border);
  padding: 12px 14px;
  border-radius: 9px;
  margin-top: 16px;
  font-size: 12px;
  color: var(--gold-dark);
  line-height: 1.45;
}

.auth-gate-info .gate-icon {
  font-size: 15px;
  line-height: 1;
}

.auth-footer-toggle {
  margin-top: 16px;
  text-align: center;
  padding-top: 12px;
  border-top: 1px solid #f0ede6;
}

.btn-text-link {
  background: none;
  border: 0;
  color: var(--gold-dark);
  font-weight: 750;
  font-size: 12px;
  cursor: pointer;
  padding: 5px 10px;
  border-radius: 6px;
  transition: background 0.15s;
}

.btn-text-link:hover {
  background: var(--gold-soft);
  text-decoration: underline;
}

.catalog-specs {
  font-size: 12px;
  color: #646b7a;
  line-height: 1.4;
}

.price-tag {
  font-weight: 850;
  font-size: 15px;
  color: #0b0c10;
}

.price-quote {
  color: #8f6815;
  font-weight: 750;
  font-size: 12px;
  background: var(--gold-soft);
  border: 1px solid var(--gold-border);
  padding: 3px 8px;
  border-radius: 6px;
  display: inline-block;
}

@media (max-width: 900px) {
  .auth-layout {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 30px 0;
  }
  .hero {
    padding: 10px 0;
  }
  .auth-card {
    justify-self: stretch;
    max-width: none;
  }
  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .admin-grid {
    grid-template-columns: 1fr;
  }
  .customer-form {
    grid-template-columns: 1fr 1fr;
  }
  .customer-form button {
    margin-bottom: 0;
  }
}

@media (max-width: 620px) {
  .topbar {
    height: 66px;
    padding: 0 16px;
  }
  .brand {
    font-size: 11px;
  }
  .userbar {
    font-size: 11px;
  }
  .shell {
    padding: 0 14px;
    margin: 20px auto;
  }
  .auth-layout {
    min-height: auto;
  }
  .hero h1 {
    font-size: 35px;
  }
  .auth-card {
    padding: 23px;
  }
  .welcome {
    align-items: flex-start;
    flex-direction: column;
  }
  .welcome h1 {
    font-size: 29px;
  }
  .quick-actions {
    width: 100%;
    flex-wrap: wrap;
  }
  .stats {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .stat-card {
    padding: 15px;
  }
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .product-visual {
    height: 85px;
  }
  .product-body {
    padding: 12px;
  }
  .product-body h3 {
    font-size: 13px;
  }
  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }
  .search {
    max-width: none;
  }
  .customer-form {
    grid-template-columns: 1fr;
  }
  .tabs {
    margin-left: -14px;
    margin-right: -14px;
    padding: 0 10px;
  }
  .two-col {
    grid-template-columns: 1fr;
  }
  footer {
    padding: 20px 14px;
    gap: 12px;
    flex-direction: column;
  }
}
