:root {
  color-scheme: light;
  --bg: #f4f7fb;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --line: #dbe4ee;
  --line-strong: #c8d5e3;
  --text: #14202b;
  --muted: #647386;
  --blue: #2463eb;
  --blue-strong: #1749b8;
  --green: #12805c;
  --amber: #b46605;
  --red: #b42318;
  --cyan: #0b7285;
  --shadow: 0 18px 45px rgba(20, 32, 43, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 1180px;
  min-height: 100vh;
  color: var(--text);
  background: var(--bg);
  font-family: Inter, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
}

.login-screen {
  min-height: 920px;
  display: grid;
  place-items: center;
  padding: 56px;
  background:
    linear-gradient(180deg, rgba(244, 247, 251, 0.95), rgba(235, 241, 248, 0.95)),
    repeating-linear-gradient(0deg, transparent 0 79px, rgba(171, 190, 211, 0.22) 80px),
    repeating-linear-gradient(90deg, transparent 0 79px, rgba(171, 190, 211, 0.22) 80px);
}

.login-panel {
  width: 1040px;
  min-height: 620px;
  display: grid;
  grid-template-columns: 1fr 390px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.login-hero {
  padding: 52px;
  display: grid;
  align-content: space-between;
  border-right: 1px solid var(--line);
  background: #fbfdff;
}

.brand-row,
.topbar,
.sidebar-logo,
.row,
.between,
.toolbar,
.metric-row,
.timeline-item,
.progress-line,
.status-line,
.chip-row {
  display: flex;
  align-items: center;
}

.between {
  justify-content: space-between;
  gap: 14px;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #e8f0ff;
  color: var(--blue);
  font-weight: 900;
}

.brand-text strong,
.sidebar-logo strong {
  display: block;
  font-size: 15px;
}

.brand-text span,
.sidebar-logo span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.brand-row {
  gap: 12px;
}

.login-hero h1 {
  max-width: 560px;
  margin: 56px 0 16px;
  font-size: 42px;
  line-height: 1.15;
  letter-spacing: 0;
}

.login-hero p {
  max-width: 580px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.75;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 42px;
}

.hero-stat,
.quick-card,
.metric,
.report-box,
.module-card,
.table-card,
.step-card,
.evidence-card,
.timeline-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.hero-stat {
  padding: 18px;
}

.hero-stat strong,
.metric strong {
  display: block;
  font-size: 24px;
  line-height: 1;
}

.hero-stat span,
.metric span {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
}

.login-form {
  padding: 52px 42px;
  display: grid;
  align-content: center;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
}

.login-form h2,
.page-title h1 {
  margin: 0;
  font-size: 28px;
  letter-spacing: 0;
}

.subtle {
  color: var(--muted);
  line-height: 1.65;
}

.form-grid {
  display: grid;
  gap: 14px;
  margin-top: 28px;
}

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

.field label,
.field span,
.small-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.input,
.select,
.textarea {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.textarea {
  min-height: 120px;
  padding: 11px 12px;
  resize: none;
  line-height: 1.55;
}

.button {
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
  font-weight: 800;
}

.button.primary {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}

.button.ghost {
  background: #eef4ff;
  color: var(--blue-strong);
  border-color: #d6e4ff;
}

.button.danger {
  background: #fff1f0;
  color: var(--red);
  border-color: #ffd8d5;
}

.app-shell {
  width: 1440px;
  min-height: 920px;
  display: grid;
  grid-template-columns: 248px 1fr;
  background: var(--bg);
}

.sidebar {
  padding: 22px 18px;
  border-right: 1px solid var(--line);
  background: #ffffff;
}

.sidebar-logo {
  gap: 12px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}

.nav {
  display: grid;
  gap: 6px;
  margin-top: 22px;
}

.nav-item {
  min-height: 42px;
  display: grid;
  grid-template-columns: 26px 1fr;
  align-items: center;
  gap: 10px;
  padding: 0 10px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.nav-item.active {
  background: #eaf1ff;
  color: var(--blue-strong);
}

.nav-icon {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: #f1f5f9;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.nav-item.active .nav-icon {
  background: var(--blue);
  color: #fff;
}

.sidebar-footer {
  margin-top: 34px;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid #dce8f7;
  background: #f5f9ff;
}

.sidebar-footer strong {
  display: block;
  font-size: 13px;
}

.sidebar-footer span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.main {
  padding: 22px 26px 30px;
}

.topbar {
  justify-content: space-between;
  min-height: 58px;
  margin-bottom: 18px;
}

.page-title h1 {
  font-size: 26px;
}

.page-title p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.toolbar {
  gap: 10px;
}

.search {
  width: 260px;
  height: 42px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
}

.content-grid {
  display: grid;
  gap: 16px;
}

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

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

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

.grid-main {
  grid-template-columns: 360px 1fr;
}

.grid-wide {
  grid-template-columns: 1.25fr 0.75fr;
}

.quick-card,
.metric,
.report-box,
.module-card,
.table-card,
.step-card,
.evidence-card,
.timeline-card {
  padding: 18px;
}

.quick-card h3,
.report-box h3,
.module-card h3,
.table-card h3,
.step-card h3,
.evidence-card h3,
.timeline-card h3 {
  margin: 0;
  font-size: 16px;
}

.quick-card p,
.report-box p,
.module-card p,
.step-card p,
.evidence-card p {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.metric-row {
  justify-content: space-between;
  margin-top: 16px;
}

.status-pill,
.tag,
.risk-pill,
.level-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.status-pill.ok,
.tag.ok {
  background: #e8f7f0;
  color: var(--green);
}

.status-pill.warn,
.tag.warn {
  background: #fff4df;
  color: var(--amber);
}

.status-pill.danger,
.tag.danger {
  background: #fff0ee;
  color: var(--red);
}

.status-pill.blue,
.tag.blue,
.level-badge {
  background: #eaf1ff;
  color: var(--blue-strong);
}

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

.panel-title p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.table th,
.table td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

.table th {
  color: var(--muted);
  background: var(--surface-soft);
  font-size: 12px;
}

.table tr:last-child td {
  border-bottom: 0;
}

.progress {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e6edf5;
}

.progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
}

.list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 13px;
}

.list strong {
  color: var(--text);
}

.segmented {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
}

.segment {
  min-height: 34px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.segment.active {
  background: #fff;
  color: var(--blue-strong);
  box-shadow: 0 5px 16px rgba(30, 64, 175, 0.08);
}

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

.check {
  min-height: 38px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 13px;
}

.check-dot {
  width: 15px;
  height: 15px;
  border: 2px solid var(--line-strong);
  border-radius: 5px;
  background: #fff;
}

.check.active .check-dot {
  border-color: var(--blue);
  background: var(--blue);
}

.report-preview {
  min-height: 560px;
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 22px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--line);
}

.report-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.report-head h2 {
  margin: 0;
  font-size: 20px;
}

.report-head p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.report-section {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

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

.report-section strong {
  font-size: 13px;
}

.report-section p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.device-visual {
  height: 250px;
  position: relative;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, #f8fbff 0%, #eef4fb 100%);
}

.drone-body {
  position: absolute;
  inset: 90px 120px;
  border-radius: 8px;
  border: 2px solid #9db4cc;
  background: #fff;
}

.arm {
  position: absolute;
  height: 2px;
  background: #9db4cc;
  transform-origin: center;
}

.arm.one {
  left: 90px;
  right: 90px;
  top: 125px;
}

.arm.two {
  left: 165px;
  right: 165px;
  top: 125px;
  transform: rotate(90deg);
}

.rotor {
  position: absolute;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid #9db4cc;
  background: rgba(255, 255, 255, 0.76);
}

.r1 { left: 74px; top: 101px; }
.r2 { right: 74px; top: 101px; }
.r3 { left: 207px; top: 28px; }
.r4 { left: 207px; bottom: 28px; }

.status-line {
  justify-content: space-between;
  gap: 16px;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  font-size: 13px;
}

.status-line span {
  color: var(--muted);
}

.log-panel {
  height: 190px;
  overflow: hidden;
  padding: 14px;
  border-radius: 8px;
  background: #0f172a;
  color: #dbeafe;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 12px;
  line-height: 1.7;
}

.tool-card {
  display: grid;
  gap: 10px;
  min-height: 168px;
}

.compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.timeline {
  display: grid;
  gap: 12px;
}

.timeline-item {
  gap: 12px;
}

.timeline-num {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #eaf1ff;
  color: var(--blue-strong);
  font-weight: 900;
}

.timeline-item strong {
  display: block;
  font-size: 13px;
}

.timeline-item span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.coverage-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.coverage-cell {
  padding: 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}

.coverage-cell strong {
  display: block;
  color: var(--blue-strong);
}

.coverage-cell span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.chip-row {
  flex-wrap: wrap;
  gap: 8px;
}

.risk-pill.high {
  background: #fff0ee;
  color: var(--red);
}

.risk-pill.mid {
  background: #fff4df;
  color: var(--amber);
}

.risk-pill.low {
  background: #e8f7f0;
  color: var(--green);
}
