/* ═══════════════════════════════════════════════════════════════
   B2C Styles — Auth, Favorites, Compare, Dashboard, Comparator
   Klovani — consistent with variables.css design tokens
   ═══════════════════════════════════════════════════════════════ */

/* ─── Global Focus Ring (accessibility) ─── */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 2px;
}

/* ─── Auth Modal Overlay ─── */
.b2c-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity var(--transition-normal);
}
.b2c-modal-overlay.visible {
  opacity: 1;
}

.b2c-modal {
  position: relative;
  width: 100%;
  max-width: 420px;
  background: var(--bg-surface, #fff);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.18);
  transform: translateY(12px) scale(0.97);
  transition: transform var(--transition-normal);
}
.b2c-modal-overlay.visible .b2c-modal {
  transform: translateY(0) scale(1);
}

.b2c-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-secondary);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition-fast), border-color var(--transition-fast);
  line-height: 1;
}
.b2c-modal-close:hover {
  background: var(--bg-surface-2);
  border-color: var(--border-hover);
}

.b2c-modal-title {
  font-family: var(--font-display, var(--fd, 'Chillax','Outfit',sans-serif));
  font-weight: 500;
  font-size: 20px;
  color: var(--text);
  margin: 0 0 24px 0;
}

/* ─── Modal Tabs ─── */
.b2c-modal-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.b2c-modal-tab {
  flex: 1;
  padding: 10px 0;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: color var(--transition-fast), border-color var(--transition-fast);
  text-align: center;
  letter-spacing: 0.02em;
}
.b2c-modal-tab:hover {
  color: var(--text);
}
.b2c-modal-tab.active {
  color: var(--text);
  border-bottom-color: var(--accent);
}

/* ─── Form Elements ─── */
.b2c-form-group {
  margin-bottom: 16px;
}

.b2c-label {
  display: block;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}

.b2c-input {
  width: 100%;
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
  color: var(--text);
  background: var(--bg-surface);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  outline: none;
  box-sizing: border-box;
}
.b2c-input::placeholder {
  color: var(--text-muted);
}
.b2c-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.b2c-submit {
  width: 100%;
  background: var(--accent);
  color: var(--accent-text);
  border: none;
  border-radius: var(--radius-full);
  padding: 12px;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition-fast), opacity var(--transition-fast);
  letter-spacing: 0.01em;
  margin-top: 8px;
}
.b2c-submit:hover {
  background: var(--accent-hover);
}
.b2c-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.b2c-submit:disabled .b2c-spinner {
  display: inline-block;
}

.b2c-error {
  color: var(--red);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  margin-top: 8px;
  min-height: 18px;
}

.b2c-link {
  color: var(--accent);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  text-decoration: none;
  transition: opacity var(--transition-fast);
}
.b2c-link:hover {
  opacity: 0.75;
}

.b2c-form-footer {
  display: flex;
  justify-content: center;
  margin-top: 16px;
}

/* ─── Spinner ─── */
.b2c-spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: b2cSpin 0.6s linear infinite;
  vertical-align: middle;
  margin-right: 6px;
}
@keyframes b2cSpin {
  to { transform: rotate(360deg); }
}

/* ─── Header Auth UI ─── */
.b2c-header-auth {
  display: flex;
  align-items: center;
  gap: 8px;
}

.b2c-login-btn {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  background: none;
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-full);
  padding: 8px 16px;
  cursor: pointer;
  transition: border-color var(--transition-fast), color var(--transition-fast);
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.b2c-login-btn svg { opacity: 0.85 }
.b2c-login-btn:hover {
  border-color: var(--accent-border);
  color: var(--text);
}

.b2c-user-menu {
  position: relative;
}

.b2c-user-trigger {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  padding: 4px;
  border-radius: var(--radius-full);
  border: none;
  background: none;
  transition: background var(--transition-fast);
}
.b2c-user-trigger:hover {
  background: var(--accent-dim);
}

.b2c-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-text);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 11px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  letter-spacing: 0.02em;
}

