/* ============================================================
   Business Trust Check v2 — HackCheck-aligned design
   Targets existing btc* IDs and classes so JS keeps working.
   Layers on top of styles-v3.css.
   ============================================================ */

/* ----- Shared token bridge (mirrors HackCheck app.css) ----- */
:root {
  --bg-soft:        #23262a;
  --surface:        #2b2e30;
  --surface-2:      #34373a;
  --border:         rgba(245,245,245,0.08);
  --border-strong:  rgba(245,245,245,0.18);
  --primary-soft:   rgba(26,127,200,0.14);
  --accent-soft:    rgba(59,189,198,0.14);
  --text-muted:     rgba(245,245,245,0.72);
  --text-dim:       rgba(245,245,245,0.55);
  --font-head:      'Exo 2', 'Calibri', 'Segoe UI', sans-serif;
  --font-mono:      'JetBrains Mono', ui-monospace, Consolas, monospace;
  --ease:           cubic-bezier(0.2, 0, 0, 1);
  --duration:       220ms;
  --crisis:         #FF6B6B;
  --warn:           #ffa726;
  --ok:             #3bbdc6;
  --ok-soft:        rgba(59,189,198,0.12);
  --warn-soft:      rgba(255,167,38,0.12);
  --crisis-soft:    rgba(255,107,107,0.12);
}

.btc-page {
  font-feature-settings: "kern" 1, "liga" 1;
  text-rendering: optimizeLegibility;
}

/* ----- Eyebrow ----- */
.btc-page .eyebrow {
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  font-size: 0.72rem;
  color: var(--teal-accent, #3bbdc6);
  text-transform: uppercase;
  letter-spacing: 0.24em;
  margin-bottom: 14px;
}

/* ----- Hero ----- */
.btc-hero { padding: clamp(28px, 6vw, 56px) 0 clamp(20px, 4vw, 40px); }
.btc-hero h1 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(1.85rem, 5.6vw, 2.85rem);
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin: 0 0 14px;
}
.btc-hero .hero-subtext {
  color: var(--text-muted);
  font-size: 1.02rem;
  max-width: 60ch;
  margin: 0 0 24px;
  line-height: 1.7;
}
.btc-hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(20px, 4vw, 40px);
  align-items: start;
}
@media (min-width: 880px) {
  .btc-hero-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
}

/* ----- Scan card (HackCheck input pattern) ----- */
.btc-check-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: clamp(20px, 3vw, 28px);
  box-shadow: 0 12px 24px rgba(0,0,0,0.24);
  transition: border-color var(--duration) var(--ease),
              box-shadow var(--duration) var(--ease);
}
.btc-check-form:focus-within {
  border-color: rgba(26,127,200,0.45);
  box-shadow: 0 0 0 1px rgba(26,127,200,0.25), 0 18px 32px rgba(0,0,0,0.28);
}
.btc-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 10px;
}
.btc-input-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
@media (min-width: 560px) {
  .btc-input-row { grid-template-columns: 1fr auto; }
}
.btc-input-row input {
  background: var(--bg-soft);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 1rem;
  color: #f5f5f5;
  min-height: 48px;
  transition: border-color var(--duration) var(--ease),
              box-shadow var(--duration) var(--ease);
}
.btc-input-row input::placeholder { color: var(--text-dim); }
.btc-input-row input:focus {
  outline: none;
  border-color: var(--teal-primary, #1a7fc8);
  box-shadow: 0 0 0 3px rgba(26,127,200,0.18);
}
#btcRunBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 22px;
  border-radius: 12px;
  background: var(--teal-primary, #1a7fc8);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  border: 0;
  cursor: pointer;
  min-height: 48px;
  transition: background-color var(--duration) var(--ease),
              transform 160ms var(--ease);
}
#btcRunBtn:hover { background: #2a8ed8; }
#btcRunBtn:active { transform: scale(0.97); }
#btcRunBtn:focus-visible {
  outline: 2px solid var(--teal-accent, #3bbdc6);
  outline-offset: 3px;
}
.btc-note {
  margin-top: 12px;
  font-size: 0.82rem;
  color: var(--text-dim);
}

/* ----- Error message ----- */
.btc-message-error {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--crisis-soft);
  border: 1px solid rgba(255,107,107,0.32);
  color: var(--crisis);
  font-size: 0.9rem;
}

