html,
body {
  height: 100%;
  margin: 0;
  font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(224, 167, 47, 0.18), transparent 30%),
    radial-gradient(circle at top right, rgba(63, 143, 131, 0.18), transparent 26%),
    linear-gradient(180deg, #f8f3ea 0%, #efe6d7 100%);
  color: #182321;
}

.bg {
  position: fixed;
  inset: 0;
  background-image: url('ifu-background.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(1px) brightness(.56);
}

.shell {
  position: relative;
  padding: 32px 16px 56px;
}

.admin-shell {
  max-width: 1280px;
  margin: 0 auto;
}

.card {
  position: relative;
  max-width: 440px;
  margin: 6vh auto;
  padding: 24px;
  background: rgba(255, 251, 245, 0.94);
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 0 24px 60px rgba(48, 40, 24, 0.14);
}

.card-wide {
  max-width: 1180px;
}

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

.logo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 14px;
}

.page-logo {
  width: min(100%, 240px);
  height: auto;
}

.brand {
  font-weight: 700;
  font-size: 20px;
  color: #a83d1d;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lead {
  margin: 12px 0 18px;
  line-height: 1.5;
}

.stack > * + * {
  margin-top: 10px;
}

input,
select,
textarea {
  width: 100%;
  padding: 10px 12px;
  margin: 0;
  border: 1px solid rgba(24, 35, 33, 0.14);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.78);
  box-sizing: border-box;
  font: inherit;
}

textarea {
  min-height: 96px;
  resize: vertical;
}

button,
.button-link {
  display: inline-block;
  background: linear-gradient(135deg, #d95f39, #a83d1d);
  color: #fff9f3;
  padding: 10px 14px;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  font: inherit;
  font-weight: 600;
  box-shadow: 0 14px 30px rgba(168, 61, 29, 0.24);
}

.button-link-secondary {
  background: rgba(255, 255, 255, 0.65);
  color: #182321;
  border: 1px solid rgba(24, 35, 33, 0.14);
  box-shadow: none;
}

.button-alt {
  background: linear-gradient(135deg, #3f8f83, #2e7067);
  box-shadow: 0 14px 30px rgba(63, 143, 131, 0.22);
}

.toolbar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.note,
.muted,
.document-meta {
  font-size: 13px;
  color: #566664;
}

.error,
.success {
  padding: 10px 12px;
  border-radius: 8px;
  margin: 12px 0;
}

.error {
  color: #8a1f1f;
  background: #ffdede;
}

.success {
  color: #0a6d2f;
  background: #e6f9ec;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 18px;
}

.product-block {
  border-top: 1px solid rgba(24, 35, 33, 0.12);
  padding-top: 18px;
  margin-top: 18px;
}

.document-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.document-list li + li {
  margin-top: 12px;
}

.document-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.admin-grid,
.check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.check-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.field-label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: #182321;
}

.action-panels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.mini-panel {
  padding: 0;
  border: 1px solid rgba(24, 35, 33, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.52);
}

.toggle-link {
  list-style: none;
  cursor: pointer;
  padding: 16px 18px;
  color: #3f8f83;
  font-weight: 700;
}

.toggle-link::-webkit-details-marker {
  display: none;
}

.mini-panel[open] {
  padding: 0 18px 18px;
}

.mini-panel[open] .toggle-link {
  padding: 16px 0 0;
}

.mini-panel .stack {
  margin-top: 0;
}

.top-gap {
  margin-top: 12px;
}

.check-item input {
  width: auto;
  margin: 0;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
}

table th,
table td {
  border: 1px solid rgba(24, 35, 33, 0.12);
  padding: 8px;
  font-size: 13px;
  text-align: left;
  vertical-align: top;
}

table th {
  background: rgba(255, 255, 255, 0.62);
}

@media (max-width: 720px) {
  .card {
    margin: 16px auto;
    padding: 18px;
  }

  .section-head,
  .document-row {
    flex-direction: column;
    align-items: stretch;
  }
}
