/* =====================================================
   RESET
===================================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", sans-serif;
  background: #0b0f19;
  color: #ffffff;
  min-height: 100vh;
}

button,
input {
  font-family: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}


/* =====================================================
   GLOBAL
===================================================== */

.hidden {
  display: none !important;
}

.screen {
  min-height: 100vh;
}


/* =====================================================
   LOADING SCREEN
===================================================== */

.loading-screen {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 25px;
  background: #0b0f19;
}

.loading-logo {
  width: 76px;
  height: 76px;
  border-radius: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #171d2b;
  color: #7c5cff;
  font-size: 34px;
  margin-bottom: 18px;
}

.loading-screen h1 {
  font-size: 27px;
  font-weight: 800;
}

.loading-screen p {
  color: #8992a5;
  margin-top: 8px;
}

.loader {
  width: 34px;
  height: 34px;
  margin-top: 24px;
  border: 3px solid #272e40;
  border-top-color: #7c5cff;
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}

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


/* =====================================================
   AUTH SCREEN
===================================================== */

.auth-screen {
  min-height: 100vh;
  background: #0b0f19;
  padding: 35px 18px;
}

.auth-container {
  width: 100%;
  max-width: 440px;
  margin: auto;
}

.auth-logo {
  text-align: center;
  margin-bottom: 28px;
}

.logo-icon {
  width: 70px;
  height: 70px;
  border-radius: 22px;
  background: #171d2b;
  color: #7c5cff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 15px;
  font-size: 30px;
}

.auth-logo h1 {
  font-size: 28px;
  font-weight: 800;
}

.auth-logo p {
  color: #8992a5;
  margin-top: 7px;
}

.auth-card {
  background: #121824;
  border: 1px solid #20283a;
  border-radius: 26px;
  padding: 25px 20px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.25);
}

.auth-card h2 {
  font-size: 23px;
  margin-bottom: 8px;
}

.auth-subtitle {
  color: #8992a5;
  font-size: 14px;
  margin-bottom: 24px;
}


/* =====================================================
   INPUTS
===================================================== */

.input-group {
  margin-bottom: 17px;
}

.input-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #cbd1dd;
  margin-bottom: 8px;
}

.input-group label span {
  color: #7d8799;
  font-size: 11px;
  margin-left: 5px;
}

.input-wrapper {
  position: relative;
}

.input-wrapper > i {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #7c5cff;
}

input {
  width: 100%;
  height: 50px;
  border: 1px solid #283247;
  border-radius: 15px;
  background: #0e1420;
  color: #ffffff;
  padding: 0 15px 0 43px;
  outline: none;
  font-size: 14px;
}

input:focus {
  border-color: #7c5cff;
}

.input-group > input {
  padding-left: 15px;
}

.input-group small {
  display: block;
  color: #727d91;
  font-size: 11px;
  line-height: 1.5;
  margin-top: 7px;
}

.password-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: #7d8799;
  cursor: pointer;
}


/* =====================================================
   BUTTONS
===================================================== */

.primary-btn,
.secondary-btn {
  width: 100%;
  min-height: 50px;
  border: none;
  border-radius: 15px;
  cursor: pointer;
  font-weight: 700;
  font-size: 14px;
  transition: 0.2s ease;
}

.primary-btn {
  background: #7c5cff;
  color: #ffffff;
}

.primary-btn:hover {
  transform: translateY(-1px);
  opacity: 0.92;
}

.secondary-btn {
  background: #20283a;
  color: #ffffff;
}

.secondary-btn:hover {
  background: #29344a;
}

.forgot-row {
  text-align: right;
  margin: -4px 0 17px;
}

.forgot-row button,
.auth-switch button {
  border: none;
  background: transparent;
  color: #927cff;
  cursor: pointer;
  font-weight: 600;
}

.auth-switch {
  text-align: center;
  color: #8992a5;
  font-size: 13px;
  margin-top: 20px;
}

.form-message {
  padding: 11px 13px;
  border-radius: 12px;
  font-size: 13px;
  margin-bottom: 15px;
}

.form-message.error {
  background: rgba(255, 75, 75, 0.12);
  color: #ff8585;
}

.form-message.success {
  background: rgba(45, 200, 120, 0.12);
  color: #65dba0;
}


/* =====================================================
   APP HEADER
===================================================== */

.app-screen {
  background: #0b0f19;
  padding-bottom: 90px;
}

