:root {
  --primary: #3f3496;
  --primary-2: #5a4bd1;
  --primary-light: #eeebfb;
  --accent: #f7a823;
  --text: #1d1b2f;
  --muted: #6b6a7d;
  --line: #e7e5f0;
  --bg: #f5f4fa;
  --danger: #d93939;
  --green: #1a9e5c;
  --radius: 14px;
  --nav-h: 64px;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; }
body {
  font-family: 'Poppins', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color: var(--text);
  background: #dcd9ea;
  font-size: 14px;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
a { color: var(--primary); text-decoration: none; }
svg { display: block; }

#app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  box-shadow: 0 0 40px rgba(40, 30, 110, .15);
}

/* ---------- top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 12px;
  height: 58px; padding: 0 14px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.topbar .title { font-weight: 600; font-size: 17px; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icon-btn { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: var(--text); flex: none; }
.icon-btn:active { background: var(--primary-light); }
.brand { display: flex; align-items: center; gap: 8px; flex: 1; }
.brand img { width: 30px; height: 30px; }
.brand-name { font-weight: 700; font-size: 19px; color: var(--primary); letter-spacing: -.2px; }
.brand-name span { color: var(--accent); }
.avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-2), var(--primary));
  color: #fff; font-weight: 600; display: grid; place-items: center; font-size: 14px; flex: none;
}

.page { padding-bottom: calc(var(--nav-h) + 24px); }

/* ---------- home hero ---------- */
.hero {
  background: linear-gradient(160deg, var(--primary-2) 0%, var(--primary) 70%);
  color: #fff;
  padding: 18px 16px 54px;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: ''; position: absolute; right: -40px; top: -40px;
  width: 170px; height: 170px; border-radius: 50%;
  background: rgba(255,255,255,.07);
}
.hero::before {
  content: ''; position: absolute; right: 40px; bottom: -70px;
  width: 140px; height: 140px; border-radius: 50%;
  background: rgba(255,255,255,.05);
}
.hero .hello { font-size: 13px; opacity: .85; }
.hero .name { font-size: 20px; font-weight: 600; margin-top: 2px; }
.hero .stats { display: flex; gap: 10px; margin-top: 14px; position: relative; z-index: 1; }
.hero .stat { background: rgba(255,255,255,.14); border-radius: 10px; padding: 8px 12px; flex: 1; }
.hero .stat b { font-size: 18px; display: block; }
.hero .stat small { opacity: .85; font-size: 11px; }

.searchbar {
  margin: -30px 16px 0; position: relative; z-index: 2;
  display: flex; align-items: center; gap: 10px;
  background: #fff; border-radius: 12px; padding: 0 14px; height: 50px;
  box-shadow: 0 6px 18px rgba(40, 30, 110, .14);
  color: var(--muted);
}
.searchbar input { border: 0; outline: 0; flex: 1; background: none; font-size: 14px; min-width: 0; }
.searchbar.flat { margin: 14px 16px 0; box-shadow: none; border: 1px solid var(--line); }

/* ---------- sections ---------- */
.section { margin: 22px 0 0; }
.section-head { display: flex; align-items: center; justify-content: space-between; padding: 0 16px; margin-bottom: 10px; }
.section-head h3 { margin: 0; font-size: 15px; font-weight: 600; }
.section-head a { font-size: 13px; font-weight: 500; }

.hscroll { display: flex; gap: 12px; overflow-x: auto; padding: 2px 16px 6px; scrollbar-width: none; }
.hscroll::-webkit-scrollbar { display: none; }

