:root {
  --bg: #0f0f10;
  --card: #141414;
  --muted: #9aa0a6;
  --accent: #b8ff7a;
  --pill: #9fff75;
  --glass: rgba(255, 255, 255, 0.06);
  --rounded: 20px;
  --gap: 18px;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  margin: 0;
  background: var(--bg);
  color: #fff;
}

.app {
  max-width: 420px;
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 18px 18px 88px; /* leave space for bottom nav */
  gap: var(--gap);
}

/* top bar */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.profile {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(180deg, #202020, #0f0f0f);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #b7ff98;
  position: relative;
  border: 2px solid rgba(255, 255, 255, 0.03);
}

.profile .dot {
  position: absolute;
  right: 0;
  top: 6px;
  width: 10px;
  height: 10px;
  background: #ff9aa2;
  border-radius: 50%;
  border: 2px solid var(--bg);
}

.pill {
  background: linear-gradient(90deg, #b8ff7a 60%, #9fff75 100%);
  color: #071b00;
  padding: 10px 22px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 17px;
  box-shadow: 0 2px 16px #b8ff7a33, 0 1.5px 0 #23232322;
  letter-spacing: 0.2px;
  border: none;
  outline: none;
  display: inline-block;
  position: relative;
  transition: box-shadow 0.18s, background 0.18s, color 0.18s, transform 0.18s;
  backdrop-filter: blur(2px);
  margin-right: 2px;
}

.pill:hover, .pill:focus {
  background: linear-gradient(90deg, #d0ffb8 60%, #b8ff7a 100%);
  color: #071b00;
  box-shadow: 0 4px 24px #b8ff7a55, 0 2px 0 #23232322;
  transform: scale(1.04) translateY(-2px);
}

h1 {
  font-size: 34px;
  margin: 0;
  line-height: 1;
  letter-spacing: -0.6px;
}

.subaction {
  margin-top: 6px;
}

.send-btn {
  background: linear-gradient(180deg, #9fff75, #6dd400);
  color: #081700;
  padding: 10px 14px;
  border-radius: 12px;
  display: inline-block;
  font-weight: 700;
}

/* invite card */
.section-title {
  font-size: 20px;
  margin: 0 0 6px 0;
  color: #fff;
}

.card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(120deg, #ffb86c 0%, #ff7e5f 100%);
  color: #181818;
  border-radius: 22px;
  box-shadow: 0 4px 24px #ffb86c33, 0 1.5px 0 #23232322;
  padding: 28px 24px 22px 24px;
  position: relative;
  overflow: hidden;
  min-height: 120px;
  margin-bottom: 18px;
  transition: box-shadow 0.18s, transform 0.18s;
}

.card .close {
  position: absolute;
  top: 14px;
  right: 18px;
  background: rgba(255,255,255,0.22);
  color: #ff7e5f;
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 1.2rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 2px 8px #ffb86c22;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.18s, color 0.18s, transform 0.18s;
}

.card .close:hover, .card .close:focus {
  background: #fff;
  color: #ff7e5f;
  transform: scale(1.08);
}

.card .text {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.2;
  color: #181818;
  text-shadow: 0 2px 8px #fff3;
}

.card .sub {
  background: rgba(255,255,255,0.18);
  color: #181818;
  font-weight: 700;
  border: none;
  border-radius: 12px;
  padding: 9px 22px;
  font-size: 1rem;
  margin-top: 8px;
  cursor: pointer;
  box-shadow: 0 2px 8px #ffb86c33;
  transition: background 0.18s, color 0.18s, transform 0.18s;
}

.card .sub:hover, .card .sub:focus {
  background: #fff;
  color: #ff7e5f;
  transform: translateY(-2px) scale(1.04);
}

/* fake image area (two people) */
.people {
  width: 72px;
  height: 72px;
  background: linear-gradient(135deg, #fff8e1 60%, #ffb86c 100%);
  border-radius: 50%;
  margin-left: 24px;
  box-shadow: 0 2px 12px #ffb86c44;
  position: relative;
}

/* transfer calculator placeholder */
.transfer {
  margin-top: 6px;
  padding: 14px;
  background: var(--card);
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.02);
}

/* bottom nav */
.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 18px;
  background: var(--glass);
  backdrop-filter: blur(20px);
  box-shadow: 0 8px 32px #0007, 0 1.5px 0 #232323;
  border-top-left-radius: 22px;
  border-top-right-radius: 22px;
  padding: 0 0 10px 0;
  z-index: 100;
  height: 72px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  max-width: 420px;
  margin: 0 auto;
  transition: box-shadow 0.2s;
}

.nav-inner {
  display: flex;
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  justify-content: space-between;
  align-items: center;
  gap: 0;
}

.nav-item {
  flex: 1 1 0;
  background: none;
  border: none;
  outline: none;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 0 6px 0;
  border-radius: 16px;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s, transform 0.18s;
  cursor: pointer;
  gap: 2px;
  position: relative;
}

.nav-item .icon {
  font-size: 24px;
  margin-bottom: 2px;
  transition: color 0.18s, transform 0.18s;
}

.nav-item.active, .nav-item:focus {
  background: rgba(184,255,122,0.08);
  color: var(--accent);
  box-shadow: 0 2px 12px #b8ff7a33;
  transform: translateY(-4px) scale(1.07);
}

.nav-item.active .icon, .nav-item:focus .icon {
  color: var(--accent);
  transform: scale(1.18);
}

.nav-item:active {
  background: #232323;
}

@media (max-width: 420px) {
  .app {
    padding-left: 14px;
    padding-right: 14px;
  }
  .bottom-nav {
    max-width: 100vw;
    left: 0;
    right: 0;
    border-radius: 0;
    margin: 0;
  }
  .nav-inner {
    max-width: 100vw;
  }
}

/* small helpers */
.muted {
  color: var(--muted);
  font-size: 14px;
}

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

/* subtle rounded shadow for elements */
.rounded-card {
  background: var(--card);
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.02);
}

#profileModal input:focus {
  outline: 2px solid var(--pill);
  background: #232323;
}

#profilePhotoBtn:hover {
  background: #b8ff7a;
  box-shadow: 0 4px 12px #0005;
}

#quizSection {
  box-shadow: 0 8px 32px #0005, 0 0 0 1.5px #b8ff7a22;
  border-radius: 24px;
  background: var(--glass);
  backdrop-filter: blur(12px);
}

#quizQuestion {
  color: #fff;
  letter-spacing: -0.2px;
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 18px;
}

#quizOptions button.send-btn {
  background: linear-gradient(180deg, #232323 60%, #1a1a1a 100%);
  color: #b8ff98;
  border: 1.5px solid var(--glass);
  border-radius: 14px;
  font-size: 17px;
  font-weight: 700;
  padding: 15px 0;
  transition: background 0.18s, color 0.18s, border 0.18s, box-shadow 0.18s;
  box-shadow: 0 2px 12px #b8ff7a11;
  cursor: pointer;
  margin-bottom: 0;
}

#quizOptions button.send-btn:active {
  background: #1a1a1a;
  color: #b8ff98;
  box-shadow: 0 1px 4px #b8ff7a22;
}

#quizOptions button.send-btn:disabled {
  background: #232323;
  color: #888;
  border: 1.5px solid #232323;
  cursor: not-allowed;
  opacity: 0.7;
}

#quizFeedback {
  min-height: 28px;
  color: var(--accent);
  text-align: center;
  letter-spacing: -0.1px;
  transition: color 0.2s, opacity 0.2s;
  font-size: 17px;
  font-weight: 700;
  margin-top: 18px;
}