/* Responsive member layout. Scale artwork inside its existing slots, never the
   entire interface: controls retain usable finger targets and text can grow. */
@media (max-width: 480px) {
 #tv-visitor-dialog.tvc-account-design {
  --tvc-mobile-top:max(8px,env(safe-area-inset-top));
  --tvc-mobile-bottom:max(8px,env(safe-area-inset-bottom));
  /* Override the theme's desktop trigger anchoring only on small screens. */
  left:max(8px,calc((100vw - 442px)/2))!important;
  top:calc(var(--tvc-visible-top,0px) + var(--tvc-mobile-top))!important;
  width:min(442px,calc(100vw - 16px))!important;
  height:calc(var(--tvc-visible-height,100dvh) - var(--tvc-mobile-top) - var(--tvc-mobile-bottom));
  max-height:calc(var(--tvc-visible-height,100dvh) - var(--tvc-mobile-top) - var(--tvc-mobile-bottom))!important;
  padding:10px 12px 14px;overflow:auto;overscroll-behavior:contain;
  scroll-padding-block:58px 20px;box-shadow:-3px 3px #080c0b;
 }
 #tv-visitor-dialog.tvc-account-design>[data-visitor-close] {
  display:flex;position:sticky;inset:auto;top:0;z-index:20;
  width:44px;height:44px;min-height:44px;margin:0 0 8px auto;
  align-items:center;justify-content:center;background:#f7c5cf;
  border:2px solid #080c0b;box-shadow:none;font-size:26px;
 }
 #tv-visitor-dialog.tvc-account-design .tvc-member-dashboard {
  container-type:inline-size;--tvc-u:clamp(.6px,.252525cqi,1px);
 }
 #tv-visitor-dialog.tvc-account-design .tvc-member-tabs {gap:6px;margin-bottom:12px!important}
 #tv-visitor-dialog.tvc-account-design .tvc-member-tabs button {font-size:clamp(14px,4cqi,16px);padding:6px 1px;min-width:0;min-height:44px}
 #tv-visitor-dialog.tvc-account-design .tvc-member-hero {
  min-height:calc(140 * var(--tvc-u));gap:calc(10 * var(--tvc-u));
  background-size:calc(18 * var(--tvc-u)) calc(18 * var(--tvc-u));
  background-position:0 0,0 0,calc(36 * var(--tvc-u)) calc(36 * var(--tvc-u)),calc(126 * var(--tvc-u)) calc(18 * var(--tvc-u)),calc(180 * var(--tvc-u)) calc(72 * var(--tvc-u)),0 calc(108 * var(--tvc-u)),calc(72 * var(--tvc-u)) calc(90 * var(--tvc-u)),calc(216 * var(--tvc-u)) calc(108 * var(--tvc-u));
 }
 #tv-visitor-dialog.tvc-account-design .tvc-designer-avatar,
 #tv-visitor-dialog.tvc-account-design .tvc-member-avatar {width:calc(112 * var(--tvc-u));min-height:calc(140 * var(--tvc-u));height:auto}
 #tv-visitor-dialog.tvc-account-design .tvc-member-identity {padding:calc(24 * var(--tvc-u)) 0 calc(20 * var(--tvc-u))}
 #tv-visitor-dialog.tvc-account-design .tvc-member-name {font-size:max(20px,calc(26 * var(--tvc-u)));margin-bottom:calc(6 * var(--tvc-u))}
 #tv-visitor-dialog.tvc-account-design .tvc-member-stats {gap:4px;flex-wrap:nowrap}
 #tv-visitor-dialog.tvc-account-design .tvc-member-balance,
 #tv-visitor-dialog.tvc-account-design .tvc-member-streak .tvc-streak,
 #tv-visitor-dialog.tvc-account-design .tvc-streak-value {font-size:max(12px,calc(15 * var(--tvc-u)));white-space:nowrap}
 #tv-visitor-dialog.tvc-account-design .tvc-member-streak {padding-inline-start:4px}
 .tvc-local-ornament {
  background-size:calc(1774 * var(--s) * var(--tvc-u)) calc(887 * var(--s) * var(--tvc-u));
  width:calc(var(--w) * var(--s) * var(--tvc-u));
  height:calc(var(--h) * var(--s) * var(--tvc-u));
  /* Sprite windows and placement use the same container-relative unit. */
  background-position:calc(-1 * var(--x) * var(--s) * var(--tvc-u)) calc(-1 * var(--y) * var(--s) * var(--tvc-u));
 }
 .tvc-local-toggle {left:calc(54 * var(--tvc-u));top:calc(10 * var(--tvc-u))}
 .tvc-local-greeting {left:36%;top:calc(3 * var(--tvc-u))}
 .tvc-local-cursor {left:calc(18 * var(--tvc-u));top:calc(48 * var(--tvc-u))}
 .tvc-local-heart {left:calc(24 * var(--tvc-u));bottom:calc(9 * var(--tvc-u))}
 .tvc-local-star {left:calc(104 * var(--tvc-u));bottom:calc(9 * var(--tvc-u))}
 .tvc-local-triangle {left:51%;bottom:calc(10 * var(--tvc-u))}
 #tv-visitor-dialog.tvc-account-design .tvc-next-badge {
  --tvc-ring-entry-x:calc(16 * var(--tvc-u));--tvc-ring-entry-y:calc(36 * var(--tvc-u));
  --tvc-ring-width:calc(74 * var(--tvc-u));--tvc-ring-height:calc(100 * var(--tvc-u));
  margin-top:calc(28 * var(--tvc-u));margin-bottom:12px;padding:10px;
  gap:8px;min-height:0;grid-template-columns:36px minmax(0,1fr) auto;
 }
 #tv-visitor-dialog.tvc-account-design .tvc-next-badge::after {clip-path:polygon(var(--tvc-ring-entry-x) var(--tvc-ring-entry-y),calc(48 * var(--tvc-u)) var(--tvc-ring-entry-y),var(--tvc-ring-entry-x) calc(80 * var(--tvc-u)))}
 #tv-visitor-dialog.tvc-account-design .tvc-progress-icon {width:32px;height:36px;font-size:26px}
 #tv-visitor-dialog.tvc-account-design .tvc-progress-title {font-size:14px;line-height:1.5}
 #tv-visitor-dialog.tvc-account-design .tvc-next-badge small {font-size:clamp(23px,7cqi,30px)}
 #tv-visitor-dialog.tvc-account-design .tvc-progress-track {height:22px}
 #tv-visitor-dialog.tvc-account-design .tvc-featured-header {margin:4px 0}
 #tv-visitor-dialog.tvc-account-design .tvc-featured-header h4 {font-size:23px}
 #tv-visitor-dialog.tvc-account-design .tvc-featured-badges {gap:8px}
 #tv-visitor-dialog.tvc-account-design .tvc-featured-badges>li {grid-template-rows:94px minmax(24px,auto);gap:6px}
 #tv-visitor-dialog.tvc-account-design .tvc-featured-badges .tvc-badge-name {font-size:13px;line-height:1.5}
 #tv-visitor-dialog.tvc-account-design .tvc-badges-expand {margin:4px auto;min-height:44px;font-size:17px}
 #tv-visitor-dialog.tvc-account-design :is(input,select,textarea) {font-size:16px;max-width:100%;box-sizing:border-box;scroll-margin-block:60px 24px}
 #tv-visitor-dialog.tvc-account-design .tvc-badge-editor {padding:10px}
 #tv-visitor-dialog.tvc-account-design .tvc-company-list {min-height:0;max-height:clamp(160px,calc(var(--tvc-visible-height,100dvh) - 320px),420px);padding:10px;gap:14px}
 #tv-visitor-dialog.tvc-account-design .tvc-company-list>li {grid-template-columns:clamp(64px,23cqi,96px) minmax(0,1fr) 78px;gap:7px}
 #tv-visitor-dialog.tvc-account-design .tvc-company-list button {width:78px;font-size:14px}
 #tv-visitor-dialog.tvc-account-design .tvc-company-name {font-size:17px}
 #tv-visitor-dialog.tvc-account-design .tvc-museum-collection {min-height:0;height:clamp(180px,calc(var(--tvc-visible-height,100dvh) - 360px),360px);max-height:none;padding:10px;overscroll-behavior:contain}
 #tv-visitor-dialog.tvc-account-design .tvc-museum-devices>li {grid-template-columns:clamp(64px,23cqi,96px) minmax(0,1fr) 48px;min-height:80px}
 #tv-visitor-dialog.tvc-account-design .tvc-device-visual {width:100%;min-height:80px;padding:6px}
 #tv-visitor-dialog.tvc-account-design .tvc-device-info {padding:8px 6px}
 #tv-visitor-dialog.tvc-account-design .tvc-device-info>span {font-size:16px;overflow-wrap:anywhere}
 #tv-visitor-dialog.tvc-account-design .tvc-device-tags {gap:4px}
 #tv-visitor-dialog.tvc-account-design .tvc-device-tags span {font-size:12px;padding:2px 4px}
 #tv-visitor-dialog.tvc-account-design .tvc-device-edit {width:44px;height:44px;min-height:44px;margin-top:8px}
}
@media (pointer:coarse) {
 #tv-visitor-dialog.tvc-account-design button {min-height:44px;touch-action:manipulation}
 #tv-visitor-dialog.tvc-account-design .tvc-badge-edit {width:44px;height:44px;min-width:44px;min-height:44px}
 #tv-visitor-dialog.tvc-account-design .tvc-stat-anchor {display:flex;align-items:center;touch-action:manipulation}
 /* Enlarge the hit area without moving the approved statistics baseline. */
 #tv-visitor-dialog.tvc-account-design .tvc-stat-anchor::after {content:'';position:absolute;left:0;right:0;top:50%;height:44px;transform:translateY(-50%)}
 #tv-visitor-dialog.tvc-account-design .tvc-stat-anchor>.tvc-stat-tooltip {opacity:0;visibility:hidden;pointer-events:none}
 #tv-visitor-dialog.tvc-account-design .tvc-member-hero .tvc-stat-anchor.tvc-local-tip-open>.tvc-stat-tooltip {
  opacity:1;visibility:visible;pointer-events:auto;white-space:normal;
  transform:translate(calc(-50% + var(--tvc-tip-offset,0px)),0);
 }
 #tv-visitor-dialog.tvc-account-design button:active {filter:brightness(.96)}
}
