:root {
  color-scheme: light;
  --ink: #2f4055;
  --muted: #687586;
  --line: #d8e0e8;
  --paper: #f5f8fb;
  --panel: #ffffff;
  --brand: #304258;
  --brand-deep: #233244;
  --brand-soft: #e9eef4;
  --aqua: #27b8b7;
  --gold: #ffc826;
  --coral: #f45170;
  --teal: #27b8b7;
  --green: #4d7c0f;
  --amber: #b45309;
  --red: #b42318;
  --blue: #304258;
  --shadow: 0 18px 48px rgba(47, 64, 85, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 86% 12%, rgba(255, 200, 38, 0.2), transparent 24%),
    radial-gradient(circle at 98% 18%, rgba(244, 81, 112, 0.14), transparent 18%),
    radial-gradient(circle at 72% 4%, rgba(39, 184, 183, 0.14), transparent 20%),
    linear-gradient(180deg, #ffffff 0%, var(--paper) 48%, #eef3f8 100%);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input {
  font: inherit;
}

.shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 54px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 0.7fr);
  gap: 36px;
  align-items: end;
  padding: 22px 0 34px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--coral);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  max-width: 860px;
  margin-bottom: 0;
  font-size: clamp(38px, 6vw, 76px);
  line-height: 0.95;
  letter-spacing: 0;
  color: var(--brand-deep);
}

h2 {
  margin-bottom: 16px;
  font-size: 18px;
  line-height: 1.2;
}

.form-title {
  margin: 0 0 4px;
  color: var(--brand);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.audit-form {
  display: grid;
  gap: 10px;
  padding: 20px;
  background:
    linear-gradient(#ffffff, #ffffff) padding-box,
    linear-gradient(135deg, rgba(39, 184, 183, 0.7), rgba(255, 200, 38, 0.75), rgba(244, 81, 112, 0.68)) border-box;
  border: 1px solid transparent;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.audit-form label,
.field span {
  font-weight: 750;
}

.field-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 12px;
}

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

.input-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

input {
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  border: 1px solid #ccd6e0;
  border-radius: 6px;
  color: var(--ink);
  background: #fff;
  outline: none;
}

input:focus {
  border-color: var(--aqua);
  box-shadow: 0 0 0 3px rgba(39, 184, 183, 0.16);
}

button {
  height: 48px;
  padding: 0 16px;
  border: 0;
  border-radius: 6px;
  color: #fff;
  background: var(--brand);
  cursor: pointer;
  font-weight: 750;
}

button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.audit-form button {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
}

.ghost-button {
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  color: var(--brand);
  background: #fff;
}

.form-note {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.summary-panel,
.panel,
.metric {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(47, 64, 85, 0.07);
}

.summary-panel {
  min-height: 156px;
  margin-bottom: 18px;
  padding: 22px;
}

.summary-panel.is-empty {
  display: grid;
  place-items: center;
  color: var(--brand);
  text-align: center;
  background:
    linear-gradient(90deg, rgba(39, 184, 183, 0.12), rgba(255, 200, 38, 0.12), rgba(244, 81, 112, 0.12)),
    #fff;
}

.empty-state {
  display: grid;
  gap: 6px;
}

.score-summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
}

.score-ring {
  display: grid;
  width: 116px;
  height: 116px;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--score-color) calc(var(--score) * 1%), #e7eee9 0);
}

.score-ring span {
  display: grid;
  width: 86px;
  height: 86px;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  font-size: 30px;
  font-weight: 850;
}

.summary-copy {
  min-width: 0;
}

.summary-copy h2 {
  margin: 0 0 8px;
  font-size: 28px;
}

.summary-copy p {
  margin: 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.status-pill {
  padding: 8px 10px;
  border-radius: 999px;
  color: var(--score-color);
  background: color-mix(in srgb, var(--score-color) 12%, white);
  font-weight: 800;
}

.dashboard {
  display: grid;
  gap: 18px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.metric {
  min-height: 112px;
  padding: 16px;
  border-top: 3px solid var(--brand);
}

.metric span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.metric strong {
  display: block;
  margin-top: 12px;
  font-size: 32px;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.75fr);
  gap: 18px;
}

.panel {
  padding: 18px;
}

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

.actions-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding-left: 22px;
}

.actions-list li {
  padding-left: 4px;
}

.actions-list strong {
  display: block;
  margin-bottom: 4px;
}

.actions-list span {
  color: var(--muted);
}

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

.fact {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.fact:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.fact span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.fact strong {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 14px;
}

.checklists {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.check-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.check-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border-bottom: 1px solid var(--line);
  background: #f8fafc;
}

.check-card h3 {
  margin: 0;
  font-size: 16px;
}

.check-card header span {
  font-weight: 850;
  color: var(--score-color);
}

.check-row {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
}

.check-row:last-child {
  border-bottom: 0;
}

.check-icon {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--red);
  font-size: 12px;
  font-weight: 900;
}

.check-row.is-pass .check-icon {
  background: var(--green);
}

.check-row p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.error-box {
  border-color: rgba(180, 35, 24, 0.28);
  color: var(--red);
  background: #fff6f4;
}

@media (max-width: 860px) {
  .hero,
  .score-summary,
  .content-grid,
  .checklists,
  .metric-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 42px;
  }

  .input-row {
    grid-template-columns: 1fr;
  }

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

  .score-summary {
    justify-items: start;
  }

}

@media (max-width: 520px) {
  .shell {
    width: min(100% - 20px, 1180px);
    padding-top: 18px;
  }

  h1 {
    font-size: 34px;
  }

  .audit-form,
  .panel,
  .summary-panel {
    padding: 14px;
  }

  .fact {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