.app-header {
  height: 68px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #1c2433;
  background: #0d121d;
  position: sticky;
  top: 0;
  z-index: 20;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 18px;
  font-weight: 800;
}

.header-brand i {
  color: #7c5cff;
}

.header-title {
  font-size: 18px;
}

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

.icon-btn,
.header-back {
  position: relative;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 13px;
  background: #171e2c;
  color: #ffffff;
  cursor: pointer;
}

.header-back {
  margin-right: 10px;
}


/* =====================================================
   APP CONTENT
===================================================== */

.app-content {
  width: 100%;
  max-width: 900px;
  margin: auto;
  padding: 25px 16px;
}


/* =====================================================
   WELCOME
===================================================== */

.welcome-section {
  margin-bottom: 20px;
}

.welcome-section p {
  color: #8992a5;
  font-size: 13px;
  margin-bottom: 6px;
}

.welcome-section h1 {
  font-size: 24px;
  font-weight: 800;
}


/* =====================================================
   BALANCE CARD
===================================================== */

.balance-card {
  background: linear-gradient(135deg, #211a46, #171d35);
  border: 1px solid #3a3266;
  border-radius: 25px;
  padding: 22px;
  margin-bottom: 28px;
}

.balance-top {
  display: flex;
  justify-content: space-between;
  color: #b7b2d4;
  font-size: 13px;
}

.balance-top i {
  color: #ffd76a;
  font-size: 20px;
}

.balance-amount {
  font-size: 38px;
  font-weight: 800;
  margin-top: 15px;
}

.balance-card > span {
  color: #9e98bd;
  font-size: 13px;
}

.balance-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 25px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 12px;
  color: #aaa5c4;
}

.balance-footer strong {
  color: #ffffff;
}

.balance-footer button {
  border: none;
  background: #7c5cff;
  color: #ffffff;
  border-radius: 12px;
  padding: 10px 13px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}


/* =====================================================
   SECTION HEADING
===================================================== */

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  margin: 24px 2px 14px;
}

.section-heading h2 {
  font-size: 18px;
}

.section-heading span {
  color: #778196;
  font-size: 11px;
}


/* =====================================================
   EARNING CARDS
===================================================== */

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

