.eyebrow {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.calculator-picker {
  margin-bottom: 20px;
  padding: 22px;
  border-radius: 0.55rem;
  border: 1px solid rgba(15, 90, 112, 0.12);
  background:
    linear-gradient(135deg, rgba(8, 63, 80, 0.99), rgba(15, 90, 112, 0.95)),
    linear-gradient(90deg, rgba(240, 126, 93, 0.26), transparent 44%);
  color: #fff;
  box-shadow: 0 28px 64px rgba(10, 33, 42, 0.14);
}

.calculator-picker__header {
  display: block;
}

.calculator-picker__select-wrap {
  display: grid;
  gap: 8px;
  width: min(100%, 460px);
}

.calculator-picker .field-label {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.calculator-picker__select {
  width: 100%;
  min-height: 54px;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 0.55rem;
  background: rgba(255, 255, 255, 0.97);
  color: #245c85;
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9);
}

.calculator-picker__select:focus {
  outline: none;
  border-color: #54b4b7;
  box-shadow:
    0 0 0 4px rgba(31, 129, 147, 0.12),
    inset 0 1px 1px rgba(255, 255, 255, 0.9);
}

.calculator-layout {
  align-items: start;
}

.print-summary-panel {
  margin-bottom: 20px;
}

.print-summary-panel__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.print-summary-panel__copy h2 {
  margin: 0 0 6px;
  font-size: 1.4rem;
  font-weight: 800;
}

.print-summary-panel__copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.btn-print-summary {
  min-height: 48px;
  padding: 12px 18px;
  border: 0;
  border-radius: 0.35rem;
  background: #daff00;
  color: #004a60;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.lot-print-sheet {
  min-height: 0;
}

.print-render-source {
  position: static;
  width: 100%;
  visibility: visible;
  pointer-events: auto;
}

.lot-print-report {
  background: #fff;
  color: #1f2a22;
  border: 1px solid #d9e1e7;
  border-radius: 0.35rem;
  padding: 22px;
}

.lot-print-report__brand {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: end;
  padding-bottom: 14px;
  margin-bottom: 16px;
  border-bottom: 4px solid #111;
}

.lot-print-report__logo {
  width: 220px;
  height: auto;
  object-fit: contain;
}

.lot-print-report__contact {
  text-align: right;
  font-size: 0.9rem;
  line-height: 1.35;
}

.lot-print-report__header {
  display: block;
  margin-bottom: 16px;
}

.lot-print-report__header h3 {
  margin: 0;
  font-size: 1.7rem;
  font-weight: 800;
}

.lot-print-report__property {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  margin: 12px 0 18px;
  align-items: start;
  width: 100%;
}

.lot-print-report__property-card {
  padding: 12px 14px;
  border: 1px solid #d9e1e7;
  border-radius: 0.35rem;
  background: #fff;
}

.lot-print-report__property-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
}

.lot-print-report__property-card span {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
}

.lot-print-report__property-card--optional-empty {
  background: #f8fafb;
}

.lot-print-report__property-card:first-child {
  min-width: 0;
  width: 100%;
}

.lot-print-report__property-card:last-child {
  justify-self: end;
  width: max-content;
  max-width: 100%;
}

.lot-print-report__header p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.lot-print-report__status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 120px;
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 0.35rem;
  font-size: 0.9rem;
  font-weight: 800;
}

.lot-print-report__status--pass {
  background: #dff0e8;
  color: #16523e;
}

.lot-print-report__status--caution,
.lot-print-report__status--pending {
  background: #fff0cc;
  color: #7a5410;
}

.lot-print-report__status--fail {
  background: #f8ddd4;
  color: #853819;
}

.lot-print-report__intro {
  margin-bottom: 18px;
  padding: 16px 18px;
  border-left: 6px solid #88939a;
  background: #f8fafb;
}

.lot-print-report__intro--pass {
  border-left-color: var(--accent);
  background: #e6f4ea;
}

.lot-print-report__intro--caution,
.lot-print-report__intro--pending {
  border-left-color: #b8860b;
  background: #fff3bf;
}

.lot-print-report__intro--fail {
  border-left-color: var(--warn);
  background: #fde8df;
}

.lot-print-report__intro h4 {
  margin: 0 0 8px;
  font-size: 1.2rem;
  font-weight: 800;
}

.lot-print-report__intro p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.lot-print-report__note {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 12px;
  padding: 8px 12px;
  border-radius: 0.35rem;
  background: #8f2d1f;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 800;
  text-transform: uppercase;
}

.lot-print-report__content {
  display: grid;
  gap: 18px;
}

.lot-print-report__section {
  display: grid;
  gap: 12px;
}