.b2c-user-name {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

.b2c-user-chevron {
  width: 14px;
  height: 14px;
  stroke: var(--text-muted);
  stroke-width: 2;
  fill: none;
  transition: transform var(--transition-fast);
}
.b2c-user-menu.open .b2c-user-chevron {
  transform: rotate(180deg);
}

.b2c-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.10);
  min-width: 200px;
  z-index: 100;
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  transition: opacity var(--transition-fast), transform var(--transition-fast);
}
.b2c-dropdown.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Selectores escopados ao .b2c-dropdown — sobe a especificidade para 0,2,0
   e ganha contra regras genéricas tipo `.header__nav a` (0,1,1) que
   aplicariam border-radius:999px / padding diferente aos <a> do dropdown. */
.b2c-dropdown .b2c-dropdown-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  font-weight: 400;
  line-height: 1.2;
  color: var(--text-secondary);
  background: none;
  border: none;
  border-radius: 0;
  width: 100%;
  height: auto;
  text-align: left;
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
  text-decoration: none;
  box-sizing: border-box;
}
.b2c-dropdown .b2c-dropdown-item:first-child {
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}
.b2c-dropdown .b2c-dropdown-item:last-child {
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}
.b2c-dropdown .b2c-dropdown-item:hover {
  background: var(--bg-surface-2);
  color: var(--text);
}
.b2c-dropdown .b2c-dropdown-item svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
  flex-shrink: 0;
}

.b2c-dropdown-sep {
  height: 1px;
  background: var(--border);
  margin: 4px 16px;
}

/* ─── White variant — for dark headers (e.g. /index.html hero nav) ─── */
.b2c-header-auth--white .b2c-login-btn {
  color: rgba(255,255,255,0.92);
  border-color: rgba(255,255,255,0.30);
  background: transparent;
}
.b2c-header-auth--white .b2c-login-btn:hover {
  border-color: #fff;
  color: #fff;
}
.b2c-header-auth--white .b2c-user-trigger:hover {
  background: rgba(255,255,255,0.10);
}
.b2c-header-auth--white .b2c-user-name {
  color: #fff;
  font-weight: 500;
}
.b2c-header-auth--white .b2c-user-chevron {
  stroke: rgba(255,255,255,0.85);
}
.b2c-header-auth--white .b2c-avatar {
  background: rgba(255,255,255,0.20);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.30);
}
/* Hide user name on small screens to keep nav tight */
@media(max-width:560px){
  .b2c-user-name { display: none; }
}

/* ─── Heart / Favorite Button ─── */
.b2c-heart-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition-fast), transform var(--transition-fast);
  padding: 0;
}
.b2c-heart-btn:hover {
  background: #fff;
  transform: scale(1.1);
}
.b2c-heart-btn svg {
  transition: fill 0.2s ease, stroke 0.2s ease;
}
.b2c-heart-btn.active svg {
  fill: var(--red);
  stroke: var(--red);
}

/* ─── Compare Button ─── */
.b2c-compare-btn {
  padding: 8px 16px;
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-full);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  font-weight: 500;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: border-color var(--transition-fast), color var(--transition-fast), background var(--transition-fast);
  white-space: nowrap;
}
.b2c-compare-btn:hover {
  border-color: var(--accent-border);
  color: var(--accent);
}
.b2c-compare-btn.active {
  border-color: var(--accent);
  color: var(--accent-text);
  background: var(--accent);
}

/* ─── Toast ─── */
.b2c-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--text);
  color: #fff;
  padding: 12px 24px;
  border-radius: var(--radius-full);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  font-weight: 500;
  opacity: 0;
  transition: opacity var(--transition-normal), transform var(--transition-normal);
  z-index: 300;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  pointer-events: none;
  white-space: nowrap;
}
.b2c-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ─── Badge ─── */
.b2c-badge {
  min-width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--red);
  color: #fff;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 10px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: -4px;
  right: -4px;
  padding: 0 4px;
  line-height: 1;
}

