:root {
  --bg: #05020a;
  --panel-width: min(calc(100% - 2rem), 1180px);
  --content-width: min(calc(100% - 3rem), 1080px);
  --topbar-height: 127px;
  --font-main: "Exo 2", "Segoe UI", sans-serif;
  --text-main: #ffffff;
  --text-soft: rgba(255, 255, 255, 0.78);
  --text-muted: rgba(255, 255, 255, 0.56);
  --topbar-bg: rgba(37, 0, 51, 0.92);
  --panel-glow: rgba(179, 41, 214, 0.32);
  --panel-bg: rgba(10, 5, 18, 0.82);
  --card-bg: rgba(8, 6, 15, 0.74);
  --card-strong: rgba(0, 0, 0, 0.62);
  --card-border: rgba(255, 255, 255, 0.08);
  --nav-bg: rgba(106, 80, 118, 0.42);
  --nav-bg-active: rgba(145, 99, 170, 0.7);
  --accent: #d870ff;
  --accent-soft: rgba(216, 112, 255, 0.16);
  --shadow-soft: 0 12px 24px rgba(0, 0, 0, 0.26);
  --shadow-strong: 0 24px 54px rgba(0, 0, 0, 0.4);
}

body {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.88) 0, rgba(5, 3, 10, 0.52) 30%, rgba(2, 1, 5, 0.92) 100%),
    url("img/chatgpt-image-28-2026-13-22-15-1.png") center top / cover no-repeat fixed,
    var(--bg);
  color: var(--text-main);
  font-family: var(--font-main);
}

.page {
  position: relative;
  min-height: 100vh;
  overflow-x: hidden;
}

.page__panel {
  position: absolute;
  inset: 0 auto 0 50%;
  width: var(--panel-width);
  transform: translateX(-50%);
  background:
    linear-gradient(180deg, rgba(86, 8, 118, 0.9), rgba(53, 2, 73, 0.94)),
    url("../img/Rectangle 2.svg") center top / 100% 100% no-repeat;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.34),
    inset 0 0 0 1px rgba(255, 255, 255, 0.03);
}

.page__panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top, rgba(216, 112, 255, 0.14), transparent 32%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 22%, rgba(0, 0, 0, 0.08));
  pointer-events: none;
}

.topbar {
  position: relative;
  z-index: 1;
  background: var(--topbar-bg);
  box-shadow:
    0 4px 8px rgba(0, 0, 0, 0.32),
    inset 0 4px 50px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(10px);
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  width: min(calc(100% - 3rem), 1560px);
  min-height: var(--topbar-height);
  margin: 0 auto;
}

.brand {
  flex-shrink: 0;
}

.brand img {
  width: clamp(132px, 10vw, 190px);
  height: auto;
  filter: drop-shadow(0 10px 22px rgba(0, 0, 0, 0.32));
}

.main-nav {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  gap: clamp(1rem, 2.5vw, 3rem);
}

.main-nav__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: clamp(132px, 10vw, 188px);
  min-height: 52px;
  padding: 0 1.5rem;
  border: 1px solid rgba(0, 0, 0, 0.72);
  border-radius: 16px;
  background: var(--nav-bg);
  box-shadow: var(--shadow-soft);
  color: rgba(255, 255, 255, 0.66);
  font-size: clamp(18px, 1.2vw, 24px);
  font-weight: 600;
  letter-spacing: 0.01em;
  backdrop-filter: blur(10px);
  transition:
    transform 0.2s ease,
    background-color 0.2s ease,
    color 0.2s ease;
}

.main-nav__link:hover {
  transform: translateY(-1px);
  background: rgba(160, 104, 191, 0.58);
  color: var(--text-main);
}

.main-nav__link--active {
  background: var(--nav-bg-active);
  color: var(--text-main);
}

.profile-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.profile-actions__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}

.profile-actions__button:hover {
  opacity: 0.86;
  transform: translateY(-1px);
}

.profile-actions__button img {
  width: 56px;
  height: 56px;
}

.profile-actions__button--compact {
  width: 38px;
  height: 38px;
}

.profile-actions__button--compact img {
  width: 18px;
  height: 18px;
}

.page__main {
  position: relative;
  z-index: 1;
  width: var(--panel-width);
  margin: 0 auto;
  padding: 2.5rem 0 5rem;
}

.content-shell {
  width: var(--content-width);
  margin: 0 auto;
}

.community-hero,
.community-panel,
.community-widget,
.community-post {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 26px;
  background: linear-gradient(180deg, rgba(12, 8, 22, 0.88), rgba(3, 2, 8, 0.84));
  box-shadow: 0 24px 54px rgba(0, 0, 0, 0.34);
}

