@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/manrope-400.ttf") format("truetype");
}

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/manrope-500.ttf") format("truetype");
}

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("fonts/manrope-600.ttf") format("truetype");
}

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/manrope-700.ttf") format("truetype");
}

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("fonts/manrope-800.ttf") format("truetype");
}

:root {
  --bg: #f4f7fb;
  --bg-soft: #eef4fb;
  --text: #07111f;
  --muted: #65748b;
  --line: #dce5f2;
  --blue: #1268ff;
  --blue-deep: #0758dd;
  --cyan: #73d8ff;
  --dark: #020814;
  --panel: #ffffff;
  --warn: #a76310;
  --ok: #138a47;
  --shadow: 0 16px 36px rgba(8, 22, 44, 0.07);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Manrope", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    linear-gradient(180deg, #f8fbff 0, var(--bg) 260px),
    var(--bg);
  overflow-x: hidden;
}

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

button,
input,
select {
  font: inherit;
}

main {
  width: 100%;
  max-width: 1180px;
  margin: 28px auto 64px;
  padding: 0 18px;
}

.topbar {
  min-height: 72px;
  padding: 0 28px;
  display: flex;
  align-items: center;
  gap: 26px;
  color: #fff;
  background: rgba(2, 8, 20, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.18);
}

.brand {
  display: inline-flex;
  align-items: center;
  color: #fff;
  line-height: 1;
  white-space: nowrap;
  flex: 0 0 auto;
}

.brand-logo {
  width: auto;
  height: 34px;
  max-width: 160px;
  display: block;
  object-fit: contain;
}

.brand.big .brand-logo {
  height: 44px;
  max-width: 206px;
}

.topbar nav {
  display: flex;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.topbar nav a {
  color: rgba(255, 255, 255, 0.75);
  border-radius: 8px;
  padding: 10px 12px;
  font-weight: 820;
  font-size: 14px;
  line-height: 1;
  transition: color 160ms ease, background 160ms ease;
}

.topbar nav a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

button,
.link-button {
  border: 0;
  border-radius: 8px;
  min-height: 42px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
}

button:focus-visible,
.link-button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(102, 170, 255, 0.5);
  outline-offset: 2px;
}

.primary {
  color: #fff;
  background: linear-gradient(135deg, #1673ff, var(--blue-deep));
  box-shadow: 0 14px 28px rgba(18, 104, 255, 0.2);
}

.ghost {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.ghost.light {
  color: var(--blue);
  background: #eef4ff;
  border-color: #cfe0f7;
}

.compact {
  min-height: 34px;
  padding: 0 12px;
  font-size: 13px;
}

.notice {
  margin: 0 0 18px;
  padding: 14px 16px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow);
  font-weight: 850;
}

.notice.ok {
  color: var(--ok);
  background: #edf9f2;
  border-color: #bde8ce;
}

.page-head,
.hero-panel,
.panel,
.stat {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.page-head {
  padding: 26px 28px;
  margin-bottom: 20px;
}

.page-head h1,
.hero-panel h1,
.panel h2 {
  margin: 0 0 8px;
  letter-spacing: 0;
}

.page-head p,
.hero-panel p,
.panel p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.hero-panel {
  padding: 32px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  color: #fff;
  background: linear-gradient(135deg, #06101f, #0b1c34 58%, #0a4bb6);
  border-color: rgba(18, 104, 255, 0.28);
}

.hero-panel h1 {
  font-size: clamp(31px, 4vw, 46px);
  line-height: 1.04;
}

.hero-panel p {
  color: rgba(255, 255, 255, 0.76);
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--cyan);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 950;
}

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

.stat {
  padding: 21px;
}

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

.stat strong {
  display: block;
  margin-top: 8px;
  font-size: 29px;
  line-height: 1.05;
}

.grid {
  display: grid;
  gap: 20px;
}

.grid.two {
  grid-template-columns: 0.85fr 1.15fr;
}

.order-flow {
  align-items: start;
}

.panel {
  padding: 24px;
  overflow-x: auto;
}

.form {
  display: grid;
  gap: 14px;
  align-content: start;
}

.form-grid,
.inline-fields {
  display: grid;
  gap: 12px;
}

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

.inline-fields {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
}

label {
  display: grid;
  gap: 7px;
  font-weight: 850;
  color: #263449;
}

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

input,
select {
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

input:focus,
select:focus {
  border-color: rgba(18, 104, 255, 0.5);
  box-shadow: 0 0 0 4px rgba(18, 104, 255, 0.08);
}

pre {
  min-height: 120px;
  padding: 14px;
  overflow: auto;
  background: #06101f;
  color: #d8e8ff;
}

.summary-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg-soft);
}

.summary-box span,
.muted {
  color: var(--muted);
  font-size: 13px;
}

.summary-box strong {
  text-align: right;
}

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

th,
td {
  padding: 13px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 14px;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.table-action {
  margin: 0;
}

code {
  padding: 2px 6px;
  border-radius: 6px;
  background: #eef4ff;
  color: #164fba;
}

.pill {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 999px;
  background: #eef4ff;
  color: var(--blue);
  font-size: 12px;
  font-weight: 900;
}

.pill.ok {
  color: var(--ok);
  background: #e9f8ef;
}

.pill.warn {
  color: var(--warn);
  background: #fff6df;
}

.steps {
  margin: 12px 0 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.8;
}

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(135deg, #06101f, #020814 66%, #082256);
  background-size: 44px 44px, 44px 44px, auto;
}

.login-card {
  width: calc(100% - 32px);
  max-width: 430px;
  display: grid;
  gap: 16px;
  padding: 30px;
  border-radius: 8px;
  background: rgba(7, 17, 31, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
  box-shadow: 0 26px 74px rgba(0, 0, 0, 0.34);
}

.login-card h1 {
  margin: 10px 0 0;
  font-size: 30px;
  line-height: 1.1;
}

.login-card p {
  color: rgba(255, 255, 255, 0.72);
}

.login-card label {
  color: rgba(255, 255, 255, 0.9);
}

.login-card input {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.18);
}

.login-card .primary {
  min-height: 46px;
  margin-top: 4px;
}

@media (max-width: 940px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

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

  .form-grid,
  .inline-fields {
    grid-template-columns: 1fr;
  }

  .inline-fields .ghost {
    width: 100%;
  }
}

@media (max-width: 820px) {
  main {
    margin-top: 20px;
    padding: 0 14px;
  }

  .topbar {
    min-height: auto;
    padding: 16px 18px;
    flex-wrap: wrap;
    gap: 14px;
  }

  .topbar nav {
    order: 3;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .topbar nav a {
    flex: 0 0 auto;
  }

  .topbar form {
    margin-left: auto;
  }

  .hero-panel {
    grid-template-columns: 1fr;
    padding: 26px;
  }

  .hero-panel .link-button {
    width: 100%;
  }
}

@media (max-width: 540px) {
  .brand {
    max-width: 150px;
  }

  .brand-logo {
    height: 32px;
    max-width: 150px;
  }

  .brand.big .brand-logo {
    height: 40px;
    max-width: 190px;
  }

  .topbar .ghost {
    min-height: 38px;
    padding: 0 12px;
    font-size: 13px;
  }

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

  .page-head,
  .panel,
  .hero-panel,
  .stat,
  .login-card {
    padding: 22px;
  }

  .hero-panel h1 {
    font-size: 31px;
  }
}