/* ─── Save Search Button ─── */
.b2c-save-search-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-full);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  font-weight: 500;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: border-color var(--transition-fast), color var(--transition-fast);
  white-space: nowrap;
}
.b2c-save-search-btn svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
}
.b2c-save-search-btn:hover {
  border-color: var(--accent-border);
  color: var(--accent);
}
.b2c-save-search-btn.saved {
  border-color: var(--accent-border);
  color: var(--accent);
}

/* ─── Price Alert ─── */
.b2c-alert-setup {
  display: flex;
  align-items: center;
  gap: 12px;
}

.b2c-alert-input {
  width: 110px;
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
  color: var(--text);
  background: var(--bg-surface);
  outline: none;
  transition: border-color var(--transition-fast);
  box-sizing: border-box;
}
.b2c-alert-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

/* ═══════════════════════════════════════════════════════════════
   Dashboard (conta.html)
   ═══════════════════════════════════════════════════════════════ */
.b2c-dashboard {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-lg);
}

.b2c-dashboard-header {
  margin-bottom: var(--space-xl);
}
.b2c-dashboard-header h1 {
  font-family: var(--font-display, var(--fd, 'Chillax','Outfit',sans-serif));
  font-weight: 500;
  font-size: 24px;
  color: var(--text);
  margin: 0 0 4px 0;
}
.b2c-dashboard-header p {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
}

.b2c-section {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  padding: var(--space-lg);
  margin-bottom: 20px;
}

.b2c-section-title {
  font-family: var(--font-display, var(--fd, 'Chillax','Outfit',sans-serif));
  font-weight: 500;
  font-size: 18px;
  color: var(--text);
  margin: 0 0 var(--space-md) 0;
}

.b2c-section-subtitle {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  color: var(--text-muted);
  margin: -8px 0 var(--space-md) 0;
}

/* ─── Favorite Cards ─── */
.b2c-fav-card {
  display: flex;
  gap: var(--space-md);
  padding: var(--space-md);
  border-bottom: 1px solid var(--border);
  align-items: center;
}
.b2c-fav-card:last-child {
  border-bottom: none;
}

.b2c-fav-img {
  width: 120px;
  height: 80px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  flex-shrink: 0;
  background: var(--bg-surface-2);
}

.b2c-fav-info {
  flex: 1;
  min-width: 0;
}

.b2c-fav-title {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-weight: 500;
  font-size: 14px;
  color: var(--text);
  margin: 0 0 4px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.b2c-fav-meta {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  color: var(--text-muted);
  margin: 0 0 6px 0;
}

.b2c-fav-price {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-weight: 600;
  font-size: 16px;
  color: var(--text);
  margin: 0;
}

.b2c-price-drop {
  color: var(--green);
  font-size: 12px;
  font-weight: 500;
}

.b2c-price-up {
  color: var(--red);
  font-size: 12px;
  font-weight: 500;
}

.b2c-fav-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.b2c-fav-remove {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
}
.b2c-fav-remove:hover {
  background: var(--red-dim);
  border-color: var(--red);
  color: var(--red);
}
.b2c-fav-remove svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

/* ─── Saved Search Cards ─── */
.b2c-search-card {
  padding: var(--space-md);
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.b2c-search-card:last-child {
  border-bottom: none;
}

.b2c-search-info {
  flex: 1;
  min-width: 0;
}

.b2c-search-title {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-weight: 500;
  font-size: 14px;
  color: var(--text);
  margin: 0 0 4px 0;
}

.b2c-search-params {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  color: var(--text-muted);
  margin: 0;
}

.b2c-search-count {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  color: var(--accent);
  font-weight: 500;
  white-space: nowrap;
  margin-left: var(--space-md);
}

/* ─── Empty State ─── */
.b2c-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
  min-height: 300px;
}
.b2c-empty h2 {
  font-family: var(--font-display, var(--fd, 'Chillax','Outfit',sans-serif));
  font-weight: 500;
  font-size: 20px;
  color: var(--text);
  margin: 0 0 8px 0;
}
.b2c-empty p {
  margin: 0 0 4px 0;
  max-width: 400px;
}
.b2c-empty svg {
  width: 48px;
  height: 48px;
  stroke: var(--border-hover);
  stroke-width: 1;
  fill: none;
  margin-bottom: 16px;
}
.b2c-empty-inline {
  text-align: center;
  padding: 24px 16px;
  color: var(--text-muted);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
}

/* ─── Loading State ─── */
.b2c-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
  gap: 12px;
  color: var(--text-muted);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
}
.b2c-loading p {
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════════
   Comparator (comparar.html)
   ═══════════════════════════════════════════════════════════════ */
.b2c-comparator {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-lg);
}

