@font-face {
  font-family: 'Roboto';
  src: url('assets/fonts/Roboto-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Roboto';
  src: url('assets/fonts/Roboto-Medium.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Roboto';
  src: url('assets/fonts/Roboto-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

* { box-sizing: border-box; }

html { overscroll-behavior-y: none; touch-action: manipulation; }

body {
  margin: 0;
  background: #000;
  color: #fff;
  font-family: 'Roboto', sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

body.no-scroll { overflow: hidden; }

.page {
  max-width: 420px;
  margin: 0 auto;
  min-height: 100vh;
  padding: 24px 20px 48px;
}

.hidden { display: none !important; }
.view { width: 100%; }

/* Glass: vertical gradient white 20% -> white 7%, 1px white 35% border, 12px radius */
.glass-panel,
.glass-input,
.glass-btn,
.home-card,
.amount-btn,
.notif-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.20) 0%, rgba(255,255,255,0.07) 100%);
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 12px;
  color: #fff;
}

.glass-panel { padding: 20px; margin-top: 16px; }

/* Login (vertically centered in the viewport, like the app login) */
.login-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
}
.logo-large { width: 280px; max-width: 80%; height: auto; margin-bottom: 56px; }
.logo-small { width: 140px; height: auto; display: block; margin: 8px auto 24px; }

#login-form { width: 100%; display: flex; flex-direction: column; gap: 16px; }

/* Unlock code (after 5 wrong passwords): same glass/login treatment. */
#login-unlock { width: 100%; display: flex; flex-direction: column; gap: 16px; }
.unlock-email { font-size: 16px; text-align: center; margin: 0; }
.unlock-title { font-size: 16px; text-align: center; margin: 0; }
.unlock-row { display: flex; align-items: center; gap: 8px; }
.unlock-row .glass-input { flex: 1; min-width: 0; }
.unlock-countdown { flex: 0 0 32px; text-align: center; font-size: 16px; }
#login-unlock .link-btn { margin-top: 0; align-self: center; }

.glass-input {
  width: 100%;
  height: 40px;
  padding: 0 16px;
  font-family: 'Roboto', sans-serif;
  font-size: 16px;
  outline: none;
}
.glass-input::placeholder { color: rgba(255,255,255,0.35); }
.glass-input:focus { border-color: rgba(255,255,255,0.7); }
select.glass-input { appearance: none; }
select.glass-input option { background: #111; color: #fff; }
textarea.glass-input { height: auto; }

.glass-btn {
  width: 100%;
  height: 40px;
  font-family: 'Roboto', sans-serif;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  padding: 0 16px;
}
.glass-btn:active { transform: scale(0.97); }
.glass-btn.dimmed,
.glass-btn:disabled { opacity: 0.4; cursor: not-allowed; }

.link-btn {
  background: none;
  border: none;
  color: #fff;
  font-family: 'Roboto', sans-serif;
  font-size: 15px;
  text-decoration: underline;
  cursor: pointer;
  margin-top: 20px;
  padding: 8px;
}
.note { color: rgba(255,255,255,0.70); font-size: 14px; line-height: 1.5; text-align: center; }
.error { color: #f87171; font-size: 14px; line-height: 1.5; text-align: center; }
.empty-state { color: rgba(255,255,255,0.50); font-size: 15px; text-align: center; margin-top: 48px; }

/* Home */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 0 8px;
}
.user-chip { display: flex; align-items: center; gap: 12px; min-width: 0; }
.avatar {
  width: 44px; height: 44px; flex: 0 0 44px;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 700; color: #fff;
  overflow: hidden;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.user-meta { display: flex; flex-direction: column; min-width: 0; }
.user-name { font-size: 17px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-id { font-size: 13px; color: rgba(255,255,255,0.50); }

.icon-btn {
  position: relative;
  background: none; border: none; color: #fff; cursor: pointer; padding: 8px;
}
.badge {
  position: absolute; top: 0; right: 0;
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9px; background: #fff; color: #000;
  font-size: 11px; font-weight: 700; line-height: 18px; text-align: center;
}

.home-cards { display: flex; flex-direction: column; gap: 16px; margin-top: 8px; }
.home-card {
  width: 100%; padding: 24px 20px; text-align: left; cursor: pointer;
  display: flex; flex-direction: column; gap: 6px;
  font-family: 'Roboto', sans-serif;
}
.home-card:active { transform: scale(0.98); }
.home-card-title { font-size: 20px; font-weight: 500; }
.home-card-sub { font-size: 14px; color: rgba(255,255,255,0.70); }
#logout-btn { display: block; margin: 32px auto 0; }

/* Sub pages */
.subbar { display: flex; align-items: center; justify-content: space-between; padding: 4px 0 8px; }
.back-btn {
  background: none; border: none; color: #fff;
  font-family: 'Roboto', sans-serif; font-size: 16px; cursor: pointer; padding: 8px 8px 8px 0;
}
.subbar-title { font-size: 18px; font-weight: 500; }
.subbar-spacer { width: 52px; }
.refresh-btn {
  background: none; border: 1px solid rgba(255,255,255,0.35); border-radius: 12px;
  color: #fff; font-family: 'Roboto', sans-serif; font-size: 14px;
  cursor: pointer; padding: 8px 12px;
}

.balance-panel { display: flex; align-items: baseline; justify-content: space-between; }
.balance-label { font-size: 15px; color: rgba(255,255,255,0.70); }
.balance-value { font-size: 26px; font-weight: 700; }

.amount-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px;
}
.amount-btn {
  padding: 20px 12px; cursor: pointer; text-align: center;
  font-family: 'Roboto', sans-serif;
  display: flex; flex-direction: column; gap: 8px;
}
.amount-btn:active { transform: scale(0.97); }
.amount-btn.selected { border-color: #fff; background: linear-gradient(180deg, rgba(255,255,255,0.32) 0%, rgba(255,255,255,0.14) 100%); }
.amount-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.amount-btn .amount-main { font-size: 20px; font-weight: 500; }
.amount-btn .amount-sub { font-size: 15px; color: rgba(255,255,255,0.70); }

.summary-line { font-size: 16px; font-weight: 500; margin: 0 0 16px; }
.method-details { margin: 16px 0 0; }
.method-details p { display: flex; justify-content: space-between; gap: 12px; font-size: 16px; margin: 0 0 8px; }
.method-details p:last-child { margin-bottom: 0; }
.method-details-label { color: rgba(255,255,255,0.70); }
.buy-qr-img { display: block; max-width: 240px; width: 100%; margin: 16px auto 0; border-radius: 12px; }
.field-label { display: block; font-size: 14px; color: rgba(255,255,255,0.70); margin: 16px 0 8px; }
.field-label:first-child { margin-top: 0; }
#buy-payment .glass-btn, #withdraw-form .glass-btn { margin-top: 20px; }
.status-title { font-size: 17px; font-weight: 500; margin: 0 0 8px; }
#buy-waiting .glass-btn { margin-top: 16px; }

/* Upload */
.upload-box { margin-top: 8px; }
.file-input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.upload-label {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; cursor: pointer;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px;
  font-size: 15px; color: rgba(255,255,255,0.70);
}
.preview-wrap { position: relative; margin-top: 12px; }
.preview-img { width: 100%; height: auto; display: block; border-radius: 12px; border: 1px solid rgba(255,255,255,0.35); }
.remove-btn {
  position: absolute; top: 8px; right: 8px;
  width: 28px; height: 28px; border-radius: 50%;
  background: #000; border: 1px solid rgba(255,255,255,0.6); color: #fff;
  font-size: 14px; cursor: pointer;
}

/* Notifications */
.notif-list { display: flex; flex-direction: column; gap: 16px; margin-top: 16px; }
.notif-card { padding: 16px; }
/* Single-session approval actions: two glass buttons side by side. */
.notif-actions { display: flex; gap: 12px; margin-top: 16px; }
.notif-actions .glass-btn { flex: 1; }
.notif-head { display: flex; align-items: center; gap: 12px; }
.notif-head .avatar { width: 40px; height: 40px; flex-basis: 40px; font-size: 16px; }
.notif-who { flex: 1; min-width: 0; }
.notif-name { font-size: 16px; font-weight: 500; display: block; }
.notif-id { font-size: 12px; color: rgba(255,255,255,0.50); display: block; }
.notif-time { font-size: 13px; color: rgba(255,255,255,0.70); white-space: nowrap; }
.notif-body { margin-top: 12px; font-size: 15px; line-height: 1.55; }
.notif-body .row { display: flex; justify-content: space-between; gap: 12px; padding: 2px 0; }
.notif-body .row span:first-child { color: rgba(255,255,255,0.70); }
.status-pending { color: #fff; font-weight: 500; }
.status-finished { color: #4ade80; font-weight: 500; }
.status-decline { color: #f87171; font-weight: 500; }
.admin-message {
  margin-top: 12px; padding: 12px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px;
  font-size: 14px; line-height: 1.5;
}
.admin-message .admin-label { display: block; font-size: 12px; color: rgba(255,255,255,0.50); margin-bottom: 4px; }
.receipt-img { width: 100%; height: auto; display: block; margin-top: 12px; border-radius: 12px; border: 1px solid rgba(255,255,255,0.35); }
.receipt-label { display: block; font-size: 12px; color: rgba(255,255,255,0.50); margin-top: 12px; }

/* Updating mode: full-screen overlay shown while a deploy runs. Hidden by
   default via .hidden; the logo is the transparent logo (no black box). */
.updating-overlay {
  position: fixed; inset: 0; z-index: 9999;
  background: #000;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 24px;
}
.updating-logo { width: 300px; max-width: 80%; height: auto; }
.updating-text { font-size: 16px; color: rgba(255,255,255,0.70); margin: 0; text-align: center; }

/* ============ USER MANUAL ============ */
.manual-btn { margin-bottom: 16px; }
.manual-topics { display: flex; flex-direction: column; gap: 16px; margin-top: 16px; }
.topic-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%; padding: 20px; text-align: left; cursor: pointer;
  font-family: 'Roboto', sans-serif; font-size: 17px; font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.20) 0%, rgba(255,255,255,0.07) 100%);
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px; color: #fff;
}
.topic-row:active { transform: scale(0.98); }
.topic-row .topic-chev { color: rgba(255,255,255,0.50); font-size: 20px; }

.manual-topic-body {
  font-size: 15px; line-height: 1.55; color: rgba(255,255,255,0.85);
  margin: 16px 0 0; text-align: left;
}

/* Carousel: one slide at a time, swipe left/right (scroll-snap). */
.manual-carousel {
  margin-top: 16px; overflow-x: auto; overflow-y: hidden;
  scroll-snap-type: x mandatory; scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.manual-carousel::-webkit-scrollbar { display: none; }
.manual-track { display: flex; }
.manual-slide { flex: 0 0 100%; scroll-snap-align: start; padding: 12px 2px 0; }
.manual-step { font-size: 15px; line-height: 1.5; margin: 16px 0 0; }
.manual-step .step-num { font-weight: 700; }

.manual-nav { display: flex; align-items: center; justify-content: center; gap: 28px; margin-top: 20px; }
.slide-arrow {
  width: 36px; height: 36px; border-radius: 50%;
  background: #000; border: 1px solid rgba(255,255,255,0.35);
  color: #fff; font-size: 20px; line-height: 1; cursor: pointer; padding: 0 0 2px;
}
.slide-arrow:disabled { opacity: 0.35; cursor: default; }
.slide-dots { display: flex; gap: 8px; align-items: center; }
.slide-dot {
  width: 8px; height: 8px; border-radius: 50%; padding: 0;
  background: transparent; border: 1px solid rgba(255,255,255,0.6); cursor: pointer;
}
.slide-dot.active { background: #fff; }
.manual-counter { text-align: center; color: rgba(255,255,255,0.50); font-size: 13px; margin: 12px 0 0; }

/* Example pictures: dark mockup screens, glass borders, red EXAMPLE
   badge straddling the top edge, pointer arrow on the tap target. */
.shot {
  position: relative; min-height: 150px;
  background: #111; border: 1px solid rgba(255,255,255,0.35); border-radius: 12px;
  padding: 16px;
  display: flex; flex-direction: column; justify-content: center; gap: 12px;
}
.example-badge {
  position: absolute; top: -10px; left: 50%; transform: translateX(-50%);
  background: #FF3B30; color: #fff; font-size: 11px; font-weight: 700;
  padding: 3px 12px; border-radius: 10px; white-space: nowrap;
}
.click-pointer { position: absolute; width: 28px; height: 28px; pointer-events: none; }
.shot-row {
  display: flex; align-items: center; justify-content: space-between;
  height: 40px; padding: 0 16px; font-size: 15px;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px; color: #fff;
}
.shot-row .shot-chev { color: rgba(255,255,255,0.50); font-size: 18px; }
.shot-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.shot-amount {
  padding: 14px 8px; text-align: center; font-size: 15px; font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px; color: #fff;
  display: flex; flex-direction: column; gap: 4px;
}
.shot-amount.selected { border-color: #fff; }
.shot-amount.dimmed { opacity: 0.35; }
.shot-amount .amount-sub { font-size: 12px; font-weight: 400; color: rgba(255,255,255,0.70); }
.shot-field {
  display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px;
  font-size: 14px; color: rgba(255,255,255,0.50);
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px;
}
.shot-field .shot-value { color: #fff; font-size: 15px; }
.shot-card {
  padding: 14px 16px; font-size: 14px; line-height: 1.5;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px; color: #fff;
}
.shot-card .shot-name { font-size: 15px; font-weight: 500; display: block; }
.shot-card .shot-id { font-size: 12px; color: rgba(255,255,255,0.70); display: block; }
.shot-dialog {
  background: #1A1A1A; border-radius: 12px; padding: 20px; text-align: center;
  display: flex; flex-direction: column; gap: 8px;
}
.shot-dialog .dialog-title { font-size: 15px; font-weight: 500; }
.shot-dialog .dialog-sub { font-size: 13px; color: rgba(255,255,255,0.70); }
.shot-dialog .dialog-confirm { font-size: 15px; font-weight: 500; margin-top: 8px; }
.shot-btn {
  height: 40px; display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px; color: #fff;
}
.shot-lock-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.shot-slider {
  position: relative; height: 6px; border-radius: 3px; margin: 14px 6px 6px;
  background: rgba(255,255,255,0.35);
}
.shot-slider .slider-thumb {
  position: absolute; left: 60%; top: 50%; transform: translate(-50%, -50%);
  width: 20px; height: 20px; border-radius: 50%;
  background: #fff; border: 1px solid rgba(0,0,0,0.4);
}
.shot-locked { position: relative; overflow: hidden; border-radius: 12px; min-height: 96px;
  background: linear-gradient(135deg, #3a3a3a, #1a1a1a); }
.shot-locked .locked-blur { position: absolute; inset: 0; filter: blur(8px);
  background: linear-gradient(135deg, #5a7a5a, #2a4a3a); opacity: 0.7; }
.shot-locked .locked-icon {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
}
.shot-thumb { width: 48px; height: 48px; flex: 0 0 48px; border-radius: 8px;
  background: linear-gradient(135deg, #5a7a5a, #2a4a3a); }
.shot-notif { display: flex; align-items: center; gap: 12px; }
.shot-notif .notif-text { flex: 1; min-width: 0; }
.shot-notif .notif-title { font-size: 14px; font-weight: 500; display: block; }
.shot-notif .notif-sub { font-size: 12px; color: rgba(255,255,255,0.70); display: block; line-height: 1.4; }
.shot-status { font-size: 13px; font-weight: 700; color: #4ade80; white-space: nowrap; }
.shot-rule { text-align: center; font-size: 13px; color: rgba(255,255,255,0.70); }
.shot-reward-row { display: flex; align-items: center; gap: 12px; }
.shot-reward-row .reward-text { flex: 1; min-width: 0; }
.shot-reward-row .reward-main { font-size: 14px; font-weight: 500; display: block; }
.shot-reward-row .reward-sub { font-size: 13px; color: rgba(255,255,255,0.70); display: block; }
.shot-claim {
  flex: 0 0 auto; padding: 10px 16px; font-size: 13px; font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px; color: #fff;
}
.shot-claimed { flex: 0 0 auto; font-size: 14px; color: rgba(255,255,255,0.50); }
.shot-wait { text-align: center; }
.shot-wait .wait-title { font-size: 15px; font-weight: 500; display: block; }
.shot-wait .wait-sub { font-size: 12px; color: rgba(255,255,255,0.70); display: block; margin-top: 6px; line-height: 1.4; }

/* Delete / lock shots: mini post card + swipe strip + dialog buttons. */
.shot-swipe { position: relative; height: 150px; }
.shot-minicard {
  position: absolute; left: 0; top: 0; bottom: 0; right: 48px;
  background: #111; border: 1px solid rgba(255,255,255,0.35); border-radius: 12px;
}
.shot-minicard.full { right: 0; }
.mini-status { position: absolute; left: 16px; top: 14px; font-size: 14px; color: #fff; }
.mini-lock { position: absolute; right: 12px; top: 12px; display: flex; align-items: center; gap: 4px; font-size: 14px; color: #fff; }
.mini-person {
  position: absolute; left: 50%; top: 50%; width: 36px; height: 36px;
  transform: translate(-50%,-50%);
  border: 2px solid rgba(255,255,255,0.5); border-radius: 50%;
}
.mini-person::after {
  content: ''; position: absolute; left: 50%; top: 38px; width: 56px; height: 28px;
  transform: translateX(-50%);
  border: 2px solid rgba(255,255,255,0.5); border-bottom: none; border-radius: 28px 28px 0 0;
}
.mini-view { position: absolute; right: 12px; bottom: 12px; font-size: 12px; color: rgba(255,255,255,0.70); }
.swipe-arrow { position: absolute; right: 64px; top: 50%; transform: translateY(-50%); font-size: 28px; color: #fff; }
.delete-strip {
  position: absolute; right: 0; top: 0; bottom: 0; width: 48px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px;
}
.delete-strip span {
  writing-mode: vertical-rl; transform: rotate(180deg);
  color: #FF3B30; font-size: 16px; font-weight: 500;
}
.dialog-btns { display: flex; gap: 12px; margin-top: 8px; }
.dialog-btn {
  flex: 1; height: 40px; display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.20), rgba(255,255,255,0.07));
  border: 1px solid rgba(255,255,255,0.35); border-radius: 12px; color: #fff;
}
.dialog-btn.delete { color: #FF3B30; }
