/**
 * components.css — header, botões, cards de produto, filtros, modal,
 * comparador, orçamento (carrinho) e botão flutuante do WhatsApp.
 */

/* ---------------- HEADER ---------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--uvtek-surface-light);
  border-bottom: 1px solid var(--uvtek-border-light);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: var(--space-md);
}
.site-header .logo img { height: 30px; width: auto; }

.main-nav { display: flex; align-items: center; gap: var(--space-lg); }
.main-nav a {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--uvtek-text-primary);
  padding: 8px 4px;
  border-bottom: 2px solid transparent;
  transition: border-color 150ms ease, color 150ms ease;
}
.main-nav a:hover, .main-nav a.active { color: var(--uvtek-primary); border-color: var(--uvtek-primary); }

.header-actions { display: flex; align-items: center; gap: var(--space-sm); }
.budget-pill {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1.5px solid var(--uvtek-border-light);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  background: none;
  color: var(--uvtek-text-primary);
}
.budget-pill .count {
  background: var(--uvtek-primary);
  color: #fff;
  border-radius: 999px;
  min-width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  padding: 0 5px;
}

.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--uvtek-text-primary); margin: 5px 0; border-radius: 2px; }

/* ---------------- BOTÕES ---------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 13px 26px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease, background 150ms ease, filter 150ms ease;
  white-space: nowrap;
}
.btn:active { transform: scale(0.98); }
.btn-primary {
  background: linear-gradient(135deg, var(--uvtek-primary), var(--uvtek-secondary));
  color: #fff;
  box-shadow: var(--shadow-card);
}
.btn-primary:hover { box-shadow: var(--shadow-card-hover); filter: brightness(1.05); }
.btn-whatsapp {
  background: #25d366;
  color: #fff;
  box-shadow: var(--shadow-card);
}
.btn-whatsapp:hover { filter: brightness(1.08); }
.btn-secondary { background: var(--uvtek-surface-light); color: var(--uvtek-primary); border: 1.5px solid var(--uvtek-primary); }
.btn-secondary:hover { background: rgba(94,49,255,0.08); }
.btn-ghost { background: transparent; color: var(--uvtek-text-primary); border: 1.5px solid var(--uvtek-border-light); }
.btn-ghost:hover { border-color: var(--uvtek-primary); color: var(--uvtek-primary); }
.btn-sm { padding: 9px 16px; font-size: 0.85rem; border-radius: 12px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-group { display: flex; flex-wrap: wrap; gap: var(--space-sm); }

/* ---------------- HERO ---------------- */
.hero {
  background: radial-gradient(circle at top right, var(--uvtek-violet-deep), var(--uvtek-background-dark) 70%);
  color: var(--uvtek-text-light);
  padding: var(--space-2xl) 0;
}
.hero .container { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: var(--space-xl); align-items: center; }
.hero-eyebrow {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--uvtek-violet-light);
  margin-bottom: var(--space-sm);
}
.hero h1 { color: #fff; }
.hero p.lead { color: #d6d3e8; font-size: 1.05rem; max-width: 480px; }
.hero-visual {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  height: 320px;
}
.hero-visual img { max-height: 280px; max-width: 100%; object-fit: contain; }

/* ---------------- BARRA INFORMATIVA ---------------- */
.info-bar {
  background: var(--uvtek-surface-light);
  border-bottom: 1px solid var(--uvtek-border-light);
}
.info-bar .container {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-lg);
  justify-content: center;
  padding: 14px 0;
  font-size: 0.85rem;
  font-family: var(--font-display);
  font-weight: 500;
}
.info-bar span { display: flex; align-items: center; gap: 6px; color: var(--uvtek-text-muted); }

/* ---------------- ATALHOS DE CATEGORIA ---------------- */
.category-shortcuts { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-md); }
.category-card {
  background: var(--uvtek-surface-light);
  border: 1px solid var(--uvtek-border-light);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  text-align: center;
  box-shadow: var(--shadow-card);
  transition: transform 150ms ease, box-shadow 150ms ease;
}
.category-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-card-hover); }
.category-card h3 { margin-bottom: 4px; }
.category-card p { color: var(--uvtek-text-muted); font-size: 0.88rem; margin: 0; }

