*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --bg: #070709;
  --panel: rgba(255, 255, 255, 0.05);
  --panel-strong: rgba(255, 255, 255, 0.08);
  --line: rgba(255, 255, 255, 0.12);
  --text: #f5f7fb;
  --muted: #a6adbb;
  --accent: #e23d52;
  --accent-2: #ff6b81;
  --success: #2ecc71;
  --danger: #ff6b6b;
  --shadow: 0 18px 70px rgba(0, 0, 0, 0.38);
  --radius: 24px;
  --radius-sm: 16px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top, rgba(226, 61, 82, 0.24), transparent 28%),
    radial-gradient(circle at 90% 15%, rgba(255, 255, 255, 0.08), transparent 16%),
    linear-gradient(180deg, #0c0d12 0%, #070709 100%);
}

a {
  color: inherit;
  text-decoration: none;
}

code {
  padding: 0.1rem 0.35rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
}

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

.container {
  width: min(1120px, calc(100% - 2rem));
  margin-inline: auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(18px);
  background: rgba(7, 7, 9, 0.7);
  border-bottom: 1px solid var(--line);
}

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 82px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.95rem;
}

.brand small {
  color: var(--muted);
  font-size: 0.8rem;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--accent), #8f1f31);
  box-shadow: 0 10px 32px rgba(226, 61, 82, 0.34);
  font-weight: 800;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.main-nav > a {
  color: #d8dde7;
  padding: 0.7rem 1rem;
  border-radius: 999px;
  transition: 0.2s ease;
}

.main-nav > a:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.nav-button {
  background: linear-gradient(135deg, var(--accent), #c53147);
  color: white !important;
}

.nav-button-outline {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.nav-toggle {
  display: none;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 5px auto;
  border-radius: 10px;
  background: white;
}

.hero,
.section {
  padding: 4.4rem 0;
}

.section-alt {
  background: rgba(255, 255, 255, 0.025);
  border-block: 1px solid rgba(255, 255, 255, 0.05);
}

.hero-grid,
.split-grid,
.card-grid,
.footer-grid,
.admin-grid {
  display: grid;
  gap: 1.35rem;
}

.hero-grid {
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  min-height: calc(100vh - 82px);
  padding: 2.2rem 0 3.5rem;
}

.hero-copy h1,
.page-head h1 {
  font-size: clamp(2.4rem, 5vw, 5rem);
  line-height: 1.03;
  margin: 0.5rem 0 1rem;
}

.hero-copy .lead {
  max-width: 54ch;
  color: var(--muted);
  font-size: 1.06rem;
  line-height: 1.8;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(226, 61, 82, 0.25);
  background: rgba(226, 61, 82, 0.1);
  color: #ffb5c0;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.74rem;
  font-weight: 700;
}

.hero-actions,
.button-row,
.button-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 1.7rem;
}

.button-stack {
  flex-direction: column;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.9rem 1.35rem;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--accent), #c63149);
  color: white;
  font-weight: 700;
  box-shadow: 0 10px 26px rgba(226, 61, 82, 0.24);
  cursor: pointer;
}

.btn:hover {
  filter: brightness(1.08);
}

.btn-secondary {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: none;
}

.btn-block {
  width: 100%;
}

.stats-grid,
.card-grid-3,
.card-grid-4 {
  display: grid;
  gap: 1rem;
}

.stats-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 2rem;
}