.earning-card {
  min-height: 165px;
  position: relative;
  text-decoration: none;
  text-align: left;
  border: 1px solid #222c3e;
  border-radius: 24px;
  background: #121824;
  color: #ffffff;
  padding: 18px;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.earning-card:hover {
  transform: translateY(-3px);
  border-color: #7c5cff;
  background: #151c2b;
}

.earning-icon {
  width: 45px;
  height: 45px;
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #20283a;
  color: #a795ff;
  font-size: 19px;
  margin-bottom: 18px;
}

.earning-card h3 {
  font-size: 14px;
  line-height: 1.3;
  margin-bottom: 6px;
}

.earning-card p {
  color: #7e899c;
  font-size: 11px;
}

.card-arrow {
  position: absolute;
  right: 16px;
  bottom: 17px;
  color: #69758a;
  font-size: 12px;
}


/* =====================================================
   ACTIVITY
===================================================== */

.activity-list {
  background: #121824;
  border: 1px solid #222c3e;
  border-radius: 20px;
  padding: 20px;
  color: #778196;
  font-size: 13px;
}


/* =====================================================
   PAGE INTRO
===================================================== */

.page-intro {
  text-align: center;
  padding: 15px 0 25px;
}

.page-icon {
  width: 65px;
  height: 65px;
  border-radius: 21px;
  background: #191f31;
  color: #927cff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: auto;
  font-size: 27px;
}

.page-intro h1 {
  margin-top: 16px;
  font-size: 24px;
}

.page-intro p {
  color: #7f899b;
  margin-top: 7px;
  font-size: 13px;
}


/* =====================================================
   SETTINGS
===================================================== */

.settings-profile {
  display: flex;
  align-items: center;
  gap: 15px;
  background: #121824;
  border: 1px solid #222c3e;
  padding: 17px;
  border-radius: 22px;
  margin-bottom: 18px;
}

.settings-profile img {
  width: 55px;
  height: 55px;
  border-radius: 18px;
  object-fit: cover;
  background: #20283a;
}

.settings-profile h2 {
  font-size: 17px;
}

.settings-profile p {
  color: #7d8799;
  font-size: 12px;
  margin-top: 4px;
}

.settings-list {
  background: #121824;
  border: 1px solid #222c3e;
  border-radius: 22px;
  overflow: hidden;
}

.settings-item {
  width: 100%;
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 17px;
  background: transparent;
  color: #ffffff;
  border: none;
  border-bottom: 1px solid #202838;
  cursor: pointer;
  text-align: left;
}

.settings-item:last-child {
  border-bottom: none;
}

.settings-item > i:first-child {
  width: 22px;
  color: #927cff;
}

.settings-item span {
  flex: 1;
  font-size: 13px;
}

.settings-item > i:last-child {
  color: #657187;
  font-size: 12px;
}

.theme-setting {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #121824;
  border: 1px solid #222c3e;
  border-radius: 18px;
  padding: 17px;
  margin-top: 15px;
}

.theme-setting > div {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

.theme-setting i {
  color: #927cff;
}


/* =====================================================
   SWITCH
===================================================== */

.switch {
  position: relative;
  width: 46px;
  height: 25px;
}

.switch input {
  display: none;
}

.slider {
  position: absolute;
  inset: 0;
  border-radius: 30px;
  background: #30394c;
  cursor: pointer;
}

.slider::before {
  content: "";
  position: absolute;
  width: 19px;
  height: 19px;
  left: 3px;
  top: 3px;
  background: #ffffff;
  border-radius: 50%;
  transition: 0.2s;
}

.switch input:checked + .slider {
  background: #7c5cff;
}

.switch input:checked + .slider::before {
  transform: translateX(21px);
}


/* =====================================================
   LOGOUT
===================================================== */

.logout-btn {
  width: 100%;
  min-height: 50px;
  margin-top: 18px;
  border: 1px solid rgba(255, 90, 90, 0.25);
  border-radius: 15px;
  background: rgba(255, 70, 70, 0.08);
  color: #ff8585;
  font-weight: 700;
  cursor: pointer;
}


/* =====================================================
   REFERRAL
===================================================== */

.referral-card-box,
.withdraw-section,
.withdraw-balance,
.help-card,
.profile-edit {
  background: #121824;
  border: 1px solid #222c3e;
  border-radius: 23px;
  padding: 20px;
  margin-bottom: 17px;
}

.referral-card-box h2,
.withdraw-section h2 {
  font-size: 17px;
  margin-bottom: 16px;
}

.referral-code-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #0d131f;
  border: 1px dashed #4d427e;
  border-radius: 15px;
  padding: 15px;
  margin-bottom: 15px;
}

.referral-code-box strong {
  color: #a795ff;
  letter-spacing: 2px;
}

.referral-code-box button {
  border: none;
  background: #252d42;
  color: #ffffff;
  width: 36px;
  height: 36px;
  border-radius: 11px;
  cursor: pointer;
}

.referral-card-box p {
  color: #8992a5;
  font-size: 13px;
  line-height: 1.6;
}

.referral-card-box p strong {
  color: #ffffff;
}

.referral-stat {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
  padding-top: 15px;
  border-top: 1px solid #222c3e;
  font-size: 13px;
}

.referral-stat span {
  color: #8992a5;
}


/* =====================================================
   WITHDRAWAL
===================================================== */

.withdraw-balance {
  text-align: center;
}

.withdraw-balance span {
  color: #8992a5;
  font-size: 13px;
}

.withdraw-balance strong {
  display: block;
  font-size: 34px;
  margin: 10px 0;
}

.withdraw-balance small {
  color: #778196;
  font-size: 11px;
}

.withdraw-section > p {
  color: #8992a5;
  font-size: 13px;
  line-height: 1.6;
  margin-bottom: 18px;
}


/* =====================================================
   LEGAL PAGES
===================================================== */

.legal-page {
  background: #121824;
  border: 1px solid #222c3e;
  border-radius: 23px;
  padding: 23px;
}

.legal-page h1 {
  font-size: 22px;
  margin-bottom: 20px;
}

.legal-page p {
  color: #9aa3b3;
  line-height: 1.7;
  font-size: 14px;
  margin-bottom: 16px;
}


/* =====================================================
   HELP
===================================================== */

.help-card {
  text-align: center;
}

.help-card > i {
  font-size: 35px;
  color: #927cff;
  margin-bottom: 15px;
}

.help-card h2 {
  font-size: 18px;
  margin-bottom: 8px;
}

.help-card a {
  display: block;
  color: #927cff;
  font-size: 13px;
  margin-bottom: 20px;
  text-decoration: none;
}


/* =====================================================
   ABOUT
===================================================== */

#page-about {
  text-align: center;
}