/* ---------------- CARDS DE PRODUTO ---------------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: var(--space-md);
}
.product-card {
  background: var(--uvtek-surface-light);
  border: 1px solid var(--uvtek-border-light);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: box-shadow 150ms ease, transform 150ms ease;
}
.product-card:hover { box-shadow: var(--shadow-card-hover); transform: translateY(-2px); }
.product-card-image {
  aspect-ratio: 1 / 1;
  background: var(--uvtek-background-light);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  overflow: hidden;
  position: relative;
}
.sold-out-ribbon {
  position: absolute;
  top: 14px;
  left: -38px;
  width: 150px;
  padding: 5px 0;
  background: #ffffff;
  color: #17171d;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: rotate(-45deg);
  transform-origin: center;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.1em;
  font-size: 0.72rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.35);
  pointer-events: none;
  z-index: 2;
}

.seller-notice {
  background: var(--uvtek-surface-light);
  border: 1px solid var(--uvtek-border-light);
  border-left: 4px solid var(--uvtek-primary);
  border-radius: var(--radius-sm);
  padding: 12px 18px;
  font-size: 0.88rem;
  margin-bottom: var(--space-lg);
}
.product-card-image img { width: 100%; height: 100%; object-fit: contain; padding: var(--space-sm); }
.product-card-line { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--uvtek-text-muted); font-weight: 600; }
.product-card-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
}
.product-card-title:hover { color: var(--uvtek-primary); }
.product-card-meta { font-size: 0.82rem; color: var(--uvtek-text-muted); }
.product-card-colors { font-size: 0.78rem; color: var(--uvtek-text-muted); }
.product-card-price { font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; color: var(--uvtek-primary); margin-top: 4px; }
.product-card-badge {
  align-self: flex-start;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: #ece5ff;
  color: var(--uvtek-primary);
}
.product-card-actions { display: flex; gap: 8px; margin-top: 6px; }
.product-card-actions .btn { flex: 1; }

/* ---------------- FILTROS ---------------- */
.filters-toggle-mobile { display: none; }
.filters-bar {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
  align-items: center;
}
.filters-bar input[type="search"],
.filters-bar select {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--uvtek-border-light);
  background: var(--uvtek-surface-light);
  color: var(--uvtek-text-primary);
  font-family: var(--font-body);
}

/* ---------------- COMPARADOR ---------------- */
.comparator-table-wrap { overflow-x: auto; }
.comparator-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
  background: var(--uvtek-surface-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.comparator-table th, .comparator-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--uvtek-border-light);
  text-align: left;
  font-size: 0.88rem;
  vertical-align: top;
}
.comparator-table th { font-family: var(--font-display); background: var(--uvtek-background-light); }
.comparator-table td:first-child, .comparator-table th:first-child { font-weight: 600; font-family: var(--font-display); }

/* ---------------- MODAL DE PRODUTO ---------------- */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(10, 8, 20, 0.7);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 24px 16px;
  overflow-y: auto;
  z-index: 200;
}
.product-modal {
  background: var(--uvtek-surface-light);
  border-radius: var(--radius-lg);
  max-width: 900px;
  width: 100%;
  padding: var(--space-lg);
  position: relative;
  margin: auto 0;
}
.modal-close {
  position: absolute;
  top: 16px; right: 16px;
  background: var(--uvtek-background-light);
  border: none;
  width: 36px; height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  color: var(--uvtek-text-primary);
}
.modal-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: var(--space-lg); align-items: start; }
.modal-image-col { display: flex; flex-direction: column; gap: var(--space-md); }
.modal-image {
  background: var(--uvtek-background-light);
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  min-height: 280px;
  padding: var(--space-md);
  position: relative;
  overflow: hidden;
}
.modal-image img { max-width: 100%; max-height: 320px; object-fit: contain; }
.modal-badge { display: inline-block; margin-bottom: 8px; }
.modal-price { font-family: var(--font-display); font-weight: 700; font-size: 1.6rem; color: var(--uvtek-primary); margin: 8px 0; }
.modal-section { margin-top: var(--space-md); }
.modal-section h4 { font-family: var(--font-display); margin-bottom: 6px; font-size: 0.95rem; }
.modal-section ul { padding-left: 18px; margin: 0; }
.modal-section li { margin-bottom: 4px; font-size: 0.9rem; }

