/* Cost calculator articles: preserve intrinsic image ratios and constrain oversized legacy figures. */
.content-left_blog.pine-cost-calculator-article .w-richtext figure.w-richtext-figure-type-image {
  clear: both;
  display: block;
  margin: 1.5rem auto 2rem;
  max-width: 42rem;
  width: 100%;
}

.content-left_blog.pine-cost-calculator-article .w-richtext figure.w-richtext-figure-type-image > div {
  display: block;
  width: 100%;
}

.content-left_blog.pine-cost-calculator-article .w-richtext figure.w-richtext-figure-type-image img {
  aspect-ratio: auto !important;
  display: block;
  height: auto !important;
  margin: 0 auto;
  max-width: 100%;
  object-fit: contain;
  width: 100%;
}

.pine-cost-calculator {
  color: #172033;
  font-family: inherit;
  margin: 2.25rem 0;
  text-align: left;
  width: 100%;
}

.pine-cost-calculator__panel {
  background: linear-gradient(145deg, #f4f7fb 0%, #eef3f9 100%);
  border: 1px solid #d6e0ec;
  border-radius: 1rem;
  box-shadow: 0 1rem 2.5rem rgba(21, 35, 75, 0.08);
  padding: clamp(1.1rem, 3vw, 2rem);
}

.content-left_blog .w-richtext .pine-cost-calculator__title {
  color: #15234b;
  font-size: clamp(1.4rem, 3vw, 1.8rem);
  line-height: 1.35;
  margin: 0;
  text-align: center;
}

.content-left_blog .w-richtext .pine-cost-calculator__description {
  color: #526078;
  line-height: 1.7;
  margin: 0.65rem auto 1.5rem;
  max-width: 42rem;
  text-align: center;
}

.pine-cost-calculator__form {
  background: #fff;
  border: 1px solid #dce4ee;
  border-radius: 0.75rem;
  display: grid;
  gap: 1.25rem;
  padding: clamp(1rem, 2.5vw, 1.5rem);
}

.pine-cost-calculator__fields {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pine-cost-calculator__field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  min-width: 0;
}

.pine-cost-calculator__field label,
.pine-cost-calculator__options legend {
  color: #263550;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.45;
}

.pine-cost-calculator__field input,
.pine-cost-calculator__field select {
  appearance: none;
  background: #fff;
  border: 1px solid #b9c6d6;
  border-radius: 0.5rem;
  box-sizing: border-box;
  color: #172033;
  font: inherit;
  height: 3rem;
  line-height: 1.4;
  margin: 0;
  padding: 0.65rem 0.8rem;
  width: 100%;
}

.pine-cost-calculator__field select {
  background-image: linear-gradient(45deg, transparent 50%, #526078 50%), linear-gradient(135deg, #526078 50%, transparent 50%);
  background-position: calc(100% - 1rem) 1.2rem, calc(100% - 0.7rem) 1.2rem;
  background-repeat: no-repeat;
  background-size: 0.3rem 0.3rem, 0.3rem 0.3rem;
  padding-right: 2.25rem;
}

.pine-cost-calculator__field input:focus,
.pine-cost-calculator__field select:focus {
  border-color: #315f9c;
  box-shadow: 0 0 0 3px rgba(49, 95, 156, 0.16);
  outline: none;
}

.pine-cost-calculator__options {
  border: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem 1.25rem;
  margin: 0;
  padding: 0;
}

.pine-cost-calculator__options legend {
  margin-bottom: 0.65rem;
  padding: 0;
  width: 100%;
}

.pine-cost-calculator__check {
  align-items: center;
  color: #34445f;
  cursor: pointer;
  display: inline-flex;
  font-weight: 500;
  gap: 0.55rem;
  margin: 0;
}

.pine-cost-calculator__check input {
  accent-color: #254f87;
  height: 1.2rem;
  margin: 0;
  width: 1.2rem;
}

.pine-cost-calculator__button {
  background: #203f70;
  border: 0;
  border-radius: 0.55rem;
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  min-height: 3.1rem;
  padding: 0.75rem 1rem;
  transition: background-color 160ms ease, transform 160ms ease;
  width: 100%;
}

.pine-cost-calculator__button:hover {
  background: #152f58;
  transform: translateY(-1px);
}

.pine-cost-calculator__button:focus-visible {
  outline: 3px solid #7ba7e0;
  outline-offset: 3px;
}

.pine-cost-calculator__result {
  margin-top: 1.75rem;
}

.content-left_blog .w-richtext .pine-cost-calculator__result-title {
  color: #15234b;
  font-size: 1.35rem;
  line-height: 1.4;
  margin: 0 0 1rem;
}

.content-left_blog .w-richtext .pine-cost-calculator__result-section h3 {
  color: #263550;
  font-size: 1.05rem;
  line-height: 1.45;
  margin: 1.2rem 0 0.55rem;
}

.pine-cost-calculator__table-wrap {
  border: 1px solid #d8e1ec;
  border-radius: 0.6rem;
  overflow: hidden;
  width: 100%;
}

.content-left_blog .w-richtext .pine-cost-calculator__result table {
  border: 0;
  border-collapse: collapse;
  border-radius: 0;
  box-shadow: none;
  font-size: 0.92rem;
  margin: 0;
  min-width: 0 !important;
  table-layout: fixed;
  width: 100%;
}

.content-left_blog .w-richtext .pine-cost-calculator__result th,
.content-left_blog .w-richtext .pine-cost-calculator__result td {
  border: 0;
  border-bottom: 1px solid #e1e7ef;
  color: #2d3b53;
  line-height: 1.5;
  padding: 0.75rem 0.85rem;
  text-align: left;
  vertical-align: top;
  white-space: normal;
  word-break: keep-all;
}

.content-left_blog .w-richtext .pine-cost-calculator__result thead th {
  background: #203f70;
  color: #fff;
  font-weight: 700;
}

.content-left_blog .w-richtext .pine-cost-calculator__result tr:last-child th,
.content-left_blog .w-richtext .pine-cost-calculator__result tr:last-child td {
  border-bottom: 0;
}

.content-left_blog .w-richtext .pine-cost-calculator__result tbody th {
  background: #f8fafc;
  font-weight: 600;
  width: 62%;
}

.content-left_blog .w-richtext .pine-cost-calculator__result td {
  background: #fff;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.content-left_blog .w-richtext .pine-cost-calculator__result .pine-cost-calculator__subtotal th,
.content-left_blog .w-richtext .pine-cost-calculator__result .pine-cost-calculator__subtotal td {
  background: #eaf0f7;
  color: #15234b;
  font-weight: 800;
}

.pine-cost-calculator__original,
.pine-cost-calculator__discounted {
  display: block;
}

.pine-cost-calculator__original {
  color: #7b8798;
  text-decoration: line-through;
}

.pine-cost-calculator__discounted {
  color: #16724a;
  font-weight: 700;
  margin-top: 0.15rem;
}

.pine-cost-calculator__total {
  align-items: center;
  background: #152f58;
  border-radius: 0.7rem;
  color: #fff;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  margin-top: 1.25rem;
  padding: 1rem 1.15rem;
}

.pine-cost-calculator__total span {
  font-weight: 600;
}

.pine-cost-calculator__total strong {
  font-size: 1.25rem;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.content-left_blog .w-richtext .pine-cost-calculator__notice {
  color: #66758a;
  font-size: 0.82rem;
  line-height: 1.65;
  margin: 1rem 0 0;
  text-align: center;
}

@media (max-width: 640px) {
  .content-left_blog.pine-cost-calculator-article .w-richtext figure.w-richtext-figure-type-image {
    max-width: 100%;
  }

  .pine-cost-calculator {
    margin: 1.75rem 0;
  }

  .pine-cost-calculator__fields {
    grid-template-columns: 1fr;
  }

  .pine-cost-calculator__options {
    align-items: flex-start;
    flex-direction: column;
  }

  .content-left_blog .w-richtext .pine-cost-calculator__result th,
  .content-left_blog .w-richtext .pine-cost-calculator__result td {
    font-size: 0.82rem;
    padding: 0.65rem;
  }

  .content-left_blog .w-richtext .pine-cost-calculator__result tbody th {
    width: 58%;
  }

  .pine-cost-calculator__total {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.35rem;
  }

  .pine-cost-calculator__total strong {
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pine-cost-calculator__button {
    transition: none;
  }

  .pine-cost-calculator__button:hover {
    transform: none;
  }
}
