:root {
  color-scheme: light;
  --bg: #eef3ef;
  --surface: #ffffff;
  --surface-soft: #f7faf8;
  --ink: #111c17;
  --muted: #68776f;
  --line: #dbe6df;
  --green: #1d7a52;
  --green-dark: #105b3a;
  --teal: #0f7582;
  --gold: #d6a936;
  --red: #b42318;
  --amber: #a15c07;
  --dark: #101b16;
  --dark-soft: #172720;
  --shadow: 0 20px 55px rgba(17, 28, 23, 0.12);
  --soft-shadow: 0 12px 30px rgba(17, 28, 23, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
}

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

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

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

.hidden {
  display: none !important;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 76px;
  padding: 0 clamp(18px, 4vw, 52px);
  background: rgba(238, 243, 239, 0.88);
  border-bottom: 1px solid rgba(219, 230, 223, 0.86);
  backdrop-filter: blur(16px);
}

.brand-link,
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--dark);
  color: #fff;
  font-size: 22px;
  font-weight: 900;
}

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

.site-nav a {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 7px;
  color: var(--muted);
  font-weight: 800;
}

.site-nav a:hover {
  background: #dfe9e2;
  color: var(--ink);
}

.site-footer {
  width: min(1180px, calc(100% - 40px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 0 auto;
  padding: 28px 0 34px;
  border-top: 1px solid var(--line);
}

.site-footer > div {
  display: grid;
  gap: 10px;
}

.site-footer p {
  color: var(--muted);
  line-height: 1.6;
}

.footer-discord {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  padding: 0 16px;
  background: var(--dark);
  color: #fff;
  font-weight: 900;
  white-space: nowrap;
}

.footer-discord:hover {
  background: var(--green-dark);
}

.footer-discord.disabled {
  cursor: default;
  color: var(--muted);
  background: #e3ebe6;
}

button,
.link-button,
.provider {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 7px;
  padding: 0 16px;
  cursor: pointer;
  font-weight: 900;
}

.primary {
  background: var(--green);
  color: #fff;
  box-shadow: 0 10px 22px rgba(29, 122, 82, 0.22);
}

.primary:hover {
  background: var(--green-dark);
}

.ghost {
  background: #e3ebe6;
  color: var(--ink);
}

.ghost:hover {
  background: #d7e4dc;
}

.danger {
  background: #ffe2dc;
  color: var(--red);
}

.hero {
  position: relative;
  min-height: calc(100vh - 76px);
  display: grid;
  align-items: center;
  padding: 58px clamp(18px, 5vw, 76px);
  overflow: hidden;
  background: var(--dark);
  color: #fff;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 34%;
  background: linear-gradient(180deg, rgba(16, 27, 22, 0), rgba(238, 243, 239, 1));
  pointer-events: none;
}

.hero-copy {
  position: relative;
  z-index: 2;
  display: grid;
  gap: 22px;
  width: min(760px, 100%);
}

.eyebrow {
  color: var(--teal);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #78dbc4;
}

h1 {
  font-size: clamp(42px, 6.6vw, 78px);
  line-height: 1;
  letter-spacing: 0;
}

h2 {
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.18;
}

h3 {
  font-size: 18px;
}

.hero-copy > p:not(.eyebrow),
.auth-card p,
.empty-state p,
.page-head > .muted {
  color: rgba(244, 250, 247, 0.72);
  font-size: 18px;
  line-height: 1.75;
  max-width: 720px;
}

.hero-actions,
.hero-proof,
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-proof span {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  padding: 0 12px;
  color: rgba(255, 255, 255, 0.78);
  background: rgba(255, 255, 255, 0.06);
  font-size: 13px;
  font-weight: 800;
}

.product-visual {
  position: absolute;
  z-index: 1;
  inset: auto clamp(18px, 5vw, 80px) 7vh auto;
  width: min(610px, 46vw);
  min-height: 440px;
  display: grid;
  align-content: space-between;
  gap: 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 26px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), transparent 42%),
    #0e1713;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.42);
}

[dir="rtl"] .product-visual {
  inset-inline: auto clamp(18px, 5vw, 80px);
}

.visual-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.visual-brand .brand-mark {
  flex: 0 0 auto;
}

.visual-brand div {
  display: grid;
  gap: 3px;
}

.visual-brand strong {
  color: #f2fff8;
  font-size: 20px;
}