.about-logo {
  width: 75px;
  height: 75px;
  border-radius: 24px;
  background: #191f31;
  color: #927cff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin: 0 auto 18px;
}

#page-about h1 {
  font-size: 25px;
  margin-bottom: 10px;
}

#page-about p {
  color: #8992a5;
  line-height: 1.6;
  font-size: 14px;
}

#page-about small {
  display: block;
  color: #626d80;
  margin-top: 20px;
}


/* =====================================================
   BOTTOM NAVIGATION
===================================================== */

.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 76px;
  background: #101621;
  border-top: 1px solid #202838;
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 50;
}

.nav-item {
  position: relative;
  flex: 1;
  height: 100%;
  border: none;
  background: transparent;
  color: #667287;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: 10px;
}

.nav-item i {
  font-size: 18px;
}

.nav-item.active {
  color: #927cff;
}

.badge {
  position: absolute;
  top: 12px;
  right: 23%;
  min-width: 17px;
  height: 17px;
  border-radius: 50%;
  background: #ff5555;
  color: #ffffff;
  font-size: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
}


/* =====================================================
   TOAST
===================================================== */

.toast {
  position: fixed;
  left: 50%;
  bottom: 92px;
  transform: translateX(-50%);
  z-index: 100;
  background: #252d40;
  color: #ffffff;
  padding: 13px 18px;
  border-radius: 14px;
  font-size: 13px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}


/* =====================================================
   DESKTOP
===================================================== */

@media (min-width: 700px) {

  .app-content {
    padding: 35px 25px;
  }

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

  .earning-card {
    min-height: 175px;
  }

  .auth-screen {
    display: flex;
    align-items: center;
  }

}


/* =====================================================
   SMALL PHONES
===================================================== */

@media (max-width: 360px) {

  .earning-grid {
    gap: 9px;
  }

  .earning-card {
    min-height: 150px;
    padding: 14px;
    border-radius: 20px;
  }

  .earning-card h3 {
    font-size: 12px;
  }

  .earning-icon {
    width: 40px;
    height: 40px;
  }

}/* =====================================================
   COLORFUL EARNING CARDS
===================================================== */

/* CPX RESEARCH */
.earning-card:nth-child(1) {
  --card-color: #3b82f6;
  --card-light: rgba(59, 130, 246, 0.16);
}

/* OGADS */
.earning-card:nth-child(2) {
  --card-color: #f97316;
  --card-light: rgba(249, 115, 22, 0.16);
}

/* OFFERWALL.ME */
.earning-card:nth-child(3) {
  --card-color: #a855f7;
  --card-light: rgba(168, 85, 247, 0.16);
}

/* KIW I WALL */
.earning-card:nth-child(4) {
  --card-color: #22c55e;
  --card-light: rgba(34, 197, 94, 0.16);
}

/* ADGEM */
.earning-card:nth-child(5) {
  --card-color: #eab308;
  --card-light: rgba(234, 179, 8, 0.16);
}

/* FLEXWALL */
.earning-card:nth-child(6) {
  --card-color: #ec4899;
  --card-light: rgba(236, 72, 153, 0.16);
}

/* TASKS */
.earning-card:nth-child(7) {
  --card-color: #06b6d4;
  --card-light: rgba(6, 182, 212, 0.16);
}

/* SURVEYS */
.earning-card:nth-child(8) {
  --card-color: #8b5cf6;
  --card-light: rgba(139, 92, 246, 0.16);
}

/* WATCH & EARN */
.earning-card:nth-child(9) {
  --card-color: #ef4444;
  --card-light: rgba(239, 68, 68, 0.16);
}

/* REFER & EARN */
.earning-card:nth-child(10) {
  --card-color: #14b8a6;
  --card-light: rgba(20, 184, 166, 0.16);
}


/* CARD ICON COLORS */
.earning-card .earning-icon {
  color: var(--card-color);
  background: var(--card-light);
}


/* CARD HOVER EFFECT */
.earning-card:hover {
  border-color: var(--card-color);
  box-shadow: 0 8px 25px var(--card-light);
  transform: translateY(-4px);
}


/* CARD ARROW */
.earning-card .card-arrow {
  color: var(--card-color);
}


/* CARD TITLE */
.earning-card h3 {
  transition: color 0.2s ease;
}

.earning-card:hover h3 {
  color: var(--card-color);
}