.fg-calculator,
.fg-calculator * {
  box-sizing: border-box;
}
.fg-calculator {
  --fg-navy: #09263f;
  --fg-blue: #0a709f;
  --fg-cyan: #6edcf5;
  --fg-gold: #d99a4e;
  --fg-ink: #102438;
  --fg-muted: #566c7a;
  --fg-line: #dbe7ef;
  position: relative;
  background: rgba(255, 255, 255, 0.97);
  color: var(--fg-ink);
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 28px;
  box-shadow: 0 32px 80px rgba(4, 26, 44, 0.24);
  overflow: hidden;
}
.fg-calculator:before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  background: linear-gradient(
    90deg,
    var(--fg-cyan),
    var(--fg-blue),
    var(--fg-gold)
  );
}
.fg-calc-topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 30px 20px;
  border-bottom: 1px solid var(--fg-line);
}
.fg-calc-kicker {
  display: block;
  color: var(--fg-blue);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  margin-bottom: 7px;
}
.fg-calc-topline h2 {
  font-size: clamp(24px, 2.3vw, 34px);
  line-height: 1.12;
  margin: 0;
  color: var(--fg-navy);
}
.fg-calc-progress {
  display: flex;
  gap: 7px;
  padding-top: 7px;
}
.fg-calc-progress span {
  display: block;
  width: 24px;
  height: 5px;
  border-radius: 9px;
  background: #d9e3ea;
  transition: 0.25s ease;
}
.fg-calc-progress span.is-active {
  width: 38px;
  background: var(--fg-blue);
}
.fg-calc-form {
  padding: 25px 30px 28px;
}
.fg-calc-step {
  animation: fgStep 0.28s ease;
}
.fg-calc-step[hidden] {
  display: none !important;
}
@keyframes fgStep {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.fg-step-copy {
  display: flex;
  gap: 13px;
  align-items: flex-start;
  margin-bottom: 20px;
}
.fg-step-no {
  display: grid;
  place-items: center;
  flex: 0 0 38px;
  height: 38px;
  border-radius: 12px;
  background: #e9f6fb;
  color: var(--fg-blue);
  font-size: 12px;
  font-weight: 900;
}
.fg-step-copy h3 {
  font-size: 20px;
  line-height: 1.2;
  margin: 1px 0 4px;
  color: var(--fg-navy);
}
.fg-step-copy p {
  font-size: 13px;
  line-height: 1.5;
  color: var(--fg-muted);
  margin: 0;
}
.fg-choice-group {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 0 0 18px;
  padding: 0;
  border: 0;
}
.fg-choice-group legend {
  grid-column: 1/-1;
  font-size: 12px;
  color: var(--fg-muted);
  font-weight: 800;
  margin-bottom: -2px;
}
.fg-choice-group button {
  appearance: none;
  display: flex;
  min-height: 128px;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  gap: 6px;
  padding: 16px;
  border: 1px solid var(--fg-line);
  border-radius: 16px;
  background: #f8fbfd;
  color: var(--fg-ink);
  cursor: pointer;
  transition: 0.2s ease;
}
.fg-choice-group button:hover {
  border-color: #9ecfe3;
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(14, 121, 178, 0.08);
}
.fg-choice-group button.is-selected {
  border-color: var(--fg-blue);
  background: #eff9fd;
  box-shadow:
    inset 0 0 0 1px var(--fg-blue),
    0 12px 26px rgba(14, 121, 178, 0.12);
}
.fg-choice-icon {
  display: grid;
  place-items: center;
  width: 31px;
  height: 31px;
  border-radius: 10px;
  background: white;
  color: var(--fg-blue);
  font-size: 20px;
  box-shadow: 0 5px 14px rgba(10, 50, 78, 0.09);
}
.fg-choice-group strong {
  font-size: 14px;
  color: var(--fg-navy);
}
.fg-choice-group small {
  font-size: 11px;
  line-height: 1.45;
  color: var(--fg-muted);
}
.fg-choice-group--compact {
  grid-template-columns: repeat(2, 1fr);
  margin-bottom: 4px;
}
.fg-choice-group--compact button {
  min-height: auto;
  padding: 13px 15px;
}
.fg-area-picker {
  padding: 24px 24px 19px;
  background: linear-gradient(145deg, #f3f9fc, #fff);
  border: 1px solid var(--fg-line);
  border-radius: 20px;
}
.fg-area-picker output {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 5px;
  color: var(--fg-navy);
  margin-bottom: 19px;
}
.fg-area-picker output strong {
  font-size: 58px;
  letter-spacing: -0.06em;
  line-height: 0.9;
}
.fg-area-picker output span {
  font-size: 16px;
  font-weight: 800;
  color: var(--fg-blue);
  padding-bottom: 5px;
}
.fg-area-picker input[type="range"] {
  --fg-range: 20%;
  appearance: none;
  width: 100%;
  height: 8px;
  border-radius: 20px;
  background: linear-gradient(
    90deg,
    var(--fg-blue) var(--fg-range),
    #d9e6ed var(--fg-range)
  );
  outline: none;
}
.fg-area-picker input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 26px;
  height: 26px;
  border: 6px solid #fff;
  border-radius: 50%;
  background: var(--fg-blue);
  box-shadow: 0 2px 12px rgba(14, 121, 178, 0.35);
  cursor: pointer;
}
.fg-area-picker input[type="range"]::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border: 6px solid #fff;
  border-radius: 50%;
  background: var(--fg-blue);
  box-shadow: 0 2px 12px rgba(14, 121, 178, 0.35);
  cursor: pointer;
}
.fg-area-scale {
  display: flex;
  justify-content: space-between;
  color: var(--fg-muted);
  font-size: 11px;
  font-weight: 700;
  margin-top: 12px;
}
.fg-area-presets {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 20px;
}
.fg-area-presets button {
  appearance: none;
  min-height: 44px;
  border: 1px solid #c9dce6;
  border-radius: 12px;
  background: #fff;
  color: var(--fg-navy);
  font: inherit;
  font-size: 13px;
  font-weight: 850;
  cursor: pointer;
  transition: 0.2s ease;
}
.fg-area-presets button:hover {
  border-color: var(--fg-blue);
  color: var(--fg-blue);
  transform: translateY(-1px);
}
.fg-area-presets button.is-selected {
  border-color: var(--fg-blue);
  background: var(--fg-blue);
  color: #fff;
  box-shadow: 0 8px 20px rgba(10, 112, 159, 0.2);
}
.fg-area-presets button:focus-visible {
  outline: 3px solid rgba(110, 220, 245, 0.55);
  outline-offset: 2px;
}
.fg-capacity-hint {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 12px;
  padding: 13px 17px;
  border: 1px dashed #b7d6e4;
  border-radius: 14px;
  color: var(--fg-muted);
  font-size: 12px;
}
.fg-capacity-hint strong {
  color: var(--fg-navy);
  font-size: 16px;
}
.fg-results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 270px));
  justify-content: center;
  gap: 14px;
  max-height: none;
  overflow: visible;
  padding: 2px;
}
.fg-result-card {
  appearance: none;
  position: relative;
  display: flex;
  min-width: 0;
  flex-direction: column;
  text-align: left;
  border: 1px solid var(--fg-line);
  border-radius: 20px;
  background: #fff;
  padding: 0 16px 16px;
  overflow: hidden;
  cursor: pointer;
  color: var(--fg-ink);
  transition: 0.2s ease;
}
.fg-result-card:hover {
  border-color: #9ecfe3;
  transform: translateY(-2px);
}
.fg-result-card.is-selected {
  border-color: var(--fg-blue);
  box-shadow:
    inset 0 0 0 1px var(--fg-blue),
    0 12px 30px rgba(14, 121, 178, 0.1);
}
.fg-match-badge {
  display: inline-flex;
  position: absolute;
  z-index: 2;
  top: 12px;
  left: 12px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #e5f7ed;
  color: #16834a;
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.fg-match-badge.is-estimate {
  background: #fff3dd;
  color: #9a5c08;
}
.fg-result-main {
  display: block;
  min-height: 54px;
  margin: 0 0 14px;
}
.fg-result-media {
  display: grid;
  place-items: center;
  width: calc(100% + 32px);
  aspect-ratio: 4 / 3;
  margin: 0 -16px 16px;
  padding: 18px;
  overflow: hidden;
  border-bottom: 1px solid #e7eff4;
  background: linear-gradient(145deg, #f8fbfd, #eef5f8);
}
.fg-result-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.fg-result-media--placeholder {
  align-content: center;
  gap: 8px;
  color: var(--fg-muted);
}
.fg-result-media--placeholder small {
  font-size: 10px;
  font-weight: 750;
}
.fg-boiler-placeholder {
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  border-radius: 18px;
  background: #fff;
  color: var(--fg-blue);
  font-size: 31px;
  box-shadow: 0 10px 25px rgba(9, 38, 63, 0.08);
}
.fg-result-brand {
  display: block;
  color: var(--fg-blue);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  margin-bottom: 3px;
}
.fg-result-name {
  display: block;
  font-size: 13px;
  line-height: 1.35;
  color: var(--fg-navy);
}
.fg-result-specs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin-top: auto;
}
.fg-result-specs span {
  padding: 8px;
  border-radius: 9px;
  background: #f5f8fa;
  color: var(--fg-muted);
  font-size: 8px;
  text-transform: uppercase;
}
.fg-result-specs b {
  display: block;
  color: var(--fg-navy);
  font-size: 11px;
  text-transform: none;
  margin-bottom: 2px;
}
.fg-result-price {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  border-top: 1px solid #edf2f5;
  margin-top: 10px;
  padding-top: 10px;
}
.fg-result-price small {
  color: var(--fg-muted);
  font-size: 9px;
  text-transform: uppercase;
}
.fg-result-price strong {
  color: var(--fg-blue);
  font-size: 16px;
}
.fg-no-result {
  grid-column: 1/-1;
  display: flex;
  flex-direction: column;
  gap: 7px;
  text-align: center;
  padding: 34px;
  border: 1px dashed #a9cbd9;
  border-radius: 16px;
  background: #f7fbfd;
}
.fg-contact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.fg-contact-grid label {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.fg-contact-grid label > span {
  font-size: 11px;
  font-weight: 800;
  color: var(--fg-muted);
}
.fg-contact-grid input,
.fg-contact-grid select,
.fg-contact-grid textarea {
  width: 100%;
  min-height: 43px;
  border: 1px solid var(--fg-line);
  border-radius: 11px;
  background: #f8fbfd;
  color: var(--fg-ink);
  padding: 10px 12px;
  font: inherit;
  font-size: 13px;
  outline: none;
  transition: 0.2s ease;
}
.fg-contact-grid input:focus,
.fg-contact-grid select:focus,
.fg-contact-grid textarea:focus {
  border-color: var(--fg-blue);
  box-shadow: 0 0 0 3px rgba(14, 121, 178, 0.1);
  background: #fff;
}
.fg-contact-full {
  grid-column: 1/-1;
}
.fg-honeypot {
  position: absolute !important;
  left: -9999px !important;
}
.fg-calc-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 21px;
}
.fg-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  border-radius: 12px;
  padding: 11px 18px;
  border: 1px solid transparent;
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: 0.2s ease;
}
.fg-btn--primary {
  background: linear-gradient(135deg, var(--fg-blue), #075e8a);
  color: #fff;
  box-shadow: 0 10px 24px rgba(14, 121, 178, 0.24);
}
.fg-btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(14, 121, 178, 0.3);
}
.fg-btn--primary:disabled {
  opacity: 0.65;
  cursor: wait;
}
.fg-btn--ghost {
  border-color: var(--fg-line);
  background: #fff;
  color: var(--fg-navy);
}
.fg-calc-feedback {
  display: none;
  margin-top: 14px;
  padding: 11px 13px;
  border-radius: 11px;
  font-size: 12px;
  font-weight: 700;
}
.fg-calc-feedback.is-visible {
  display: block;
}
.fg-calc-feedback.is-error {
  background: #fff0f0;
  color: #a52a2a;
}
.fg-calc-feedback.is-success {
  background: #e9f8ef;
  color: #197341;
}
.fg-calc-success {
  text-align: center;
  padding: 56px 30px;
}
.fg-calc-success[hidden] {
  display: none !important;
}
.fg-success-icon {
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  margin: 0 auto 20px;
  border-radius: 50%;
  background: #e7f8ee;
  color: #19824b;
  font-size: 30px;
  font-weight: 900;
}
.fg-calc-success h3 {
  font-size: 30px;
  color: var(--fg-navy);
  margin: 0 0 8px;
}
.fg-calc-success p {
  color: var(--fg-muted);
  margin: 0 auto 24px;
  max-width: 420px;
}
.fg-calculator [hidden] {
  display: none !important;
}
@media (max-width: 740px) {
  .fg-calculator {
    border-radius: 22px;
  }
  .fg-calc-topline,
  .fg-calc-form {
    padding-left: 20px;
    padding-right: 20px;
  }
  .fg-calc-topline {
    padding-top: 24px;
  }
  .fg-calc-topline h2 {
    font-size: 25px;
  }
  .fg-calc-progress span {
    width: 14px;
  }
  .fg-calc-progress span.is-active {
    width: 23px;
  }
  .fg-choice-group {
    grid-template-columns: 1fr;
  }
  .fg-choice-group button {
    min-height: 92px;
  }
  .fg-choice-group--compact {
    grid-template-columns: 1fr;
  }
  .fg-results {
    grid-template-columns: 1fr;
    max-height: none;
  }
  .fg-contact-grid {
    grid-template-columns: 1fr;
  }
  .fg-contact-full {
    grid-column: auto;
  }
  .fg-calc-actions .fg-btn {
    flex: 1;
  }
  .fg-area-picker output strong {
    font-size: 50px;
  }
  .fg-area-presets {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
}