details.modal-expand { border-top: 1px solid var(--uvtek-border-light); padding-top: 10px; margin-top: 10px; }
details.modal-expand summary {
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9rem;
  list-style: none;
}
details.modal-expand summary::-webkit-details-marker { display: none; }
details.modal-expand summary::after { content: " ▾"; }
details.modal-expand[open] summary::after { content: " ▴"; }

.selector-row { display: flex; flex-direction: column; gap: 4px; margin-top: var(--space-sm); }
.selector-row label { font-size: 0.8rem; font-weight: 600; color: var(--uvtek-text-muted); }
.selector-row select, .qty-input {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--uvtek-border-light);
  background: var(--uvtek-background-light);
  color: var(--uvtek-text-primary);
}
.qty-row { display: flex; align-items: center; gap: 8px; }
.qty-btn {
  width: 34px; height: 34px;
  border-radius: 8px;
  border: 1px solid var(--uvtek-border-light);
  background: var(--uvtek-background-light);
  cursor: pointer;
  font-size: 1rem;
  color: var(--uvtek-text-primary);
}
.qty-input { width: 56px; text-align: center; }

/* ---------------- SELETOR DE CORES ---------------- */
.color-selector-block {
  background: var(--uvtek-background-light);
  border: 1px solid var(--uvtek-border-light);
  border-radius: var(--radius-md);
  padding: var(--space-md);
}
.color-selector-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 10px;
}
.color-swatch-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 8px;
}
.color-swatch-wrap { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.color-swatch {
  position: relative;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 2px solid var(--uvtek-border-light);
  background-size: cover;
  background-position: center;
  cursor: pointer;
  padding: 0;
  transition: transform 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
  flex-shrink: 0;
}
.color-swatch:hover { transform: scale(1.06); }
.color-swatch:focus-visible { outline: 3px solid var(--uvtek-primary); outline-offset: 2px; }
.color-swatch.is-selected {
  border-color: var(--uvtek-primary);
  box-shadow: 0 0 0 3px rgba(94,49,255,0.25);
  transform: scale(1.1);
}
.color-swatch-check {
  position: absolute;
  bottom: -3px; right: -3px;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--uvtek-primary);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.6rem;
  border: 2px solid var(--uvtek-surface-light);
}
.color-swatch.is-translucent {
  background-image:
    linear-gradient(45deg, #3a3846 25%, transparent 25%),
    linear-gradient(-45deg, #3a3846 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #3a3846 75%),
    linear-gradient(-45deg, transparent 75%, #3a3846 75%);
  background-size: 10px 10px;
  background-position: 0 0, 0 5px, 5px -5px, -5px 0px;
}
.color-swatch.is-translucent::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: var(--swatch-color, rgba(220,220,220,0.55));
  border: 1px solid rgba(255,255,255,0.4);
}
.color-swatch-name {
  font-size: 0.72rem;
  color: var(--uvtek-text-muted);
  text-align: center;
  max-width: 60px;
}
.color-swatch-wrap.is-selected .color-swatch-name {
  color: var(--uvtek-primary);
  font-weight: 700;
}
.color-selected-label {
  font-size: 0.85rem;
  margin-bottom: var(--space-sm);
}
.color-selected-label strong { color: var(--uvtek-primary); }

/* ---------------- GALERIA DE IMPRESSÕES ---------------- */
.print-gallery { margin-top: var(--space-sm); }
.print-gallery-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 8px;
}
.print-gallery-main {
  position: relative;
  background: var(--uvtek-background-light);
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  display: flex; align-items: center; justify-content: center;
  cursor: zoom-in;
}
.print-gallery-main img { width: 100%; height: 100%; object-fit: contain; }
.print-gallery-arrow {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  width: 34px; height: 34px;
  border-radius: 50%;
  border: none;
  background: rgba(23,23,29,0.55);
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.print-gallery-arrow.prev { left: 8px; }
.print-gallery-arrow.next { right: 8px; }
.print-gallery-thumbs { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.print-gallery-thumb {
  width: 52px; height: 52px;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid transparent;
  padding: 0;
  cursor: pointer;
  background: var(--uvtek-background-light);
}
.print-gallery-thumb.is-active { border-color: var(--uvtek-primary); }
.print-gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }

.lightbox-backdrop {
  position: fixed; inset: 0;
  background: rgba(10,8,20,0.9);
  z-index: 300;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
}
.lightbox-backdrop img { max-width: 100%; max-height: 100%; object-fit: contain; }
.lightbox-close {
  position: absolute; top: 20px; right: 20px;
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  color: #fff;
  border: none;
  font-size: 1.3rem;
  cursor: pointer;
}

.notice-box {
  background: #2a2410;
  border: 1px solid #574a1a;
  border-radius: var(--radius-md);
  padding: var(--space-md);
  color: #ffd77a;
  font-size: 0.85rem;
}

/* ---------------- ORÇAMENTO (painel/carrinho) ---------------- */
.budget-panel-backdrop {
  position: fixed; inset: 0;
  background: rgba(10,8,20,0.6);
  z-index: 250;
  display: flex; justify-content: flex-end;
}
.budget-panel {
  background: var(--uvtek-surface-light);
  width: 100%;
  max-width: 440px;
  height: 100%;
  padding: var(--space-lg);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}
.budget-panel-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: var(--space-md); }
.budget-item {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--uvtek-border-light);
}
.budget-item img { width: 56px; height: 56px; object-fit: contain; background: var(--uvtek-background-light); border-radius: 8px; }
.budget-item-name { font-family: var(--font-display); font-weight: 600; font-size: 0.9rem; }
.budget-item-meta { font-size: 0.78rem; color: var(--uvtek-text-muted); }
.budget-item-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.budget-item-remove { background: none; border: none; color: var(--uvtek-error); cursor: pointer; font-size: 0.78rem; }
.budget-summary { margin-top: var(--space-md); border-top: 1px solid var(--uvtek-border-light); padding-top: var(--space-md); }
.budget-summary-row { display: flex; justify-content: space-between; margin-bottom: 6px; font-size: 0.9rem; }
.budget-summary-row.total { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; color: var(--uvtek-primary); }
.budget-empty { text-align: center; color: var(--uvtek-text-muted); padding: var(--space-2xl) 0; }