.visual-brand small,
.visual-main p,
.visual-list span {
  color: rgba(244, 250, 247, 0.68);
}

.visual-main {
  display: grid;
  gap: 12px;
  max-width: 500px;
}

.visual-main p {
  font-weight: 900;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0;
}

.visual-main h2 {
  max-width: 540px;
  color: #ffffff;
  font-size: clamp(28px, 3.6vw, 42px);
  line-height: 1.08;
}

.visual-list {
  display: grid;
  gap: 10px;
}

.visual-list article {
  display: grid;
  gap: 5px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.055);
}

.visual-list strong {
  color: #f4faf7;
}

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

.visual-footer span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(120, 219, 196, 0.22);
  border-radius: 999px;
  color: #c5fff2;
  background: rgba(120, 219, 196, 0.08);
  font-weight: 900;
  font-size: 13px;
}

.section,
.pricing-grid,
.auth-page,
.client-layout {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 52px 0;
}

.section-title,
.page-head {
  display: grid;
  gap: 10px;
  margin-bottom: 22px;
}

.page-head {
  text-align: center;
}

.page-head > .muted {
  margin: 0 auto;
  color: var(--muted);
}

.feature-grid,
.pricing-grid {
  display: grid;
  gap: 16px;
}

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

.feature,
.price-card,
.panel,
.auth-card,
.editor,
.table-wrap,
.stat-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--soft-shadow);
}

.feature {
  min-height: 176px;
  display: grid;
  align-content: space-between;
  padding: 20px;
}

.feature span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: #e2f2e9;
  color: var(--green-dark);
  font-weight: 900;
}

.feature p,
.muted,
.form-note {
  color: var(--muted);
  line-height: 1.65;
}

.operations-band {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 18px;
  align-items: stretch;
  border: 1px solid rgba(16, 91, 58, 0.18);
  border-radius: 8px;
  padding: 28px;
  background: #fbfdfb;
  box-shadow: var(--soft-shadow);
}

.ops-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.ops-grid article {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.ops-grid span {
  color: var(--muted);
}

.pricing-grid {
  grid-template-columns: repeat(2, minmax(260px, 1fr));
}

.price-card {
  display: grid;
  gap: 24px;
  padding: 28px;
}

.price-card.featured {
  border-color: rgba(29, 122, 82, 0.62);
  box-shadow: 0 20px 55px rgba(29, 122, 82, 0.14);
}

.price-card strong {
  display: block;
  margin-top: 14px;
  font-size: 22px;
}

.price-card ul {
  display: grid;
  gap: 12px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.price-card li::before {
  content: "✓";
  color: var(--green);
  margin-inline-end: 8px;
  font-weight: 900;
}

.auth-page {
  min-height: calc(100vh - 76px);
  display: grid;
  place-items: center;
}

.auth-card {
  width: min(460px, 100%);
  display: grid;
  gap: 16px;
  padding: 28px;
}

.auth-card p {
  color: var(--muted);
}

.provider {
  color: #fff;
}

.discord {
  background: #5865f2;
}

.google {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 11px 12px;
  background: #fff;
  color: var(--ink);
  outline: none;
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(15, 117, 130, 0.12);
}

input:disabled,
textarea:disabled,
button:disabled {
  opacity: 0.68;
  cursor: not-allowed;
}

.error {
  min-height: 20px;
  color: var(--red);
  font-weight: 900;
}

.dashboard {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px 1fr;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding: 24px;
  background: var(--dark);
  color: #fff;
}

.compact .brand-mark {
  background: #fff;
  color: var(--dark);
}

.sidebar nav {
  display: grid;
  gap: 8px;
}

.nav-item {
  justify-content: flex-start;
  background: transparent;
  color: #dbe7e1;
}

.nav-item.active {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.logout {
  margin-top: auto;
}

.workspace {
  display: grid;
  align-content: start;
  gap: 22px;
  padding: 28px;
}

.workspace-header,
.form-header,
.table-header,
.status-panel,
.resource-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(130px, 1fr));
  gap: 14px;
}

.stat-card {
  padding: 18px;
}

.stat-card strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
}

.editor,
.panel {
  padding: 22px;
}

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

.compact-form {
  grid-template-columns: repeat(2, 1fr);
}

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

.table-wrap {
  overflow: hidden;
}

