.tool-main {
  padding: 36px 0 40px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.breadcrumbs a {
  color: var(--ink-soft);
  text-decoration: none;
}

.breadcrumbs a:hover {
  color: var(--blue);
}

.tool-hero {
  max-width: 1040px;
  padding: clamp(54px, 7vw, 94px) 0 50px;
}

.tool-hero h1 {
  max-width: 960px;
  margin: 0;
  font-size: clamp(48px, 7.4vw, 96px);
  font-weight: 700;
  letter-spacing: -0.065em;
  line-height: 0.96;
}

.tool-hero h1 em {
  color: var(--blue);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
}

.tool-lead {
  max-width: 720px;
  margin: 30px 0 0;
  color: var(--ink-soft);
  font-size: clamp(17px, 1.6vw, 21px);
  line-height: 1.65;
}

.tool-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 24px;
}

.tool-facts span {
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 254, 249, 0.58);
  font-size: 11px;
  font-weight: 800;
}

.tool-shell {
  display: grid;
  grid-template-columns: minmax(340px, 0.93fr) minmax(360px, 1.07fr);
  gap: 22px;
  margin: 0 0 84px;
}

.calculator-card,
.result-card,
.resolution-panel {
  padding: clamp(22px, 3vw, 34px);
  border-radius: 24px;
}

.calculator-card,
.resolution-panel {
  border: 1px solid var(--line);
  background: var(--white);
  box-shadow: 0 18px 55px rgba(45, 42, 30, 0.08);
}

.result-card {
  display: flex;
  min-height: 100%;
  background: var(--ink);
  color: var(--white);
  flex-direction: column;
}

.tool-panel-kicker {
  margin: 0 0 22px;
  color: var(--blue);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.result-card .tool-panel-kicker {
  color: var(--acid);
}

.audit-preview {
  display: grid;
  min-height: 240px;
  max-height: 360px;
  margin-bottom: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 13px;
  background:
    linear-gradient(45deg, #34342f 25%, transparent 25%),
    linear-gradient(-45deg, #34342f 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #34342f 75%),
    linear-gradient(-45deg, transparent 75%, #34342f 75%),
    #252521;
  background-position:
    0 0,
    0 10px,
    10px -10px,
    -10px 0;
  background-size: 20px 20px;
  place-items: center;
}

.audit-preview img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 360px;
  object-fit: contain;
}

.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

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

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

.field label {
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.field input,
.field select {
  width: 100%;
  min-height: 50px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--paper);
  color: var(--ink);
  font-size: 17px;
  font-weight: 700;
}

.field select {
  appearance: none;
  background:
    linear-gradient(45deg, transparent 50%, var(--ink) 50%) calc(100% - 18px) 22px /
      5px 5px no-repeat,
    linear-gradient(135deg, var(--ink) 50%, transparent 50%) calc(100% - 13px) 22px /
      5px 5px no-repeat,
    var(--paper);
}

.field-hint {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--ink-soft);
  font-size: 10px;
}

.tool-field-spacing {
  margin-top: 20px;
}

.preset-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.preset-button {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-soft);
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
}

.preset-button:hover,
.preset-button.is-active {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--white);
}

.primary-tool-button {
  width: 100%;
  min-height: 52px;
  margin-top: 24px;
  padding: 0 16px;
  border: 0;
  border-radius: 11px;
  background: var(--acid);
  color: var(--ink);
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
}

.primary-tool-button:hover {
  filter: brightness(1.03);
}

.secondary-tool-button {
  width: 100%;
  min-height: 44px;
  margin-top: 11px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
}

.secondary-tool-button:hover {
  border-color: var(--blue);
  color: var(--blue);
}

.secondary-tool-button:disabled {
  cursor: wait;
  opacity: 0.55;
}

