:root {
  --navy: #071832;
  --navy-2: #10264d;
  --purple: #6d3ff2;
  --purple-2: #9b5cff;
  --green: #16c784;
  --green-dark: #0f9b66;
  --gold: #ffbd4a;
  --red: #ef476f;
  --ink: #14213d;
  --muted: #667085;
  --line: #e7eaf3;
  --surface: #ffffff;
  --soft: #f6f8fc;
  --shadow: 0 20px 45px rgba(7, 24, 50, 0.13);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--soft);
  line-height: 1.6;
}

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

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

button {
  cursor: pointer;
}

.site-shell {
  min-height: 100vh;
  background:
    radial-gradient(circle at 12% 5%, rgba(109, 63, 242, 0.22), transparent 30%),
    linear-gradient(160deg, #f7fbff 0%, #f6f4ff 46%, #effaf5 100%);
}

.container {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(7, 24, 50, 0.92);
  color: #fff;
  backdrop-filter: blur(18px);
}

.nav {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--green), var(--purple-2));
  box-shadow: 0 12px 25px rgba(22, 199, 132, 0.28);
}

.brand-mark::before {
  content: "$";
  color: #fff;
  font-weight: 900;
}

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

.nav-links a {
  color: rgba(255, 255, 255, 0.82);
  padding: 9px 11px;
  border-radius: var(--radius);
  font-size: 0.94rem;
  transition: 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.btn {
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 18px;
  border-radius: var(--radius);
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, var(--green), var(--green-dark));
  box-shadow: 0 14px 28px rgba(22, 199, 132, 0.26);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(22, 199, 132, 0.34);
}

.btn.secondary {
  background: linear-gradient(135deg, var(--purple), var(--purple-2));
  box-shadow: 0 14px 28px rgba(109, 63, 242, 0.24);
}

.btn.ghost {
  color: var(--navy);
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: none;
}

.btn.locked,
.btn:disabled {
  background: #aab2c5;
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

.icon {
  width: 20px;
  height: 20px;
  display: inline-grid;
  place-items: center;
  border-radius: 6px;
  color: inherit;
  font-weight: 900;
  line-height: 1;
}

.hero {
  min-height: calc(100vh - 74px);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  align-items: center;
  gap: 44px;
  padding: 58px 0 48px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border: 1px solid rgba(109, 63, 242, 0.18);
  border-radius: 999px;
  color: #3e2da1;
  background: rgba(255, 255, 255, 0.76);
  font-weight: 800;
  font-size: 0.86rem;
}

.hero h1,
.page-title h1 {
  margin: 18px 0 16px;
  font-size: clamp(2.35rem, 6vw, 5rem);
  line-height: 1;
  letter-spacing: 0;
  color: var(--navy);
}

.hero p,
.page-title p {
  max-width: 650px;
  margin: 0 0 24px;
  color: #42526f;
  font-size: 1.08rem;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin: 26px 0;
}

.highlight-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 30px;
}

.mini-stat {
  padding: 16px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 10px 26px rgba(7, 24, 50, 0.08);
}

.mini-stat strong {
  display: block;
  color: var(--navy);
  font-size: 1.05rem;
}

.mini-stat span {
  color: var(--muted);
  font-size: 0.9rem;
}

.hero-panel,
.card,
.auth-card,
.table-wrap {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero-panel {
  padding: 24px;
  animation: floatIn 0.8s ease both;
}

.earning-preview {
  padding: 20px;
  border-radius: var(--radius);
  color: #fff;
  background:
    linear-gradient(135deg, rgba(109, 63, 242, 0.92), rgba(7, 24, 50, 0.96)),
    var(--navy);
}

.earning-preview h2 {
  margin: 0;
  font-size: 1.45rem;
}

.balance-number {
  margin: 14px 0 4px;
  font-size: 3rem;
  font-weight: 900;
  line-height: 1;
}

.progress {
  height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: #e9edf7;
}

.progress span {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), var(--gold));
  transition: width 0.7s ease;
}

.offer-stack {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.offer-line {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 13px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line);
}

.section {
  padding: 58px 0;
}

.section.compact {
  padding: 34px 0;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}

.section-heading h2 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(1.65rem, 3vw, 2.4rem);
  line-height: 1.1;
}

.section-heading p {
  margin: 6px 0 0;
  color: var(--muted);
  max-width: 620px;
}

.grid {
  display: grid;
  gap: 18px;
}

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

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

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

.card {
  padding: 22px;
}

.card h3 {
  margin: 10px 0 8px;
  color: var(--navy);
}

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

.card-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  color: #fff;
  background: linear-gradient(135deg, var(--purple), var(--green));
  font-weight: 900;
}

.quote {
  position: relative;
}