.table-header {
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.table-header input {
  max-width: 280px;
}

.table-scroller {
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 1320px;
  border-collapse: collapse;
}

th,
td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  text-align: start;
  vertical-align: middle;
}

th {
  color: var(--muted);
  font-size: 13px;
}

.badge {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 10px;
  font-size: 13px;
  font-weight: 900;
}

.badge.active {
  background: #dbf2e5;
  color: var(--green-dark);
}

.badge.expired {
  background: #ffe3df;
  color: var(--red);
}

.badge.suspended {
  background: #fff0d6;
  color: var(--amber);
}

.client-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 20px;
  align-items: start;
}

.client-side {
  display: grid;
  justify-items: center;
  gap: 10px;
  text-align: center;
}

.avatar {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 8px;
  background: var(--dark);
  color: #fff;
  font-size: 34px;
  font-weight: 900;
}

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

.client-main {
  display: grid;
  gap: 18px;
}

.resource-panel p {
  margin-top: 8px;
}

.client-stats {
  grid-template-columns: repeat(3, 1fr);
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 16px;
}

.detail-grid div,
.system-strip div {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.detail-grid span,
.system-strip span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
}

code {
  display: inline-block;
  max-width: 230px;
  padding: 5px 7px;
  overflow-wrap: anywhere;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #edf4ef;
  color: var(--ink);
}

.settings-form {
  display: grid;
  gap: 24px;
  margin-top: 16px;
}

.settings-form section {
  display: grid;
  gap: 12px;
}

.toggle-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.toggle {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--ink);
}

.toggle input {
  width: 18px;
  height: 18px;
}

.permission-list {
  display: grid;
  gap: 10px;
}

.permission-row {
  display: grid;
  grid-template-columns: 220px 1fr 1fr;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.system-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.admin-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.admin-filters input,
.admin-filters select {
  min-width: 150px;
}

.tiny {
  min-height: 28px;
  padding: 0 8px;
  border-radius: 6px;
  font-size: 12px;
  background: #e3ebe6;
  color: var(--ink);
  box-shadow: none;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(16, 27, 22, 0.56);
}

.modal-panel {
  width: min(920px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  display: grid;
  gap: 18px;
  padding: 22px;
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.action-log-list,
.message-list {
  display: grid;
  gap: 10px;
}

.action-log-list > div,
.message-item {
  display: grid;
  gap: 5px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.action-log-list span,
.message-item span {
  color: var(--muted);
  font-size: 13px;
}

.setup-list {
  display: grid;
  gap: 10px;
  margin: 14px 0;
  padding-inline-start: 22px;
  color: var(--muted);
}

.setup-list li::marker {
  color: var(--accent);
  font-weight: 800;
}

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

.code-box code {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.loading,
.empty-state {
  text-align: center;
}

@media (max-width: 1100px) {
  .hero {
    min-height: auto;
    padding-bottom: 360px;
  }

  .product-visual {
    width: min(720px, calc(100% - 36px));
    inset: auto 18px 32px 18px;
  }

  .dashboard,
  .client-layout,
  .operations-band {
    grid-template-columns: 1fr;
  }

  .feature-grid,
  .stats,
  .form-grid,
  .ops-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .site-header {
    position: static;
    flex-wrap: wrap;
    padding: 16px;
  }

  .site-nav {
    order: 3;
    width: 100%;
    overflow-x: auto;
  }

  .site-footer {
    width: calc(100% - 32px);
    display: grid;
    align-items: stretch;
  }

  .footer-discord {
    width: 100%;
  }

  .hero,
  .section,
  .pricing-grid,
  .auth-page,
  .client-layout,
  .workspace {
    width: 100%;
    padding: 24px 16px;
  }

  .hero {
    padding-bottom: 24px;
  }

  .product-visual {
    position: relative;
    inset: auto;
    width: 100%;
    min-height: auto;
  }

  h1 {
    font-size: 38px;
  }

  .feature-grid,
  .pricing-grid,
  .stats,
  .system-strip,
  .form-grid,
  .compact-form,
  .client-stats,
  .detail-grid,
  .toggle-grid,
  .permission-row,
  .resource-panel,
  .ops-grid {
    grid-template-columns: 1fr;
  }

  .resource-panel,
  .workspace-header,
  .form-header,
  .table-header,
  .status-panel {
    display: grid;
    align-items: stretch;
  }

  .table-header input {
    max-width: none;
  }
}