.result-primary {
  display: grid;
  gap: 4px;
  padding-bottom: 25px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.result-primary strong {
  font-size: clamp(54px, 7vw, 88px);
  letter-spacing: -0.06em;
  line-height: 0.9;
}

.result-primary span {
  color: var(--acid);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.result-measurements {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 22px;
}

.result-measurement {
  padding: 18px 16px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 12px;
}

.result-measurement span {
  display: block;
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.47);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.result-measurement strong {
  font-size: 18px;
}

.result-note {
  margin: auto 0 0;
  padding-top: 26px;
  color: rgba(255, 255, 255, 0.57);
  font-size: 13px;
  line-height: 1.68;
}

.note-soft {
  color: var(--ink-soft);
}

.tool-copy {
  display: grid;
  grid-template-columns: minmax(250px, 0.66fr) minmax(400px, 1.34fr);
  gap: clamp(40px, 7vw, 92px);
  margin-bottom: 84px;
}

.tool-copy h2 {
  max-width: 640px;
  margin: 0;
  font-size: clamp(34px, 4.3vw, 56px);
  letter-spacing: -0.055em;
  line-height: 1.04;
}

.tool-copy-body h3 {
  margin: 28px 0 10px;
  font-size: 18px;
  letter-spacing: -0.025em;
}

.tool-copy-body h3:first-child {
  margin-top: 0;
}

.tool-copy-body p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 16px;
  line-height: 1.75;
}

.tool-copy-body p + p {
  margin-top: 12px;
}

.tool-copy-heading {
  margin: 0 0 14px;
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -0.045em;
  line-height: 1.04;
}

.readiness-intro {
  margin: 0;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.7;
}

.formula {
  margin: 20px 0;
  padding: 16px 18px;
  border-left: 3px solid var(--blue);
  background: rgba(49, 88, 255, 0.06);
  color: var(--ink);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 13px;
}

.related-tools {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 76px;
}

.tool-link-card {
  display: grid;
  min-height: 170px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--white);
  color: var(--ink);
  text-decoration: none;
  align-content: space-between;
  transition:
    transform 160ms ease,
    border-color 160ms ease;
}

.tool-link-card:hover {
  border-color: var(--blue);
  transform: translateY(-2px);
}

.tool-link-card span {
  color: var(--blue);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.tool-link-card strong {
  max-width: 340px;
  margin-top: 30px;
  font-size: 24px;
  letter-spacing: -0.04em;
  line-height: 1.08;
}

.tool-cta {
  display: flex;
  margin-bottom: 92px;
  padding: clamp(28px, 5vw, 52px);
  border-radius: 24px;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  background: var(--blue);
  color: var(--white);
}

.tool-cta h2 {
  max-width: 650px;
  margin: 0;
  font-size: clamp(28px, 4vw, 48px);
  letter-spacing: -0.055em;
  line-height: 1;
}

.tool-cta p {
  max-width: 570px;
  margin: 12px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15px;
  line-height: 1.62;
}

.tool-cta a {
  flex: 0 0 auto;
  padding: 14px 20px;
  border-radius: 999px;
  background: var(--acid);
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.file-picker {
  display: grid;
  min-height: 180px;
  padding: 24px;
  border: 1px dashed rgba(23, 23, 19, 0.26);
  border-radius: 16px;
  background: var(--paper);
  cursor: pointer;
  text-align: center;
  place-content: center;
}

.file-picker input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.file-picker strong {
  font-size: 18px;
}

.file-picker span {
  margin-top: 8px;
  color: var(--ink-soft);
  font-size: 12px;
}

.resolution-preview {
  display: grid;
  min-height: 260px;
  margin-bottom: 20px;
  overflow: hidden;
  border-radius: 14px;
  background:
    linear-gradient(45deg, rgba(23, 23, 19, 0.06) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(23, 23, 19, 0.06) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(23, 23, 19, 0.06) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(23, 23, 19, 0.06) 75%),
    var(--paper);
  background-position:
    0 0,
    0 8px,
    8px -8px,
    -8px 0;
  background-size: 16px 16px;
  place-items: center;
}

.resolution-preview img {
  display: block;
  max-width: 100%;
  max-height: 420px;
  object-fit: contain;
}

.resolution-results {
  display: grid;
  gap: 12px;
}

.resolution-stat {
  display: flex;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
}

.resolution-stat span {
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
}

.resolution-stat strong {
  font-size: 16px;
  text-align: right;
}

.resolution-status {
  margin: 10px 0 0;
  padding: 16px;
  border-radius: 11px;
  background: rgba(49, 88, 255, 0.07);
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.6;
}

.tool-error {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(206, 67, 46, 0.09);
  color: #a33425;
  font-size: 12px;
}

@media (max-width: 900px) {
  .tool-shell,
  .tool-copy {
    grid-template-columns: 1fr;
  }

  .result-card {
    min-height: 410px;
  }

  .tool-cta {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 620px) {
  .tool-main {
    padding-top: 24px;
  }

  .tool-hero h1 {
    font-size: clamp(48px, 15vw, 72px);
  }

  .field-grid,
  .result-measurements,
  .related-tools {
    grid-template-columns: 1fr;
  }

  .tool-shell {
    margin-right: -8px;
    margin-left: -8px;
  }

  .calculator-card,
  .result-card,
  .resolution-panel {
    border-radius: 18px;
  }
}