.community-hero {
  padding: 1.35rem;
}

.community-hero__eyebrow {
  margin: 0;
  color: #d870ff;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.community-hero h1 {
  margin: 0.55rem 0 0;
  font-size: clamp(2rem, 3.3vw, 3.2rem);
  line-height: 1.05;
}

.community-hero p {
  margin: 0.85rem 0 0;
  color: rgba(255, 255, 255, 0.8);
}

.community-layout {
  margin-top: 1.25rem;
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(280px, 0.9fr);
  gap: 1rem;
}

.community-panel {
  padding: 1rem;
}

.community-panel__status {
  margin: 0.85rem 0 0;
  color: rgba(255, 255, 255, 0.76);
}

.community-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.community-filter {
  min-height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.28);
  color: rgba(255, 255, 255, 0.76);
  padding: 0 0.8rem;
}

.community-filter.is-active {
  background: linear-gradient(135deg, rgba(216, 112, 255, 0.95), rgba(138, 56, 180, 0.92));
  color: #ffffff;
}

.community-posts {
  margin-top: 1rem;
  display: grid;
  gap: 0.9rem;
}

.community-post {
  border-radius: 18px;
  padding: 0.95rem;
}

.community-post h3 {
  margin: 0;
}

.community-post p {
  margin: 0.55rem 0 0;
  color: rgba(255, 255, 255, 0.82);
}

.community-post__meta {
  margin-top: 0.7rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  color: rgba(255, 255, 255, 0.64);
  font-size: 0.9rem;
}

.community-post__actions {
  margin-top: 0.75rem;
  display: flex;
  gap: 0.55rem;
}

.community-post__button {
  min-height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.28);
  color: #ffffff;
  padding: 0 0.8rem;
}

.community-post__button.is-liked {
  border-color: rgba(216, 112, 255, 0.55);
  background: rgba(216, 112, 255, 0.22);
}

.community-post__comments {
  margin-top: 0.75rem;
  display: grid;
  gap: 0.55rem;
}

.community-post-comment {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.25);
  padding: 0.6rem 0.7rem;
}

.community-post-comment__meta {
  margin: 0;
  font-size: 0.86rem;
  color: rgba(255, 255, 255, 0.66);
}

.community-post-comment__body {
  margin: 0.35rem 0 0;
}

.community-post__comment-form {
  margin-top: 0.55rem;
  display: grid;
  gap: 0.45rem;
}

.community-post__comment-form textarea {
  width: 100%;
  min-height: 84px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.25);
  color: #ffffff;
  padding: 0.6rem 0.7rem;
}

.community-post__comment-form button {
  justify-self: start;
  min-height: 36px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(216, 112, 255, 0.95), rgba(138, 56, 180, 0.92));
  color: #ffffff;
  padding: 0 0.8rem;
}

.community-post__empty-comments {
  margin: 0;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.9rem;
}

.community-side {
  display: grid;
  gap: 1rem;
}

.community-widget {
  padding: 1rem;
}

.community-widget h2 {
  margin: 0;
}

.community-widget__hint {
  margin: 0.65rem 0 0;
  color: rgba(255, 255, 255, 0.72);
}

.community-form {
  margin-top: 0.8rem;
  display: grid;
  gap: 0.7rem;
}

.community-form label {
  display: grid;
  gap: 0.35rem;
  color: rgba(255, 255, 255, 0.84);
}

.community-form input,
.community-form select,
.community-form textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.25);
  padding: 0.55rem 0.7rem;
  color: #ffffff;
}

.community-form button {
  min-height: 44px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(216, 112, 255, 0.95), rgba(138, 56, 180, 0.92));
  color: #ffffff;
  font-weight: 700;
}

.community-stats {
  margin: 0.9rem 0 0;
  display: grid;
  gap: 0.55rem;
}

.community-stats div {
  display: flex;
  justify-content: space-between;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.24);
  padding: 0.5rem 0.7rem;
}

.community-stats dt {
  color: rgba(255, 255, 255, 0.72);
}

.community-stats dd {
  margin: 0;
  font-weight: 700;
}

@media (max-width: 960px) {
  .topbar__inner {
    flex-wrap: wrap;
    justify-content: center;
    width: min(calc(100% - 2rem), 1560px);
    padding: 1rem 0;
  }

  .main-nav {
    order: 3;
    width: 100%;
    flex-wrap: wrap;
  }

  .main-nav__link {
    flex: 1 1 180px;
  }

  .community-layout {
    grid-template-columns: 1fr;
  }
}