.lot-print-report__section-title {
  margin: 0;
  padding: 10px 14px;
  border-radius: 0.35rem;
  background: #0f5a70;
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.lot-print-report__inputs,
.lot-print-report__metrics {
  display: grid;
  gap: 14px;
}

.lot-print-report__inputs {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.lot-print-report__metrics {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.lot-print-report__inputs,
.lot-print-report__metrics {
  gap: 14px;
}

.lot-print-report__input-card,
.lot-print-report__metric-card {
  padding: 14px 16px;
  border: 1px solid #d9e1e7;
  border-radius: 0.35rem;
  background: #fff;
}

.lot-print-report__input-card--optional-empty {
  background: #f8fafb;
}

.lot-print-report__input-card strong,
.lot-print-report__metric-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.lot-print-report__input-card span,
.lot-print-report__metric-card span {
  display: block;
  font-size: 1.2rem;
  font-weight: 800;
  line-height: 1.2;
}

.lot-print-report__metric-card small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.calculator-form-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(0, 2fr);
  gap: 24px;
  padding: 18px;
  align-items: start;
}

.calculator-form-main {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  align-content: start;
  align-self: start;
}

.calculator-form-side {
  display: flex;
  align-items: stretch;
}

.site-details-side-stack {
  display: grid;
  gap: 16px;
  width: 100%;
}

.field {
  display: grid;
  gap: 10px;
}

.field-group--optional-print {
  display: grid;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid #d9e1e7;
  border-radius: 0.35rem;
  background: #f8fafb;
}

.field-group__note {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.4;
}

.field-label {
  display: flex;
  align-items: baseline;
  justify-content: flex-start;
  gap: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  text-align: left;
}

.field-unit {
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 600;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 52px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 0.35rem;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid rgba(23, 98, 74, 0.18);
  border-color: var(--accent);
}

.summary-grid,
.details-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.summary-grid--side {
  margin-top: 0;
  grid-template-columns: 1fr;
}

.summary-card {
  padding: 18px;
}

.recommendation-card {
  border-left: 6px solid #88939a;
}

.recommendation-card--pass {
  border-left-color: var(--accent);
  background: #e6f4ea;
}

.recommendation-card--caution {
  border-left-color: #b8860b;
  background: #fff3bf;
}

.recommendation-card--fail {
  border-left-color: var(--warn);
  background: #fde8df;
}

.summary-status-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.status-pill,
.status-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  min-height: 32px;
  padding: 6px 10px;
  border-radius: 0.35rem;
  font-size: 0.83rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.status-pill--pass,
.status-chip--pass {
  background: #dff0e8;
  color: #16523e;
}

.status-pill--caution {
  background: #fff0cc;
  color: #7a5410;
}

.status-pill--fail,
.status-chip--fail {
  background: #f8ddd4;
  color: #853819;
}

.summary-heading {
  font-size: 1.2rem;
  font-weight: 800;
}

.recommendation-card--side {
  min-height: 0;
  padding: 22px;
}

.recommendation-card--side.recommendation-card--pass {
  display: flex;
  align-items: start;
  gap: 16px;
}

.recommendation-icon {
  font-size: 3rem;
  line-height: 1;
  flex: 0 0 60px;
  margin-top: 6px;
  text-align: center;
}

.recommendation-content {
  flex: 1 1 auto;
  min-width: 0;
}

.recommendation-card--side .summary-status-row {
  align-items: flex-start;
}

.recommendation-card--side .summary-heading {
  font-size: 1.05rem;
  line-height: 1.2;
}

.recommendation-card--side .summary-text {
  font-size: 0.96rem;
  line-height: 1.55;
}

.recommendation-note-row {
  margin-top: 14px;
}

.recommendation-note {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 0.35rem;
  background: #8f2d1f;
  color: #fff;
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.summary-grid--side .metric-card {
  padding: 18px 20px;
}

.summary-grid--side .metric-label {
  font-size: 1rem;
}

.summary-grid--side .metric-value {
  font-size: clamp(1.45rem, 2.4vw, 2rem);
}

.metric-subvalue {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.metric-subvalue--side {
  margin: 0;
  white-space: nowrap;
}

.metric-inline-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.summary-grid--side .metric-detail {
  font-size: 0.92rem;
}

.metric-detail--top {
  margin: 0 0 12px;
}

.summary-text,
.decision-text,
.metric-detail {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.summary-text--alert {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.summary-heading--alert {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.summary-heading--alert::before {
  content: "!";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.44rem;
  height: 1.44rem;
  flex: 0 0 auto;
  background: #f4c542;
  color: #111;
  border-radius: 50%;
  font-size: 1rem;
  font-weight: 900;
  line-height: 1;
}

.summary-heading--alert-fail::before {
  background: #a23420;
  color: #fff;
}

.summary-text--alert::before {
  content: "!";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.44rem;
  height: 1.44rem;
  margin-top: calc(0.18rem - 8px);
  flex: 0 0 auto;
  background: #54b4b7;
  color: #004a60;
  border-radius: 50%;
  font-size: 1rem;
  font-weight: 900;
  line-height: 1;
  transform: translateY(6px);
}

.metric-label {
  margin: 0;
  color: #111;
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.metric-value {
  margin: 8px 0 0;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 800;
  line-height: 1;
  color: #1f2a22;
}

.metric-value--small {
  font-size: clamp(1.2rem, 3vw, 1.65rem);
  line-height: 1.2;
}

.metric-value--pass {
  color: #16523e;
}

.metric-value--fail {
  color: #853819;
}

.decision-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.decision-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.decision-header h3 {
  margin: 0;
  font-size: 1.05rem;
}

.decision-header--card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  column-gap: 12px;
  row-gap: 4px;
  margin-bottom: 14px;
}

.decision-header--card .metric-label {
  margin: 0;
  grid-column: 1 / -1;
}

.decision-header--card .metric-formula {
  grid-column: 1;
  margin: 0;
}

.decision-header--card .status-chip {
  grid-column: 2;
  grid-row: 2;
  align-self: start;
}

.metric-formula {
  margin: 4px 0 0;
  color: #8a949b;
  font-size: 0.74rem;
  font-weight: 500;
  line-height: 1.35;
}

.table-wrap {
  margin-top: 18px;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.lookup-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

.lookup-table th,
.lookup-table td {
  padding: 12px 14px;
  border-bottom: 1px solid #e3e8ec;
  text-align: left;
}

.lookup-table thead th {
  background: #0f5a70;
  color: #fff;
  font-size: 0.9rem;
}

.lookup-table tbody tr:nth-child(even) {
  background: #f8fafb;
}

@media (max-width: 900px) {
  .print-summary-panel__head {
    flex-direction: column;
    align-items: stretch;
  }

  .calculator-form-grid,
  .summary-grid,
  .details-grid,
  .lot-print-report__content,
  .lot-print-report__property,
  .lot-print-report__inputs,
  .lot-print-report__metrics {
    grid-template-columns: 1fr;
  }

  .calculator-form-main {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .print-summary-panel,
  .field-group--optional-print {
    display: none;
  }
}

@media print {
  @page {
    margin: 0.45in;
  }

  body {
    background: #fff;
  }

  .site-header,
  #siteHeaderMenuRow,
  .hero,
  .calculator-picker,
  .panel,
  .calculator-details-panel,
  .print-summary-panel__head,
  .site-footer {
    display: none !important;
  }

  .page-shell,
  .calculator-layout,
  .print-summary-panel,
  .lot-print-sheet {
    width: 100%;
    margin: 0;
    padding: 0;
  }

  .print-summary-panel,
  .lot-print-sheet {
    border: 0;
    box-shadow: none;
    background: #fff;
  }

  .print-render-source {
    position: static;
    width: 100%;
    visibility: visible;
    pointer-events: auto;
  }

  .lot-print-report {
    display: block;
    border: 0;
    border-radius: 0;
    padding: 0;
    font-size: 12px;
  }

  .lot-print-report__header {
    align-items: flex-start;
    margin-bottom: 10px;
  }

  .lot-print-report__property {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    margin: 8px 0 12px;
  }

  .lot-print-report__content {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .lot-print-report__inputs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }

  .lot-print-report__metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .lot-print-report__brand {
    gap: 12px;
    padding-bottom: 8px;
    margin-bottom: 10px;
    border-bottom-width: 3px;
  }

  .lot-print-report__logo {
    width: 170px;
  }

  .lot-print-report__contact {
    font-size: 0.72rem;
    line-height: 1.2;
  }

  .lot-print-report__header h3 {
    font-size: 1.28rem;
    line-height: 1.05;
  }

  .lot-print-report__property-card {
    padding: 8px 10px;
  }

  .lot-print-report__property-card strong {
    margin-bottom: 4px;
    font-size: 0.62rem;
  }

  .lot-print-report__property-card span {
    font-size: 0.86rem;
    line-height: 1.2;
  }

  .lot-print-report__intro {
    margin-bottom: 12px;
    padding: 10px 12px;
    border-left-width: 5px;
  }

  .lot-print-report__intro h4 {
    margin-bottom: 4px;
    font-size: 1rem;
    line-height: 1.15;
  }

  .lot-print-report__intro p {
    font-size: 0.82rem;
    line-height: 1.3;
  }

  .lot-print-report__note {
    margin-top: 8px;
    padding: 6px 10px;
    font-size: 0.72rem;
  }

  .lot-print-report__section {
    gap: 8px;
  }

  .lot-print-report__section-title {
    padding: 7px 10px;
    font-size: 0.76rem;
  }

  .lot-print-report__input-card,
  .lot-print-report__metric-card {
    padding: 10px 12px;
  }

  .lot-print-report__input-card strong,
  .lot-print-report__metric-card strong {
    margin-bottom: 4px;
    font-size: 0.62rem;
  }

  .lot-print-report__input-card span,
  .lot-print-report__metric-card span {
    font-size: 0.98rem;
    line-height: 1.15;
  }

  .lot-print-report__metric-card small {
    margin-top: 6px;
    font-size: 0.7rem;
    line-height: 1.25;
  }
}

.summary-card.recommendation-card--pass {
  background: #e6f4ea;
  border-color: #7fb68f;
}

.summary-card.recommendation-card--caution {
  background: #fff3bf;
  border-color: #d4a017;
}

.summary-card.recommendation-card--fail {
  background: #fde8df;
  border-color: #cf8b72;
}

.form-section {
  margin-bottom: 18px;
  border: 0;
  border-radius: 0;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.96);
}

.section-banner {
  border-top-left-radius: 0.35rem;
  border-top-right-radius: 0.35rem;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  padding: 16px;
}

.project-record-stack {
  padding: 16px 16px 16px;
  display: grid;
  gap: 0;
}

.record-group {
  border: 0.5px solid #111;
  border-top: 0;
  background: #fff;
}

.record-group-title {
  padding: 8px 12px 7px;
  background: #0f5a70;
  color: #fff;
  font-size: 1.1rem;
  font-family: "Outfit", "Plus Jakarta Sans", "Helvetica Neue", Arial, sans-serif;
  font-weight: 200;
  line-height: 1.15;
}

.record-grid,
.comments-grid {
  padding: 0;
}

.record-grid {
  grid-template-columns: 2fr 1.55fr 1.3fr;
}

.comments-grid {
  grid-template-columns: 2.8fr 1fr;
  align-items: start;
}

.comments-field textarea {
  min-height: 180px;
  height: 100%;
}

.comments-field {
  height: 100%;
}

.stamp-upload-wrap {
  display: grid;
  justify-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px;
}

.stamp-preview {
  position: relative;
  display: grid;
  place-items: center;
  width: 200px;
  height: 200px;
  border: 0.5px solid #111;
  background: #fff;
  overflow: hidden;
}

.stamp-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
}

.stamp-placeholder {
  color: #49545c;
  font-size: 0.95rem;
  text-align: center;
  padding: 12px;
}

.stamp-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.permit-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) fit-content(22rem);
  align-items: stretch;
  background: #fff;
}

.permit-grid .field {
  min-width: 0;
}

.permit-grid .permit-type-field {
  min-width: 20rem;
}

.property-grid {
  grid-template-columns: 2fr 1fr 1.25fr;
  align-items: stretch;
  border: 0.5px solid #111;
  background: #fff;
}

.property-grid .field {
  min-width: 0;
}

.property-address {
  grid-column: span 1;
}

.permit-grid .field:last-child,
.property-grid .field:last-child {
  border-right: 0;
}

.toolbar {
  display: flex;
  gap: 12px;
  align-items: end;
  flex-wrap: wrap;
  padding: 18px;
  margin-bottom: 0;
}

.toolbar .field {
  margin: 0;
  flex: 1 1 260px;
}

.button-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.button-row--form {
  margin-top: 4px;
}

.button-row--form .btn-secondary {
  background: #004a60;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

#individualComponentsSection {
  margin-top: 20px;
  border-color: #256fb0;
  background: linear-gradient(180deg, #b9e1ff 0%, #7fc8ff 100%);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.42),
    0 10px 24px rgba(37, 111, 176, 0.14);
}

#individualComponentsSection .section-banner {
  background: linear-gradient(180deg, #2a688f 0%, #174663 100%);
}

#individualComponentsSection .toolbar {
  background: transparent;
}

#individualComponentsSection .toolbar select {
  height: 58px;
  min-height: 58px;
}

#individualComponentsSection .toolbar .btn-primary {
  height: 58px;
  min-height: 58px;
}

.sort-hint {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: -4px 0 18px;
  padding: 12px 14px;
  border: 1px solid #e2c15b;
  border-radius: var(--radius);
  background: linear-gradient(180deg, #fff5bf 0%, #f5dd6d 100%);
  color: #5b4500;
  font-size: 0.94rem;
  font-weight: 700;
}

.sort-hint-icon {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 42px;
  height: 38px;
  align-self: center;
}

.sort-hint-icon::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  border-left: 21px solid transparent;
  border-right: 21px solid transparent;
  border-bottom: 36px solid #a87300;
  transform: translate(-50%, -50%);
}

.sort-hint-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: calc(50% + 2px);
  width: 0;
  height: 0;
  border-left: 16px solid transparent;
  border-right: 16px solid transparent;
  border-bottom: 28px solid #ffe88d;
  transform: translate(-50%, -50%);
}

.sort-hint-icon-inner {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #7b5600;
  font-size: 1.55rem;
  font-weight: 800;
  line-height: 1;
  transform: translateY(4px);
}

button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 0.35rem;
  padding: 12px 18px;
  font: inherit;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.btn-icon-plus {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 8px;
  font-size: 1.55em;
  font-weight: 800;
  line-height: 1;
  vertical-align: middle;
  transform: translateY(-0.08em);
}

.btn-icon-minus {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 8px;
  font-size: 1.55em;
  font-weight: 900;
  line-height: 1;
  vertical-align: middle;
  transform: translateY(-0.12em);
}

.btn-icon-print {
  display: inline-flex;
  width: 1.53em;
  height: 1.53em;
  margin-right: 10px;
  flex: 0 0 auto;
  object-fit: contain;
  transform: translateY(0.02em);
}

button:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-secondary {
  background: #e8ecef;
  color: var(--ink);
}

.btn-print {
  background: #54b4b7;
  color: #004a60;
}

.btn-danger {
  background: #56215e;
  color: #fff;
}

.switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
  padding: 0;
  background: transparent;
  border: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #ccc;
  transition: 0.4s;
}

.slider::before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: #fff;
  transition: 0.4s;
}