/* ----- Loading state (HackCheck recon aesthetic) ----- */
.btc-loading {
  margin-top: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: #11141a;
  border: 1px solid rgba(59,189,198,0.18);
  border-radius: 16px;
  font-family: var(--font-mono);
  font-size: 0.88rem;
  color: var(--text-muted);
}
.btc-spinner {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(59,189,198,0.25);
  border-top-color: var(--teal-accent, #3bbdc6);
  animation: btc-spin 0.9s linear infinite;
  flex-shrink: 0;
}
@keyframes btc-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .btc-spinner { animation: none; border-top-color: transparent; }
}
#btcLoadingMessage { margin: 0; }

/* ----- Hero preview card (right column) ----- */
.btc-preview-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: clamp(20px, 3vw, 28px);
  box-shadow: 0 12px 24px rgba(0,0,0,0.24);
}
.btc-preview-card .badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--teal-accent, #3bbdc6);
  background: var(--accent-soft);
  border: 1px solid rgba(59,189,198,0.25);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 14px;
}
.btc-preview-card .hero-card-title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.1rem;
  color: #f5f5f5;
  margin: 0 0 16px;
}
.hero-features { display: grid; gap: 10px; }
.hero-feature-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
}
.hero-feature-item img {
  width: 28px; height: 28px;
  flex-shrink: 0;
  filter: brightness(0) saturate(100%) invert(72%) sepia(40%) saturate(467%) hue-rotate(141deg) brightness(96%) contrast(92%);
}
.hero-feature-item p { margin: 0; color: var(--text-muted); font-size: 0.92rem; }

/* ----- Results section ----- */
.btc-results-section {
  padding: clamp(36px, 6vw, 56px) 0;
  background: linear-gradient(180deg, transparent 0%, rgba(26,127,200,0.04) 100%);
}
.btc-results-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 960px) {
  .btc-results-grid { grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); }
}

/* Score card (HackCheck score-card pattern) */
.btc-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: clamp(24px, 4vw, 32px);
  box-shadow: 0 12px 24px rgba(0,0,0,0.24);
}
.btc-score-card { text-align: center; }
.btc-score-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.btc-shield {
  width: 110px; height: 110px;
  border-radius: 50%;
  background: var(--primary-soft);
  border: 4px solid var(--teal-accent, #3bbdc6);
  display: grid;
  place-items: center;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 2.4rem;
  color: #f5f5f5;
  letter-spacing: -0.02em;
}
.btc-shield[data-rating="critical"] { border-color: var(--crisis); background: var(--crisis-soft); }
.btc-shield[data-rating="weak"]     { border-color: var(--warn);   background: var(--warn-soft); }
.btc-shield[data-rating="moderate"] { border-color: var(--warn);   background: var(--warn-soft); }
.btc-shield[data-rating="strong"]   { border-color: var(--ok);     background: var(--ok-soft); }
.btc-mini-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--text-dim);
  margin: 0;
}
.btc-rating-text {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.15rem;
  color: #f5f5f5;
  margin: 4px 0 0;
}
.btc-domain-pill {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--teal-accent, #3bbdc6);
  background: var(--accent-soft);
  border: 1px solid rgba(59,189,198,0.25);
  padding: 6px 14px;
  border-radius: 999px;
  margin: 12px 0;
}
.btc-score-card h2 {
  font-family: var(--font-head);
  font-size: clamp(1.25rem, 3vw, 1.55rem);
  margin: 8px 0;
  color: #f5f5f5;
}
.btc-summary {
  color: var(--text-muted);
  max-width: 50ch;
  margin: 8px auto 0;
  line-height: 1.6;
}

