:root {
  color-scheme: dark;
  font-family:
    Inter,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  background: #09111d;
  color: #f7f9fc;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(43, 115, 191, 0.22), transparent 35%),
    radial-gradient(circle at top right, rgba(86, 58, 156, 0.18), transparent 32%),
    linear-gradient(180deg, #0b1524 0%, #07101b 100%);
}

a {
  color: inherit;
}

.site-header,
.page-shell,
.site-footer {
  width: min(1180px, calc(100% - 32px));
  margin-inline: auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 54px 0 30px;
}

.eyebrow {
  margin: 0 0 8px;
  color: #85bfff;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 10px;
  font-size: clamp(2.2rem, 5vw, 4.5rem);
  line-height: 0.95;
}

.intro {
  margin-bottom: 0;
  color: #aebdd0;
  font-size: 1.05rem;
}

.admin-link {
  flex: 0 0 auto;
  padding: 12px 18px;
  border: 1px solid rgba(151, 183, 222, 0.25);
  border-radius: 999px;
  background: rgba(15, 30, 49, 0.7);
  color: #dcecff;
  text-decoration: none;
}

.category-section {
  margin: 28px 0 46px;
}

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

.section-heading h2 {
  margin-bottom: 0;
  font-size: 1.35rem;
}

.section-heading span {
  color: #8092a8;
  font-size: 0.9rem;
}

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

.app-card,
.empty-card,
.legal-card {
  border: 1px solid rgba(144, 174, 208, 0.16);
  border-radius: 22px;
  background: rgba(12, 26, 43, 0.76);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(16px);
}

.app-card {
  position: relative;
  display: flex;
  gap: 16px;
  min-height: 132px;
  padding: 18px;
  overflow: hidden;
  text-decoration: none;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.app-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--accent);
  content: "";
}

.app-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  background: rgba(17, 35, 57, 0.92);
}

.app-logo {
  display: grid;
  flex: 0 0 76px;
  width: 76px;
  height: 76px;
  place-items: center;
  overflow: hidden;
  border-radius: 20px;
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--accent) 42%, #17263a), #101c2d);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 10px 30px rgba(0, 0, 0, 0.25);
  font-size: 2rem;
  font-weight: 900;
}

.app-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.app-content {
  min-width: 0;
  flex: 1;
}

.app-title-row {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 10px;
}

.app-title-row h3 {
  margin-bottom: 8px;
  font-size: 1.1rem;
}

.app-content p {
  margin-bottom: 0;
  color: #a9b8ca;
  font-size: 0.92rem;
  line-height: 1.45;
}

.status {
  padding: 4px 7px;
  border-radius: 999px;
  background: rgba(73, 198, 142, 0.12);
  color: #72d9a8;
  font-size: 0.68rem;
  text-transform: uppercase;
}

.empty-card,
.legal-card {
  padding: 26px;
  color: #aab9ca;
}

.legal-content {
  white-space: pre-wrap;
  line-height: 1.7;
}

.legal-updated {
  margin: 32px 0 0;
  color: #728398;
  font-size: 0.85rem;
}

.site-footer {
  display: flex;
  justify-content: center;
  gap: 22px;
  padding: 22px 0 44px;
  color: #8293a8;
  font-size: 0.9rem;
}

.site-footer a {
  text-decoration: none;
}

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

@media (max-width: 620px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    padding-top: 34px;
  }

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

  .app-card {
    min-height: 116px;
  }

  .app-logo {
    flex-basis: 66px;
    width: 66px;
    height: 66px;
    border-radius: 17px;
  }

  .site-footer {
    flex-wrap: wrap;
  }
}

/* ===== ADMINBEREICH ===== */

.admin-shell {
  display: grid;
  gap: 24px;
  padding-bottom: 60px;
}

.admin-section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.admin-section-heading h2 {
  margin: 4px 0 0;
}

.admin-section-heading > span {
  font-size: 0.9rem;
  color: #9fb0c6;
}

.admin-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin: 24px 0 32px;
  padding: 24px;
  border: 1px solid rgba(117, 180, 255, 0.2);
  border-radius: 18px;
  background:
    linear-gradient(
      145deg,
      rgba(18, 38, 61, 0.96),
      rgba(10, 25, 43, 0.96)
    );
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.22);
}

.admin-form > div {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-form label {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #9cc9ff;
}

.admin-form input,
.admin-form select,
.admin-form textarea {
  width: 100%;
  min-height: 46px;
  padding: 11px 13px;
  border: 1px solid rgba(153, 188, 226, 0.25);
  border-radius: 11px;
  background: rgba(5, 16, 29, 0.72);
  color: #f5f8fc;
  font: inherit;
  outline: none;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    background 0.18s ease;
}

.admin-form input::placeholder,
.admin-form textarea::placeholder {
  color: #70839a;
}

.admin-form input:focus,
.admin-form select:focus,
.admin-form textarea:focus {
  border-color: #63aefc;
  background: rgba(8, 24, 42, 0.96);
  box-shadow: 0 0 0 3px rgba(72, 154, 240, 0.16);
}

.admin-form button {
  grid-column: 1 / -1;
  justify-self: start;
  min-height: 46px;
  padding: 0 22px;
  border: 0;
  border-radius: 11px;
  background: linear-gradient(135deg, #2586e8, #60b1ff);
  color: #ffffff;
  font-weight: 800;
  font-size: 0.95rem;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(37, 134, 232, 0.25);
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.admin-form button:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 30px rgba(37, 134, 232, 0.34);
}

.admin-table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(133, 177, 226, 0.16);
  border-radius: 14px;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-table th,
.admin-table td {
  padding: 13px 14px;
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid rgba(133, 177, 226, 0.12);
}

.admin-table th {
  background: rgba(14, 35, 58, 0.88);
  color: #a9c9ea;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

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

.admin-table tbody tr:hover {
  background: rgba(45, 113, 181, 0.08);
}

.admin-table button {
  padding: 8px 12px;
  border: 1px solid rgba(125, 183, 240, 0.28);
  border-radius: 9px;
  background: rgba(28, 76, 122, 0.55);
  color: #eaf4ff;
  cursor: pointer;
}

@media (max-width: 760px) {
  .admin-section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-form {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .admin-form button {
    width: 100%;
  }
}
