/* Bizkit.Tools shared UI styles (Core) */

/* Utility: prevent first-paint flicker for blocks revealed by JS */
.bizkit-hidden{ display:none !important; }

/*
  Full-width breakout wrapper
  Some WP themes/blocks constrain content width (e.g. 800–900px).
  This wrapper breaks the tool UI out to the viewport width while keeping
  the inner card at a sensible max width.
*/
.bizkit-wrap{ box-sizing:border-box; width:100%; display:block; padding: 0 16px; }
.bizkit-wrap--full{ position:static; left:auto; right:auto; width:auto; margin:0; padding:0; }

.bizkit-vat{
  box-sizing:border-box;
  border:1px solid rgba(255,255,255,0.12);
  border-radius:16px;
  padding:18px;
  background:rgba(16,24,40,0.92);
  color:#fff;
  /* Container width contract:
     - default tools are capped for readability
     - launcher can override via --bizkit-max-width */
  max-width: var(--bizkit-max-width, 1400px);
  width:100%;
  margin:0 auto;
}

.bizkit-vat *{ box-sizing:border-box; }

/* Prevent grid children from overflowing (CSS grid default min-width:auto can overflow) */
.bizkit-grid > *,
.bizkit-cards > *{
  min-width: 0;
}
.bizkit-vat__header h3{ margin:0 0 6px; font-size:20px; }
.bizkit-vat__header p{ margin:0 0 14px; opacity:0.85; }

/* VAT registration banner */
.bizkit-grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:12px 14px;
}
.bizkit-grid label{
  display:flex;
  flex-direction:column;
  gap:6px;
  font-size:13px;
}
.bizkit-grid input, .bizkit-grid select{
  border-radius:10px;
  border:1px solid rgba(255,255,255,0.18);
  background:rgba(0,0,0,0.22);
  color:#fff;
  padding:10px 12px;
}
.bizkit-inline{
  grid-column: 1 / -1;
  flex-direction:row !important;
  align-items:center;
  gap:10px !important;
}
.bizkit-inline input{ width:18px; height:18px; padding:0; }

.bizkit-actions{
  display:flex;
  align-items:center;
  gap:12px;
  margin-top:14px;
}
.bizkit-btn{
  border:1px solid rgba(255,255,255,0.18);
  background:rgba(255,255,255,0.06);
  color:#fff;
  border-radius:12px;
  padding:10px 14px;
  cursor:pointer;
}
.bizkit-btn:hover{ background:rgba(255,255,255,0.10); }
.bizkit-hint{ opacity:0.75; font-size:12px; }

.bizkit-cards{
  margin-top:16px;
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:12px;
}
.bizkit-card{
  border:1px solid rgba(255,255,255,0.12);
  border-radius:14px;
  padding:14px;
  background:rgba(0,0,0,0.22);
  /* Critical: allow grid items to shrink and prevent content overflow beyond container */
  min-width:0;
}
.bizkit-card--accent{
  border-color: rgba(242,129,29,0.55);
}
.bizkit-card h4{ margin:0 0 10px; font-size:14px; opacity:0.9; }
.bizkit-metric{ display:flex; justify-content:space-between; align-items:baseline; gap:10px; }
.bizkit-metric span{ opacity:0.8; font-size:12px; }
.bizkit-metric strong{ font-size:18px; }
.bizkit-mini{ margin-top:10px; display:grid; gap:8px; }
.bizkit-mini div{ display:flex; justify-content:space-between; gap:10px; font-size:12px; opacity:0.9; }
.bizkit-rec{ margin:10px 0 0; }
.bizkit-note{ margin:8px 0 0; opacity:0.75; font-size:12px; }

@media (max-width: 780px){
  .bizkit-grid{ grid-template-columns: 1fr; }
  .bizkit-cards{ grid-template-columns: 1fr; }
}

.bizkit-purchase-card{
  margin-top:14px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:14px;
  border:1px solid rgba(242,129,29,0.45);
  border-radius:14px;
  padding:14px;
  background:rgba(242,129,29,0.08);
}
.bizkit-purchase-sub{ opacity:0.85; font-size:12px; margin-top:4px; }

/* Percent suffix */
.bizkit-suffix{margin-left:6px;opacity:.85;}

.bizkit-select{width:100%;max-width:520px;}
.bizkit-help{font-size:12px;opacity:.8;margin-top:6px;}

.bizkit-sub{display:block;font-size:12px;opacity:.9;margin-bottom:6px;}

/* Match sector dropdown to VAT optimiser dark pane */
.bizkit-vat select,
.bizkit-vat option {
  background-color: #0b1423;
  color: #e6edf7;
}

.bizkit-vat select:focus {
  outline: none;
  border-color: #3aa0ff;
}

/* Inline helper text under inputs */
.bizkit-vat label .bizkit-help-inline{
  display:block;
  margin-top:6px;
  font-style:normal;
  font-size:12px;
  opacity:.75;
  line-height:1.3;
}

/* Small note row under key-value pairs */
.bizkit-kv--note em{
  display:block;
  font-style:normal;
  font-size:12px;
  opacity:.75;
  line-height:1.3;
  margin-top:-6px;
}

.bizkit-vat__footer{margin-top:10px;display:flex;justify-content:space-between;gap:12px;color:#9ca3af;font-size:12px;opacity:0.9}

/* Button variants (dark UI) */
.bizkit-btn--primary{
  border-color: rgba(242,129,29,0.65);
  background: rgba(242,129,29,0.20);
}
.bizkit-btn--primary:hover{ background: rgba(242,129,29,0.26); }

.bizkit-btn--secondary{
  border-color: rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.06);
}

/* Context indicator: highlights the action button that triggered email capture */
.bizkit-btn.bizkit-context-active{
  background: rgba(255,255,255,0.90);
  color: #000;
  border-color: rgba(255,255,255,0.90);
}


/* Report footer: shared */
.bizkit-report-footer{
  margin-top: 16px;
  font-size: 12px;
  opacity: 0.85;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.bizkit-report-footer .bizkit-footer-prefix{ flex: 1 1 auto; }
.bizkit-report-footer .bizkit-footer-page{ white-space: nowrap; }

/* Print: use CSS paged-media counters for HTML printouts */
@media print {
  .bizkit-report-footer .bizkit-footer-page{
    color: transparent;
    position: relative;
    min-width: 90px;
  }
  .bizkit-report-footer .bizkit-footer-page::after{
    content: "Page " counter(page) " of " counter(pages);
    color: inherit;
    position: absolute;
    left: 0;
    top: 0;
  }
}