.switch input:checked + .slider {
  background-color: #2196f3;
}

.switch input:focus + .slider {
  box-shadow: 0 0 1px #2196f3;
}

.switch input:checked + .slider::before {
  transform: translateX(26px);
}

.slider.round {
  border-radius: 34px;
}

.slider.round::before {
  border-radius: 50%;
}

.field-list {
  display: grid;
  gap: 18px;
}

.component-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 0 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 246, 248, 0.95));
  cursor: move;
  overflow: hidden;
}

.component-card.is-dragging {
  opacity: 0.55;
  border-color: var(--accent);
}

.component-dragbar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 68px;
  margin: 0 -18px 18px;
  padding: 12px 16px;
  border-bottom: 1px solid #e2c15b;
  background: linear-gradient(180deg, #fff5bf 0%, #f5dd6d 100%);
}

.component-dragbar::before,
.component-dragbar::after {
  content: "";
  position: absolute;
  top: 0;
  width: 44px;
  height: 100%;
  background:
    radial-gradient(circle at 10px 10px, rgba(154, 106, 0, 0.24) 0, rgba(154, 106, 0, 0.24) 3px, transparent 3px),
    radial-gradient(circle at 24px 18px, rgba(154, 106, 0, 0.18) 0, rgba(154, 106, 0, 0.18) 2px, transparent 2px),
    repeating-linear-gradient(135deg, rgba(154, 106, 0, 0.14) 0 4px, transparent 4px 8px);
  opacity: 0.95;
}