.b2c-comparator-header {
  margin-bottom: var(--space-xl);
}
.b2c-comparator-header h1 {
  font-family: var(--font-display, var(--fd, 'Chillax','Outfit',sans-serif));
  font-weight: 500;
  font-size: 24px;
  color: var(--text);
  margin: 0 0 4px 0;
}
.b2c-comparator-header p {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
}

.b2c-compare-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: var(--space-xl);
}

.b2c-compare-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  position: relative;
}

.b2c-compare-card-img {
  width: 100%;
  aspect-ratio: 16 / 10;
  height: auto;
  max-height: 200px;
  object-fit: cover;
  background: var(--bg-surface-2);
  display: block;
}

.b2c-compare-card-body {
  padding: 10px var(--space-md);
}

.b2c-compare-card-title {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-weight: 500;
  font-size: 13px;
  color: var(--text);
  margin: 0 0 2px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.b2c-compare-card-price {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-weight: 600;
  font-size: 15px;
  color: var(--text);
  margin: 0 0 8px 0;
}

.b2c-compare-card-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: background var(--transition-fast), color var(--transition-fast);
}
.b2c-compare-card-remove:hover {
  background: #fff;
  color: var(--red);
}
.b2c-compare-card-remove svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.b2c-compare-add-slot {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 2px dashed var(--border-hover);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 280px;
  cursor: pointer;
  color: var(--text-muted);
  transition: border-color var(--transition-fast), color var(--transition-fast);
}
.b2c-compare-add-slot:hover {
  border-color: var(--accent-border);
  color: var(--accent);
}
.b2c-compare-add-slot svg {
  width: 32px;
  height: 32px;
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
  margin-bottom: 8px;
}
.b2c-compare-add-slot span {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  font-weight: 500;
}

/* ─── Comparison Table ─── */
.b2c-compare-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.b2c-compare-table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  margin-top: var(--space-lg);
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
}

.b2c-compare-table th {
  text-align: left;
  padding: 10px 16px;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
  border-bottom: 1px solid var(--border);
  background: var(--bg-surface-2);
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.b2c-compare-table td {
  padding: 10px 16px;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
  color: var(--text);
  border-bottom: 1px solid var(--border);
}

.b2c-compare-table tr:last-child td {
  border-bottom: none;
}

.b2c-compare-table .b2c-compare-best {
  color: var(--green);
  font-weight: 600;
}

.b2c-compare-table .b2c-compare-worst {
  color: var(--text-muted);
}

/* ─── Buttons ─── */
.b2c-btn-sm {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
  border: 1px solid var(--border-hover);
  background: transparent;
  color: var(--text-secondary);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}
.b2c-btn-sm:hover {
  border-color: var(--accent-border);
  color: var(--accent);
}
.b2c-btn-sm--ghost {
  border-color: transparent;
  color: var(--text-muted);
}
.b2c-btn-sm--ghost:hover {
  color: var(--red);
  border-color: transparent;
}

.b2c-btn-outline {
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid var(--border-hover);
  background: transparent;
  color: var(--text-secondary);
  transition: border-color var(--transition-fast), color var(--transition-fast);
}
.b2c-btn-outline:hover {
  border-color: var(--text);
  color: var(--text);
}

.b2c-btn-danger {
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid var(--red);
  background: transparent;
  color: var(--red);
  transition: background var(--transition-fast), color var(--transition-fast);
}
.b2c-btn-danger:hover {
  background: var(--red);
  color: #fff;
}

/* ─── Section Extras ─── */
.b2c-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-md);
}
.b2c-section-header .b2c-section-title {
  margin: 0;
}
.b2c-section-count {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-surface-2);
  padding: 2px 10px;
  border-radius: var(--radius-full);
}

