:root {
  --bg-main: #080808;
  --bg-card: rgba(13, 13, 13, 0.88);
  --bg-card-strong: rgba(10, 10, 10, 0.96);
  --text-main: #f2f2f2;
  --text-soft: rgba(255, 255, 255, 0.7);
  --accent: #c92a2a;
  --accent-soft: rgba(201, 42, 42, 0.16);
  --line: rgba(255, 255, 255, 0.08);
  --shadow: 0 18px 44px rgba(0, 0, 0, 0.42);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
  --font-main: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
  font-family: var(--font-main);
  color: var(--text-main);
  background:
    linear-gradient(180deg, rgba(70, 8, 8, 0.68), rgba(12, 12, 12, 0.9)),
    radial-gradient(circle at top, rgba(201, 42, 42, 0.16), transparent 34%),
    url("/site/background.jpg") center / cover no-repeat fixed,
    var(--bg-main);
}

body {
  overflow-x: hidden;
}

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

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

.site-auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px 16px;
}

.site-auth-shell {
  width: min(100%, 460px);
}

.site-auth-panel {
  padding: 32px 26px 24px;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background:
    linear-gradient(180deg, rgba(18, 18, 18, 0.94), rgba(8, 8, 8, 0.96));
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
}

.site-auth-brand {
  font-size: clamp(29px, 5vw, 42px);
  font-weight: 800;
  letter-spacing: 0;
  text-align: center;
}

.site-auth-subtitle {
  margin-top: 8px;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-soft);
}

.site-auth-form {
  display: grid;
  gap: 14px;
  margin-top: 24px;
}

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

.site-field span {
  font-size: 13px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
}

.site-field input {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  outline: none;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.site-field input::placeholder {
  color: rgba(255, 255, 255, 0.38);
}

.site-field input:focus {
  border-color: rgba(201, 42, 42, 0.7);
  background: rgba(255, 255, 255, 0.06);
}

.site-primary-btn,
.site-secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  width: 100%;
  border: 0;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.site-primary-btn {
  margin-top: 2px;
  color: #fff;
  background: linear-gradient(135deg, #dc4040, #b51f1f);
}

.site-secondary-btn {
  margin-top: 10px;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
}

.site-auth-status {
  min-height: 22px;
  margin-top: 12px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  line-height: 1.5;
}

.site-auth-status.is-error {
  color: #ffb3b3;
}

.site-auth-status.is-success {
  color: #9be5b6;
}

.site-primary-btn:hover,
.site-secondary-btn:hover,
.api-index a:hover {
  transform: translateY(-1px);
}

.site-info-page {
  padding: 28px 16px 56px;
}

body.site-info-page {
  background:
    linear-gradient(180deg, rgba(70, 8, 8, 0.68), rgba(70, 8, 8, 0.68)),
    radial-gradient(circle at top, rgba(201, 42, 42, 0.16), transparent 34%),
    url("/site/background.jpg") center / cover no-repeat fixed,
    var(--bg-main);
}

.info-layout {
  width: min(1080px, 100%);
  margin: 0 auto;
}

.info-hero-card,
.api-card {
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: var(--bg-card);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.info-hero-card {
  padding: 24px;
  margin-bottom: 20px;
}

.info-badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  border: 1px solid rgba(201, 42, 42, 0.3);
  color: #f0adad;
  font-size: 12px;
  font-weight: 800;
}

.info-hero-card h1 {
  margin: 14px 0 8px;
  font-size: clamp(30px, 5vw, 48px);
  line-height: 1;
  letter-spacing: 0;
}

.info-hero-card p {
  margin: 0;
  max-width: 760px;
  color: var(--text-soft);
  font-size: 15px;
  line-height: 1.7;
}

.api-index {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.api-index a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: rgba(255, 255, 255, 0.82);
  font-size: 12px;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.api-list {
  display: grid;
  gap: 16px;
}

.api-card {
  padding: 22px;
}

.api-card-head h2 {
  margin: 0;
  font-size: clamp(21px, 3vw, 28px);
  line-height: 1.35;
  word-break: break-word;
}

.api-block + .api-block {
  margin-top: 18px;
}

.api-block h3 {
  margin: 0 0 10px;
  font-size: 15px;
  color: #ef9d9d;
}

.api-block ul {
  margin: 0;
  padding-left: 18px;
}

.api-block li {
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.75;
  font-size: 14px;
}

.api-block pre {
  margin: 0;
  padding: 14px 16px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: var(--bg-card-strong);
  color: #f2dede;
  overflow: auto;
  line-height: 1.55;
  font-size: 13px;
  white-space: pre-wrap;
  word-break: break-word;
}

@media (max-width: 720px) {
  .site-auth-panel,
  .info-hero-card,
  .api-card {
    padding: 18px;
  }

  .site-auth-shell {
    width: min(100%, 420px);
  }

  .site-auth-brand {
    font-size: 30px;
  }

  .api-card-head h2 {
    font-size: 20px;
  }
}