.component-dragbar::before {
  left: 0;
  border-right: 1px solid rgba(154, 106, 0, 0.2);
}

.component-dragbar::after {
  right: 0;
  border-left: 1px solid rgba(154, 106, 0, 0.2);
  transform: scaleX(-1);
}

.component-dragbar-icon {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 42px;
  height: 38px;
}

.component-dragbar-icon::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  border-left: 21px solid transparent;
  border-right: 21px solid transparent;
  border-bottom: 36px solid #a87300;
  transform: translate(-50%, -50%);
}

.component-dragbar-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: calc(50% + 1px);
  width: 0;
  height: 0;
  border-left: 16px solid transparent;
  border-right: 16px solid transparent;
  border-bottom: 28px solid #ffe88d;
  transform: translate(-50%, -50%);
}

.component-dragbar-icon-inner {
  position: relative;
  z-index: 1;
  color: #7b5600;
  font-size: 1.55rem;
  font-weight: 800;
  line-height: 1;
  transform: translateY(4px);
}

.component-dragbar-label {
  position: relative;
  z-index: 1;
  font-family: "Outfit", "Plus Jakarta Sans", "Helvetica Neue", Arial, sans-serif;
  color: #5b4500;
  font-size: 1.88rem;
  font-weight: 200;
  line-height: 1.3;
  text-align: center;
  max-width: 620px;
}

.component-sort-banner {
  display: block;
  margin: 0 0 18px;
  border: 1px solid #e2c15b;
  border-radius: var(--radius);
}

.component-sort-banner-main {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.component-sort-banner-subcopy {
  position: relative;
  z-index: 1;
  margin-top: 12px;
  padding-top: 12px;
  width: fit-content;
  max-width: calc(100% - 60px);
  margin-left: auto;
  margin-right: auto;
  border-top: 1px solid rgba(154, 106, 0, 0.28);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.35;
  text-align: center;
  color: #6a5300;
}

.component-head {
  position: relative;
  display: grid;
  grid-template-columns: max-content max-content minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  margin: 0;
  padding: 15px 58px;
  background: #0f5a70;
  color: #fff;
  overflow: hidden;
}

.component-head.has-mode-toggle {
  min-height: 108px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.lot-size-page .lot-size-shell {
  --ls-teal: #004a60;
  --ls-teal-deep: #245c85;
  --ls-sea: #54b4b7;
  --ls-coral: #54b4b7;
  --ls-gold: #fbf0d7;
  --ls-shadow: 0 28px 64px rgba(10, 33, 42, 0.14);
  width: min(1040px, calc(100% - 28px));
  padding-bottom: 88px;
}

.lot-size-page .hero {
  margin-bottom: 22px;
}

.lot-size-page .hero-card {
  position: relative;
  overflow: hidden;
  padding: 28px 30px;
  border: 1px solid rgba(15, 90, 112, 0.12);
  border-radius: 0.55rem;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.98) 0%, rgba(251, 240, 215, 0.9) 72%, rgba(227, 243, 243, 0.72) 100%);
  box-shadow: var(--ls-shadow);
}

.lot-size-page .hero-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 12px;
  background: linear-gradient(180deg, #004a60 0%, #54b4b7 100%);
}

.lot-size-page .hero-card h1 {
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 4.5rem);
  line-height: 0.94;
  letter-spacing: -0.04em;
}

.lot-size-page .panel,
.lot-size-page .summary-card,
.lot-size-page .form-section {
  border-radius: 0.55rem;
  box-shadow: var(--ls-shadow);
}