.issued-card {
  color: var(--text);
  flex: none; width: 150px; background: #fff; border-radius: var(--radius);
  padding: 14px 12px; border: 1px solid var(--line); text-align: left;
  display: flex; flex-direction: column; gap: 10px;
}
.issued-card .doc-name { font-weight: 600; font-size: 13px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 34px; }
.issued-card .issuer { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.add-card { border: 1.5px dashed #c5bfeb; background: var(--primary-light); align-items: center; justify-content: center; text-align: center; color: var(--primary); font-weight: 600; font-size: 13px; }
.add-card .plus { width: 40px; height: 40px; border-radius: 50%; background: var(--primary); color: #fff; display: grid; place-items: center; }

.logo-tile {
  width: 42px; height: 42px; border-radius: 10px; flex: none;
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 14px;
  overflow: hidden;
}
.logo-tile img { width: 100%; height: 100%; object-fit: cover; }

.banner {
  margin: 22px 16px 0; border-radius: var(--radius); padding: 16px;
  background: linear-gradient(110deg, #fff4e0, #ffe3b3);
  display: flex; align-items: center; gap: 14px;
}
.banner h4 { margin: 0 0 4px; font-size: 14px; }
.banner p { margin: 0 0 10px; font-size: 12px; color: #6b5a3a; }
.banner .art { width: 74px; flex: none; }

.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px 6px; padding: 0 12px; }
.grid-item { display: flex; flex-direction: column; align-items: center; gap: 7px; text-align: center; font-size: 11px; line-height: 1.25; color: var(--text); }
.grid-item .circle {
  width: 56px; height: 56px; border-radius: 50%; background: #fff;
  border: 1px solid var(--line); display: grid; place-items: center;
}
.card-box { background: #fff; margin: 0 16px; border-radius: var(--radius); padding: 16px 4px; border: 1px solid var(--line); }

/* ---------- lists ---------- */
.list { background: #fff; margin: 0 16px; border-radius: var(--radius); border: 1px solid var(--line); overflow: hidden; }
.row { display: flex; align-items: center; gap: 12px; padding: 13px 14px; width: 100%; text-align: left; position: relative; }
.row + .row { border-top: 1px solid var(--line); }
.row:active { background: #faf9ff; }
.row .meta { flex: 1; min-width: 0; }
.row .meta b { display: block; font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .meta small { color: var(--muted); font-size: 12px; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .chev { color: #a9a6bd; }

.tabs { display: flex; background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 58px; z-index: 10; }
.tabs button { flex: 1; padding: 13px 0; font-weight: 500; color: var(--muted); border-bottom: 2.5px solid transparent; }
.tabs button.on { color: var(--primary); border-color: var(--primary); font-weight: 600; }

.empty { text-align: center; padding: 50px 30px 20px; color: var(--muted); }
.empty svg { margin: 0 auto 14px; }
.empty h4 { margin: 0 0 6px; color: var(--text); font-size: 16px; }
.empty p { margin: 0 0 18px; font-size: 13px; }

/* ---------- buttons / forms ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 22px; border-radius: 10px;
  background: var(--primary); color: #fff; font-weight: 600; font-size: 15px;
}
.btn:active { background: #332a7d; }
.btn:disabled { opacity: .55; }
.btn.block { width: 100%; }
.btn.small { height: 36px; padding: 0 14px; font-size: 13px; border-radius: 8px; }
.btn.outline { background: #fff; color: var(--primary); border: 1.5px solid var(--primary); }
.btn.ghost { background: var(--primary-light); color: var(--primary); }
.btn.danger { background: #fff; color: var(--danger); border: 1.5px solid #f1c6c6; }

.form { padding: 18px 16px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 500; margin-bottom: 6px; }
.field label i { color: var(--danger); font-style: normal; }
.input {
  width: 100%; height: 48px; border: 1px solid #d6d3e4; border-radius: 10px;
  padding: 0 14px; background: #fff; outline: 0; font-size: 15px;
}
.input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(63, 52, 150, .12); }
.input-group { display: flex; align-items: center; border: 1px solid #d6d3e4; border-radius: 10px; background: #fff; overflow: hidden; }
.input-group:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(63, 52, 150, .12); }
.input-group .prefix { padding: 0 4px 0 14px; color: var(--muted); font-size: 15px; }
.input-group .input { border: 0; box-shadow: none; }
.hint { font-size: 12px; color: var(--muted); margin-top: 5px; }
.error { background: #fdeeee; color: var(--danger); border-radius: 8px; padding: 10px 12px; font-size: 13px; margin-bottom: 14px; }

.pin-row { display: flex; gap: 8px; }
.pin-row input {
  width: 100%; height: 50px; text-align: center; font-size: 20px; font-weight: 600;
  border: 1px solid #d6d3e4; border-radius: 10px; outline: 0; background: #fff;
  -webkit-text-security: disc;
}
.pin-row input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(63, 52, 150, .12); }

.check { display: flex; gap: 10px; align-items: flex-start; font-size: 12.5px; color: var(--muted); margin: 6px 0 18px; line-height: 1.45; }
.check input { width: 18px; height: 18px; accent-color: var(--primary); margin: 1px 0 0; flex: none; }

.uploader {
  border: 1.5px dashed #c5bfeb; border-radius: 12px; background: #fbfaff;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  min-height: 130px; padding: 14px; color: var(--primary); font-weight: 500; font-size: 13px;
  position: relative; overflow: hidden; text-align: center; width: 100%;
}
.uploader small { color: var(--muted); font-weight: 400; font-size: 11.5px; }
.uploader img { max-width: 100%; max-height: 190px; border-radius: 8px; }
.uploader .remove { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,.6); color: #fff; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; }
.uploader input { display: none; }
.upl-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* ---------- auth ---------- */
.auth { background: #fff; min-height: 100vh; display: flex; flex-direction: column; }
.auth-head {
  background: linear-gradient(160deg, var(--primary-2), var(--primary));
  color: #fff; padding: 40px 24px 70px; text-align: center; position: relative; overflow: hidden;
}
.auth-head img { width: 64px; height: 64px; margin: 0 auto 10px; border-radius: 16px; box-shadow: 0 6px 18px rgba(0,0,0,.2); }
.auth-head .brand-name { color: #fff; font-size: 26px; }
.auth-head p { margin: 4px 0 0; opacity: .85; font-size: 13px; }
.auth-card { background: #fff; margin: -40px 16px 0; border-radius: 18px; padding: 22px 18px; box-shadow: 0 10px 30px rgba(40, 30, 110, .12); position: relative; }
.auth-card h2 { margin: 0 0 4px; font-size: 19px; }
.auth-card .sub { margin: 0 0 20px; color: var(--muted); font-size: 13px; }
.auth-foot { text-align: center; padding: 22px 16px; color: var(--muted); font-size: 13px; }
.auth-foot a { font-weight: 600; }
.trust { display: flex; justify-content: center; gap: 18px; padding: 10px 0 30px; color: var(--muted); font-size: 11px; margin-top: auto; }
.trust span { display: flex; align-items: center; gap: 5px; }

/* ---------- document view ---------- */
.doc-hero { background: #fff; padding: 16px; border-bottom: 1px solid var(--line); display: flex; gap: 12px; align-items: center; }
.doc-hero b { font-size: 16px; display: block; }
.doc-hero small { color: var(--muted); }
.badge { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 20px; background: #e6f6ee; color: var(--green); margin-top: 4px; }
.badge.warn { background: #fff1e0; color: #b46800; }
.side-switch { display: flex; gap: 8px; padding: 14px 16px 0; }
.side-switch button { flex: 1; height: 36px; border-radius: 8px; background: #fff; border: 1px solid var(--line); font-weight: 500; color: var(--muted); font-size: 13px; }
.side-switch button.on { background: var(--primary); color: #fff; border-color: var(--primary); }
.doc-image { margin: 14px 16px 0; background: #fff; border-radius: var(--radius); border: 1px solid var(--line); padding: 10px; text-align: center; }
.doc-image img { max-width: 100%; max-height: 60vh; border-radius: 8px; display: block; margin: 0 auto; cursor: zoom-in; }
.doc-image iframe { width: 100%; height: 60vh; border: 0; }
.details { margin: 14px 16px 0; background: #fff; border-radius: var(--radius); border: 1px solid var(--line); padding: 4px 14px; }
.details .kv { display: flex; justify-content: space-between; gap: 14px; padding: 11px 0; font-size: 13px; }
.details .kv + .kv { border-top: 1px solid var(--line); }
.details .kv span { color: var(--muted); }
.details .kv b { font-weight: 500; text-align: right; word-break: break-word; }
.actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 14px 16px 0; }
.actions button { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 0; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; color: var(--primary); }
.actions button.del { color: var(--danger); }

.viewer { position: fixed; inset: 0; background: rgba(10, 8, 25, .95); z-index: 100; display: flex; align-items: center; justify-content: center; overflow: auto; }
.viewer img { max-width: 100%; max-height: 100%; touch-action: pinch-zoom; }
.viewer.zoom { align-items: flex-start; justify-content: flex-start; }
.viewer.zoom img { max-width: none; max-height: none; width: 220%; }
.viewer .close { position: fixed; top: 14px; right: 14px; color: #fff; background: rgba(255,255,255,.15); }

/* ---------- profile ---------- */
.profile-head { background: linear-gradient(160deg, var(--primary-2), var(--primary)); color: #fff; padding: 26px 16px; display: flex; align-items: center; gap: 14px; }
.profile-head .avatar { width: 62px; height: 62px; font-size: 22px; background: rgba(255,255,255,.2); }
.profile-head b { font-size: 18px; display: block; }
.profile-head small { opacity: .85; }
.storage { margin: 16px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.storage .bar { height: 8px; background: var(--primary-light); border-radius: 8px; overflow: hidden; margin: 10px 0 6px; }
.storage .bar div { height: 100%; background: linear-gradient(90deg, var(--primary-2), var(--primary)); border-radius: 8px; }
.storage small { color: var(--muted); font-size: 12px; }

/* ---------- side menu ---------- */
.drawer-bg { position: fixed; inset: 0; background: rgba(20, 15, 50, .45); z-index: 60; }
.drawer { position: fixed; top: 0; bottom: 0; left: max(0px, calc(50% - 240px)); width: 290px; background: #fff; z-index: 61; display: flex; flex-direction: column; animation: slide .2s ease-out; }
@keyframes slide { from { transform: translateX(-100%); } }
.drawer .profile-head { padding: 34px 16px 22px; }
.drawer .list { margin: 10px 0; border: 0; border-radius: 0; }
.drawer .ver { margin-top: auto; padding: 16px; color: var(--muted); font-size: 11px; text-align: center; }

/* ---------- bottom nav ---------- */
.bottomnav {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; height: var(--nav-h); z-index: 30;
  background: #fff; border-top: 1px solid var(--line);
  display: flex; padding-bottom: env(safe-area-inset-bottom);
}
.bottomnav a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: #8a879e; font-size: 11px; font-weight: 500; position: relative; }
.bottomnav a.on { color: var(--primary); font-weight: 600; }
.bottomnav a.on::before { content: ''; position: absolute; top: 0; width: 34px; height: 3px; border-radius: 0 0 3px 3px; background: var(--primary); }

.fab {
  position: fixed; bottom: calc(var(--nav-h) + 18px); right: max(18px, calc(50% - 222px));
  height: 52px; padding: 0 20px 0 16px; border-radius: 26px; background: var(--primary); color: #fff;
  display: flex; align-items: center; gap: 8px; font-weight: 600; z-index: 25;
  box-shadow: 0 8px 20px rgba(63, 52, 150, .35);
}

/* ---------- sheet / toast ---------- */
.sheet-bg { position: fixed; inset: 0; background: rgba(20, 15, 50, .45); z-index: 70; display: flex; align-items: flex-end; justify-content: center; }
.sheet { background: #fff; width: 100%; max-width: 480px; border-radius: 20px 20px 0 0; padding: 10px 0 20px; animation: up .2s ease-out; }
@keyframes up { from { transform: translateY(100%); } }
.sheet .grab { width: 40px; height: 4px; border-radius: 4px; background: #d8d5e6; margin: 0 auto 10px; }
.sheet h4 { margin: 4px 18px 10px; font-size: 15px; }
.sheet p { margin: 0 18px 16px; color: var(--muted); font-size: 13px; }
.sheet .btns { display: flex; gap: 10px; padding: 0 18px; }
.sheet .btns .btn { flex: 1; }
.sheet .list { margin: 0; border: 0; }

#toast {
  position: fixed; left: 50%; bottom: calc(var(--nav-h) + 20px); transform: translateX(-50%) translateY(20px);
  background: #232036; color: #fff; padding: 10px 18px; border-radius: 10px; font-size: 13px;
  opacity: 0; pointer-events: none; transition: .2s; z-index: 200; max-width: 90vw; text-align: center;
}
#toast.show { opacity: 1; transform: translateX(-50%); }

.spinner { width: 28px; height: 28px; border: 3px solid var(--primary-light); border-top-color: var(--primary); border-radius: 50%; animation: spin .8s linear infinite; margin: 60px auto; }
.btn .spinner { width: 18px; height: 18px; margin: 0; border-width: 2.5px; border-color: rgba(255,255,255,.35); border-top-color: #fff; }
@keyframes spin { to { transform: rotate(360deg); } }

.info-strip { margin: 14px 16px 0; background: var(--primary-light); color: var(--primary); border-radius: 10px; padding: 10px 12px; font-size: 12px; display: flex; gap: 8px; align-items: flex-start; }
.form-head { background: #fff; padding: 16px; display: flex; gap: 12px; align-items: center; border-bottom: 1px solid var(--line); }
.form-head b { display: block; font-size: 15px; }
.form-head small { color: var(--muted); font-size: 12px; }

/* =========================================================
   DigiLocker-style home (measured from reference @ 393pt)
   ========================================================= */
:root { --dl-blue: #4123d0; --dl-top: max(12px, calc(env(safe-area-inset-top) - 2px)); }
.dl-home { position: relative; background: #fff; min-height: 100vh; display: flex; flex-direction: column; padding-bottom: calc(49px + var(--sab, env(safe-area-inset-bottom))); overflow: clip; }
.dl-wave { position: absolute; top: 0; left: 0; width: 100%; height: calc(337px + var(--dl-top) - 44px); }
.dl-home > *:not(.dl-wave) { position: relative; }

/* header stays pinned while the page scrolls under it, like DigiLocker */
.dl-home > .dl-bar { position: sticky; top: 0; z-index: 5; height: calc(var(--dl-top) + 36px); background: var(--dl-blue); }
.dl-logo { display: flex; align-items: center; height: calc(var(--dl-top) + 21px); padding: var(--dl-top) 0 0 29px; color: #fff;
  font-family: 'Archivo Narrow', sans-serif; font-weight: 700; font-size: 22px; }
.dl-glyph { width: 18px; height: 20px; margin-right: 6px; display: block; }

.dl-welcome { display: flex; align-items: center; justify-content: space-between; margin: 9px 10px 0 20px; height: 50px; }
.dl-welcome h1 { margin: 0; color: #fff; font: 700 21.8px/1 'Montserrat', sans-serif; position: relative; top: -3.3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 8px; }
.dl-avatar { width: 50px; height: 50px; flex: none; border-radius: 50%; border: 2.5px solid #fff; background: #6b52e0;
  color: #fff; display: grid; place-items: center; font: 700 18px 'Montserrat', sans-serif; }

.dl-note { margin: 14.4px 20px 0 20px; color: #fff; font: 400 14px/19px 'Open Sans', sans-serif; max-width: 330px; }

.dl-head { display: flex; align-items: center; justify-content: space-between; margin: 15.3px 15px 0 15px; height: 40px; }
.dl-head h2 { margin: 0; color: #fff; font: 700 15.25px/1 'Montserrat', sans-serif; }
.dl-seeall { width: 77px; height: 40px; border-radius: 20px; background: #d9d3f6; border: 1.5px solid #a99ce8;
  color: var(--dl-blue); font: 400 12.2px/37px 'Open Sans', sans-serif; text-align: center; }

.dl-cards { display: flex; gap: 20px; overflow-x: auto; scrollbar-width: none; padding: 18px 20px 4px; margin-top: 0; scroll-snap-type: x mandatory; scroll-padding: 20px; }
.dl-cards::-webkit-scrollbar { display: none; }
.dl-card { flex: none; width: 263px; height: 165px; background: #fff; border-radius: 11px; position: relative; overflow: hidden;
  box-shadow: 0 1px 8px rgba(30, 20, 90, .14); scroll-snap-align: start; color: #000; display: block; }
.dl-card-top { display: flex; align-items: flex-start; padding: 17.4px 0 0 16px; }
.dl-card-logo { width: 70px; height: 46px; margin-top: 15.6px; flex: none; display: grid; place-items: center; }
.dl-card-logo img { max-width: 70px; max-height: 46px; border-radius: 4px; object-fit: contain; }
.dl-card-title { margin-left: 10px; min-width: 0; padding-right: 10px; }
.dl-card-title b { display: block; font: 700 15.2px/22px 'Montserrat', sans-serif; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dl-card-title span { display: block; margin-top: 7px; color: #555; font: 400 13.9px/20px 'Open Sans', sans-serif; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dl-card-issuer { position: absolute; left: 14px; right: 14px; top: 104px; margin: 0; text-align: center; color: #7a7777;
  font: 400 12px/16.4px 'Open Sans', sans-serif; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; z-index: 1; }
.dl-card-mark { position: absolute; right: -4px; bottom: -14px; opacity: .08; }
.dl-card-cta .dl-card-top { padding: 24.5px 0 0 24px; align-items: center; }
.dl-cta-glyph { width: 30px; height: 33px; display: block; margin: 0 12px 0 0; }
.dl-card-cta .dl-card-top b { font: 700 15.2px/22px 'Montserrat', sans-serif; }
.dl-card-cta p { margin: 11px 12px 0 66px; color: #7a7777; font: 400 12px/16.4px 'Open Sans', sans-serif; }
.dl-cta-btn { position: absolute; left: 16px; right: 16px; bottom: 17px; height: 40px; border-radius: 20px; background: #613af5;
  color: #fff; font: 600 13px/40px 'Open Sans', sans-serif; text-align: center; }

.dl-promo { margin: 23.3px 16px 0 14px; height: 141px; }
.dl-slides { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; border-radius: 12px; }
.dl-slides::-webkit-scrollbar { display: none; }
.dl-wallet, .dl-umang { display: block; flex: 0 0 100%; scroll-snap-align: start; height: 141px; border-radius: 12px; overflow: hidden; position: relative; }
.dl-wallet { background: #f2ecff; border: 1px solid #e6dcfd; }
.dl-umang { background: #fff; border: 1px solid #e8e0fc; }
.dl-umang-art { position: absolute; left: 213px; top: 18.6px; }
.dl-umang-text { position: absolute; left: 13.5px; top: 20.3px; z-index: 1; }
.dl-umang-text h3 { margin: 0; color: #33549e; font: 700 14.4px/20px 'Open Sans', sans-serif; white-space: nowrap; }
.dl-umang-text p { margin: 5.9px 0 0; width: 200px; color: #434343; font: 400 12.25px/16.2px 'Open Sans', sans-serif; }
.dl-umang-btn { display: inline-block; margin-top: 11.5px; height: 36.2px; width: 120px; border-radius: 18px; background: #e47934; text-align: center;
  color: #fff; font: 700 12.6px/36.2px 'Open Sans', sans-serif; box-shadow: 0 2px 6px rgba(228, 121, 52, .25); }
.dl-rings { position: absolute; right: -40px; top: -10px; width: 300px; height: 160px; opacity: .8; }
.dl-wallet-text { position: absolute; left: 14.3px; top: 22px; z-index: 1; }
.dl-wallet-text h3 { margin: 0; color: var(--dl-blue); font: 700 14.4px/20px 'Open Sans', sans-serif; }
.dl-wallet-text p { margin: 1.6px 0 0; color: #4a4a4a; font: 400 12.25px/20px 'Open Sans', sans-serif; }
.dl-wallet-btn { display: inline-block; margin-top: 17.7px; height: 37px; padding: 0 16px; border-radius: 19px; background: #4010f5;
  color: #fff; font: 700 12.25px/37px 'Open Sans', sans-serif; box-shadow: 0 2px 6px rgba(64, 16, 245, .2); }
.dl-vc { position: absolute; left: 246px; top: 19px; width: 150px; height: 108px; }
.dl-vc-card { position: absolute; inset: 0 0 12px 0; border-radius: 6px; background: linear-gradient(135deg, #7a31f5, #5a1bef 60%, #4f18ea);
  color: #fff; padding: 10px 0 0 11px; font-family: 'Open Sans', sans-serif; overflow: hidden; }
.dl-vc-stack { position: absolute; left: 4px; right: 0; top: 6px; bottom: 6px; border-radius: 6px; background: #a07af8; border: 1px solid #8f5df5; }
.dl-vc-stack.s2 { top: 12px; bottom: 0; left: 6px; background: #b796fa; }
.dl-vc-head { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 8px; white-space: nowrap; }
.dl-vc-glyph { width: 16px; height: 17px; display: block; margin-top: 1px; }
.dl-vc-head b { display: block; font: 600 6.3px/9px 'Open Sans', sans-serif; }
.dl-vc-head small { display: flex; align-items: center; gap: 3px; font: 400 4.7px/7px 'Open Sans', sans-serif; opacity: .9; }
.dl-vc-head small i { background: #e8f6ea; color: #1a9e5c; border-radius: 1px; width: 6px; height: 6px; display: grid; place-items: center; }
.dl-vc-card > small { display: block; font: 400 4.3px/6px 'Open Sans', sans-serif; opacity: .85; margin-top: 2px; }
.dl-vc-card > b { display: block; font: 600 6.2px/10px 'Open Sans', sans-serif; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 8px; }
.dl-promo { position: relative; }
.dl-dots { position: absolute; left: 0; right: 0; bottom: 1.3px; pointer-events: none; display: flex; justify-content: center; gap: 9.7px; transform: translateX(1.3px); }
.dl-dots i { width: 7px; height: 7px; border-radius: 50%; background: #fff; }
.dl-dots i:not(.on) { opacity: .55; }

.dl-utility { flex: 1; background: #fafafa; margin-top: 16.7px; padding: 18px 16px 30px; }
.dl-utility h2 { margin-left: -1px !important; }
.dl-utility h2 { margin: 0; color: #2b2b2b; font: 700 15.9px/22px 'Montserrat', sans-serif; }
.dl-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12.3px 17px; margin-top: 13.7px; }
.dl-tile { display: block; border: 0; padding: 0; text-align: left; cursor: pointer; height: 93px; border-radius: 8px; background: #f3f3f3; box-shadow: 0 2px 4px rgba(0, 0, 0, .14); position: relative; color: #444; }
.dl-tile svg { position: absolute; left: 13px; top: 9px; }
.dl-tile:nth-child(2) svg { left: 10px; top: 10px; }
.dl-tile:nth-child(3) svg { left: 13px; }
.dl-tile:nth-child(4) svg { left: 16px; top: 9px; }
.dl-tile:nth-child(5) svg { left: 10px; top: 9.5px; }
.dl-tile:nth-child(6) svg { left: 13px; top: 9px; }
.dl-tile:nth-child(7) svg { left: 10px; top: 14px; }
.dl-tile:nth-child(8) svg { left: 10px; top: 9.5px; }
.dl-tile:nth-child(9) svg { left: 15px; top: 9.5px; }
.dl-tile:nth-child(10) svg { left: 10px; top: 9px; }
.dl-need-h { margin-top: 26px !important; }
.dl-need { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 14px; }
.dl-need-card { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 8px; background: #fff; box-shadow: 0 2px 4px rgba(0, 0, 0, .1);
  color: #2b2b2b; font: 600 12.5px/16px 'Open Sans', sans-serif; }
.dl-need-card .logo-tile { flex: none; border-radius: 8px; }
.dl-tile span { position: absolute; left: 10px; right: 6px; top: 63.8px; transform: translateY(-50%); font: 400 14px/19px 'Open Sans', sans-serif; }

.dl-nav { height: calc(49px + var(--sab, env(safe-area-inset-bottom))); padding-bottom: 0; border-top: 0; align-items: flex-start; }
.dl-nav a { justify-content: flex-start; padding-top: 6px; gap: 0; color: #000; font: 400 10.75px/1 -apple-system, 'SF Pro Text', 'Inter', 'Segoe UI', Roboto, sans-serif; flex: 0 0 20%; }
.dl-nav a > span:last-child { margin-top: 7.4px; letter-spacing: .1px; }
.dl-nav a.on { color: #6b44fd; font-weight: 400; }
.dl-nav a.on::before { display: none; }
.dl-nav a svg { width: 24px; height: 24px; }
.dl-nav-glyph { width: 23px; height: 24px; display: block; }
.dl-nav .dl-upload { position: absolute; right: 0; top: 2px; width: 73px; height: 49px; flex: none; padding: 0 0 0 6px; border-radius: 12px 0 0 12px;
  background: #f58220; color: #fff; font: 700 13.7px/46px 'Open Sans', sans-serif; text-align: center; justify-content: center; }

/* =========================================================
   Splash (measured from the DigiLocker splash @ 393×852pt)
   ========================================================= */
#splash { position: fixed; inset: 0; z-index: 500; background: linear-gradient(90deg, #673ffd, #4128d0); color: #fff;
  transition: opacity .35s ease; }
#splash.hide { opacity: 0; pointer-events: none; }
.sp-mark { position: absolute; left: 50%; top: calc(50% - 69.4px); width: 60.6px; height: 57.1px; margin-left: -30.5px; }
.sp-mark svg { display: block; width: 100%; height: 100%; }
.sp-word { position: absolute; left: 0; right: 0; top: calc(50% - 1px); text-align: center; white-space: nowrap;
  font: 700 37.4px/1 'Archivo Narrow', sans-serif; }
.sp-tag { position: absolute; left: 0; right: 0; top: calc(100% - 125.3px); margin: 0; text-align: center; color: rgba(255, 255, 255, .8);
  font: 700 17px/23.7px 'Noto Sans', sans-serif; }
.sp-bar { position: absolute; left: 50%; bottom: 62.7px; width: 36px; height: 3px; margin-left: -18px; border-radius: 1.5px; background: rgba(255, 255, 255, .6); }

/* =========================================================
   ID record page (measured from DigiLocker's PAN "Verification Record" @ 393×852pt)
   ========================================================= */
.vr { --vr-top: max(8px, calc(var(--sat, env(safe-area-inset-top)) - 14px)); --vr-sab: var(--sab, env(safe-area-inset-bottom));
  min-height: 100vh; background: #f3f2f8; padding-bottom: calc(49px + var(--vr-sab) + 24px); color: #181c24; overflow: hidden; }
.vr-head { position: relative; height: calc(var(--vr-top) + 45px); background: #fafafa; }
.vr-back { position: absolute; left: 18px; top: calc(var(--vr-top) + 8px); width: 24px; height: 24px; color: #000; }
.vr-back svg { fill: currentColor; }
.vr-title { position: absolute; left: 59.6px; right: 80px; top: calc(var(--vr-top) + 11.3px); margin: 0; color: #2c2c2c;
  font: 700 15.35px/1.2 'Montserrat', sans-serif; letter-spacing: .12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vr-avatar { position: absolute; right: 30px; top: var(--vr-top); width: 40px; height: 40px; border-radius: 50%; border: 2px solid #78bb7d;
  overflow: hidden; background: #e7e4f6; display: grid; place-items: center; }
.vr-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vr-avatar b { color: #4128d0; font: 600 14px 'Inter', sans-serif; }

.vr-card { position: relative; margin: 10px 10px 0; background: #fff; box-shadow: 0 0 14px rgba(0, 0, 0, .3); padding: 23.5px 0 0; }
.vr-emblem { position: absolute; left: 18px; top: 11px; width: 35px; height: 46.3px; display: grid; place-items: center; }
.vr-emblem img, .vr-emblem svg { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.vr-doc { margin: 0; padding: 0 64px; text-align: center; color: #000; font: 600 16px/1 'Inter', sans-serif; letter-spacing: -.27px; }
.vr-rows { margin-top: 34.85px; padding: 0 12px 0 25px; }
.vr-row { display: grid; grid-template-columns: 122px 20px 1fr; align-items: start; min-height: 26.9px; }
.vr-row b { font: 600 14px/26.9px 'Inter', sans-serif; letter-spacing: -.2px; color: #181c24; }
.vr-row i { font: 600 14px/26.9px 'Inter', sans-serif; font-style: normal; color: #191c23; }
.vr-row span { font: 400 11.8px/16px 'Inter', sans-serif; letter-spacing: 0; color: #191c22; overflow-wrap: anywhere; padding: 4.65px 0 6.25px; }
.vr-div { border: 0; height: 1px; margin: 5.3px 10px 0; background: linear-gradient(#d3d3d3 34%, transparent 34%); }
.vr-foot { position: relative; height: 123px; }
.vr-badge { position: absolute; left: 15px; top: 8.4px; height: 82.7px; }
.vr-ring { position: absolute; left: 0; top: 0; width: 82.7px; height: 82.7px; border-radius: 50%; background: #fff; border: 6px solid #6241f4; box-sizing: border-box; }
.vr-ring-mark { position: absolute; left: 8.3px; top: 11.3px; width: 49px; height: 46.3px; }
.vr-pill { position: absolute; left: 41px; top: 13.6px; height: 55.7px; border-radius: 0 7px 7px 0; background: #6241f4; color: #fff;
  padding: 0 10.7px 0 44px; white-space: nowrap; display: block; }
.vr-pill em { display: block; margin-top: 7.4px; font: italic 500 11.6px/1.2 'Inter', sans-serif; letter-spacing: .1px; }
.vr-pill strong { display: block; margin-top: -1.2px; font: 700 25px/1.2 'Archivo Narrow', sans-serif; }
.vr-qr { position: absolute; left: 272.7px; top: 22px; width: 65.6px; padding: 0; }
.vr-qr img { display: block; width: 65.6px; height: 65.6px; }
.vr-qr span { position: absolute; left: 50%; top: 75px; transform: translateX(calc(-50% - 2.8px)); white-space: nowrap;
  font: 500 12px/1.2 'Inter', sans-serif; letter-spacing: .2px; color: #181c23; }

.vr-tip { margin: 10.3px 10px 0; min-height: 100px; border-radius: 12px; background: #e9e8f8; padding: 18.7px 24px 14px 8.1px; }
.vr-tip small { display: block; color: #706f78; font: 400 11.85px/1.2 Arimo, Arial, sans-serif; }
.vr-tip p { margin: 14.9px 0 0; color: #525156; font: 400 13.36px/15.7px Arimo, Arial, sans-serif; }
.vr-tell { display: flex; align-items: center; margin: 21.4px 0 0 41.2px; color: #5b6bcb; font: 400 11.7px/1.2 'Inter', sans-serif; letter-spacing: .07px; text-align: left; }
.vr-tell i { width: 22.7px; height: 25.3px; margin-left: 9.3px; flex: none; }

.vr-bar { position: fixed; left: 50%; transform: translateX(-50%); bottom: 0; width: 100%; max-width: 480px; z-index: 30;
  height: calc(49px + var(--vr-sab)); background: #fff; display: grid; grid-template-columns: repeat(3, 1fr); align-items: start; }
.vr-bar button { height: 49px; display: grid; place-items: center; }
.vr-bar-mark { width: 23px; height: 24px; display: block; }
.vr-bar-mark svg { width: 23px; height: 24px; }
.vr-bar-share { width: 18px; height: 20px; display: block; }

.viewer.qr img { background: #fff; padding: 18px; width: min(80vw, 360px); max-height: none; }
.viewer-flip { position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%); background: rgba(255,255,255,.15); color: #fff; padding: 10px 18px; border-radius: 20px; font-size: 13px; }