.b2c-section--danger {
  border-color: rgba(220, 38, 38, 0.2);
}

.b2c-text-muted {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 13px;
  color: var(--text-muted);
  margin: 0 0 12px 0;
}

/* ─── Profile Form ─── */
.b2c-profile-form {
  max-width: 600px;
}
.b2c-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.b2c-form-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
}

/* ─── Stats Row ─── */
.b2c-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: var(--space-xl);
}

/* ─── Page Title ─── */
.b2c-page-title {
  font-family: var(--font-display, var(--fd, 'Chillax','Outfit',sans-serif));
  font-weight: 500;
  font-size: 24px;
  color: var(--text);
  margin: 0 0 4px 0;
}
.b2c-page-subtitle {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
}

/* ─── Favorite Extras ─── */
.b2c-fav-list {
  display: flex;
  flex-direction: column;
}
.b2c-fav-price-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.b2c-unavailable {
  display: inline-block;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 11px;
  font-weight: 500;
  color: var(--red);
  background: rgba(220, 38, 38, 0.08);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-top: 4px;
}

/* ─── Search Card Extras ─── */
.b2c-search-name {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-weight: 500;
  font-size: 14px;
  color: var(--text);
  margin: 0 0 4px 0;
}
.b2c-search-desc {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  color: var(--text-muted);
  margin: 0;
}
.b2c-search-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

/* ─── Alert Card ─── */
.b2c-alert-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md);
  border-bottom: 1px solid var(--border);
}
.b2c-alert-card:last-child {
  border-bottom: none;
}
.b2c-alert-info {
  flex: 1;
  min-width: 0;
}
.b2c-alert-title {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-weight: 500;
  font-size: 14px;
  color: var(--text);
  margin: 0 0 4px 0;
}
.b2c-alert-type {
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 12px;
  color: var(--text-muted);
  margin: 0 0 4px 0;
}
.b2c-alert-triggered {
  display: inline-block;
  font-family: var(--font-body, var(--fb, 'Satoshi','Inter',sans-serif));
  font-size: 11px;
  font-weight: 500;
  color: var(--green);
  background: rgba(22, 163, 74, 0.08);
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

/* ─── Compare Actions ─── */
.b2c-compare-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: var(--space-lg) 0;
}

/* ─── Compare Label ─── */
.b2c-compare-label {
  font-weight: 500;
  color: var(--text-secondary);
  white-space: nowrap;
}

/* ═══════════════════════════════════════════════════════════════
   Responsive — Mobile
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  /* Modal: full-screen on mobile */
  .b2c-modal {
    max-width: 100%;
    min-height: 100vh;
    border-radius: 0;
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
  }
  .b2c-modal-overlay {
    align-items: stretch;
  }

  /* Heart button: larger touch target */
  .b2c-heart-btn {
    width: 40px;
    height: 40px;
  }

  /* Dashboard: tighter spacing */
  .b2c-dashboard {
    padding: var(--space-lg) var(--space-md);
  }

  /* Fav cards: stack */
  .b2c-fav-card {
    flex-direction: column;
    align-items: stretch;
  }
  .b2c-fav-img {
    width: 100%;
    height: 140px;
  }

  /* Comparator */
  .b2c-comparator {
    padding: var(--space-lg) var(--space-md);
  }
  .b2c-compare-grid {
    grid-template-columns: 1fr;
  }

  /* Form row stack */
  .b2c-form-row {
    grid-template-columns: 1fr;
  }

  /* Stats row stack */
  .b2c-stats-row {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  /* Compare actions stack */
  .b2c-compare-actions {
    flex-direction: column;
  }

  /* User dropdown — abre por baixo do avatar.
     NÃO usar position:fixed aqui: o .header tem backdrop-filter, o que o torna
     o containing block de qualquer descendente fixed → o menu ficava preso ao
     header e cortado no topo. position:absolute ancora ao .b2c-user-menu
     (position:relative) e cai por baixo do avatar, sem corte. */
  .b2c-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    left: auto;
    bottom: auto;
    min-width: 200px;
    max-width: calc(100vw - 32px);
    border-radius: var(--radius-lg);
  }
}