.lot-size-page .panel {
  padding: 0;
  overflow: visible;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.lot-size-page .form-section,
.lot-size-page .summary-card {
  border: 1px solid rgba(15, 90, 112, 0.12);
}

.lot-size-page .calculator-picker {
  padding: 22px;
  background:
    linear-gradient(135deg, rgba(8, 63, 80, 0.99), rgba(15, 90, 112, 0.95)),
    linear-gradient(90deg, rgba(240, 126, 93, 0.26), transparent 44%);
  color: #fff;
}

.lot-size-page .calculator-picker__header,
.lot-size-page .calculator-picker__select-wrap,
.lot-size-page .calculator-picker .field-label {
  background: transparent;
}

.lot-size-page .calculator-picker__select-wrap {
  width: min(100%, 460px);
  padding: 0;
  position: relative;
  z-index: 1;
}

.lot-size-page .calculator-picker .field-label {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lot-size-page .calculator-picker__select {
  border-color: rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.97);
  color: var(--ls-teal-deep);
}

.lot-size-page .calculator-picker__select:focus {
  border-color: var(--ls-sea);
  box-shadow:
    0 0 0 4px rgba(31, 129, 147, 0.12),
    inset 0 1px 1px rgba(255, 255, 255, 0.9);
}

.lot-size-page .form-section {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 251, 252, 0.97));
  overflow: hidden;
}

.lot-size-page .section-banner {
  position: relative;
  overflow: hidden;
  padding: 18px 22px 16px;
  border-top-left-radius: 0.55rem;
  border-top-right-radius: 0.55rem;
  background:
    linear-gradient(135deg, var(--ls-teal-deep), var(--ls-sea)),
    linear-gradient(90deg, rgba(240, 126, 93, 0.28), transparent 50%);
  color: #fff;
}

.lot-size-page .section-banner::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 12px;
  background: linear-gradient(180deg, #daff00 0%, #b8df00 100%);
}

.lot-size-page .section-banner__title,
.lot-size-page .section-banner__detail {
  display: block;
}

.lot-size-page .section-banner__detail {
  margin-top: 4px;
  font-size: 0.52em;
  font-weight: 300;
  line-height: 1.15;
  opacity: 0.92;
}

.lot-size-page .calculator-form-grid {
  gap: 20px;
  padding: 22px;
  grid-template-columns: minmax(280px, 0.92fr) minmax(0, 1.08fr);
}

.lot-size-page .calculator-form-main {
  gap: 14px;
}

.lot-size-page .site-details-side-stack {
  gap: 18px;
}

.lot-size-page .field {
  gap: 8px;
}

.lot-size-page .field-label {
  color: #39535d;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.lot-size-page .field-unit {
  color: #71818a;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: none;
}

.lot-size-page .field input,
.lot-size-page .field select,
.lot-size-page .field textarea {
  min-height: 54px;
  padding: 12px 14px;
  border: 1px solid rgba(15, 90, 112, 0.12);
  border-radius: 0.55rem;
  background: linear-gradient(180deg, #ffffff, #f8fbfc);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9);
}

.lot-size-page .field input:focus,
.lot-size-page .field select:focus,
.lot-size-page .field textarea:focus {
  outline: none;
  border-color: var(--ls-sea);
  box-shadow:
    0 0 0 4px rgba(31, 129, 147, 0.12),
    inset 0 1px 1px rgba(255, 255, 255, 0.9);
}

.lot-size-page .field--empty input,
.lot-size-page .field--empty select {
  border-color: rgba(240, 126, 93, 0.36);
  background: linear-gradient(180deg, #fffdfb, #fff5f0);
}

.lot-size-page .button-row--form {
  margin-top: 8px;
}

.lot-size-page .button-row--form .btn-secondary {
  min-height: 52px;
  padding: 12px 18px;
  border-radius: 0.55rem;
  background: #004a60;
  color: #fff;
  letter-spacing: 0.04em;
}

.lot-size-page .recommendation-card--side,
.lot-size-page .metric-card {
  border-radius: 0.55rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 251, 252, 0.97));
}

.lot-size-page .recommendation-card {
  border-left: 0;
  position: relative;
  overflow: hidden;
}

.lot-size-page .recommendation-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 8px;
  background: linear-gradient(180deg, #daff00 0%, #b8df00 100%);
}

.lot-size-page .recommendation-card--pass {
  background: linear-gradient(135deg, rgba(230, 244, 234, 0.98), rgba(247, 251, 252, 0.97));
}

.lot-size-page .recommendation-card--caution {
  background: linear-gradient(135deg, rgba(255, 243, 191, 0.98), rgba(255, 250, 233, 0.97));
}

.lot-size-page .recommendation-card--fail {
  background: linear-gradient(135deg, rgba(253, 232, 223, 0.98), rgba(255, 246, 242, 0.97));
}

.lot-size-page .summary-grid {
  gap: 18px;
}

.lot-size-page .summary-grid--side {
  grid-template-columns: 1fr;
}

.lot-size-page .summary-grid--side .metric-card {
  padding: 20px;
}

.lot-size-page .decision-header--card {
  margin-bottom: 16px;
  row-gap: 6px;
}

.lot-size-page .metric-label {
  color: #21323a;
  font-size: 0.94rem;
  letter-spacing: 0.07em;
}

.lot-size-page .metric-formula {
  color: #73828a;
  font-size: 0.76rem;
  line-height: 1.4;
}

.lot-size-page .status-chip,
.lot-size-page .status-pill {
  min-height: 34px;
  border-radius: 0.7rem;
}

.lot-size-page .metric-inline-row {
  display: grid;
  justify-items: start;
  gap: 4px;
}

.lot-size-page .metric-inline-row + .metric-inline-row {
  margin-top: 18px;
}

.lot-size-page .metric-value {
  margin: 0;
  font-size: clamp(1.55rem, 3vw, 2.15rem);
  line-height: 1.02;
}

.lot-size-page .metric-value--small {
  font-size: clamp(1.55rem, 3vw, 2.15rem);
}

.lot-size-page .metric-subvalue {
  color: #617078;
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  margin: 0;
}

.lot-size-page .summary-text--alert::before {
  background: #f4c542;
  color: #111;
}

.lot-size-page .calculator-details-panel {
  margin-top: 18px;
  padding: 22px;
  border: 1px solid rgba(15, 90, 112, 0.12);
  border-radius: 1.1rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 251, 252, 0.97));
  box-shadow: var(--ls-shadow);
}

.lot-size-page .calculator-details-panel h2 {
  color: var(--ls-teal-deep);
}

.lot-size-page .table-wrap {
  border-radius: 0.9rem;
  overflow: hidden;
}

.lot-size-page .lookup-table thead th {
  background: linear-gradient(135deg, var(--ls-teal-deep), var(--ls-sea));
}

