:root {
  --bg: #050608;
  --surface: #0d1018;
  --surface-2: #141824;
  --text: #f6f7fb;
  --muted: #aeb6ca;
  --line: rgba(255, 255, 255, 0.14);
  --pink: #e244ff;
  --cyan: #22c7ff;
  --green: #66e3a5;
  --red: #ff6c8b;
  --shadow: 0 22px 80px rgba(0, 0, 0, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 16% 12%, rgba(226, 68, 255, 0.18), transparent 25rem),
    radial-gradient(circle at 86% 18%, rgba(34, 199, 255, 0.16), transparent 28rem),
    linear-gradient(180deg, #030406 0%, #080a10 48%, #050608 100%);
}

a {
  color: inherit;
}

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

button {
  cursor: pointer;
}

.site-shell {
  min-height: 100vh;
}

.topbar {
  align-items: center;
  backdrop-filter: blur(18px);
  background: rgba(5, 6, 8, 0.78);
  border-bottom: 1px solid var(--line);
  display: flex;
  height: 76px;
  justify-content: space-between;
  left: 0;
  padding: 0 clamp(18px, 4vw, 56px);
  position: sticky;
  right: 0;
  top: 0;
  z-index: 20;
}

.brand {
  align-items: center;
  display: inline-flex;
  font-size: 1.05rem;
  font-weight: 900;
  gap: 12px;
  text-decoration: none;
  text-transform: lowercase;
}

.brand img {
  height: 42px;
  object-fit: contain;
  width: 42px;
}

.nav-links {
  align-items: center;
  display: flex;
  gap: 6px;
}

.nav-links a {
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--muted);
  padding: 10px 13px;
  text-decoration: none;
}

.nav-links a:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--line);
  color: var(--text);
}

.nav-toggle {
  background: transparent;
  border: 0;
  display: none;
  height: 42px;
  padding: 8px;
  width: 42px;
}

.nav-toggle span {
  background: var(--text);
  border-radius: 99px;
  display: block;
  height: 2px;
  margin: 6px 0;
}

main:focus {
  outline: none;
}

.hero {
  display: grid;
  min-height: calc(100vh - 76px);
  overflow: hidden;
  place-items: center;
  position: relative;
}

.hero-backdrop {
  background-image:
    linear-gradient(180deg, rgba(5, 6, 8, 0.62), rgba(5, 6, 8, 0.9)),
    url("/assets/banner.svg");
  background-position: center;
  background-size: cover;
  inset: 0;
  opacity: 0.86;
  position: absolute;
}

.hero::after {
  background: linear-gradient(180deg, transparent 0%, var(--bg) 100%);
  bottom: 0;
  content: "";
  height: 28%;
  left: 0;
  position: absolute;
  right: 0;
}

.hero-inner {
  max-width: 900px;
  padding: clamp(48px, 8vw, 96px) clamp(18px, 4vw, 32px);
  position: relative;
  text-align: center;
  z-index: 2;
}

.hero-logo {
  display: block;
  height: clamp(116px, 17vw, 190px);
  margin: 0 auto 20px;
  object-fit: contain;
  width: clamp(116px, 17vw, 190px);
}

.eyebrow {
  color: var(--cyan);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0;
  margin: 0 0 10px;
  text-transform: uppercase;
}

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

h1 {
  font-size: clamp(3.6rem, 11vw, 8rem);
  line-height: 0.9;
  margin-bottom: 18px;
  text-transform: lowercase;
}

h2 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 1;
  margin-bottom: 14px;
}

h3 {
  font-size: 1.25rem;
  margin-bottom: 8px;
}

p {
  color: var(--muted);
  line-height: 1.65;
}

.hero-copy {
  color: #dce3f6;
  font-size: clamp(1rem, 2vw, 1.24rem);
  margin: 0 auto;
  max-width: 740px;
}

.content-section,
.game-page,
.legal-page,
.admin-shell,
.app-legal-footer {
  margin: 0 auto;
  max-width: 1180px;
  padding: clamp(44px, 7vw, 84px) clamp(18px, 4vw, 32px);
}

.section-heading {
  max-width: 760px;
  margin-bottom: 24px;
}

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

.app-card {
  align-items: center;
  background: rgba(13, 16, 24, 0.88);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: inherit;
  display: grid;
  gap: 22px;
  grid-template-columns: 92px minmax(0, 1fr);
  min-height: 156px;
  padding: 20px;
  text-decoration: none;
  transition: border-color 160ms ease, transform 160ms ease;
}

.app-card:hover {
  border-color: rgba(34, 199, 255, 0.68);
  transform: translateY(-2px);
}

.app-card img {
  aspect-ratio: 1;
  object-fit: contain;
  width: 92px;
}

.app-card span {
  color: var(--green);
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 850;
  line-height: 1.35;
  margin-bottom: 12px;
}

.app-card h3 {
  margin-bottom: 12px;
}

.app-card p {
  margin-bottom: 0;
}

.feedback-section {
  border-top: 1px solid var(--line);
}

