* {
  box-sizing: border-box;
}

:root {
  --bg: #020308;
  --text: #f4f4f6;
  --neon-main: #4953ff;
  --border-card: rgba(112, 120, 148, 0.62);

  --shadow-outer:
    0 0 0 1px rgba(86, 97, 255, 0.55),
    0 0 10px rgba(73, 83, 255, 0.32),
    0 0 18px rgba(73, 83, 255, 0.14);

  --shadow-hover:
    0 0 0 1px rgba(92, 103, 255, 0.9),
    0 0 12px rgba(73, 83, 255, 0.55),
    0 0 20px rgba(73, 83, 255, 0.18),
    inset 0 0 12px rgba(73, 83, 255, 0.08);
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top center, rgba(23, 30, 76, 0.18), transparent 28%),
    linear-gradient(180deg, #020308 0%, #010207 100%);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  padding: 28px 22px;
}

.ecosystem {
  width: min(1036px, 100%);
  margin: 0 auto;
}

.topbar {
  min-height: 88px;
  padding: 12px 24px;
  border-radius: 23px;
  border: 1.5px solid #7f7f86;
  box-shadow: 0 0 0 1px rgba(180, 180, 188, 0.25);
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(72, 72, 78, 0.96), rgba(48, 48, 54, 0.98));
}

.topbar__content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  opacity: 0.22;
  filter: grayscale(1);
  user-select: none;
}

.topbar__title {
  font-size: 33px;
  line-height: 1;
  font-weight: 300;
  letter-spacing: 0.2px;
  color: #f3f3f5;
  white-space: nowrap;
}

.topbar__nav {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.nav-btn {
  appearance: none;
  border: 1px solid rgba(220, 220, 225, 0.45);
  background: linear-gradient(180deg, rgba(90, 90, 96, 0.95), rgba(60, 60, 66, 0.95));
  color: #f3f3f5;
  border-radius: 14px;
  min-height: 42px;
  padding: 8px 14px 8px 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.nav-btn__icon {
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  border-radius: 3px;
  background: #f2f2f2;
}

.nav-btn__text {
  font-size: 18px;
  line-height: 1;
  font-weight: 400;
}

.topbar__status {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ffffff;
  text-shadow: 0 0 12px rgba(0, 0, 0, 0.35);
  z-index: 2;
}

.workspace {
  margin-top: 26px;
  min-height: 474px;
  padding: 24px 22px;
  border-radius: 30px;
  background: rgba(2, 4, 11, 0.97);
  border: 1.5px solid var(--neon-main);
  box-shadow: var(--shadow-outer);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1fr) 18px minmax(0, 1fr);
  align-items: stretch;
}

.panel-card,
.panel-card:hover,
.panel-card:focus,
.panel-card:visited {
  text-decoration: none;
  color: inherit;
}

.panel-card {
  cursor: pointer;
  position: relative;
  min-height: 420px;
  border-radius: 18px;
  border: 1.2px solid var(--border-card);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.015),
    0 0 0 1px rgba(20, 24, 36, 0.45),
    0 0 8px rgba(255, 255, 255, 0.02);
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(5, 8, 18, 0.98), rgba(0, 1, 6, 0.98));
  transition:
    border-color 0.24s ease,
    box-shadow 0.24s ease,
    transform 0.24s ease;
}

.panel-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 18px;
  pointer-events: none;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    inset 0 -1px 0 rgba(255, 255, 255, 0.015);
}

.panel-card__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
}

.panel-card__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.34)),
    linear-gradient(135deg, rgba(73, 83, 255, 0.08), transparent 50%);
  transition: background 0.24s ease;
}

.panel-card:hover {
  border-color: var(--neon-main);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.panel-card:hover .panel-card__overlay {
  background: rgba(0, 0, 0, 0.64);
}

.panel-card__title {
  position: relative;
  z-index: 2;
  margin: 0;
  padding: 0 18px;
  font-size: 29px;
  line-height: 1.1;
  font-weight: 700;
  text-align: center;
  color: #f5f5f6;
  letter-spacing: -0.2px;
  text-shadow: 0 0 14px rgba(0, 0, 0, 0.55);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.24s ease, transform 0.24s ease;
}

.panel-card:hover .panel-card__title {
  opacity: 1;
  transform: translateY(0);
}

.panel-card__muted {
  font-size: 0.72em;
  font-weight: 500;
  opacity: 0.9;
}

.panel-card--disabled::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(12, 12, 16, 0.2);
  z-index: 1;
}

.panel-card--messenger {
  cursor:default;
}

.separator {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
}

.separator::before {
  content: "";
  width: 1px;
  height: 100%;
  opacity: 0.95;
  background: repeating-linear-gradient(
    to bottom,
    rgba(175, 182, 202, 0.72) 0 28px,
    transparent 28px 56px
  );
  filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.1));
  mask-image: linear-gradient(to bottom, transparent 0, black 6%, black 94%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, black 6%, black 94%, transparent 100%);
}

@media (max-width: 980px) {
  .topbar__content {
    flex-direction: column;
    align-items: flex-start;
  }

  .topbar__title {
    white-space: normal;
    font-size: 30px;
  }

  .topbar__status {
    font-size: 22px;
  }

  .workspace {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .separator {
    display: none;
  }

  .panel-card {
    min-height: 300px;
  }

  .panel-card__title {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 640px) {
  body {
    padding: 18px 12px;
  }

  .topbar {
    padding: 14px;
    border-radius: 20px;
  }

  .topbar__title {
    font-size: 26px;
  }

  .nav-btn {
    min-height: 40px;
    padding: 8px 12px 8px 10px;
  }

  .nav-btn__text {
    font-size: 16px;
  }

  .workspace {
    margin-top: 18px;
    padding: 16px;
    border-radius: 24px;
  }

  .panel-card {
    min-height: 240px;
    border-radius: 16px;
  }

  .panel-card__title {
    font-size: 24px;
  }
}