@media (max-width: 900px) {
  .lot-size-page .lot-size-shell {
    width: min(100%, calc(100% - 20px));
  }

  .lot-size-page .calculator-form-grid,
  .lot-size-page .summary-grid--side {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .lot-size-page .lot-size-shell {
    width: min(100%, calc(100% - 16px));
    padding-bottom: 96px;
  }

  .lot-size-page .hero-card,
  .lot-size-page .form-section,
  .lot-size-page .summary-card,
  .lot-size-page .calculator-details-panel {
    border-radius: 0.55rem;
  }

  .lot-size-page .hero-card {
    padding: 22px 18px;
  }

  .lot-size-page .hero-card h1 {
    font-size: clamp(2rem, 11vw, 2.85rem);
    line-height: 0.96;
  }

  .lot-size-page .section-banner {
    padding: 16px 16px 14px;
    font-size: 1.28rem;
  }

  .lot-size-page .calculator-form-grid,
  .lot-size-page .calculator-details-panel {
    padding: 16px;
  }

  .lot-size-page .summary-grid--side .metric-card,
  .lot-size-page .recommendation-card--side {
    padding: 16px;
  }

  .lot-size-page .field-label {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .lot-size-page .metric-inline-row {
    justify-items: center;
    text-align: center;
  }

  .lot-size-page .decision-header--card {
    display: block;
    margin-bottom: 14px;
    text-align: center;
  }

  .lot-size-page .decision-header--card .status-chip {
    margin-top: 10px;
    margin-left: auto;
    margin-right: auto;
  }
}

.component-head-copy {
  position: relative;
  z-index: 1;
  min-width: 0;
  max-width: 100%;
  grid-column: 1;
}

.component-head::before,
.component-head::after {
  content: "";
  position: absolute;
  top: 0;
  width: 44px;
  height: 100%;
  background:
    radial-gradient(circle at 12px 11px, rgba(219, 239, 231, 0.42) 0, rgba(219, 239, 231, 0.42) 3px, transparent 3px),
    radial-gradient(circle at 28px 21px, rgba(219, 239, 231, 0.28) 0, rgba(219, 239, 231, 0.28) 2px, transparent 2px),
    repeating-linear-gradient(135deg, rgba(214, 236, 227, 0.34) 0 4px, transparent 4px 8px);
  opacity: 0.95;
}

.component-head::before {
  left: 0;
  border-right: 1px solid rgba(214, 236, 227, 0.24);
}

.component-head::after {
  right: 0;
  border-left: 1px solid rgba(214, 236, 227, 0.24);
  transform: scaleX(-1);
}

.component-head h3 {
  margin: 0 0 4px;
  font-size: 1.15rem;
  color: #fff;
}

.component-head p {
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.96rem;
}

.component-head-actions {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  grid-column: 4;
  justify-self: end;
  margin-left: 0;
}

.component-head-actions .btn-danger {
  white-space: nowrap;
}

.component-mode-toggle {
  display: grid;
  gap: 7px;
  justify-items: center;
  grid-column: 2;
  justify-self: start;
  width: 220px;
  min-width: 220px;
  max-width: 220px;
  flex: 0 0 220px;
  align-self: center;
  padding: 10px 7px;
  border-radius: 0.35rem;
  background: rgba(214, 236, 227, 0.2);
  border: 1px solid rgba(214, 236, 227, 0.28);
  position: relative;
  z-index: 1;
}

.component-mode-toggle-label {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.2;
  min-height: 20px;
  display: flex;
  align-items: center;
  text-align: center;
}

.component-mode-toggle-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.component-mode-toggle-text {
  color: #fff;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1;
}

.component-mode-toggle .switch {
  width: 54px;
  height: 30px;
  flex: 0 0 auto;
}

.component-mode-toggle .slider {
  background-color: #33b8ff;
  border: 1px solid rgba(17, 17, 17, 0.12);
}

.component-mode-toggle .slider::before {
  height: 22px;
  width: 22px;
  left: 4px;
  bottom: 3px;
}

.component-mode-toggle .switch input:checked + .slider {
  background-color: #6a1b9a;
}

.component-mode-toggle .switch input:focus + .slider {
  box-shadow: 0 0 1px #6a1b9a;
}

.component-mode-toggle .switch input:checked + .slider::before {
  transform: translateX(24px);
}

.component-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
  width: 100%;
  min-width: 0;
  margin: 16px 18px 0;
  border: 0.5px solid #111;
  background: #fff;
}

.component-grid-row {
  display: grid;
  gap: 0;
}

.component-grid-row + .component-grid-row {
  border-top: 0.5px solid #111;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-right: 0.5px solid #111;
  border-bottom: 0.5px solid #111;
  background: #fff;
}

.field-full {
  grid-column: 1 / -1;
}

.field-no-label input,
.field-no-label select,
.field-no-label textarea {
  min-height: 56px;
}

label {
  display: block;
  padding: 7px 8px 6px;
  background: #efefef;
  color: #111;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.15;
  border-bottom: 0.5px solid #111;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
}

.component-grid label {
  height: 100%;
}

input,
select,
textarea {
  width: 100%;
  border: 0;
  border-radius: 0;
  background: #fff;
  min-height: 56px;
  padding: 10px 12px;
  font: inherit;
  color: var(--ink);
  box-shadow: none;
}

textarea {
  min-height: 88px;
  resize: vertical;
}

.calculator-form-main .field {
  display: grid;
  gap: 4px;
  border-right: 0;
  border-bottom: 0;
  background: transparent;
  align-content: start;
}

.calculator-form-main label.field {
  padding: 0;
  background: transparent;
  border-bottom: 0;
  text-align: left;
}

.calculator-form-main .field input,
.calculator-form-main .field select,
.calculator-form-main .field textarea {
  min-height: 40px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 0.35rem;
  background: #fff;
  font-size: 0.96rem;
  font-weight: 600;
}

.calculator-form-main .field--empty .field-label {
  color: #8a5a00;
}

.calculator-form-main .field--empty .field-unit {
  color: #a86a00;
}

.calculator-form-main .field--empty input,
.calculator-form-main .field--empty select,
.calculator-form-main .field--empty textarea {
  background: #fff8dc;
  border-color: #d4a017;
  box-shadow: inset 0 0 0 1px rgba(212, 160, 23, 0.08);
}

.calculator-form-main .field input:focus,
.calculator-form-main .field select:focus,
.calculator-form-main .field textarea:focus {
  outline: 2px solid rgba(23, 98, 74, 0.18);
  border-color: var(--accent);
}

.component-grid .field-full {
  border-right: 0;
}

.component-grid-row .field:last-child:not(.field-full) {
  border-right: 0;
}

.component-grid-row:last-child .field {
  border-bottom: 0;
}

.component-grid .field-full:last-child {
  border-bottom: 0;
}

.empty-state {
  border: 1px dashed #c2cad2;
  border-radius: var(--radius);
  padding: 26px;
  text-align: center;
  color: var(--muted);
  background: rgba(244, 246, 248, 0.9);
}

.summary-card {
  padding: 24px;
  position: static;
}

.summary-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.summary-head-copy {
  display: grid;
  gap: 4px;
}

.summary-head h2 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
}

