:root {
  color-scheme: light;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f5f7fb;
  color: #17202f;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #f5f7fb;
}

button,
input {
  font: inherit;
}

.shell {
  width: min(100%, 760px);
  margin: 0 auto;
  padding: 28px 16px 40px;
}

.intro {
  margin-bottom: 20px;
}

.eyebrow {
  margin: 0 0 10px;
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 12px;
  max-width: 680px;
  font-size: 34px;
  line-height: 1.08;
  letter-spacing: 0;
}

.lead {
  max-width: 620px;
  margin-bottom: 0;
  color: #536173;
  font-size: 17px;
  line-height: 1.5;
}

.panel,
.result-card {
  border: 1px solid #d8e0ec;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(21, 34, 55, 0.08);
}

.panel {
  padding: 18px;
}

.upload-form {
  display: grid;
  gap: 14px;
}

.file-field {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid #d8e0ec;
  border-radius: 8px;
  background: #fbfcfe;
}

.file-label {
  font-weight: 750;
}

.file-help {
  color: #6b7788;
  font-size: 14px;
}

input[type="file"] {
  width: 100%;
  min-height: 44px;
  color: #38465a;
}

input[type="file"]::file-selector-button {
  min-height: 40px;
  margin-right: 12px;
  border: 1px solid #b8c5d8;
  border-radius: 8px;
  background: #ffffff;
  color: #17202f;
  font-weight: 700;
}

.primary-button {
  width: 100%;
  min-height: 52px;
  border: 0;
  border-radius: 8px;
  background: #1d4ed8;
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

.primary-button:disabled {
  cursor: wait;
  opacity: 0.68;
}

.status-box,
.error-box {
  margin-top: 14px;
  border-radius: 8px;
  padding: 13px 14px;
  font-size: 15px;
  line-height: 1.45;
}

.status-box {
  border: 1px solid #b7cffd;
  background: #edf4ff;
  color: #1e3a8a;
}

.error-box {
  border: 1px solid #f3b4b4;
  background: #fff1f1;
  color: #991b1b;
}

.result-card {
  margin-top: 18px;
  padding: 18px;
}

.result-head {
  border-bottom: 1px solid #e6ebf2;
  padding-bottom: 14px;
}

.result-status {
  display: inline-flex;
  margin-bottom: 10px;
  border-radius: 999px;
  padding: 5px 10px;
  background: #e8f5ee;
  color: #166534;
  font-size: 13px;
  font-weight: 800;
}

.result-status.needs-attention {
  background: #fff7e8;
  color: #92400e;
}

.result-status.do-not-pay-before-check {
  background: #fff1f1;
  color: #991b1b;
}

.result-head h2 {
  margin-bottom: 0;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: 0;
}

.key-grid {
  display: grid;
  gap: 10px;
  margin: 16px 0 0;
}

.key-grid div {
  min-width: 0;
  border: 1px solid #e1e7f0;
  border-radius: 8px;
  padding: 12px;
  background: #fbfcfe;
}

.key-grid dt {
  color: #6b7788;
  font-size: 13px;
}

.key-grid dd {
  margin: 4px 0 0;
  overflow-wrap: anywhere;
  font-weight: 750;
}

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

.report-section h3 {
  margin-bottom: 8px;
  font-size: 16px;
  letter-spacing: 0;
}

.plain-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
  color: #38465a;
}

.plain-list:empty::after {
  content: "Нет";
  display: block;
  margin-left: -20px;
  color: #6b7788;
}

.disclaimer {
  margin: 18px 0 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.5;
}

[hidden] {
  display: none !important;
}

@media (min-width: 700px) {
  .shell {
    padding-top: 46px;
  }

  h1 {
    font-size: 46px;
  }

  .panel,
  .result-card {
    padding: 24px;
  }

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

  .primary-button {
    grid-column: 1 / -1;
  }

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