/**
 * Brand Consistency Checker styles.
 * Owns: upload UI, score gauge, color comparison, recommendation cards, pro gate.
 * Does NOT own: tool-nav layout (tools-tool.css), nav system (nav.ejs).
 */

/* ── Score Gauge ─────────────────────────────────────────────────── */
.bc-gauge-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.bc-gauge {
  position: relative;
  width: 160px;
  height: 160px;
}

.bc-gauge-track {
  fill: none;
  stroke: rgba(255,255,255,0.08);
  stroke-width: 12;
}

.bc-gauge-fill {
  fill: none;
  stroke-width: 12;
  stroke-linecap: round;
  transition: stroke-dashoffset 1s cubic-bezier(0.16, 1, 0.3, 1), stroke 0.3s;
  transform: rotate(-90deg);
  transform-origin: center;
}

.bc-gauge-score {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.bc-gauge-num {
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
}

.bc-gauge-num.score-high { color: #10B981; }
.bc-gauge-num.score-mid  { color: #F59E0B; }
.bc-gauge-num.score-low  { color: #EF4444; }

.bc-gauge-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
}

.bc-gauge-legend {
  display: flex;
  gap: 12px;
  font-size: 0.72rem;
  color: rgba(255,255,255,0.4);
}

.bc-gauge-legend span { display: flex; align-items: center; gap: 4px; }
.bc-gauge-legend .dot {
  width: 8px; height: 8px; border-radius: 50%; display: inline-block;
}
.bc-gauge-legend .dot-high { background: #10B981; }
.bc-gauge-legend .dot-mid  { background: #F59E0B; }
.bc-gauge-legend .dot-low  { background: #EF4444; }

/* ── Input Section ──────────────────────────────────────────────── */
.bc-input-section {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 28px;
}

.bc-input-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

@media (max-width: 640px) {
  .bc-input-row { grid-template-columns: 1fr; }
}

.bc-kit-select {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  color: #fff;
  font-family: var(--font-display, system-ui);
  font-size: 0.88rem;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 10 10'%3E%3Cpath d='M2 3.5l3 3 3-3' stroke='rgba(255,255,255,0.4)' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.bc-kit-select:focus {
  outline: none;
  border-color: var(--tool-accent, #10B981);
}

.bc-input-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.bc-input-tab {
  flex: 1;
  padding: 8px 12px;
  border-radius: 8px;
  font-family: var(--font-display, system-ui);
  font-size: 0.78rem;
  font-weight: 600;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.bc-input-tab.is-active {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.2);
  color: #fff;
}

.bc-drop-zone {
  border: 2px dashed rgba(255,255,255,0.15);
  border-radius: 12px;
  padding: 32px 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.bc-drop-zone.is-dragging,
.bc-drop-zone:hover {
  border-color: var(--tool-accent, #10B981);
  background: rgba(16,185,129,0.05);
}

.bc-drop-zone input[type="file"] { display: none; }

.bc-drop-icon {
  font-size: 2rem;
  margin-bottom: 8px;
}

.bc-drop-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: rgba(255,255,255,0.7);
  margin-bottom: 4px;
}

.bc-drop-sub {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.35);
}

.bc-drop-filename {
  font-size: 0.82rem;
  color: var(--tool-accent, #10B981);
  font-weight: 600;
  margin-top: 6px;
}

.bc-url-input {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  color: #fff;
  font-family: var(--font-display, system-ui);
  font-size: 0.88rem;
}

.bc-url-input::placeholder { color: rgba(255,255,255,0.3); }
.bc-url-input:focus { outline: none; border-color: var(--tool-accent, #10B981); }

.bc-input-panel { display: none; }
.bc-input-panel.is-active { display: block; }

.bc-check-btn {
  width: 100%;
  padding: 14px;
  background: var(--tool-accent, #10B981);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-family: var(--font-display, system-ui);
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.bc-check-btn:hover { opacity: 0.9; transform: translateY(-1px); }
.bc-check-btn:active { transform: scale(0.98); }
.bc-check-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.bc-loading-spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: bc-spin 0.8s linear infinite;
}

@keyframes bc-spin { to { transform: rotate(360deg); } }

/* ── Results Section ────────────────────────────────────────────── */
.bc-results {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 20px;
  margin-top: 28px;
}

@media (max-width: 768px) {
  .bc-results { grid-template-columns: 1fr; }
}

.bc-results-score-panel {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.bc-results-breakdown {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bc-dim-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 10px;
  background: rgba(255,255,255,0.04);
  border-radius: 7px;
  font-size: 0.8rem;
}

.bc-dim-name { color: rgba(255,255,255,0.6); font-weight: 500; }
.bc-dim-score { font-weight: 700; }

.bc-color-compare {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.bc-panel-title {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  margin: 0;
}

.bc-color-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.bc-color-row:last-child { border-bottom: none; }

.bc-color-site { flex: 1; }

.bc-color-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.4);
  margin-bottom: 6px;
}

.bc-color-swatch {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bc-color-chip {
  width: 36px; height: 36px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.1);
  flex-shrink: 0;
}

.bc-color-hex {
  font-size: 0.8rem;
  font-weight: 600;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: rgba(255,255,255,0.8);
}

.bc-color-kit { flex: 1; }

.bc-color-delta {
  flex-shrink: 0;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 0.72rem;
  font-weight: 700;
}

.bc-color-delta.good    { background: rgba(16,185,129,0.15); color: #10B981; }
.bc-color-delta.medium { background: rgba(245,158,11,0.15); color: #F59E0B; }
.bc-color-delta.poor    { background: rgba(239,68,68,0.15);  color: #EF4444; }

.bc-recs {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bc-rec-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  transition: background 0.15s;
}

.bc-rec-card:hover { background: rgba(255,255,255,0.07); }

.bc-rec-icon { flex-shrink: 0; width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 0.9rem; }
.bc-rec-icon.red    { background: rgba(239,68,68,0.15); }
.bc-rec-icon.yellow { background: rgba(245,158,11,0.15); }
.bc-rec-icon.green  { background: rgba(16,185,129,0.15); }

.bc-rec-content { flex: 1; }
.bc-rec-title { font-size: 0.85rem; font-weight: 600; color: #fff; margin-bottom: 3px; }
.bc-rec-detail { font-size: 0.78rem; color: rgba(255,255,255,0.5); line-height: 1.5; }
.bc-rec-code {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 0.75rem;
  padding: 2px 7px;
  background: rgba(255,255,255,0.06);
  border-radius: 4px;
  margin-top: 4px;
}

.bc-recheck-btn {
  padding: 10px 20px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  color: rgba(255,255,255,0.7);
  font-family: var(--font-display, system-ui);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.bc-recheck-btn:hover { background: rgba(255,255,255,0.1); color: #fff; }

/* ── Pro Gate ──────────────────────────────────────────────────── */
.bc-pro-gate {
  background: rgba(255,255,255,0.03);
  border: 1px dashed rgba(255,255,255,0.15);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
}

.bc-pro-gate-score {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 6px;
}

.bc-pro-gate-tease {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.45);
  margin-bottom: 16px;
}

.bc-pro-gate-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--tool-accent, #10B981);
  color: #fff;
  border-radius: 10px;
  font-family: var(--font-display, system-ui);
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
  transition: opacity 0.15s;
}

.bc-pro-gate-btn:hover { opacity: 0.9; }

/* ── History (Pro) ─────────────────────────────────────────────── */
.bc-history {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 16px;
}

.bc-history-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  margin-bottom: 4px;
}

.bc-history-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(255,255,255,0.04);
  border-radius: 8px;
  font-size: 0.78rem;
  cursor: pointer;
  transition: background 0.15s;
}

.bc-history-item:hover { background: rgba(255,255,255,0.08); }

.bc-history-date { color: rgba(255,255,255,0.4); }
.bc-history-score { font-weight: 700; }

/* ── Upgrade modal ─────────────────────────────────────────────── */
.bc-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(4px);
}

.bc-modal-overlay.is-open { display: flex; }

.bc-modal {
  background: #1a1f2e;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  padding: 32px;
  max-width: 400px;
  width: 100%;
  position: relative;
}

.bc-modal-close {
  position: absolute;
  top: 16px; right: 16px;
  background: rgba(255,255,255,0.08);
  border: none;
  border-radius: 8px;
  width: 32px; height: 32px;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bc-modal-close:hover { color: #fff; }

.bc-modal-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: rgba(240,84,12,0.12);
  border: 1px solid rgba(240,84,12,0.2);
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #F0540C;
  margin-bottom: 16px;
}

.bc-modal-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.bc-modal-sub {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.55);
  line-height: 1.6;
  margin-bottom: 20px;
}

.bc-modal-plan {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  margin-bottom: 16px;
}

.bc-modal-plan-price {
  font-size: 2rem;
  font-weight: 800;
  color: #fff;
  line-height: 1;
}

.bc-modal-plan-price span { font-size: 0.85rem; font-weight: 600; color: rgba(255,255,255,0.5); }

.bc-modal-plan-label {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.4);
  margin-top: 4px;
}

.bc-modal-cta {
  display: block;
  width: 100%;
  padding: 14px;
  background: var(--tool-accent, #10B981);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-family: var(--font-display, system-ui);
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: opacity 0.15s;
}

.bc-modal-cta:hover { opacity: 0.9; }