.print-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.35;
}

.print-sheet {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  min-height: 420px;
}

.report-brand-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: end;
  padding-bottom: 14px;
  margin-bottom: 10px;
  border-bottom: 4px solid #111;
}

.report-brand-block {
  display: flex;
  align-items: end;
  gap: 18px;
}

.report-logo {
  width: 220px;
  height: auto;
  object-fit: contain;
}

.report-brand-contact {
  text-align: right;
  font-size: 0.9rem;
  line-height: 1.35;
}

.report-header {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.8fr);
  gap: 18px;
  align-items: start;
  padding-bottom: 10px;
  margin-bottom: 10px;
}

.report-title-block {
  min-width: 0;
}

.report-header-side {
  display: grid;
  gap: 0;
}

.report-header h3 {
  margin: 0;
  font-size: 1.65rem;
  font-weight: 800;
  line-height: 1.12;
}

.report-header p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.project-report-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.project-report-grid-primary {
  justify-self: stretch;
  width: 100%;
  max-width: 100%;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
}

.project-report-grid-secondary {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-top: 14px;
}

.report-property-section {
  margin-top: 10px;
  border: 0.5px solid #111;
}

.report-property-title {
  padding: 8px 12px 7px;
  background: #0f5a70;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.report-property-section .project-report-grid-secondary {
  margin-top: 0;
  gap: 0;
}

.report-property-section .project-report-grid-secondary .report-item {
  padding: 0;
  border-radius: 0;
  border: 0.5px solid #111;
  background: #fff;
}

.report-property-section .project-report-grid-secondary .report-item strong {
  margin: 0;
  padding: 6px 8px 4px;
  background: transparent;
  color: #111;
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
  border-bottom: 0;
  white-space: nowrap;
}

.report-property-section .project-report-grid-secondary .report-item div {
  min-height: 42px;
  padding: 0 8px 8px;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
}

.report-permit-display {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 8px 10px;
  background: #fff;
  color: #111;
  border: 0.5px solid #111;
  border-top: 0;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
}

.report-item-half {
  grid-column: span 3;
}

.report-item-full {
  grid-column: span 6;
}

.report-item-address {
  grid-column: span 3;
}

.report-item-third {
  grid-column: span 1;
}

.report-property-section .project-report-grid-secondary .report-item:last-child {
  grid-column: span 2;
}

.report-item.report-item-compact {
  padding: 0;
  overflow: hidden;
  border-radius: 0;
  border: 0.5px solid #111;
  background: #fff;
}

.report-item.report-item-compact strong {
  display: block;
  margin: 0;
  padding: 8px 10px 7px;
  background: #0f5a70;
  color: #fff;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  white-space: nowrap;
  border-bottom: 0.5px solid #111;
  text-align: center;
}