/* Findings card */
.btc-findings-card .btc-section-head { margin-bottom: 18px; }
.btc-findings-card h2 {
  font-family: var(--font-head);
  font-size: 1.25rem;
  margin: 0 0 6px;
}
.btc-findings-card .btc-section-head p {
  color: var(--text-muted);
  margin: 0;
}
.btc-findings-list { display: grid; gap: 10px; }

/* Locked panel */
.btc-locked-panel {
  margin-top: 16px;
  padding: 18px;
  background: var(--bg-soft);
  border: 1px dashed var(--border-strong);
  border-radius: 16px;
  position: relative;
  overflow: hidden;
}
.btc-locked-copy { position: relative; z-index: 1; }
.btc-locked-copy h3 {
  font-family: var(--font-head);
  font-size: 1.05rem;
  color: var(--teal-accent, #3bbdc6);
  margin: 4px 0 8px;
}
.btc-locked-copy p {
  color: var(--text-muted);
  margin: 0;
  font-size: 0.92rem;
}
.btc-locked-cards {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 18px;
  opacity: 0.18;
  filter: blur(2px);
  pointer-events: none;
}
.btc-locked-card {
  height: 24px;
  background: linear-gradient(90deg, var(--surface) 0%, var(--surface-2) 50%, var(--surface) 100%);
  border-radius: 6px;
}

/* Lead form */
.btc-lead-form { margin-top: 18px; }
.btc-field-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-bottom: 12px;
}
@media (min-width: 560px) {
  .btc-field-grid { grid-template-columns: 1fr 1fr; }
}
.btc-field label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 6px;
}
.btc-field input,
.btc-field textarea {
  width: 100%;
  background: var(--bg-soft);
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 0.95rem;
  color: #f5f5f5;
  font-family: inherit;
  min-height: 44px;
  transition: border-color var(--duration) var(--ease),
              box-shadow var(--duration) var(--ease);
}
.btc-field input:focus,
.btc-field textarea:focus {
  outline: none;
  border-color: var(--teal-primary, #1a7fc8);
  box-shadow: 0 0 0 3px rgba(26,127,200,0.18);
}
.btc-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 12px 0 16px;
  font-size: 0.88rem;
  color: var(--text-muted);
  cursor: pointer;
}
.btc-consent input { margin-top: 3px; flex-shrink: 0; }
.btc-lead-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.btc-lead-actions .btn { min-height: 48px; }
#btcRequestBtn:active { transform: scale(0.97); }

/* Success panel */
.btc-success-panel {
  text-align: center;
  padding: 28px 18px;
  background: var(--ok-soft);
  border: 1px solid rgba(59,189,198,0.32);
  border-radius: 16px;
  margin-top: 18px;
}
.btc-success-icon {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--ok);
  color: #042c14;
  font-size: 1.8rem;
  font-weight: 700;
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
}
.btc-success-panel h3 {
  font-family: var(--font-head);
  font-size: 1.2rem;
  margin: 0 0 8px;
}
.btc-success-panel p {
  color: var(--text-muted);
  max-width: 45ch;
  margin: 0 auto 16px;
}

/* ----- Footer card ----- */
.btc-footer {
  padding: clamp(36px, 6vw, 56px) 0;
}
.btc-footer-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: clamp(24px, 4vw, 40px);
  text-align: center;
  box-shadow: 0 12px 24px rgba(0,0,0,0.24);
}
.btc-footer-card h2 {
  font-family: var(--font-head);
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  margin: 0 0 10px;
}
.btc-footer-card p {
  color: var(--text-muted);
  max-width: 50ch;
  margin: 0 auto 18px;
}
.btc-contact-panel { margin-top: 20px; text-align: left; }
.btc-contact-form { margin-top: 12px; }

/* ----- Section-wide tints ----- */
.section--tinted { background-color: rgba(255,255,255,0.015); }

/* ----- Findings items (rendered by JS into btcVisibleFindings) ----- */
.btc-findings-list > * {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
}