.quote strong {
  display: block;
  margin-top: 14px;
  color: var(--navy);
}

.faq {
  display: grid;
  gap: 12px;
}

.faq details {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  box-shadow: 0 8px 18px rgba(7, 24, 50, 0.05);
}

.faq summary {
  cursor: pointer;
  color: var(--navy);
  font-weight: 800;
}

.faq p {
  color: var(--muted);
  margin: 10px 0 0;
}

.footer {
  padding: 34px 0;
  color: rgba(255, 255, 255, 0.78);
  background: var(--navy);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.footer a {
  color: rgba(255, 255, 255, 0.82);
  margin-left: 16px;
}

.page-header {
  padding: 44px 0 18px;
}

.page-title h1 {
  font-size: clamp(2.1rem, 4vw, 3.4rem);
}

.auth-layout {
  min-height: calc(100vh - 74px);
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 1.05fr);
  gap: 34px;
  align-items: center;
  padding: 44px 0;
}

.auth-card {
  padding: 28px;
}

.form {
  display: grid;
  gap: 16px;
}

.field {
  display: grid;
  gap: 7px;
}

.field label {
  font-weight: 800;
  color: var(--navy);
  font-size: 0.93rem;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid #dce2ef;
  border-radius: var(--radius);
  padding: 11px 12px;
  color: var(--ink);
  background: #fff;
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: rgba(109, 63, 242, 0.7);
  box-shadow: 0 0 0 4px rgba(109, 63, 242, 0.12);
}

.inline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.checkline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}

.muted-link {
  color: var(--purple);
  font-weight: 800;
}

.app-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  padding: 28px 0 58px;
}

.sidebar {
  position: sticky;
  top: 96px;
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}

.sidebar a,
.sidebar button {
  width: 100%;
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: rgba(255, 255, 255, 0.82);
  border: 0;
  border-radius: var(--radius);
  padding: 10px;
  background: transparent;
  text-align: left;
}

.sidebar a:hover,
.sidebar a.active,
.sidebar button:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

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

.stat-card {
  padding: 20px;
  border-radius: var(--radius);
  color: #fff;
  background: linear-gradient(135deg, var(--navy), var(--purple));
  box-shadow: var(--shadow);
}

.stat-card.green {
  background: linear-gradient(135deg, #0c7f5a, var(--green));
}

.stat-card.light {
  color: var(--navy);
  background: #fff;
  border: 1px solid var(--line);
}

.stat-card span {
  color: inherit;
  opacity: 0.78;
  font-weight: 700;
}

.stat-card strong {
  display: block;
  margin-top: 8px;
  font-size: 2rem;
  line-height: 1;
}

.survey-card {
  display: grid;
  gap: 14px;
}

.survey-meta,
.activity-item,
.reward-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  padding: 7px 10px;
  border-radius: 999px;
  color: #263957;
  background: #eef3ff;
  font-size: 0.86rem;
  font-weight: 800;
}

.pill.green {
  color: #075a3d;
  background: rgba(22, 199, 132, 0.14);
}

.pill.gold {
  color: #704500;
  background: rgba(255, 189, 74, 0.2);
}

.pill.red {
  color: #8f1f3c;
  background: rgba(239, 71, 111, 0.14);
}

.empty {
  padding: 26px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed #cbd4e4;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.7);
}

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

.activity-item {
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.activity-item:last-child {
  border-bottom: 0;
}

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

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

th,
td {
  padding: 13px 14px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

th {
  color: var(--navy);
  background: #f7f9fd;
  font-size: 0.88rem;
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 50;
  width: min(360px, calc(100% - 36px));
  padding: 15px 16px;
  color: #fff;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--navy), var(--purple));
  box-shadow: var(--shadow);
  transform: translateY(18px);
  opacity: 0;
  pointer-events: none;
  transition: 0.25s ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.loader {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  background: var(--navy);
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.loader.hide {
  opacity: 0;
  visibility: hidden;
}

.spinner {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 5px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--green);
  animation: spin 0.8s linear infinite;
}

.legal {
  max-width: 860px;
  padding-bottom: 58px;
}

.legal h2 {
  color: var(--navy);
  margin-top: 28px;
}

.legal p,
.legal li {
  color: var(--muted);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes floatIn {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 960px) {
  .hero,
  .auth-layout,
  .app-layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
  }

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

@media (max-width: 720px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px 0;
  }

  .nav-links {
    width: 100%;
  }

  .nav-links a {
    flex: 1 1 auto;
  }

  .hero {
    min-height: auto;
    padding-top: 38px;
  }

  .highlight-row,
  .grid.cols-4,
  .grid.cols-3,
  .grid.cols-2 {
    grid-template-columns: 1fr;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer a {
    display: inline-block;
    margin: 0 14px 8px 0;
  }
}