.feedback-form,
.admin-login,
.admin-login form,
.admin-board {
  background: rgba(13, 16, 24, 0.9);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.feedback-form,
.admin-login form,
.admin-board {
  display: grid;
  gap: 16px;
  padding: clamp(22px, 4vw, 34px);
}

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

label {
  color: var(--muted);
  display: grid;
  font-size: 0.92rem;
  gap: 8px;
}

input,
textarea,
select {
  background: #070910;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  min-height: 46px;
  padding: 12px 14px;
  width: 100%;
}

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

input:focus,
textarea:focus,
select:focus {
  border-color: var(--cyan);
  outline: 2px solid rgba(34, 199, 255, 0.18);
}

.hidden-field {
  left: -9999px;
  position: absolute;
}

.form-status {
  margin: 0;
  min-height: 24px;
}

.button {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: inline-flex;
  font-weight: 850;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  text-decoration: none;
}

.button.primary {
  background: linear-gradient(135deg, var(--pink), var(--cyan));
  border: 0;
  color: #050608;
}

.button.ghost {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.button:disabled {
  cursor: not-allowed;
  filter: grayscale(0.8);
  opacity: 0.7;
}

.game-layout {
  align-items: center;
  display: grid;
  gap: clamp(28px, 5vw, 58px);
  grid-template-columns: minmax(180px, 330px) minmax(0, 1fr);
  min-height: calc(82vh - 76px);
}

.game-logo-wrap {
  aspect-ratio: 1;
  background: rgba(13, 16, 24, 0.72);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  place-items: center;
}

.game-logo-wrap img {
  object-fit: contain;
  width: 82%;
}

.platforms,
.actions,
.message-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

.platforms span,
.badge,
.tab {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  display: inline-flex;
  font-size: 0.86rem;
  font-weight: 750;
  padding: 8px 12px;
}

.back-link {
  color: var(--muted);
  display: inline-block;
  margin-bottom: 24px;
  text-decoration: none;
}

.back-link:hover {
  color: var(--text);
}

.app-legal-footer {
  align-items: center;
  border-top: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  font-size: 0.78rem;
  font-weight: 800;
  gap: 10px 14px;
  justify-content: center;
  padding-bottom: 32px;
  padding-top: 30px;
  text-align: center;
}

.app-legal-footer a {
  color: var(--green);
  font-weight: 900;
  text-decoration: none;
}

.app-legal-footer a:hover,
.app-legal-footer a:focus-visible {
  text-decoration: underline;
}

.legal-page {
  max-width: 840px;
  min-height: 60vh;
}

.legal-page h1,
.admin-shell h1 {
  font-size: clamp(2.8rem, 7vw, 5.2rem);
}

.admin-shell {
  max-width: 1080px;
}

.admin-login {
  max-width: 460px;
  padding: clamp(22px, 4vw, 34px);
}

.is-hidden {
  display: none !important;
}

.admin-head,
.message-top,
.admin-controls {
  align-items: start;
  display: flex;
  gap: 16px;
  justify-content: space-between;
}

.admin-controls {
  align-items: end;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
  padding-top: 18px;
}

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

.tab {
  cursor: pointer;
}

.tab.is-active {
  background: rgba(34, 199, 255, 0.18);
  border-color: rgba(34, 199, 255, 0.62);
}

.admin-select {
  min-width: min(280px, 100%);
}

.message-list {
  display: grid;
  gap: 14px;
}

.message {
  background: #070910;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
}

.message p {
  white-space: pre-wrap;
}

.badge.report {
  background: rgba(255, 108, 139, 0.16);
  border-color: rgba(255, 108, 139, 0.46);
}

.badge.idea {
  background: rgba(102, 227, 165, 0.14);
  border-color: rgba(102, 227, 165, 0.4);
}

.badge.neutral {
  color: var(--muted);
}

time {
  color: var(--muted);
  font-size: 0.88rem;
}

.icon-button {
  align-items: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  display: inline-flex;
  font-size: 1.15rem;
  font-weight: 900;
  height: 42px;
  justify-content: center;
  width: 42px;
}

.icon-button svg {
  fill: none;
  height: 20px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
  width: 20px;
}

.icon-button:hover {
  border-color: rgba(34, 199, 255, 0.62);
}

.icon-button.danger:hover {
  border-color: rgba(255, 108, 139, 0.7);
  color: var(--red);
}

.empty-state {
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  padding: 32px;
  text-align: center;
}

@media (max-width: 820px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    align-items: stretch;
    background: rgba(5, 6, 8, 0.96);
    border-bottom: 1px solid var(--line);
    display: none;
    flex-direction: column;
    left: 0;
    padding: 12px 18px 18px;
    position: absolute;
    right: 0;
    top: 76px;
  }

  .nav-links.is-open {
    display: flex;
  }

  .hero {
    min-height: 720px;
  }

  .form-grid,
  .game-layout {
    grid-template-columns: 1fr;
  }

  .app-card {
    grid-template-columns: 74px minmax(0, 1fr);
  }

  .app-card img {
    width: 74px;
  }
}

@media (max-width: 520px) {
  .topbar {
    padding: 0 14px;
  }

  .brand span {
    font-size: 0.95rem;
  }

  .button {
    width: 100%;
  }

  .admin-head,
  .message-top,
  .admin-controls {
    align-items: stretch;
    flex-direction: column;
  }
}
