/* BitBeam Package Builder — configurator styles */

.bitbeam-bundle-builder {
  max-width: 800px;
  margin: 2em auto;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.bb-builder-loading {
  text-align: center;
  padding: 3em;
  color: #666;
}

.bb-builder-section {
  margin-bottom: 2em;
  padding: 1.5em;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
}

.bb-builder-step-title {
  display: flex;
  align-items: center;
  gap: 0.5em;
  margin: 0 0 1em 0;
  font-size: 1.1em;
  font-weight: 600;
}

.bb-step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: #0073aa;
  color: #fff;
  border-radius: 50%;
  font-size: 0.85em;
  font-weight: 700;
}

/* Module grid */
.bb-module-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1em;
}

.bb-module-card {
  display: flex;
  align-items: flex-start;
  gap: 0.75em;
  padding: 1em;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.bb-module-card:hover {
  border-color: #0066cc;
  box-shadow: 0 2px 8px rgba(0, 102, 204, 0.08);
}

.bb-module-card:has(input:checked) {
  border-color: #0066cc;
  background: rgba(0, 102, 204, 0.05);
  box-shadow: 0 2px 12px rgba(0, 102, 204, 0.12);
}

.bb-module-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bb-module-icon img {
  width: 48px;
  height: 48px;
  display: block;
}

.bb-module-checkbox {
  margin-top: 0.2em;
  width: 18px;
  height: 18px;
}

.bb-module-name {
  font-weight: 600;
  font-size: 0.95em;
}

.bb-module-price {
  color: #0073aa;
  font-size: 0.9em;
  margin: 0.2em 0;
}

.bb-module-desc {
  font-size: 0.8em;
  color: #666;
  line-height: 1.4;
}

/* Term options */
.bb-term-options {
  display: flex;
  gap: 0.75em;
  flex-wrap: wrap;
}

.bb-term-option {
  display: flex;
  align-items: center;
  gap: 0.5em;
  padding: 0.75em 1.25em;
  border: 2px solid #e0e0e0;
  border-radius: 6px;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.bb-term-option:hover {
  border-color: #0073aa;
}

.bb-term-option.selected {
  border-color: #0073aa;
  background: #f0f7ff;
}

.bb-term-option input {
  display: none;
}

.bb-term-label {
  font-weight: 600;
  font-size: 0.95em;
}

/* Infrastructure / Support options */
.bb-infra-options,
.bb-support-options {
  display: flex;
  flex-direction: column;
  gap: 0.5em;
}

.bb-infra-option,
.bb-support-option {
  display: flex;
  align-items: center;
  gap: 0.75em;
  padding: 0.75em 1em;
  border: 2px solid #e0e0e0;
  border-radius: 6px;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.bb-infra-option:hover,
.bb-support-option:hover {
  border-color: #0073aa;
}

.bb-infra-option.selected,
.bb-support-option.selected {
  border-color: #0073aa;
  background: #f0f7ff;
}

.bb-infra-option[disabled],
.bb-support-option[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
}

.bb-infra-option input,
.bb-support-option input {
  display: none;
}

.bb-infra-info,
.bb-support-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.bb-infra-name,
.bb-support-name {
  font-weight: 600;
  font-size: 0.95em;
}

.bb-infra-price,
.bb-support-price {
  color: #0073aa;
  font-size: 0.9em;
}

/* Price summary */
.bb-price-summary-section {
  background: #f9f9f9;
}

.bb-price-summary {
  display: flex;
  flex-direction: column;
  gap: 0.5em;
}

.bb-price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5em 0;
}

.bb-price-label {
  font-weight: 500;
  color: #444;
}

.bb-price-value {
  font-weight: 700;
  color: #0073aa;
}

.bb-price-detail {
  padding: 0.5em 0 0.5em 1em;
  font-size: 0.85em;
  color: #666;
  border-left: 3px solid #e0e0e0;
  margin-left: 0.5em;
}

.bb-price-detail-row {
  padding: 0.15em 0;
}

.bb-discount {
  color: #46b450;
  font-weight: 600;
}

.bb-price-recurring-total {
  border-top: 1px solid #e0e0e0;
  margin-top: 0.5em;
  padding-top: 0.75em;
}

.bb-price-recurring-total .bb-price-value {
  font-size: 1.15em;
}

.bb-price-contract-value {
  font-size: 0.85em;
  color: #888;
}

.bb-price-contract-value .bb-price-label,
.bb-price-contract-value .bb-price-value {
  font-weight: 500;
  color: #888;
}

/* Checkout button */
.bb-checkout-button {
  display: block;
  width: 100%;
  padding: 1em;
  margin-top: 1.5em;
  background: #0073aa;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 1.05em;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
}

.bb-checkout-button:hover:not(:disabled) {
  background: #005a87;
}

.bb-checkout-button:disabled {
  background: #ccc;
  cursor: not-allowed;
}

/* Error */
.bb-builder-error {
  margin-top: 1em;
  padding: 1em;
  background: #fff0f0;
  border: 1px solid #dc3232;
  border-radius: 6px;
  color: #dc3232;
}
