:root {
  color-scheme: light;
  --canvas: #efe8e1;
  --paper: #fff;
  --ink: #30231d;
  --muted: #77675e;
  --copper: #a84f28;
  --copper-soft: #f3d9c2;
  --sage: #308366;
  --device-top: 0px;
  --device-bottom: 0px;
  --content-top: 0px;
  --content-bottom: 0px;
  --safe-top: calc(max(env(safe-area-inset-top, 0px), var(--device-top)) + var(--content-top));
  --safe-bottom: calc(max(env(safe-area-inset-bottom, 0px), var(--device-bottom)) + var(--content-bottom));
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --ease-out: cubic-bezier(.22, 1, .36, 1);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
body { margin: 0; color: var(--ink); background: var(--canvas); min-width: 280px; }
button, a, input { font: inherit; }
button { border: 0; cursor: pointer; color: inherit; -webkit-appearance: none; appearance: none; }
button:disabled { cursor: default; }
a { color: inherit; text-decoration: none; }
h1, h2, p { margin: 0; }
button:focus-visible, a:focus-visible { outline: 0; box-shadow: 0 0 0 4px rgba(164,101,66,.18); }
[hidden] { display: none !important; }
.icon-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { display: block; width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.icon.small { width: 18px; height: 18px; }
.muted { color: var(--muted); }
.app-shell { width: min(100%, 480px); margin: 0 auto; padding: calc(var(--safe-top) + 22px) max(22px, var(--safe-right)) calc(var(--safe-bottom) + 122px) max(22px, var(--safe-left)); }
.app-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 35px; }
.user-profile { display: flex; align-items: center; gap: 10px; min-width: 0; min-height: 44px; flex: 1; }
.user-avatar { position: relative; display: grid; place-items: center; width: 42px; height: 42px; flex: 0 0 42px; overflow: hidden; border-radius: 50%; color: #fff3e8; background: linear-gradient(140deg, #c47b46, #87401f); box-shadow: 0 5px 12px -4px rgba(94,44,22,.3); }
.user-avatar > span { font-size: 14px; font-weight: 700; }
.user-avatar img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 50%; opacity: 0; transition: opacity 220ms ease; }
.user-avatar img.is-loaded { opacity: 1; }
.user-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; font-weight: 700; letter-spacing: -.4px; }
.wallet-pill { display: flex; flex-shrink: 0; gap: 6px; align-items: center; min-height: 40px; padding: 0 12px; background: #fff; border-radius: 22px; box-shadow: 0 4px 14px rgba(86,52,31,.07); font-size: 11px; font-weight: 650; white-space: nowrap; }
.wallet-pill .icon { width: 12px; height: 12px; color: var(--muted); }
.connection-dot { width: 5px; height: 5px; border-radius: 50%; background: #b5b8bf; flex-shrink: 0; }
.connection-dot.connected { background: #45a987; }
.wallet-pill:disabled { opacity: .6; }
.screen { min-height: 240px; }
.screen[inert] { pointer-events: none; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 24px; }
h1 { font-size: clamp(30px, 8.7vw, 36px); line-height: 1.05; letter-spacing: -1.25px; font-weight: 750; }
.icon-button { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; flex-shrink: 0; border-radius: 50%; background: #fff; color: #825038; box-shadow: 0 3px 16px rgba(86,52,31,.045); transition: transform 140ms ease, background 140ms ease; }
.icon-button:active, .button:active, .action-card:active, .wallet-pill:active { transform: scale(.975); }
.icon-button:disabled { opacity: .4; }
.rewards-card { position: relative; padding: 22px; overflow: hidden; isolation: isolate; border-radius: 28px; color: #fff9f2; background: radial-gradient(ellipse at 100% 0%, rgba(246,170,101,.45), transparent 64%), linear-gradient(125deg, #60301f, #9b4c29 65%, #bd703d); box-shadow: 0 16px 32px -18px rgba(100,45,21,.5), 0 1px 1px rgba(255,226,198,.2) inset; }
.reward-art { position: absolute; right: -2px; top: 6px; width: 160px; height: 150px; z-index: -1; }
.reward-art svg { width: 100%; height: 100%; }
.wide-balance .reward-art { opacity: .12; }
.reward-balance { position: relative; margin: 18px 0 38px; max-width: 100%; }
.amount { font-size: 62px; font-weight: 600; letter-spacing: -3px; line-height: 1.1; font-variant-numeric: tabular-nums; width: fit-content; min-width: 32px; }
.amount.compact { font-size: 38px; letter-spacing: -1.4px; }
.currency { display: block; color: #f5d5bc; font-size: 11px; font-weight: 650; letter-spacing: 1.8px; margin-top: 4px; }
.reward-footer { display: flex; flex-direction: column; gap: 13px; }
.reward-footer > span { font-size: 10px; color: #f5d5bc; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 52px; width: 100%; padding: 13px 16px; border-radius: 17px; font-size: 13px; font-weight: 650; letter-spacing: -.15px; transition: transform 140ms ease, opacity 140ms ease; }
.button.primary { background: linear-gradient(120deg, #9b4926, #783a23); color: #fff; box-shadow: 0 6px 16px -8px rgba(93,43,22,.38); }
.button.primary:disabled { background: #e3d7ce; color: #88766b; box-shadow: none; }
.rewards-card .button.primary { background: #fff4e7; color: #66331e; box-shadow: 0 5px 14px rgba(59,25,12,.14); }
.rewards-card .button.primary:disabled { background: rgba(255,242,226,.68); color: #6c4432; box-shadow: none; }
.button.secondary { background: #f2e8df; color: #79503a; }
.button:disabled { opacity: .8; }
.spinner { display: inline-block; width: 16px; height: 16px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin 700ms linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.is-loading { color: transparent; background: rgba(255,231,205,.2); border-radius: 10px; min-width: 75px; animation: breathe 1.4s ease-in-out infinite; }
@keyframes breathe { 50% { opacity: .45; } }
.context-note { margin: 12px 8px 0; font-size: 11px; line-height: 1.5; color: var(--copper); }
.action-card { display: flex; align-items: center; gap: 13px; width: 100%; min-height: 89px; padding: 18px; margin-top: 16px; text-align: left; border-radius: 24px; background: #fff; transition: transform 140ms ease; box-shadow: 0 9px 24px -18px rgba(88,54,33,.22); }
.action-art { display: flex; align-items: center; justify-content: center; width: 47px; height: 47px; border-radius: 16px; background: linear-gradient(145deg, #d4955e, #a5542d); color: #fff2df; flex-shrink: 0; box-shadow: 0 5px 12px -7px rgba(128,60,26,.5); }
.action-art svg { width: 28px; height: 28px; }
.action-copy { display: flex; flex-direction: column; gap: 5px; min-width: 0; flex: 1; }
.action-copy strong { font-size: 14px; font-weight: 650; letter-spacing: -.3px; }
.action-copy > span { font-size: 10px; color: var(--muted); line-height: 1.3; }
.action-arrow { width: 18px; height: 18px; color: #956a50; }
.collection-art { width: 47px; height: 47px; position: relative; flex-shrink: 0; }
.collection-art > span { position: absolute; inset: 3px 5px 4px 2px; border-radius: 11px; background: #dba678; transform: rotate(-12deg); }
.collection-art > span + span { inset: 6px 1px 1px 7px; display: grid; place-items: center; background: linear-gradient(145deg, #70452e, #36251e); color: #ffe6ca; transform: rotate(6deg); box-shadow: 0 4px 8px rgba(77,41,22,.16); }
.collection-art .icon { width: 22px; height: 22px; }
.quiet-caption { color: var(--muted); font-size: 10px; line-height: 1.5; text-align: center; margin: 20px 0 0; }
.surface { background: #fff; border-radius: 24px; padding: 22px; box-shadow: 0 9px 24px -18px rgba(88,54,33,.22); }
.deal-card { margin-top: 16px; }
.section-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.section-row h2 { font-size: 15px; letter-spacing: -.35px; font-weight: 650; }
.status-badge { display: inline-flex; align-items: center; border-radius: 15px; background: #edf6f1; color: var(--sage); padding: 5px 9px; font-size: 9px; font-weight: 650; white-space: nowrap; }
.status-badge.neutral { color: #796456; background: #f4ebe3; }
.status-badge.warning { color: #a7774d; background: #fbf2e9; }
.deal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 20px 0 15px; }
.deal-grid span { display: block; font-size: 10px; color: var(--muted); margin-bottom: 6px; }
.deal-grid strong { font-size: 14px; font-weight: 650; font-variant-numeric: tabular-nums; }
.deal-grid > div:last-child { text-align: right; }
.deal-grid > div:last-child strong { color: var(--copper); }
.deal-foot { display: flex; justify-content: space-between; font-size: 10px; color: var(--muted); gap: 8px; }
.bottom-nav { position: fixed; z-index: 20; left: 50%; bottom: calc(var(--safe-bottom) + 13px); transform: translateX(-50%); display: grid; grid-template-columns: repeat(3, 1fr); width: min(calc(100% - 40px), 396px); padding: 7px; background: rgba(255,255,255,.93); border-radius: 26px; box-shadow: 0 10px 35px -12px rgba(52,59,77,.18), 0 2px 4px rgba(255,255,255,.9) inset; }
@supports (backdrop-filter: blur(16px)) { .bottom-nav { background: rgba(255,255,255,.76); backdrop-filter: blur(16px) saturate(1.2); -webkit-backdrop-filter: blur(16px) saturate(1.2); } }
.bottom-nav::before { content: ''; position: absolute; left: 7px; top: 7px; bottom: 7px; width: calc((100% - 14px) / 3); border-radius: 20px; background: linear-gradient(135deg, #ac5a31, #7e3e25); box-shadow: 0 5px 12px -7px rgba(111,48,21,.4); transform: translateX(calc(var(--nav-index, 0) * 100%)); transition: transform 380ms var(--ease-out); pointer-events: none; }
.nav-tab { position: relative; min-height: 59px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; background: transparent; border-radius: 20px; color: #7d695d; transition: color 180ms ease, transform 300ms var(--ease-out); }
.nav-tab .icon { width: 23px; height: 23px; }
.nav-tab span { font-size: 9px; font-weight: 600; letter-spacing: -.1px; }
.nav-tab.active { color: #fff5ea; }
.nav-tab.active .icon { animation: icon-settle 380ms var(--ease-out); }
@keyframes icon-settle { 0% { transform: scale(.88) translateY(2px); } 55% { transform: scale(1.08) translateY(-1px); } 100% { transform: none; } }
.nft-summary { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11px; color: var(--muted); margin: -3px 0 22px; }
.address-mini { padding: 5px 8px; background: #e6dbd1; border-radius: 12px; color: #7d6657; font-size: 9px; }
.empty-state { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 52px 20px 32px; }
.empty-art { width: 95px; height: 95px; border-radius: 30px; background: linear-gradient(140deg, #d3915c, #8d4527); box-shadow: 0 18px 32px -24px #8f4b2a; display: grid; place-items: center; transform: rotate(-6deg); margin-bottom: 30px; color: #fff2e0; }
.empty-art .icon { width: 38px; height: 38px; stroke-width: 1.4; }
.empty-state h2 { font-size: 18px; letter-spacing: -.55px; line-height: 1.3; max-width: 250px; }
.empty-state h2 + .button, .empty-state p[hidden] + .button { margin-top: 24px; }
.empty-state p { color: var(--muted); font-size: 12px; line-height: 1.65; max-width: 240px; margin: 10px 0 24px; }
.empty-state .button { max-width: 255px; }
.nft-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 14px; }
.nft-card { display: block; padding: 0; text-align: left; background: transparent; min-width: 0; }
.nft-picture { position: relative; display: grid; place-items: center; aspect-ratio: 1; background: #eceef3; border-radius: 22px; overflow: hidden; color: #c1c4cf; }
.nft-picture > .icon { width: 38px; height: 38px; stroke-width: 1.3; }
.nft-picture img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 300ms ease; }
.nft-picture img.is-loaded, .nft-detail-image img.is-loaded { opacity: 1; }
.nft-card:active .nft-picture { opacity: .8; }
.nft-title { display: block; font-size: 13px; font-weight: 650; letter-spacing: -.3px; margin: 10px 3px 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nft-collection { display: block; margin: 0 3px; font-size: 10px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nft-skeleton .nft-picture, .nft-skeleton .nft-title { animation: breathe 1.4s ease-in-out infinite; }
.nft-skeleton .nft-title { background: #e8eaf0; width: 65%; height: 10px; border-radius: 4px; margin-top: 14px; }
.load-more { margin-top: 24px; }
.wallet-card { padding: 25px; }
.wallet-card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 27px; }
.wallet-emblem { display: grid; place-items: center; width: 49px; height: 49px; border-radius: 17px; background: linear-gradient(145deg, #d4955e, #a5542d); color: #fff2df; }
.wallet-emblem .icon { width: 25px; height: 25px; }
.wallet-card h2 { font-size: 22px; font-weight: 650; letter-spacing: -.75px; }
.wallet-card > p { font-size: 11px; line-height: 1.6; margin: 7px 0 25px; color: var(--muted); }
.full-address { overflow-wrap: anywhere; font-size: 12px; line-height: 1.7; color: var(--muted); font-variant-numeric: tabular-nums; user-select: all; }
.wallet-actions { display: flex; gap: 9px; align-items: center; margin-top: 20px; }
.wallet-actions .icon-button { background: #f2e8df; width: 52px; height: 52px; border-radius: 17px; }
.text-button { display: block; width: 100%; min-height: 44px; background: transparent; font-size: 11px; font-weight: 600; color: var(--muted); padding: 12px 8px; }
.text-button.danger { color: #a15735; margin-top: 8px; }
.history-heading { margin: 30px 4px 14px; }
.history-list { padding: 8px 20px; }
.history-row { display: flex; align-items: center; gap: 12px; padding: 16px 0; }
.history-icon { display: grid; place-items: center; width: 35px; height: 35px; border-radius: 12px; background: #f3dcc6; color: var(--copper); flex-shrink: 0; }
.history-icon .icon { width: 16px; height: 16px; }
.history-copy { display: flex; flex-direction: column; gap: 5px; flex: 1; min-width: 0; }
.history-copy strong { font-size: 12px; font-weight: 650; font-variant-numeric: tabular-nums; }
.history-copy span { font-size: 9px; color: var(--muted); }
.history-empty { color: var(--muted); font-size: 11px; line-height: 1.6; padding: 20px 0; }
.sheet { width: min(calc(100% - 24px), 430px); max-height: calc(100dvh - var(--safe-top) - 35px); padding: 23px; border: 0; border-radius: 30px; color: var(--ink); background: #fff; box-shadow: 0 24px 70px rgba(27,29,37,.12); margin: auto auto calc(var(--safe-bottom) + 12px); overflow-y: auto; }
.sheet::backdrop { background: rgba(28,31,40,.25); animation: backdrop-in 240ms ease; }
.sheet.is-closing::backdrop { animation: backdrop-out 180ms ease forwards; }
@keyframes backdrop-in { from { background: rgba(28,31,40,0); } }
@keyframes backdrop-out { to { background: rgba(28,31,40,0); } }
.sheet-handle { width: 32px; height: 4px; border-radius: 4px; background: #e5e7ec; margin: -9px auto 18px; }
.sheet-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 22px; }
.sheet-heading h2 { font-size: 21px; letter-spacing: -.7px; overflow-wrap: anywhere; }
.sheet-heading .icon-button { background: #f4ebe3; }
.sheet-label { font-size: 11px; color: var(--muted); margin-bottom: 8px; }
.sheet > .full-address { background: #f7f1eb; padding: 15px; border-radius: 16px; margin-bottom: 16px; }
.disconnect-button { background: #f7e5dc; color: #a04d2b; margin-top: 10px; }
.inline-error { color: #a54b30; font-size: 11px; line-height: 1.5; margin-top: 12px; }
.nft-detail-image { aspect-ratio: 1; display: grid; place-items: center; border-radius: 23px; overflow: hidden; background: #f0f1f5; margin-bottom: 20px; color: #b5bac8; }
.nft-detail-image img { display: block; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 300ms ease; }
.nft-detail-image > .icon { width: 56px; height: 56px; }
.nft-description { font-size: 12px; line-height: 1.6; color: var(--muted); margin-bottom: 20px; }
.nft-detail > .button { margin-top: 17px; }
.toast { position: fixed; bottom: calc(var(--safe-bottom) + 102px); left: 50%; transform: translateX(-50%); width: min(calc(100% - 44px), 370px); padding: 15px 18px; border-radius: 18px; background: #fff; color: #636975; box-shadow: 0 6px 24px rgba(34,39,58,.12); font-size: 12px; line-height: 1.5; text-align: center; z-index: 30; }
.toast.error { color: #aa715d; }
/* Keep compositor-friendly feedback scoped to app controls, never SDK portals. */
.app-shell button, .sheet button { transition: transform 320ms var(--ease-out), opacity 180ms ease, background-color 180ms ease; }
.app-shell button:not(:disabled):active, .sheet button:not(:disabled):active, .nav-tab:active { transform: scale(.965); }
.user-profile { transition: transform 320ms var(--ease-out); }
.user-profile:active { transform: scale(.97); }
.nft-picture { transition: opacity 180ms ease; }
@media (max-width: 350px) {
  .app-shell { padding-left: max(17px, var(--safe-left)); padding-right: max(17px, var(--safe-right)); }
  .user-profile { gap: 8px; }
  .user-name { font-size: 14px; }
  .wallet-pill { font-size: 10px; padding: 0 9px; }
  .wallet-pill .connection-dot { display: none; }
  .rewards-card { padding: 20px; }
  .reward-art { width: 133px; height: 133px; top: 15px; right: -11px; }
  .amount { font-size: 55px; }
  .action-copy strong { font-size: 12px; }
  .action-card { padding: 16px; gap: 10px; }
  .nft-grid { gap: 18px 12px; }
  .nft-title { font-size: 12px; }
  .sheet { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
