* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', Arial, sans-serif;
}

:root {
  --blue: #16169b;
  --blue-dark: #0e0e6e;
  --green: #7fc41e;
  --green-dark: #5fa314;
  --white: #ffffff;
}

body {
  background: #1a1a1a;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

/* ---------- Phone frame wrapper ---------- */
.phone {
  width: 100%;
  max-width: 400px;
  min-height: 720px;
  background: var(--green);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
  position: relative;
  display: flex;
  flex-direction: column;
}

/* ---------- Top blue bar ---------- */
.topbar {
  background: var(--blue);
  color: var(--white);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 20px;
  font-weight: 600;
}

/* ---------- LOGIN PAGE ---------- */
.login-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px 30px;
  gap: 18px;
}

.login-logo {
  font-size: 26px;
  font-weight: 700;
  color: var(--blue);
  background: var(--white);
  padding: 14px 28px;
  border-radius: 14px;
  margin-bottom: 10px;
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

.login-card {
  width: 100%;
  background: var(--blue);
  border-radius: 18px;
  padding: 28px 24px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}

.login-card h2 {
  color: var(--white);
  text-align: center;
  font-size: 19px;
  margin-bottom: 20px;
  font-weight: 600;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  color: #d7ffb0;
  font-size: 13px;
  margin-bottom: 6px;
  font-weight: 600;
}

.field input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: none;
  outline: none;
  font-size: 15px;
  background: var(--white);
  color: #222;
}

.btn {
  display: block;
  width: 100%;
  text-align: center;
  padding: 13px;
  border-radius: 10px;
  border: none;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  color: var(--white);
}

.btn-green {
  background: var(--green);
  margin-top: 6px;
}
.btn-green:hover { background: var(--green-dark); }

.error-msg {
  background: #ffe1e1;
  color: #a30000;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  text-align: center;
  margin-bottom: 14px;
}

.hint {
  color: rgba(255,255,255,0.6);
  font-size: 12px;
  text-align: center;
  margin-top: 14px;
}

/* ---------- DASHBOARD ---------- */
.dashboard-body {
  flex: 1;
  background: var(--green);
  padding: 22px 18px 18px;
  position: relative;
}

.flag {
  width: 40px;
  height: 26px;
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  position: absolute;
  left: 18px;
  top: 22px;
}
.flag span { flex: 1; }
.flag .r { background: #d90012; }
.flag .b { background: #0033a0; }
.flag .o { background: #f2a800; }

.menu-icon {
  position: absolute;
  right: 18px;
  top: 22px;
  color: var(--white);
  font-size: 26px;
  cursor: pointer;
  line-height: 1;
}

.action-btn {
  display: block;
  width: 100%;
  background: var(--blue);
  color: var(--white);
  text-align: center;
  padding: 18px;
  border-radius: 10px;
  font-size: 20px;
  font-weight: 700;
  margin-top: 60px;
  border: none;
  text-decoration: none;
  cursor: pointer;
}
.action-btn.second { margin-top: 14px; }

.arrow-bg {
  margin-top: 60px;
  display: flex;
  justify-content: center;
}
.arrow-bg svg { opacity: 0.9; }

/* ---------- Info Card (popup) ---------- */
.info-overlay {
  position: absolute;
  top: 130px;
  left: 12px;
  right: 12px;
  background: var(--blue);
  border: 2px solid #9fe04a;
  border-radius: 16px;
  padding: 20px 22px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.4);
  z-index: 10;
}

.info-overlay h3 {
  color: var(--white);
  text-align: center;
  font-size: 19px;
  font-weight: 700;
  margin-bottom: 16px;
}

.info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--white);
  font-size: 17px;
  font-weight: 600;
  padding: 6px 0;
}

.info-row .val {
  font-weight: 700;
}

.amount-row {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}

.unit-box {
  border: 2px solid #cfd6ff;
  border-radius: 10px;
  padding: 12px 16px;
  color: var(--white);
  font-weight: 700;
  font-size: 15px;
  min-width: 70px;
  text-align: center;
}

.save-btn {
  flex: 1;
  background: #d9d9d9;
  color: #8a8a8a;
  border: none;
  border-radius: 10px;
  font-weight: 700;
  font-size: 16px;
  cursor: not-allowed;
}

.overlay-actions {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.overlay-actions .btn-green {
  margin-top: 0;
  font-size: 17px;
  padding: 14px;
}

.version-tag {
  text-align: center;
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  margin-top: 16px;
}

.logout-link {
  color: var(--white);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
}
