:root {
  --bg: #050607;
  --panel: #0f1115;
  --surface: #0f1115;
  --surface-soft: #111827;
  --border: #2a2f38;
  --text: #d1d5db;
  --text-strong: #e5e7eb;
  --muted: #9ca3af;
  --accent: #16d3ff;
  --accent-2: #0ea5e9;
  --primary: #0369a1;
  --success: #22c55e;
  --shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
  --radius: 18px;
}

html[data-theme="light"] {
  --bg: #e8eaf8;
  --panel: #e5e1ff;
  --surface: #f4f5f8;
  --surface-soft: #eef0fa;
  --border: #c9c6df;
  --text: #334155;
  --text-strong: #0f172a;
  --muted: #64748b;
  --accent: #2563eb;
  --accent-2: #1d4ed8;
  --primary: #2563eb;
  --success: #15803d;
  --shadow: 0 8px 30px rgba(37, 99, 235, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, Arial, sans-serif;
  line-height: 1.55;
}

a {
  color: inherit;
}

.site-header,
main,
footer {
  width: min(1180px, calc(100% - 40px));
  margin-inline: auto;
}

.site-header {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--border);
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.brand-logo {
  height: 42px;
  width: auto;
  display: block;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.theme-toggle {
  min-width: 42px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--panel);
  color: var(--text-strong);
  cursor: pointer;
  font-size: 16px;
}

.back-link {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 650;
  text-underline-offset: 4px;
}

.hero {
  max-width: 790px;
  margin: 56px auto 40px;
  text-align: center;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 16px;
  color: var(--text-strong);
  font-size: clamp(2rem, 4.5vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.hero-copy {
  margin-bottom: 14px;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.12rem);
}

.token-note {
  display: inline-block;
  margin: 0;
  padding: 7px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 0.82rem;
}

.plans {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

.plan-card {
  position: relative;
  display: flex;
  min-height: 540px;
  flex-direction: column;
  padding: 30px 24px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.plan-card.featured {
  border: 2px solid var(--accent);
  background: linear-gradient(180deg, rgba(22, 211, 255, 0.08), var(--surface) 34%);
  transform: translateY(-8px);
}

html[data-theme="light"] .plan-card.featured {
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.08), var(--surface) 34%);
}

.badge {
  position: absolute;
  top: -13px;
  right: 20px;
  padding: 6px 11px;
  border-radius: 999px;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.popular {
  background: linear-gradient(90deg, var(--accent-2), var(--accent));
}

.savings {
  background: var(--success);
}

.plan-heading h2 {
  margin-bottom: 3px;
  color: var(--text-strong);
  font-size: 1.28rem;
}

.plan-heading p,
.period,
.allowance span {
  color: var(--muted);
}

.plan-heading p {
  min-height: 48px;
  font-size: 0.9rem;
}

.price {
  min-height: 94px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin: 4px 0 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.amount {
  color: var(--text-strong);
  font-size: 2.05rem;
  font-weight: 850;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.period {
  font-size: 0.83rem;
}

.original-price {
  color: var(--muted);
  font-size: 0.8rem;
  text-decoration: line-through;
}

.allowance {
  display: flex;
  flex-direction: column;
  margin-bottom: 18px;
}

.allowance strong {
  color: var(--accent);
  font-size: 1.13rem;
}

.allowance span {
  font-size: 0.82rem;
}

.features {
  display: grid;
  gap: 11px;
  margin: 0 0 26px;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 0.86rem;
}

.features li {
  position: relative;
  padding-left: 23px;
}

.features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--success);
  font-weight: 900;
}

.plan-button,
.team-button {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel);
  color: var(--text-strong);
  cursor: pointer;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 800;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.plan-button:hover:not(:disabled),
.team-button:hover,
.theme-toggle:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.plan-button.primary,
.team-button {
  border-color: transparent;
  background: linear-gradient(100deg, var(--accent-2), var(--primary));
  color: #fff;
}

.plan-button:disabled {
  border-color: var(--border);
  background: var(--surface-soft);
  color: var(--muted);
  cursor: default;
}

.plan-button:focus-visible,
.team-button:focus-visible,
.back-link:focus-visible,
.brand:focus-visible,
.theme-toggle:focus-visible,
.toast-close:focus-visible {
  outline: 3px solid rgba(22, 211, 255, 0.45);
  outline-offset: 3px;
}

html[data-theme="light"] .plan-button:focus-visible,
html[data-theme="light"] .team-button:focus-visible,
html[data-theme="light"] .back-link:focus-visible,
html[data-theme="light"] .brand:focus-visible,
html[data-theme="light"] .theme-toggle:focus-visible,
html[data-theme="light"] .toast-close:focus-visible {
  outline-color: rgba(37, 99, 235, 0.45);
}

.usage-policy {
  display: flex;
  gap: 18px;
  margin: 34px 0 18px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface-soft);
}

.usage-policy h2 {
  margin-bottom: 8px;
  color: var(--text-strong);
  font-size: 1rem;
}

.usage-policy p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.info-icon {
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent);
  color: #041018;
  font-family: Georgia, serif;
  font-weight: 700;
}

html[data-theme="light"] .info-icon {
  color: #fff;
}

.team-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  margin: 18px 0 70px;
  padding: clamp(26px, 5vw, 44px);
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 90% 20%, rgba(22, 211, 255, 0.18), transparent 230px),
    #0b1220;
  color: #fff;
  box-shadow: var(--shadow);
}

html[data-theme="light"] .team-card {
  background:
    radial-gradient(circle at 90% 20%, rgba(37, 99, 235, 0.18), transparent 230px),
    #1e3a8a;
}

.team-card h2 {
  margin-bottom: 8px;
  font-size: clamp(1.45rem, 3vw, 2rem);
}

.team-card p:not(.eyebrow) {
  max-width: 680px;
  margin: 0;
  color: #c8d7ee;
}

.team-card .eyebrow {
  color: var(--accent);
}

.team-card .team-button {
  min-width: 170px;
  margin: 0;
  padding: 0 22px;
  background: #fff;
  color: #0f172a;
}

footer {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.82rem;
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 50;
  width: min(390px, calc(100% - 32px));
  display: grid;
  gap: 3px;
  padding: 18px 48px 18px 20px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel);
  color: var(--text-strong);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(18px);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.toast.visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.toast span {
  color: var(--muted);
  font-size: 0.84rem;
}

.toast-close {
  position: absolute;
  top: 10px;
  right: 12px;
  border: 0;
  background: transparent;
  color: var(--text-strong);
  cursor: pointer;
  font-size: 1.35rem;
}

@media (max-width: 1030px) {
  .plans {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 26px 18px;
  }

  .plan-card.featured {
    transform: none;
  }
}

@media (max-width: 620px) {
  .site-header,
  main,
  footer {
    width: min(100% - 28px, 1180px);
  }

  .site-header {
    min-height: 68px;
  }

  .back-link {
    font-size: 0;
  }

  .back-link::after {
    content: "Back";
    font-size: 0.88rem;
  }

  .hero {
    margin: 40px auto 32px;
  }

  .plans {
    grid-template-columns: 1fr;
  }

  .plan-card {
    min-height: auto;
  }

  .plan-heading p {
    min-height: auto;
  }

  .team-card {
    align-items: stretch;
    flex-direction: column;
    gap: 24px;
  }

  .team-card .team-button {
    min-height: 48px;
  }

  footer {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    padding: 18px 0;
  }

  .toast {
    right: 16px;
    bottom: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