@media (max-width: 768px) {
  .b2c-compare-table-wrap {
    margin: 0 -16px;
    padding: 0 16px;
  }

  .b2c-user-name {
    display: none;
  }

  .b2c-dashboard-header h1 {
    font-size: 20px;
  }

  .b2c-comparator-header h1 {
    font-size: 20px;
  }

  /* Universal mobile fixes consolidated from per-page audits.
     These had been worked-around inline in many HTMLs — now central. */

  /* iOS zoom guard: input < 16px makes Safari zoom on focus.
     .b2c-input was 14px; bump on mobile only so desktop density survives. */
  .b2c-input {
    font-size: 16px;
    min-height: 44px;
  }

  /* .b2c-form-row was only collapsing at 480px — leaves 2-col grid
     crammed between 481 and 768 (typical tablet portrait + landscape phone). */
  .b2c-form-row {
    grid-template-columns: 1fr;
  }

  /* .b2c-form-actions row stacks on tablet+phone; buttons full-width touch. */
  .b2c-form-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }
  .b2c-form-actions .b2c-btn,
  .b2c-form-actions button {
    width: 100%;
    min-height: 48px;
  }

  /* Empty state was 300px min-height — pushes CTA off-screen on phones.
     Tighter padding + auto min-height. */
  .b2c-empty {
    min-height: auto;
    padding: 48px 20px;
  }
  .b2c-empty h2 { font-size: 18px; }
  .b2c-empty svg { width: 40px; height: 40px; margin-bottom: 12px; }

  /* Compare actions stacked on tablet too (was only 480px). */
  .b2c-compare-actions {
    flex-direction: column;
    width: 100%;
    gap: 10px;
  }
  .b2c-compare-actions > * {
    width: 100%;
    min-height: 44px;
  }
}

@media (min-width: 481px) and (max-width: 768px) {
  .b2c-compare-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  /* .b2c-stats-row was 3-col down to 480px — cramped 481–768.
     Scoped to 481–768 so the ≤480px rule (1-col) above is left intact. */
  .b2c-stats-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ─── Navigation Overlay ─── */
.nav-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

body.menu-open {
  overflow: hidden;
}

/* ──────────────────────────────────────────────────────────
   QA W2.C1 — Mobile 375px touch-target fixes (Apple HIG ≥44px)
   ────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  /* Home hero icons */
  .hv2-icon {
    min-width: 44px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .hero-v2-sim {
    min-height: 44px;
    padding: 10px 12px;
    display: inline-flex;
    align-items: center;
    font-size: 14px;
  }

  /* Car-cards heart toggle */
  .car-heart {
    min-width: 44px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  /* Header nav: login / favoritos / conta */
  .b2c-login-btn,
  .header-nav-action,
  .nav-account-btn {
    min-height: 44px;
    padding: 10px 14px;
    display: inline-flex;
    align-items: center;
  }
  .header__logo {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
  .ham-btn {
    width: 44px;
    height: 44px;
  }

  /* Resultados — sort pills + filtros */
  .sort-pill {
    min-height: 44px;
    padding: 10px 14px;
    display: inline-flex;
    align-items: center;
  }
  .adv-filters-drawer:not(.open) {
    pointer-events: none;
    visibility: hidden;
  }

  /* Carro detail — back link + gallery + reserve buttons */
  .back-link {
    min-height: 44px;
    padding: 10px 12px;
    display: inline-flex;
    align-items: center;
  }
  .dp-gallery-btn,
  .dp-reserve-btn {
    min-height: 44px;
    padding: 10px 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  /* Mobile drawer items */
  #mob-drawer a,
  .mob-drawer a {
    min-height: 44px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
  }

  /* Footer text-only links — keep visual size but expand tap area */
  footer a {
    padding: 6px 0;
    display: inline-block;
  }

  /* Bump tiny labels to readable 12px minimum (DPR-corrected) */
  .card-info-label {
    font-size: 12px !important;
  }
}