/* ---------------- WHATSAPP FLUTUANTE ---------------- */
.whatsapp-float {
  position: fixed;
  bottom: 20px; right: 20px;
  width: 58px; height: 58px;
  border-radius: 50%;
  background: #25d366;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-elevated);
  cursor: pointer;
  z-index: 150;
  border: none;
}
.whatsapp-float svg { width: 30px; height: 30px; }

/* ---------------- RODAPÉ ---------------- */
.site-footer { background: var(--uvtek-background-dark); color: #cfcbe0; padding: var(--space-xl) 0 var(--space-lg); }
.site-footer .logo img { height: 26px; margin-bottom: var(--space-sm); }
.site-footer a { color: #cfcbe0; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: var(--space-lg); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.08); margin-top: var(--space-lg); padding-top: var(--space-md); font-size: 0.8rem; color: #86829c; }

/* ---------------- ESTADOS ---------------- */
.empty-state, .loading-state { text-align: center; padding: var(--space-2xl) var(--space-md); color: var(--uvtek-text-muted); }
.img-placeholder {
  display: flex; align-items: center; justify-content: center;
  background: var(--uvtek-background-light); color: var(--uvtek-text-muted);
  font-size: 0.8rem; text-align: center; height: 100%; width: 100%; border-radius: var(--radius-sm);
}
.toast {
  position: fixed; bottom: 90px; left: 50%; transform: translateX(-50%);
  background: var(--uvtek-text-primary); color: #17171d;
  padding: 12px 22px; border-radius: var(--radius-sm); font-size: 0.9rem; z-index: 999;
  box-shadow: var(--shadow-elevated);
}