.report-item-compact div {
  font-size: 0.95rem;
  font-weight: 600;
  white-space: nowrap;
  min-height: 40px;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.report-section {
  margin-top: 14px;
}

.report-section:first-of-type {
  margin-top: 14px;
}

.report-section h4 {
  position: relative;
  margin: 0;
  padding: 8px 14px 7px;
  background: #0f5a70;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  text-align: left;
}

.report-table-head,
.report-table-body {
  display: grid;
  gap: 0;
}

.report-table-cell {
  border: 0.5px solid #111;
}

.report-table-label {
  padding: 7px 8px 6px;
  background: #efefef;
  color: #111;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
}

.report-table-value {
  min-height: 48px;
  padding: 10px 8px;
  background: #fff;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.25;
  text-align: center;
}

.report-notes {
  margin-top: 12px;
  padding: 12px 14px;
  background: #f5f7f8;
  border-radius: var(--radius);
  border: 1px solid #dde3e8;
  white-space: pre-wrap;
}

.report-empty {
  color: var(--muted);
  line-height: 1.6;
}

.report-records {
  margin-top: 18px;
}

.report-records-heading {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
}

.report-records-subheading {
  margin: 2px 0 18px;
  font-size: 0.92rem;
  font-weight: 700;
  text-align: center;
}

.report-records-note,
.report-records-ack-copy {
  margin: 0 0 14px;
  font-size: 0.98rem;
  line-height: 1.45;
}

.report-records-note strong,
.report-records-ack-title {
  font-weight: 800;
}

.report-records-ack-title {
  margin: 0 0 4px;
  font-size: 0.98rem;
}

.report-drawing-box {
  height: 420px;
  margin: 0 0 10px;
  border: 0.5px solid #111;
  background: #fff;
}

.report-record-group {
  margin-top: 10px;
  border: 0.5px solid #111;
}

.report-record-group-title {
  padding: 8px 12px 7px;
  background: #0f5a70;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.report-record-grid,
.report-comments-output-grid {
  display: grid;
  gap: 0;
  background: #fff;
}

.report-comments-output-grid {
  grid-template-columns: 2.8fr 1fr;
}

.report-record-item {
  border-right: 0.5px solid #111;
}

.report-record-item:last-child {
  border-right: 0;
}

.report-record-label {
  padding: 6px 8px 2px;
  background: #fff;
  color: #111;
  font-size: 0.7rem;
  font-weight: 500;
  line-height: 1.15;
}

.report-record-value {
  min-height: 52px;
  padding: 0 8px 8px;
  background: #fff;
  color: #111;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
}

.report-record-value-comments {
  min-height: 240px;
  white-space: pre-wrap;
}

.report-record-value-stamp {
  min-height: 240px;
  display: grid;
  place-items: center;
}

.report-stamp-image {
  display: block;
  width: 200px;
  height: 200px;
  object-fit: contain;
  background: #fff;
}

.report-record-label-footer {
  display: block;
  padding: 6px 8px 2px;
  background: transparent;
  color: #111;
  font-size: 0.7rem;
  font-weight: 500;
  line-height: 1.15;
  text-align: left;
}

.report-record-value-footer {
  min-height: 42px;
  padding: 0 8px 8px;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
}

.report-record-item-footer {
  padding: 0;
}

.report-record-item-footer .report-record-value {
  background: #fff;
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 20px, 100%);
    margin: 18px auto 30px;
    padding-bottom: 132px;
  }

  .hero-card,
  .panel,
  .summary-card,
  .print-sheet,
  .component-card {
    padding: 6px;
  }

  .decision-header--card {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 8px;
  }

  .decision-header--card .metric-label,
  .decision-header--card .metric-formula,
  .decision-header--card .status-chip {
    grid-column: 1;
  }

  .decision-header--card .status-chip {
    grid-row: auto;
    justify-self: center;
    width: min(100%, 10rem);
    min-width: 0;
  }

  .metric-inline-row {
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-align: center;
  }

  .metric-subvalue--side {
    white-space: normal;
  }

  .component-grid,
  .project-grid,
  .property-grid,
  .record-grid,
  .comments-grid,
  .project-report-grid,
  .report-table-head,
  .report-table-body,
  .report-record-grid,
  .report-comments-output-grid {
    grid-template-columns: 1fr;
  }

  .report-item-wide {
    grid-column: span 1;
  }

  .report-item-half,
  .report-item-full,
  .report-item-address,
  .report-item-third {
    grid-column: span 1;
  }

  .permit-grid {
    grid-template-columns: 1fr;
  }

  .permit-grid .permit-type-field {
    min-width: 0;
  }

  .project-record-stack {
    padding: 0 16px 16px;
  }

  .hero-card h1 {
    font-size: clamp(2.7rem, 12vw, 4rem);
  }

  .report-brand-row,
  .report-header {
    grid-template-columns: 1fr;
  }

  .report-brand-block {
    align-items: center;
  }

  .report-brand-contact {
    text-align: left;
  }

  .component-head {
    align-items: flex-start;
  }

  .component-head-actions {
    width: 100%;
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .component-mode-toggle {
    justify-items: start;
    min-width: 0;
  }

  .report-record-item {
    border-right: 0;
    border-bottom: 0.5px solid #111;
  }

  .report-record-item:last-child {
    border-bottom: 0;
  }

  .report-drawing-box {
    height: 280px;
  }
}

@media print {
  body {
    background: #fff;
  }

  .page-shell {
    width: 100%;
    margin: 0;
  }

  .hero,
  .panel,
  .screen-only {
    display: none !important;
  }

  .layout {
    display: block;
  }

  .report-header {
    grid-template-columns: minmax(0, 1fr) minmax(420px, 0.95fr);
    gap: 12px;
    padding-bottom: 8px;
    margin-bottom: 8px;
  }

  .report-brand-row {
    gap: 12px;
    padding-bottom: 8px;
    margin-bottom: 8px;
    border-bottom-width: 3px;
  }

  .report-logo {
    width: 164px;
  }

  .report-brand-contact {
    font-size: 0.72rem;
    line-height: 1.25;
  }

  .report-header h3 {
    font-size: 1.45rem;
    line-height: 1.08;
    white-space: normal;
  }

  .project-report-grid-primary {
    justify-self: stretch;
    width: 100%;
    max-width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    overflow: visible;
  }

  .report-item.report-item-compact strong,
  .report-item-compact div {
    white-space: nowrap;
  }

  .report-item.report-item-compact strong {
    font-size: 0.62rem;
    padding: 4px 6px 3px;
  }

  .report-item-compact div {
    font-size: 0.8rem;
    min-height: 24px;
    padding: 4px 6px;
  }

  #reportProjectInfoSecondary {
    margin-bottom: 8px;
  }

  .report-permit-display {
    min-height: 32px;
    padding: 6px 8px;
    font-size: 0.8rem;
    white-space: nowrap;
  }

  .report-property-title {
    padding: 5px 8px 4px;
    font-size: 0.75rem;
  }

  .report-property-section .project-report-grid-secondary .report-item strong {
    padding: 4px 6px 2px;
    font-size: 0.56rem;
    white-space: nowrap;
  }

  .report-property-section .project-report-grid-secondary .report-item div {
    min-height: 24px;
    padding: 0 6px 5px;
    font-size: 0.8rem;
    font-weight: 600;
  }

  .report-section {
    border: 0.5px solid #111;
    padding-top: 0;
    margin-top: 8px;
  }

  .report-section h4 {
    margin: 0;
    padding: 5px 42px 4px;
    background: #0f5a70;
    color: #fff;
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.03em;
  }

  .report-table-label {
    padding: 4px 5px 3px;
    font-size: 0.56rem;
    border-width: 0.5px;
  }

  .report-table-value {
    min-height: 22px;
    padding: 4px 5px;
    font-size: 0.72rem;
    border-width: 0.5px;
  }

  .summary-card,
  .print-sheet {
    border: 0;
    box-shadow: none;
    padding: 0;
    background: #fff;
  }

  .report-section,
  .report-item,
  .report-notes {
    break-inside: avoid;
  }

  .report-records {
    margin-top: 10px;
  }

  .report-records-heading {
    font-size: 0.98rem;
  }

  .report-records-subheading {
    margin: 1px 0 10px;
    font-size: 0.7rem;
  }

  .report-records-note,
  .report-records-ack-copy,
  .report-records-ack-title {
    font-size: 0.62rem;
    line-height: 1.35;
  }

  .report-records-note,
  .report-records-ack-copy {
    margin-bottom: 8px;
  }

  .report-records-ack-title {
    margin-bottom: 2px;
  }

  .report-record-group {
    margin-top: 6px;
    border-width: 0.5px;
  }

  .report-record-group-title {
    padding: 5px 8px 4px;
    font-size: 0.82rem;
  }

  .report-record-label {
    padding: 4px 5px 1px;
    font-size: 0.56rem;
  }

  .report-record-value {
    min-height: 22px;
    padding: 4px 5px;
    font-size: 0.72rem;
  }

  .report-record-value-comments,
  .report-record-value-stamp {
    min-height: 170px;
  }

  .report-drawing-box {
    height: 320px;
    margin-bottom: 8px;
  }

  .report-stamp-image {
    width: 140px;
    height: 140px;
  }

  .report-record-value-footer {
    min-height: 28px;
    padding: 0 5px 5px;
    font-size: 0.72rem;
  }

  .report-record-label-footer {
    padding: 4px 5px 1px;
    font-size: 0.56rem;
  }
}