.stat-card,
.card,
.form-card,
.glass-card,
.list-card {
  border: 1px solid rgba(255, 255, 255, 0.11);
  background: var(--panel);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.stat-card,
.card,
.list-card {
  padding: 1.25rem;
}

.stat-card strong {
  display: block;
  font-size: 2rem;
  margin-bottom: 0.35rem;
}

.stat-card span,
.muted,
.small-text {
  color: var(--muted);
}

.stat-card.plain strong {
  font-size: 1.25rem;
}

.hero-panel {
  position: relative;
}

.hero-panel::before {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 32px;
  background: radial-gradient(circle, rgba(226, 61, 82, 0.2), transparent 62%);
  filter: blur(20px);
}

.glass-card {
  position: relative;
  overflow: hidden;
  padding: 1.4rem;
  background: linear-gradient(180deg, rgba(20, 20, 26, 0.92), rgba(8, 8, 12, 0.86));
}

.glass-head,
.list-card-row,
.meta-row,
.page-head,
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.glass-head h2,
.section-head h2,
.card h2,
.card h3,
.form-card h1,
.form-card h2 {
  margin: 0.4rem 0 0;
}

.glass-head small,
.meta-row {
  color: var(--muted);
}

.online-dot {
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  background: rgba(46, 204, 113, 0.14);
  color: #98f1b9;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 700;
}

.feature-list,
.stack-list,
.timeline {
  display: grid;
  gap: 0.95rem;
}

.feature-item {
  padding: 1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.feature-item p,
.card p,
.thread-body {
  color: #d7dbe5;
  line-height: 1.75;
}

.card-grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card-grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.card-grid-2,
.split-grid,
.footer-grid,
.admin-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.section-head {
  margin-bottom: 1.15rem;
}

.section-head.slim {
  margin-bottom: 0.8rem;
}

.max-text {
  max-width: 65ch;
}

.timeline-item {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 1rem;
  align-items: start;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.timeline-item strong {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: rgba(226, 61, 82, 0.12);
  color: #ffbac5;
}

.timeline-item h3 {
  margin: 0 0 0.4rem;
}

.auth-main {
  padding: 4rem 0 5rem;
}

.auth-wrap {
  display: grid;
  place-items: center;
}

.form-card {
  width: min(100%, 620px);
  padding: 1.7rem;
}

.form-card.wide {
  width: auto;
}

.form-grid {
  display: grid;
  gap: 1rem;
  margin-top: 1.2rem;
}

.form-grid.compact-form {
  gap: 0.8rem;
}

.form-grid .full-width {
  grid-column: 1 / -1;
}

label {
  display: grid;
  gap: 0.5rem;
}

label span {
  font-weight: 600;
  color: #e9edf5;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  outline: none;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  color: white;
  padding: 0.95rem 1rem;
  font: inherit;
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(226, 61, 82, 0.68);
  box-shadow: 0 0 0 4px rgba(226, 61, 82, 0.12);
}

.alerts {
  margin-top: 1rem;
}

.alert {
  padding: 1rem 1.15rem;
  border-radius: 18px;
  margin-bottom: 0.8rem;
  border: 1px solid transparent;
}

.alert-success {
  background: rgba(46, 204, 113, 0.11);
  border-color: rgba(46, 204, 113, 0.25);
  color: #baf5cf;
}

.alert-error {
  background: rgba(255, 107, 107, 0.11);
  border-color: rgba(255, 107, 107, 0.24);
  color: #ffc5c5;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #edf1f8;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.badge-pending {
  background: rgba(255, 193, 7, 0.12);
  color: #ffd971;
}

.badge-approved {
  background: rgba(46, 204, 113, 0.12);
  color: #97efb8;
}

.badge-rejected {
  background: rgba(255, 107, 107, 0.12);
  color: #ffb1b1;
}

.page-head {
  align-items: end;
}

.top-gap {
  margin-top: 1.4rem;
}

.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: var(--shadow);
}

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

.table th,
.table td {
  padding: 1rem 1rem;
  text-align: left;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.table th {
  color: var(--muted);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.footer {
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(0, 0, 0, 0.22);
  padding: 2rem 0 3rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-content: start;
}

.brand-footer {
  margin-bottom: 0.9rem;
}

.text-link {
  display: inline-block;
  margin-top: 1rem;
  color: #ffbfca;
  font-weight: 700;
}

.wrap {
  flex-wrap: wrap;
}

@media (max-width: 980px) {
  .hero-grid,
  .split-grid,
  .card-grid-2,
  .card-grid-3,
  .card-grid-4,
  .footer-grid,
  .admin-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .main-nav {
    position: absolute;
    left: 1rem;
    right: 1rem;
    top: calc(100% + 0.75rem);
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    background: rgba(10, 10, 14, 0.95);
    box-shadow: var(--shadow);
  }

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

  .nav-toggle {
    display: inline-block;
  }

  .hero-grid {
    min-height: auto;
    padding-top: 2rem;
  }

  .page-head,
  .glass-head,
  .list-card-row,
  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }
}


.nav-role {
  display: inline-flex;
  align-items: center;
}

.stack-inline {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1rem;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #eef2f9;
  font-size: 0.84rem;
  font-weight: 600;
}

.notice {
  margin-top: 0.8rem;
  padding: 1rem 1.1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #e7ebf4;
  line-height: 1.7;
}

.table-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
}

.table-form select {
  min-width: 150px;
}

.badge-role-ceo {
  background: rgba(255, 204, 77, 0.14);
  color: #ffd670;
}

.badge-role-admin {
  background: rgba(255, 107, 107, 0.14);
  color: #ffb8b8;
}

.badge-role-zdane {
  background: rgba(46, 204, 113, 0.14);
  color: #9af0b8;
}

.badge-role-nie-zdane {
  background: rgba(255, 145, 77, 0.16);
  color: #ffca9b;
}

.badge-role-gracz-wl {
  background: rgba(75, 192, 255, 0.16);
  color: #afe4ff;
}

.badge-role-gracz {
  background: rgba(180, 180, 255, 0.14);
  color: #d3d3ff;
}

.badge-visibility-public {
  background: rgba(255, 255, 255, 0.08);
  color: #edf1f8;
}

.badge-visibility-wl {
  background: rgba(75, 192, 255, 0.16);
  color: #afe4ff;
}

.badge-visibility-staff {
  background: rgba(255, 107, 107, 0.16);
  color: #ffc2c2;
}
