* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: #18202a;
  background: #f4f6f8;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

.topbar {
  align-items: center;
  background: #ffffff;
  border-bottom: 1px solid #d9e0e7;
  display: flex;
  height: 64px;
  justify-content: space-between;
  padding: 0 32px;
}

.brand {
  align-items: center;
  display: inline-flex;
  gap: 12px;
  font-size: 20px;
  font-weight: 800;
}

.brand-mark {
  align-items: center;
  background: #000000;
  border-radius: 6px;
  display: inline-flex;
  height: 36px;
  justify-content: center;
  overflow: hidden;
  width: 60px;
}

.brand-mark img {
  display: block;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.topbar nav {
  align-items: center;
  display: flex;
  gap: 8px;
}

.topbar nav a,
.link-button {
  background: transparent;
  border: 0;
  border-radius: 6px;
  color: #435063;
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  padding: 8px 12px;
}

.topbar nav a:hover,
.link-button:hover {
  background: #edf1f5;
  color: #18202a;
}

.topbar form {
  margin: 0;
}

.shell {
  margin: 0 auto;
  max-width: 1180px;
  padding: 36px 24px;
}

.dashboard-header {
  align-items: flex-start;
  display: flex;
  gap: 24px;
  justify-content: space-between;
  margin-bottom: 28px;
}

.platform-title {
  display: grid;
  gap: 12px;
}

.platform-logo {
  background: #000000;
  border-radius: 8px;
  display: block;
  height: auto;
  max-width: 320px;
  width: min(100%, 320px);
}

.eyebrow {
  color: #28706d;
  font-size: 13px;
  font-weight: 700;
  margin: 0 0 10px;
  text-transform: uppercase;
}

h1 {
  font-size: 40px;
  line-height: 1.05;
  margin: 0;
}

.subtle {
  color: #536173;
  font-size: 16px;
  line-height: 1.55;
  margin: 14px 0 0;
  max-width: 760px;
}

.primary-action {
  align-items: center;
  background: #18202a;
  border: 0;
  border-radius: 6px;
  color: #ffffff;
  cursor: pointer;
  display: inline-flex;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
}

.secondary-action {
  align-items: center;
  background: #ffffff;
  border: 1px solid #b9c4d0;
  border-radius: 6px;
  color: #253142;
  cursor: pointer;
  display: inline-flex;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
}

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

.metric-grid article {
  background: #ffffff;
  border: 1px solid #d9e0e7;
  border-radius: 8px;
  min-height: 176px;
  padding: 20px;
}

.metric-grid span {
  color: #5a6778;
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 14px;
  text-transform: uppercase;
}

.metric-grid strong {
  color: #28706d;
  display: block;
  font-size: 28px;
  margin-bottom: 14px;
}

.metric-grid p,
.page-band p {
  color: #536173;
  line-height: 1.5;
  margin: 0;
}

.page-band {
  background: #ffffff;
  border: 1px solid #d9e0e7;
  border-radius: 8px;
  padding: 24px;
}

.auth-panel {
  background: #ffffff;
  border: 1px solid #d9e0e7;
  border-radius: 8px;
  margin: 40px auto;
  max-width: 520px;
  padding: 28px;
}

.auth-logo {
  background: #000000;
  border-radius: 8px;
  display: block;
  height: auto;
  margin-bottom: 22px;
  max-width: 240px;
  width: 100%;
}

.form-grid,
.wizard {
  display: grid;
  gap: 18px;
}

.form-grid.single {
  margin-top: 24px;
}

label {
  color: #253142;
  display: grid;
  font-size: 14px;
  font-weight: 700;
  gap: 8px;
}

input,
select {
  border: 1px solid #b9c4d0;
  border-radius: 6px;
  color: #18202a;
  font: inherit;
  min-height: 42px;
  padding: 8px 10px;
}

.validation {
  color: #9a3412;
  font-weight: 700;
}

.toolbar {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.toolbar input {
  flex: 1;
}

.table-wrap {
  background: #ffffff;
  border: 1px solid #d9e0e7;
  border-radius: 8px;
  overflow: auto;
}

table {
  border-collapse: collapse;
  min-width: 900px;
  width: 100%;
}

th,
td {
  border-bottom: 1px solid #e5ebf0;
  padding: 12px 14px;
  text-align: left;
  white-space: nowrap;
}

th {
  color: #5a6778;
  font-size: 12px;
  text-transform: uppercase;
}

td a {
  color: #28706d;
  font-weight: 800;
}

.wizard fieldset {
  background: #ffffff;
  border: 1px solid #d9e0e7;
  border-radius: 8px;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
  padding: 20px;
}

.wizard legend {
  color: #28706d;
  font-weight: 800;
  padding: 0 8px;
}

.checkbox {
  align-items: center;
  display: flex;
  flex-direction: row;
  gap: 10px;
}

.checkbox input {
  min-height: auto;
}

.module-grid {
  display: grid;
  gap: 10px;
  grid-column: 1 / -1;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.module-grid label {
  align-items: center;
  background: #f7f9fb;
  border: 1px solid #d9e0e7;
  border-radius: 6px;
  display: flex;
  flex-direction: row;
  padding: 10px;
}

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

.event-list {
  color: #536173;
  line-height: 1.6;
  margin: 14px 0 0;
  padding-left: 20px;
}

.success-panel {
  background: #ffffff;
  border: 1px solid #d9e0e7;
  border-radius: 8px;
  padding: 28px;
}

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

.check-list li::before {
  color: #28706d;
  content: "✓ ";
  font-weight: 900;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 900px) {
  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .wizard fieldset,
  .split-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 640px) {
  .topbar,
  .dashboard-header {
    align-items: stretch;
    flex-direction: column;
    height: auto;
  }

  .topbar {
    gap: 12px;
    padding: 16px;
  }

  .topbar nav {
    flex-wrap: wrap;
  }

  .shell {
    padding: 24px 16px;
  }

  h1 {
    font-size: 32px;
  }

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

  .toolbar {
    flex-direction: column;
  }

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