/* LA Life — UI in the language of Caltrans guide signs: freeway green, white inset border, Highway-Gothic-like type. */
:root {
  --sign: #006B4F;          /* freeway guide-sign green */
  --sign-deep: #00523C;
  --white: #FFFFFF;
  --gold: #F2C230;          /* money, waypoints */
  --red: #E3131B;           /* Metro B line red: warnings */
  --blue: #1F6FB2;          /* Pacific blue: city channel */
  --asphalt: #262A2F;       /* phone & chat */
  --ink: #17231D;
  --ok: #3ECF8E;
  --font: "Overpass", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #1d2b24; font-family: var(--font); color: var(--white); -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
#game { position: fixed; inset: 0; }
#game canvas { display: block; image-rendering: pixelated; }
#hud { position: fixed; inset: 0; pointer-events: none; display: none; }
body.playing #hud { display: block; }
#hud > * { pointer-events: auto; }
[hidden] { display: none !important; }

/* ---------- sign primitives ---------- */
.sign, #loc, #activity, .title-sign {
  background: var(--sign); border: 2.5px solid var(--white); border-radius: 10px;
  box-shadow: 0 0 0 4px var(--sign), 0 14px 34px rgba(0, 0, 0, .38);
}
.exit-tab {
  position: absolute; top: -27px; right: 18px; padding: 3px 14px 1px; font-weight: 800; font-size: 14px; color: var(--white);
  background: var(--sign); border: 2.5px solid var(--white); border-bottom: 0; border-radius: 7px 7px 0 0;
  box-shadow: 0 -4px 0 0 var(--sign), 4px 0 0 0 var(--sign), -4px 0 0 0 var(--sign);
}
.exit-tab:hover { background: var(--white); color: var(--sign); }

/* ---------- HUD ---------- */
#loc { position: fixed; top: 16px; left: 16px; padding: 7px 16px 6px; display: flex; flex-direction: column; min-width: 150px; }
#loc-name { font-weight: 900; font-size: 22px; line-height: 1.05; letter-spacing: .01em; }
#clock { font-weight: 600; font-size: 14px; opacity: .92; font-variant-numeric: tabular-nums; margin-top: 2px; }
#topright { position: fixed; top: 18px; right: 16px; display: flex; gap: 8px; align-items: center; }
#money { background: var(--gold); color: var(--ink); font-weight: 900; font-size: 20px; padding: 7px 14px 5px; border-radius: 8px; border: 2.5px solid var(--ink); font-variant-numeric: tabular-nums; min-width: 96px; text-align: right; }
#money.neg { background: var(--red); color: var(--white); }
#topright button { width: 44px; height: 44px; border-radius: 10px; border: 2.5px solid var(--white); background: var(--sign); font-size: 20px; box-shadow: 0 0 0 3px var(--sign); }
#topright button:hover { background: var(--sign-deep); }

#activity { position: fixed; top: 16px; left: 50%; transform: translateX(-50%); padding: 8px 10px 8px 16px; display: flex; gap: 12px; align-items: center; min-width: 300px; max-width: min(560px, 60vw); }
.act-text { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.act-text strong { font-weight: 800; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act-text small { font-size: 12px; opacity: .85; }
.act-text em { font-style: normal; color: var(--gold); font-weight: 800; font-size: 13px; }
#activity .bar { width: 110px; }
#activity button { background: var(--white); color: var(--sign); font-weight: 800; border: 0; border-radius: 6px; padding: 6px 12px 4px; }

.bar { height: 7px; border-radius: 4px; background: rgba(255, 255, 255, .2); overflow: hidden; }
.bar s { display: block; height: 100%; background: var(--ok); border-radius: 4px; transition: width .4s; }
.bar.low s { background: var(--gold); } .bar.crit s { background: var(--red); } .bar.skill s { background: #7FB6FF; }

#toasts { position: fixed; top: 84px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 6px; align-items: center; pointer-events: none !important; width: min(520px, 92vw); }
.toast { background: var(--asphalt); border-left: 5px solid var(--white); padding: 8px 14px 6px; border-radius: 6px; font-size: 14px; font-weight: 600; box-shadow: 0 6px 18px rgba(0, 0, 0, .35); transition: opacity .5s, transform .5s; max-width: 100%; }
.toast.ok { border-color: var(--ok); } .toast.err { border-color: var(--red); background: #3a1d20; }
.toast.out { opacity: 0; transform: translateY(-6px); }

#prompt { position: fixed; bottom: 26%; left: 50%; transform: translateX(-50%); display: flex; gap: 10px; align-items: center; background: var(--white); color: var(--sign); border: 0; border-radius: 8px; padding: 6px 14px 4px 6px; font-weight: 800; font-size: 15px; box-shadow: 0 8px 20px rgba(0, 0, 0, .35); }
#prompt kbd { background: var(--sign); color: var(--white); border-radius: 5px; padding: 3px 9px 1px; font-family: var(--font); font-weight: 900; }

#needs { position: fixed; right: 16px; bottom: 16px; background: rgba(23, 35, 29, .86); border-radius: 10px; padding: 10px 12px; display: grid; gap: 6px; width: 176px; }
.need { display: flex; align-items: center; gap: 8px; }
.need i { font-style: normal; width: 20px; text-align: center; font-size: 15px; }
.need b { flex: 1; height: 9px; background: rgba(255, 255, 255, .16); border-radius: 5px; overflow: hidden; }
.need s { display: block; height: 100%; background: var(--ok); transition: width .5s; }
.need.low s { background: var(--gold); } .need.crit s { background: var(--red); }
.need.crit i { animation: throb 1s infinite; }
@keyframes throb { 50% { transform: scale(1.3); } }

#chat { position: fixed; left: 16px; bottom: 16px; width: min(360px, 44vw); display: flex; flex-direction: column; background: rgba(23, 35, 29, .78); border-radius: 10px; overflow: hidden; }
.chat-tabs { display: flex; gap: 2px; padding: 6px 6px 0; }
.chat-tabs button { border: 0; background: transparent; color: rgba(255, 255, 255, .6); font-weight: 800; font-size: 13px; padding: 4px 10px 2px; border-radius: 6px 6px 0 0; }
.chat-tabs button.on { background: rgba(255, 255, 255, .12); color: var(--white); }
#chat-log { height: 150px; overflow-y: auto; padding: 6px 10px; font-size: 13.5px; line-height: 1.4; scrollbar-width: thin; }
.msg { margin: 2px 0; word-break: break-word; }
.msg b { color: #9FE3C4; margin-right: 6px; font-weight: 800; }
.msg i { font-style: normal; background: var(--blue); border-radius: 4px; padding: 0 5px; font-size: 11px; margin-right: 5px; font-weight: 800; }
.msg.news span { color: var(--gold); font-weight: 600; }
#chat-input { border: 0; border-top: 1px solid rgba(255, 255, 255, .12); background: rgba(0, 0, 0, .25); color: var(--white); padding: 9px 10px; font: inherit; font-size: 14px; }
#chat-input::placeholder { color: rgba(255, 255, 255, .5); }
#joy { display: none; position: fixed; left: 28px; bottom: 210px; width: 110px; height: 110px; border-radius: 50%; background: rgba(255, 255, 255, .12); border: 2px solid rgba(255, 255, 255, .4); touch-action: none; }
#joy i { position: absolute; left: 35px; top: 35px; width: 40px; height: 40px; border-radius: 50%; background: rgba(255, 255, 255, .7); }
@media (pointer: coarse) { #joy { display: block; } #prompt { bottom: 30%; font-size: 17px; padding: 10px 16px 8px 10px; } }

/* ---------- modal & sign panels ---------- */
#modal { position: fixed; inset: 0; display: grid; place-items: center; background: rgba(10, 18, 14, .35); padding: 40px 12px 12px; }
.sign { position: relative; width: min(560px, 96vw); max-height: min(78vh, 760px); display: flex; flex-direction: column; }
.sign-head { padding: 14px 20px 8px; display: flex; justify-content: space-between; align-items: flex-start; }
.sign-head h2 { margin: 0; font-size: 26px; font-weight: 900; line-height: 1.1; }
.sign-head p { margin: 3px 0 0; font-weight: 600; opacity: .85; font-size: 14px; }
.sign-body { overflow-y: auto; padding: 4px 20px 18px; scrollbar-width: thin; }
.sign h3, .app h3 { margin: 16px 0 6px; font-size: 15px; font-weight: 800; padding-bottom: 4px; border-bottom: 2px solid rgba(255, 255, 255, .35); }
.lead { font-size: 15px; line-height: 1.5; margin: 6px 0 10px; }
.note { font-size: 13px; line-height: 1.5; opacity: .82; margin: 8px 0; }
.row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid rgba(255, 255, 255, .13); }
.row.mine { background: rgba(255, 255, 255, .08); border-radius: 6px; padding: 8px; }
.row-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.row-main > span { font-weight: 700; font-size: 15px; }
.row-main small { font-size: 12.5px; opacity: .78; margin-top: 2px; }
.row-btns { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.eff { font-size: 12px; letter-spacing: 1px; }
.price { font-style: normal; color: var(--gold); font-weight: 900; font-variant-numeric: tabular-nums; }
.price.free { color: var(--ok); }
.sign button, .app button, .phone button:not(.exit-tab):not(.back) { background: var(--white); color: var(--sign); border: 0; border-radius: 6px; padding: 6px 12px 4px; font-weight: 800; font-size: 14px; }
.sign button.ghost, .app button.ghost { background: transparent; color: var(--white); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .7); }
.sign button.wide, .app button.wide { display: block; width: 100%; margin: 10px 0 0; padding: 10px; }
.sign button.sm, .app button.sm { padding: 2px 8px; font-size: 12px; }
.sign .exit-tab { background: var(--sign); color: var(--white); border-radius: 7px 7px 0 0; padding: 3px 14px 1px; }
.sign .exit-tab:hover { background: var(--white); color: var(--sign); }
input[type=number], input[type=text], select { width: 92px; background: rgba(255, 255, 255, .95); color: var(--ink); border: 0; border-radius: 6px; padding: 6px 8px 4px; font: inherit; font-weight: 700; font-size: 14px; }
input[type=text] { width: 140px; }
select { width: auto; max-width: 110px; }
.clothes-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; margin: 6px 0; }
.fit-mirror { display: flex; justify-content: center; margin: 2px 0 6px; } .fit-mirror canvas { width: 120px; height: 152px; border-radius: 14px; background: linear-gradient(#eef6f8, #dfeaee); }
.cloth { background: rgba(0, 0, 0, .18); border-radius: 8px; padding: 8px; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.cloth.on { box-shadow: inset 0 0 0 2px var(--gold); }
.cloth i { width: 30px; height: 18px; border-radius: 4px; border: 2px solid var(--white); }
.cloth i.none { background: repeating-linear-gradient(45deg, transparent 0 4px, rgba(255, 255, 255, .5) 4px 6px); }
.cloth span { font-weight: 700; font-size: 13px; }
.cloth small { color: var(--gold); font-weight: 800; }
.types { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.sign .type, .app .type { display: flex; flex-direction: column; gap: 3px; align-items: flex-start; text-align: left; padding: 10px; }
.type small { font-weight: 600; opacity: .8; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 8px; margin: 8px 0; }
.stats div { background: rgba(0, 0, 0, .2); border-radius: 8px; padding: 8px 10px 6px; display: flex; flex-direction: column; }
.stats small { font-size: 12px; opacity: .75; }
.stats b { font-size: 18px; font-weight: 900; font-variant-numeric: tabular-nums; }
.up { color: var(--ok); } .down { color: #FF8A7A; }
.danger { margin-top: 14px; }
.emotes { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.sign .emotes button { display: flex; flex-direction: column; align-items: center; font-size: 22px; padding: 6px 2px; }
.emotes small { font-size: 11px; }
.line { display: inline-block; min-width: 22px; text-align: center; border-radius: 50%; color: #fff; font-weight: 900; font-size: 13px; padding: 3px 0 1px; margin-right: 4px; border: 2px solid #fff; }
.line.sm { min-width: 18px; font-size: 11px; padding: 1px 0 0; }
.sign.metro { --sign: #1B1C20; }

/* ---------- phone ---------- */
.phone { position: relative; width: min(390px, 96vw); height: min(700px, 86vh); background: var(--asphalt); border-radius: 30px; border: 6px solid #111417; box-shadow: 0 24px 60px rgba(0, 0, 0, .5); display: flex; flex-direction: column; overflow: visible; }
.phone-top { display: flex; align-items: center; gap: 10px; padding: 14px 18px 8px; font-weight: 800; position: relative; }
.phone-top b { font-size: 18px; flex: 1; }
.phone-top span { flex: 1; font-variant-numeric: tabular-nums; }
.phone .exit-tab { top: -32px; }
.back { background: transparent; border: 0; font-size: 28px; line-height: 1; padding: 0 6px; color: var(--white); }
.apps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; padding: 18px; }
.phone .apps button { position: relative; background: transparent; color: var(--white); display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 0; font-weight: 700; font-size: 13px; }
.apps i { font-style: normal; font-size: 30px; width: 68px; height: 68px; display: grid; place-items: center; border-radius: 18px; background: var(--sign); border: 2px solid rgba(255, 255, 255, .85); }
.apps em { position: absolute; top: -4px; right: 14px; background: var(--red); border-radius: 10px; font-style: normal; font-size: 12px; padding: 1px 6px; }
.app { padding: 4px 18px 18px; flex: 1; }
.app .row-main > span { font-size: 14.5px; }
.kv { display: flex; justify-content: space-between; font-size: 14px; font-weight: 600; margin-top: 8px; margin-bottom: 4px; }
.me-card { display: flex; gap: 14px; align-items: center; }
.me-card canvas { image-rendering: pixelated; background: rgba(255, 255, 255, .06); border-radius: 12px; }
.me-card h3 { border: 0; margin: 0 0 4px; font-size: 20px; }
.me-card p { margin: 2px 0; font-size: 13.5px; }
.mine-card { background: rgba(0, 107, 79, .45); border: 2px solid rgba(255, 255, 255, .5); border-radius: 10px; padding: 4px 12px 12px; margin-bottom: 10px; }
.mine-card p { margin: 4px 0; font-size: 13.5px; }
.job { padding: 10px 0; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.job > div:first-child { display: flex; flex-direction: column; }
.job small { opacity: .75; font-size: 12.5px; }
.wheres { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.app button.chip { background: rgba(255, 255, 255, .1); color: var(--white); font-size: 12px; padding: 4px 9px 2px; font-weight: 700; }
.app button.stock { display: flex; align-items: center; gap: 10px; width: 100%; background: rgba(255, 255, 255, .05); color: var(--white); margin: 6px 0; padding: 10px 12px; text-align: left; border-radius: 10px; }
.stock > div:first-child { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.stock small { font-size: 12px; opacity: .75; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stock .px { display: flex; flex-direction: column; align-items: flex-end; font-variant-numeric: tabular-nums; }
.stock .px small { opacity: 1; }
.big-price b { font-size: 30px; font-weight: 900; font-variant-numeric: tabular-nums; margin-right: 8px; }
.spark { display: block; }
.big-price + .spark { width: 100%; height: auto; margin: 8px 0; }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: #6b7078; margin-right: 7px; vertical-align: 1px; }
.dot.on { background: var(--ok); }
.dm-log { height: calc(100% - 52px); min-height: 300px; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; padding: 6px 0; }
.dm { align-self: flex-start; max-width: 80%; background: rgba(255, 255, 255, .1); padding: 7px 11px 5px; border-radius: 14px 14px 14px 4px; font-size: 14px; }
.dm.mine { align-self: flex-end; background: var(--sign); border-radius: 14px 14px 4px 14px; }
.dm small { display: block; font-size: 10.5px; opacity: .6; }
.dm-send { display: flex; gap: 6px; } .dm-send input { flex: 1; width: auto; }
.map-wrap { margin: 0 -12px; } #minimap { width: 100%; border-radius: 10px; cursor: crosshair; image-rendering: pixelated; }
.biz { margin-bottom: 16px; }
.biz h3 { display: flex; justify-content: space-between; align-items: center; }

/* ---------- sign in ---------- */
#auth { position: fixed; inset: 0; overflow-y: auto; display: grid; place-items: center; padding: 20px;
  background:
    radial-gradient(ellipse 46% 70% at 50% 52%, rgba(10, 30, 24, .55), rgba(10, 30, 24, 0) 100%),
    url("/img/title.jpg") center / cover no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 220' preserveAspectRatio='none'%3E%3Cg fill='%23281e3d'%3E%3Cpath d='M0 220V170h1200v50z'/%3E%3Cpath d='M140 172c4-60 8-100 6-140l6 1c2 40-2 80-6 139z'/%3E%3Cpath d='M150 34c-30-10-60 0-74 14 26-6 48-6 74-12zm0 0c28-14 60-10 76 2-26-2-50-2-76-2zm0 0c-14-20-40-28-60-24 22 6 40 14 60 24zm0 0c10-22 34-34 56-32-20 8-38 18-56 32z'/%3E%3Cpath d='M960 172c3-70 7-120 4-160l6 1c3 44-1 90-4 159z'/%3E%3Cpath d='M968 14c-32-8-62 4-76 18 28-6 50-8 76-18zm0 0c30-12 62-6 78 6-28-2-52-4-78-6zm0 0c-16-20-42-26-62-20 22 4 42 12 62 20zm0 0c12-22 36-32 58-28-22 6-40 16-58 28z'/%3E%3Cpath d='M1060 172c2-50 4-80 3-110l5 1c1 32-1 64-3 109z'/%3E%3Cpath d='M1066 62c-24-6-46 2-58 12 20-4 38-6 58-12zm0 0c22-8 46-4 58 6-20-2-38-4-58-6zm0 0c-10-14-30-20-46-16 16 4 32 10 46 16z'/%3E%3Cpath d='M300 172h60v-50h40v-30h30v80h50v-110h44v110h40v-60h50v60z'/%3E%3C/g%3E%3C/svg%3E") bottom / 100% 26vh no-repeat,
    linear-gradient(180deg, #2E3A7A 0%, #8A4C8F 38%, #F06C6B 64%, #FFB36B 84%, #FFD98A 100%);
}
.auth-card { width: min(460px, 100%); display: flex; flex-direction: column; position: relative; margin-bottom: 18vh; }
.title-sign { display: flex; gap: 16px; align-items: center; padding: 16px 20px; margin-bottom: 18px; }
.title-sign h1 { margin: 0; font-size: 40px; font-weight: 900; line-height: 1; }
.title-sign p { margin: 6px 0 0; font-weight: 600; font-size: 14px; line-height: 1.35; }
.shield { flex: none; width: 58px; height: 62px; background: var(--white); color: var(--sign); font-weight: 900; font-size: 24px; display: grid; place-items: center; border-radius: 10px 10px 28px 28px; border: 3px solid var(--sign); box-shadow: 0 0 0 2.5px var(--white); padding-top: 4px; }
.lang-switch { position: absolute; top: -6px; right: 0; display: flex; gap: 4px; }
.lang-switch button { background: rgba(0, 0, 0, .3); border: 0; color: var(--white); border-radius: 6px; padding: 3px 9px 1px; font-weight: 800; font-size: 12px; }
.lang-switch button.on { background: var(--white); color: var(--sign); }
.auth-card label { font-weight: 800; font-size: 14px; margin: 10px 0 4px; text-shadow: 0 1px 2px rgba(0, 0, 0, .4); }
.auth-card input { width: 100%; padding: 11px 12px 9px; border-radius: 8px; border: 2.5px solid var(--white); background: rgba(255, 255, 255, .96); color: var(--ink); font: inherit; font-weight: 700; font-size: 16px; }
.creator { display: flex; gap: 16px; background: rgba(23, 35, 29, .72); border-radius: 12px; padding: 14px; align-items: center; }
.creator canvas { image-rendering: pixelated; flex: none; background: radial-gradient(circle at 50% 70%, rgba(255, 255, 255, .25), transparent 65%); border-radius: 10px; }
.opts { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.opts label { margin: 6px 0 4px; font-size: 13px; }
.sw { display: flex; flex-wrap: wrap; gap: 6px; }
.sw button { width: 26px; height: 26px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .5); padding: 0; }
.sw button.num { background: rgba(255, 255, 255, .15); color: var(--white); font-weight: 800; font-size: 13px; }
.sw button.wide { width: auto; border-radius: 13px; padding: 0 12px; }
.sw button.on { border-color: var(--gold); box-shadow: 0 0 0 2px var(--gold); }
.auth-err { color: #fff; background: var(--red); border-radius: 6px; font-weight: 700; padding: 0 10px; margin: 10px 0 0; min-height: 0; }
.auth-err:empty { display: none; }
.auth-err:not(:empty) { padding: 6px 10px 4px; }
.go { margin-top: 16px; background: var(--white); color: var(--sign); border: 0; border-radius: 8px; padding: 13px 10px 10px; font-weight: 900; font-size: 18px; box-shadow: 0 0 0 3px var(--sign), 0 0 0 5.5px var(--white); }
.go:disabled { opacity: .6; }
.switch { margin-top: 14px; background: transparent; border: 0; color: var(--white); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 720px) {
  #loc-name { font-size: 17px; } #loc { min-width: 0; padding: 5px 12px 4px; top: 10px; left: 10px; }
  #topright { top: 10px; right: 10px; } #money { font-size: 16px; min-width: 0; padding: 6px 10px 4px; }
  #topright button { width: 38px; height: 38px; font-size: 17px; }
  #loc { max-width: calc(100vw - 262px); } #loc-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }   /* long place names never run under the coin pill */
  #needs { width: 132px; padding: 8px; gap: 4px; right: 10px; bottom: 10px; }
  #chat { width: 56vw; left: 10px; bottom: 10px; } #chat-log { height: 86px; font-size: 12.5px; }
  #activity { top: 62px; min-width: 0; width: 92vw; }
  #toasts { top: 120px; }
  .sign-head h2 { font-size: 21px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- 3D world overlays ---------- */
#game canvas { display: block; }
.labels { position: absolute; inset: 0; pointer-events: none; }
.tag-name { font: 800 12px var(--font); color: #fff; white-space: nowrap; text-shadow: 0 1px 2px rgba(0, 0, 0, .85), 0 0 6px rgba(0, 0, 0, .45); letter-spacing: .01em; }
.tag-name.me { color: var(--gold); }
.tag-emote { font-size: 22px; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .35)); }
.tag-bubble { position: relative; background: #fff; color: var(--ink); font: 700 13px/1.35 var(--font); padding: 6px 10px 4px; border-radius: 12px; max-width: 200px; width: max-content; box-shadow: 0 4px 12px rgba(0, 0, 0, .25); margin-bottom: 10px; word-break: break-word; }
.tag-bubble::after { content: ''; position: absolute; left: 50%; bottom: -7px; margin-left: -7px; border: 7px solid transparent; border-top-color: #fff; border-bottom: 0; }
#wp-arrow { position: fixed; left: 0; top: 0; margin: -18px 0 0 -18px; width: 36px; height: 36px; display: grid; place-items: center; color: var(--gold); font-size: 30px; text-shadow: 0 2px 4px rgba(0, 0, 0, .6); pointer-events: none; }

/* ---------- life checklist ---------- */
#goal { position: fixed; top: 86px; left: 16px; max-width: min(320px, 60vw); text-align: left; font: inherit; font-weight: 800; font-size: 13px; line-height: 1.25;
  color: var(--ink); background: var(--white); border: 0; border-radius: 8px; padding: 7px 11px 6px; box-shadow: 0 0 0 2.5px var(--gold), 0 3px 10px rgba(0, 0, 0, .25); cursor: pointer; }
#goal b { color: var(--sign); margin-left: 4px; white-space: nowrap; }
#goal:hover { transform: translateY(-1px); }
#goal:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.goal-row { display: flex; align-items: center; gap: 10px; padding: 9px 4px; border-bottom: 1px solid rgba(255, 255, 255, .12); }
.goal-row i { flex: none; width: 24px; text-align: center; font-style: normal; font-weight: 900; }
.goal-row div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.goal-row small { opacity: .8; font-weight: 600; margin-top: 2px; }
.goal-row span { font-weight: 800; color: var(--gold); }
.goal-row.done { opacity: .5; } .goal-row.done b { text-decoration: line-through; }
.goal-row.next { background: rgba(242, 194, 48, .14); border-radius: 8px; }
@media (max-width: 640px) { #goal { top: 64px; left: 10px; font-size: 12px; } }

/* ---------- phones & tablets ---------- */
#chat-toggle { display: none; }
#kicked { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 20px; background: rgba(10, 20, 16, .72); }
#kicked .sign { width: min(440px, 100%); }
#hud > * { --sl: env(safe-area-inset-left, 0px); --sr: env(safe-area-inset-right, 0px); --st: env(safe-area-inset-top, 0px); --sb: env(safe-area-inset-bottom, 0px); }
@media (pointer: coarse) {
  html, body { overscroll-behavior: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
  #game canvas { touch-action: none; }
  #loc { top: calc(10px + var(--st)); left: calc(10px + var(--sl)); }
  #goal { top: calc(64px + var(--st)); left: calc(10px + var(--sl)); }
  #topright { top: calc(10px + var(--st)); right: calc(10px + var(--sr)); }
  #topright button { width: 46px; height: 46px; }
  #joy { display: block; left: calc(22px + var(--sl)); bottom: calc(26px + var(--sb)); width: 128px; height: 128px; }
  #joy i { left: 42px; top: 42px; }
  #needs { right: calc(10px + var(--sr)); bottom: calc(10px + var(--sb)); width: 122px; padding: 7px 8px; gap: 3px; }
  #needs .need i { font-size: 13px; }
  #chat-toggle { display: grid; place-items: center; position: fixed; left: calc(166px + var(--sl)); bottom: calc(30px + var(--sb)); width: 48px; height: 48px; border-radius: 50%; border: 2.5px solid var(--white); background: var(--sign); color: var(--white); font-size: 20px; box-shadow: 0 0 0 3px var(--sign); }
  #chat-toggle[data-n]:not([data-n=""])::after { content: attr(data-n); position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px; border-radius: 10px; background: var(--red); color: #fff; font-size: 12px; font-weight: 800; display: grid; place-items: center; padding: 0 4px; }
  #chat { left: calc(10px + var(--sl)); bottom: calc(90px + var(--sb)); width: min(420px, calc(100vw - 20px)); z-index: 5; }
  #chat.collapsed { display: none; }
  #chat-input { font-size: 16px; }   /* stops iOS zooming into the field */
  #prompt { bottom: calc(190px + var(--sb)); font-size: 17px; padding: 12px 18px 10px 12px; }
  #prompt kbd { display: none; }
  #prompt::before { content: '👆'; margin-right: 2px; }
  #activity { top: calc(110px + var(--st)); }
  #wp-arrow { top: calc(150px + var(--st)); }
  .auth-card input, .modal input, #modal input { font-size: 16px; }
  #modal .sign { max-height: calc(100dvh - 24px - var(--st) - var(--sb)); }
}
@media (pointer: coarse) and (orientation: landscape) and (max-height: 500px) {
  #goal { top: calc(10px + var(--st)); left: calc(190px + var(--sl)); }
  #needs { grid-template-columns: 1fr 1fr; width: 200px; }
  #prompt { bottom: calc(40px + var(--sb)); }
  #activity { top: calc(60px + var(--st)); }
  #chat { bottom: calc(10px + var(--sb)); left: calc(230px + var(--sl)); width: min(340px, 40vw); }
  #chat-log { height: 90px; }
  #chat-toggle { left: calc(160px + var(--sl)); bottom: calc(20px + var(--sb)); }
}

/* ================= toy-box finish: rounder, puffier, with a little depth =================
   Same freeway-sign green and white inset border, but every panel is a chunky rounded tile with a
   darker "extrusion" underneath and a soft highlight on top, and buttons press down when tapped. */
:root { --display: "Fredoka", "Overpass", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif; --lip: #003D2D; --gold-deep: #B88A10; }
#loc-name, .sign-head h2, .title-sign h1, #money, .apps button, .go, .sign button, .app button, #prompt, .act-text strong, h3 { font-family: var(--display); }
.sign, #loc, #activity, .title-sign {
  border-radius: 20px; border-width: 3px;
  box-shadow: 0 0 0 4px var(--sign), 0 7px 0 4px var(--lip), inset 0 3px 0 rgba(255, 255, 255, .22), 0 18px 34px rgba(0, 0, 0, .35);
}
#loc { padding: 6px 15px 7px; min-width: 0; border-radius: 16px; }
#loc-name { font-weight: 700; font-size: 20px; letter-spacing: 0; }
#clock { font-size: 13px; }
/* money: a gold coin-pill */
#money { border-radius: 999px; border: 0; padding: 6px 16px 5px; font-weight: 700; font-size: 19px; min-width: 0;
  background: linear-gradient(#FFD95A, var(--gold)); box-shadow: 0 4px 0 var(--gold-deep), inset 0 2px 0 rgba(255, 255, 255, .6), 0 8px 16px rgba(0, 0, 0, .25); }
#money.neg { background: linear-gradient(#FF5A5F, var(--red)); box-shadow: 0 4px 0 #8C0A10, inset 0 2px 0 rgba(255, 255, 255, .4); }
/* round toy buttons */
#topright { gap: 10px; }
#topright button { width: 42px; height: 42px; border-radius: 50%; border: 2.5px solid var(--white); font-size: 18px;
  background: radial-gradient(circle at 35% 30%, #13936E, var(--sign) 60%); box-shadow: 0 4px 0 var(--lip), 0 8px 14px rgba(0, 0, 0, .3); transition: transform .08s, box-shadow .08s; }
#topright button:active, #chat-toggle:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--lip); }
/* compact interact pill */
#prompt { bottom: 21%; gap: 7px; padding: 4px 13px 4px 5px; border-radius: 999px; font-size: 13.5px; font-weight: 600; color: var(--ink);
  background: linear-gradient(#FFFFFF, #EEF5F1); box-shadow: 0 4px 0 #B9CFC4, 0 8px 18px rgba(0, 0, 0, .28); transition: transform .08s; }
#prompt:active { transform: translate(-50%, 3px); }
#prompt kbd { border-radius: 999px; padding: 2px 8px 1px; font-size: 12px; font-family: var(--display); box-shadow: 0 2px 0 var(--lip); }
/* life checklist chip */
#goal { border-radius: 999px; padding: 5px 12px 5px; font-size: 12.5px; font-weight: 600; box-shadow: 0 0 0 2px var(--gold), 0 4px 0 var(--gold-deep), 0 8px 14px rgba(0, 0, 0, .22); }
#goal b { font-family: var(--display); font-weight: 700; }
/* needs: a soft tray with pill gauges */
#needs { border-radius: 18px; background: rgba(20, 34, 28, .78); box-shadow: 0 5px 0 rgba(0, 0, 0, .35), inset 0 2px 0 rgba(255, 255, 255, .08); backdrop-filter: blur(6px); }
.need b { height: 10px; border-radius: 999px; box-shadow: inset 0 2px 2px rgba(0, 0, 0, .35); }
.need s { border-radius: 999px; background: linear-gradient(#6FE6AE, var(--ok)); box-shadow: inset 0 2px 0 rgba(255, 255, 255, .45); }
.need.low s { background: linear-gradient(#FFE07A, var(--gold)); } .need.crit s { background: linear-gradient(#FF7A7E, var(--red)); }
/* chat */
#chat { border-radius: 18px; box-shadow: 0 5px 0 rgba(0, 0, 0, .35); backdrop-filter: blur(6px); }
.chat-tabs button { border-radius: 999px; padding: 3px 11px 2px; }
#chat-input { border-radius: 0 0 18px 18px; }
#chat-toggle { width: 40px !important; height: 40px !important; font-size: 17px !important; border-width: 2px !important;
  background: radial-gradient(circle at 35% 30%, #13936E, var(--sign) 60%) !important; box-shadow: 0 4px 0 var(--lip), 0 8px 14px rgba(0, 0, 0, .3) !important; transition: transform .08s; }
/* activity bar + toasts */
#activity { border-radius: 18px; }
#activity button { border-radius: 999px; box-shadow: 0 3px 0 #B9CFC4; }
.toast { border-radius: 14px; border-left: 0; box-shadow: inset 5px 0 0 var(--white), 0 4px 0 rgba(0, 0, 0, .3), 0 8px 18px rgba(0, 0, 0, .3); }
.toast.ok { box-shadow: inset 5px 0 0 var(--ok), 0 4px 0 rgba(0, 0, 0, .3), 0 8px 18px rgba(0, 0, 0, .3); }
.toast.err { box-shadow: inset 5px 0 0 var(--red), 0 4px 0 rgba(0, 0, 0, .3), 0 8px 18px rgba(0, 0, 0, .3); }
/* panels and their buttons */
.sign-head h2 { font-weight: 700; }
.sign button, .app button, .phone button:not(.exit-tab):not(.back) { border-radius: 999px; font-weight: 600; padding: 6px 14px 5px; box-shadow: 0 3px 0 #B9CFC4; transition: transform .08s, box-shadow .08s; }
.sign button:active, .app button:active { transform: translateY(2px); box-shadow: 0 1px 0 #B9CFC4; }
.sign button.ghost, .app button.ghost { box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .7), 0 3px 0 rgba(0, 0, 0, .25); }
.sign button.wide, .app button.wide { padding: 11px; }
.exit-tab { border-radius: 12px 12px 0 0; font-family: var(--display); font-weight: 600; }
input[type=number], input[type=text], select { border-radius: 999px; padding: 6px 12px 5px; box-shadow: inset 0 2px 3px rgba(0, 0, 0, .18); }
.row.mine, .cloth, .goal-row.next { border-radius: 14px; }
/* phone */
.phone { border-radius: 38px; border-width: 7px; box-shadow: 0 8px 0 #050607, 0 26px 60px rgba(0, 0, 0, .5); }
.apps i { border-radius: 22px; background: radial-gradient(circle at 35% 25%, #16A07A, var(--sign) 65%); border: 2.5px solid rgba(255, 255, 255, .9); box-shadow: 0 5px 0 var(--lip), 0 10px 16px rgba(0, 0, 0, .3); transition: transform .08s, box-shadow .08s; }
.phone .apps button:active i { transform: translateY(3px); box-shadow: 0 2px 0 var(--lip); }
.apps em { border-radius: 999px; }
/* sign-in */
.title-sign h1 { font-weight: 700; }
.go { border-radius: 999px; font-family: var(--display); font-weight: 700; box-shadow: 0 0 0 3px var(--sign), 0 0 0 5.5px var(--white), 0 8px 0 5px var(--lip); }
.go:active { transform: translateY(3px); }
.creator { border-radius: 20px; }
.sw button { box-shadow: 0 3px 0 rgba(0, 0, 0, .35); }
/* joystick: a rubbery thumb pad */
#joy { background: radial-gradient(circle, rgba(255, 255, 255, .06), rgba(255, 255, 255, .18)); border: 3px solid rgba(255, 255, 255, .55); box-shadow: 0 5px 0 rgba(0, 0, 0, .25); }
#joy i { background: radial-gradient(circle at 35% 30%, #FFFFFF, #DCE8E2); box-shadow: 0 4px 0 #9DB5A9, 0 6px 10px rgba(0, 0, 0, .3); }
@media (pointer: coarse) {
  #prompt { font-size: 14px; padding: 6px 14px 6px 10px; bottom: calc(176px + var(--sb, 0px)); }
  #prompt::before { content: ''; }
}
/* in-world labels: small round name chips and compact speech bubbles */
.tag-name { font: 600 11px var(--display); background: rgba(20, 34, 28, .55); padding: 1px 7px 1px; border-radius: 999px; text-shadow: none; }
.tag-name.me { color: #FFE07A; }
.tag-bubble { font: 500 12px/1.3 var(--display); padding: 4px 9px 4px; border-radius: 14px; max-width: 170px; box-shadow: 0 3px 0 #C9D8D0, 0 6px 12px rgba(0, 0, 0, .25); }
.phone .apps button { background: transparent !important; box-shadow: none !important; padding: 0 !important; border-radius: 0 !important; color: var(--white) !important; font-weight: 600 !important; }
.app button.chip { background: rgba(255, 255, 255, .1) !important; color: var(--white) !important; box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .35) !important; }
.app button.chip.on { background: var(--white) !important; color: var(--sign) !important; box-shadow: 0 3px 0 #B9CFC4 !important; }

/* billboard auctions */
.ad-card { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; background: rgba(255, 255, 255, .07); border-radius: 14px; padding: 10px; margin: 8px 0; }
.ad-prev { width: 128px; aspect-ratio: 896 / 364; border-radius: 6px; overflow: hidden; display: grid; place-items: center; box-shadow: 0 0 0 3px #2A2C30, 0 4px 0 3px rgba(0, 0, 0, .25); flex: none; }
.ad-prev.sz-S { width: 54px; aspect-ratio: 256 / 394; }
.ad-prev img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ad-prev b { color: #fff; font-size: 12px; padding: 4px; text-align: center; text-shadow: 0 1px 0 rgba(0, 0, 0, .5); }
.ad-info { flex: 1; min-width: 160px; display: flex; flex-direction: column; gap: 4px; }
.ad-info small { opacity: .8; }
.ad-edit { flex-basis: 100%; display: flex; flex-direction: column; gap: 6px; }
.ad-bid { background: rgba(255, 255, 255, .06); border-radius: 12px; padding: 2px 10px; margin: -4px 0 8px; }
.app label.filebtn { display: inline-block; background: var(--white); color: var(--sign); border-radius: 999px; padding: 6px 14px 5px; font: 600 14px var(--display); box-shadow: 0 3px 0 #B9CFC4; cursor: pointer; }
.app label.filebtn input { display: none; }

/* coin store */
.coin-hero { display: flex; align-items: center; gap: 12px; background: linear-gradient(180deg, #F7D774, #E9B93A); color: #3A2A06; border-radius: 16px; padding: 12px 16px; margin: 4px 0 10px; box-shadow: 0 4px 0 #B88A1C; }
.coin-hero i { font-style: normal; font-size: 34px; }
.coin-hero b { display: block; font: 700 24px var(--display); }
.coin-hero small { opacity: .75; }
.packs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 8px 0 12px; }
.app button.pack { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 10px 4px 8px; border-radius: 14px; position: relative; }
.app button.pack b { font-size: 14px; }
.app button.pack span { font: 600 12px var(--body, inherit); opacity: .8; }
.app button.pack em { position: absolute; top: -6px; right: -4px; background: #E2463A; color: #fff; font: 700 10px var(--display); font-style: normal; padding: 2px 6px; border-radius: 999px; }
.app button.pack[disabled] { opacity: .5; }
.test-pill { color: #F2C230; }

/* Match (swipe app) */
.m-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin: 2px 0 8px; font-size: 13px; opacity: .9; }
.m-matches { display: flex; gap: 8px; overflow-x: auto; padding: 2px 0 10px; }
.app .m-matches button { flex: none; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 10px; border-radius: 16px; position: relative; font-size: 12px; }
.m-matches button i { font-style: normal; font-size: 20px; }
.m-matches button em { position: absolute; top: 6px; right: 6px; width: 9px; height: 9px; border-radius: 50%; background: #3ECF8E; box-shadow: 0 0 0 2px #fff; }
.mstack { position: relative; height: min(400px, 50vh); min-height: 330px; margin: 4px auto 10px; max-width: 340px; touch-action: pan-y; }
.mcard { position: absolute; inset: 0; background: #FFFDF8; color: #24262B; border-radius: 24px; overflow: hidden; box-shadow: 0 6px 0 #D9CDB8, 0 14px 28px rgba(0, 0, 0, .35); cursor: grab; user-select: none; touch-action: none; }
.mcard.under { transform: scale(.94) translateY(14px); opacity: .7; box-shadow: 0 6px 0 #D9CDB8; }
.m-photo { position: relative; height: 46%; background: radial-gradient(circle at 50% 35%, #FFF3D6, #FDD7E2 60%, #F7B6C8); display: grid; place-items: center; }
.m-photo canvas { position: absolute; left: 50%; top: 3%; height: 94%; width: auto; aspect-ratio: 240 / 250; transform: translateX(-50%); }
.stamp { position: absolute; top: 18px; font: 700 26px var(--display); padding: 2px 10px; border: 4px solid; border-radius: 10px; opacity: 0; transition: opacity .1s; }
.stamp.like { left: 16px; color: #2FA866; transform: rotate(-14deg); }
.stamp.nope { right: 16px; color: #E2463A; transform: rotate(14deg); }
.mcard.liking .stamp.like, .mcard.noping .stamp.nope { opacity: 1; }
.m-info { padding: 10px 16px; overflow: hidden; }
.m-info h3 { margin: 0; font: 700 22px var(--display); color: #24262B; border: 0; padding: 0; }
.m-info small { color: #6A6F78; }
.m-info p { margin: 6px 0; font-size: 14px; line-height: 1.35; }
.m-tags, .m-wants { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }
.m-tags span { background: #EFEAE0; border-radius: 999px; padding: 3px 9px; font-size: 12px; }
.m-tags span.same { background: #FFE08A; font-weight: 700; }
.m-wants b { background: #FDE3EA; color: #B83262; border-radius: 999px; padding: 3px 9px; font-size: 12px; }
.m-btns { display: flex; justify-content: center; gap: 28px; margin: 6px 0; }
.app .m-btns button { width: 64px; height: 64px; border-radius: 50%; font-size: 28px; padding: 0; display: grid; place-items: center; }
.app .m-btns .m-no { color: #E2463A !important; font-size: 30px !important; }
.app .m-btns .m-yes { color: #E8467C !important; font-size: 32px !important; }
.m-safety { display: flex; justify-content: center; gap: 8px; opacity: .8; }
.m-empty { text-align: center; padding: 30px 10px; }
.m-empty i { font-style: normal; font-size: 48px; }
.app textarea { width: 100%; box-sizing: border-box; border-radius: 14px; border: 0; padding: 10px 12px; font: inherit; resize: vertical; }
.match-pop { position: fixed; inset: 0; z-index: 60; background: rgba(232, 70, 124, .55); backdrop-filter: blur(4px); display: grid; place-items: center; padding: 16px; }
.mp-card { background: #FFFDF8; color: #24262B; border-radius: 26px; padding: 22px 18px; text-align: center; max-width: 360px; width: 100%; box-shadow: 0 8px 0 #D9CDB8, 0 20px 40px rgba(0, 0, 0, .35); animation: mpop .35s cubic-bezier(.2, 1.4, .4, 1); }
.mp-card h2 { font: 700 34px var(--display); color: #E8467C; margin: 0; }
.mp-avs { display: flex; align-items: center; justify-content: center; gap: 2px; margin: 8px 0 12px; }
.mp-avs canvas { width: 120px; height: 136px; background: radial-gradient(circle, #FFF3D6, #FDD7E2); border-radius: 50%; }
.mp-avs i { font-style: normal; font-size: 30px; }
.mp-card button { display: block; width: 100%; margin: 8px 0 0; padding: 12px; border: 0; border-radius: 999px; font: 600 16px var(--display); }
.mp-hi { background: #E8467C; color: #fff; box-shadow: 0 4px 0 #B8305E; }
.mp-keep { background: #EFEAE0; color: #24262B; }
@keyframes mpop { from { transform: scale(.6); opacity: 0; } }

/* who's inside: badge above each entrance */
.occ-badge { display: flex; align-items: center; gap: 3px; background: #FFFDF8; color: #24262B; border-radius: 999px; padding: 2px 9px 2px 6px; font: 700 13px var(--display); box-shadow: 0 3px 0 #C9BFA8, 0 4px 10px rgba(0, 0, 0, .25); pointer-events: none; transform: translateY(-4px); }
.occ-badge i { font-style: normal; font-size: 12px; }
.occ-badge.empty { opacity: .62; }
.occ-badge:not(.empty) { background: #3ECF8E; color: #0E3A26; box-shadow: 0 3px 0 #2A9A66, 0 4px 10px rgba(0, 0, 0, .25); }
/* decorating */
.deco-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 8px; margin: 6px 0 12px; }
.sign button.deco, .app button.deco { display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 8px 4px 6px; border-radius: 14px; }
button.deco i { font-style: normal; font-size: 24px; }
button.deco span { font-size: 12px; line-height: 1.1; text-align: center; }
button.deco small { font-size: 11px; opacity: .75; }
#loc-name { max-width: min(46vw, 420px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 600px) { #loc-name { max-width: 34vw; } }

.cut { display: flex; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
.cut canvas { width: 96px; height: 120px; background: radial-gradient(circle, #FFF3D6, #F2DCC0); border-radius: 18px; }
.cut > div { flex: 1; min-width: 180px; }
.sign button.chip { background: rgba(255, 255, 255, .1) !important; color: var(--white) !important; box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .35) !important; font-size: 13px; padding: 5px 11px 4px; }
.sign button.chip.on { background: var(--white) !important; color: var(--sign) !important; box-shadow: 0 3px 0 #B9CFC4 !important; }

/* ---------- social: family tree + relationships ---------- */
.bar.rel s { background: #FF9EC4; } .bar.rom s { background: #FF4F8B; }
.ftree { display: flex; flex-direction: column; align-items: center; gap: 0; padding: 12px 6px 14px; margin: 4px 0 6px; border-radius: 10px; background: rgba(255, 255, 255, .06); }
.ftree.empty { padding: 4px 12px; }
.ftree .fr { display: flex; justify-content: center; align-items: flex-end; gap: 8px; flex-wrap: wrap; position: relative; }
.ftree .fl { display: block; width: 2px; height: 14px; background: rgba(255, 255, 255, .5); }
.ftree .fr.up::after, .ftree .fr.down::before { content: ""; position: absolute; left: 22%; right: 22%; height: 2px; background: rgba(255, 255, 255, .5); }
.ftree .fr.up::after { bottom: -2px; } .ftree .fr.down::before { top: -2px; }
.ftree .fr.up:has(> .fn:only-child)::after, .ftree .fr.down:has(> .fn:only-child)::before { display: none; }
.app .fn { display: flex; flex-direction: column; align-items: center; width: 78px; border-radius: 12px; box-shadow: none; padding: 4px 2px 5px; background: rgba(0, 0, 0, .18); border: 2px solid rgba(255, 255, 255, .25); border-radius: 9px; color: inherit; font: inherit; cursor: pointer; }
.fn.on { border-color: var(--ok); } .fn.me { border-color: var(--gold); background: rgba(242, 194, 48, .14); cursor: default; } .fn.mate { border-color: #FF7FB0; } .fn.sib { opacity: .95; }
.fn canvas { width: 46px; height: 58px; } .fn .ph { font-size: 30px; font-style: normal; line-height: 58px; }
.fn b { font-size: 12.5px; max-width: 72px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .fn small { font-size: 11px; opacity: .8; white-space: nowrap; }
.ftree .heart { font-style: normal; font-size: 20px; align-self: center; margin: 0 -4px; }
.relrow { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 2px; background: none; border: 0; border-bottom: 1px solid rgba(255, 255, 255, .13); color: inherit; font: inherit; text-align: left; cursor: pointer; }
.relrow > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; } .relrow small { font-size: 12.5px; opacity: .8; } .relrow > span { font-size: 22px; opacity: .6; }
.rel-strip { margin: 8px 0 4px; padding: 8px 10px; border-radius: 8px; background: rgba(255, 255, 255, .07); } .rel-strip > b { display: block; margin-bottom: 4px; }
.rel-head { display: flex; gap: 12px; align-items: center; margin-bottom: 6px; } .rel-head canvas { width: 70px; height: 87px; } .rel-head h3 { margin: 0; border: 0; padding: 0; } .rel-head p { margin: 2px 0; }
em.live { font-style: normal; font-size: 11px; font-weight: 800; padding: 1px 6px; border-radius: 9px; background: var(--red); color: #fff; vertical-align: 2px; }
label.chk { display: flex; gap: 8px; align-items: center; font-size: 13.5px; padding: 6px 0; } label.chk input { width: 18px; height: 18px; accent-color: var(--gold); }
.app select { max-width: 190px; }
.sw.hairs { gap: 5px; } .sw.hairs button.num { width: auto; height: 24px; border-radius: 12px; padding: 0 9px; font-size: 11.5px; font-weight: 700; white-space: nowrap; }
/* pet shop: coat swatches */
.coats { display: inline-flex; gap: 6px; margin-left: 8px; vertical-align: middle; }
.coat { width: 26px; height: 26px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.25); padding: 0; cursor: pointer; }
.coat:hover:not([disabled]) { transform: scale(1.12); }
.coat[disabled] { opacity: .35; cursor: default; }

@media (max-width: 430px) { #loc-name { font-size: 15px; } #loc { max-width: calc(100vw - 250px); } }

button.armed { background: var(--red) !important; color: var(--white) !important; }

/* ---- toy pictures (public/js/icons.js) ---- */
.ic { display: inline-block; width: 1.45em; height: 1.45em; background-repeat: no-repeat; vertical-align: -0.4em; flex: none; margin: 0 0.06em; }
.tag-emote .ic { width: 38px; height: 38px; vertical-align: middle; filter: drop-shadow(0 2px 2px rgba(60, 40, 20, 0.25)); }


/* ---------- picture tiles + colour dots (character creator, barber, wardrobe) ---------- */
:is(#auth, #modal) .cc-sub { margin: 0 2px 8px; font: 800 13px var(--font); color: var(--ui-text2, #725D42); }
:is(#auth, #modal) .cc-sub:not(:first-child) { margin-top: 16px; }
:is(#auth, #modal) .cc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
:is(#auth, #modal) .cc-tile { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 6px 9px; border-radius: 18px; border: 2px solid #E6D3B3;
  background: #FFFDF6; color: #794F27; font: 700 12.5px/1.2 var(--font); text-align: center; transition: transform .15s cubic-bezier(0.4, 0, 0.2, 1), border-color .15s; }
:is(#auth, #modal) .cc-tile:hover { transform: translateY(-2px); border-color: #3DD4C6; }
:is(#auth, #modal) .cc-tile .cc-pic { width: 74px; height: 74px; margin: 0; border-radius: 14px; }
:is(#auth, #modal) .cc-tile span { min-height: 2.4em; display: flex; align-items: center; }
:is(#auth, #modal) .cc-tile.on { border: 3px solid #19C8B9; background: #E6F9F6; padding: 7px 5px 8px; color: #1E6E64; }
:is(#auth, #modal) .cc-nopic { display: block; background: #F3E6CF; }
:is(#auth, #modal) .cc-check { position: absolute; top: -7px; right: -7px; width: 24px; height: 24px; border-radius: 50%; background: #19C8B9; border: 2px solid #FFFDF6; display: none; z-index: 1; }
:is(#auth, #modal) .cc-check::after { content: ""; position: absolute; left: 6px; top: 2.5px; width: 5px; height: 10px; border: solid #FFFFFF; border-width: 0 3px 3px 0; transform: rotate(45deg); }
:is(#auth, #modal) .on > .cc-check { display: block; }
:is(#auth, #modal) .cc-swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 12px; padding-top: 4px; }
:is(#auth, #modal) .cc-swatch { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; background: none; border: 0; padding: 4px 0; color: inherit; font: 700 12.5px var(--font); }
:is(#auth, #modal) .cc-swatch i { width: 52px; height: 52px; border-radius: 50%; border: 3px solid #FFFDF6; box-shadow: 0 0 0 2px #E6D3B3, inset 0 -4px 0 rgba(0, 0, 0, .12);
  background: radial-gradient(circle at 34% 30%, rgba(255, 255, 255, .75) 0 12%, rgba(255, 255, 255, 0) 36%), var(--c); }
:is(#auth, #modal) .cc-swatch.on i { box-shadow: 0 0 0 3px #19C8B9, inset 0 -4px 0 rgba(0, 0, 0, .12); }
:is(#auth, #modal) .cc-swatch .cc-check { top: 0; right: calc(50% - 34px); }
#modal .cc-grid, #modal .cc-swatches { margin: 6px 0 12px; }
#modal .cc-sub { color: inherit; opacity: .92; }

/* ---------- sign-up: three steps on one cream card over the blurred street ---------- */
#auth.cc-on { isolation: isolate; padding: 24px 16px; background: #F4E3C7; }
#auth.cc-on::before { content: ""; position: fixed; inset: -30px; z-index: -1; background: url("/img/title.jpg") center / cover no-repeat; filter: blur(8px) saturate(1.06); }
#auth.cc-on::after { content: ""; position: fixed; inset: 0; z-index: -1; background: rgba(255, 246, 230, .28); }
#auth .cc-card { width: min(1180px, 100%); background: #FBF3E4; border: 2px solid #E6D3B3; border-radius: 28px; box-shadow: 0 18px 50px rgba(80, 55, 30, .25);
  padding: 18px 24px 0; font-family: var(--font); color: #794F27; display: flex; flex-direction: column; }
#auth .cc-card.cc-enter { animation: cc-zoom .3s cubic-bezier(0.4, 0, 0.2, 1) both; }
#auth .cc-card.cc-signin { width: min(480px, 100%); }
@keyframes cc-zoom { from { opacity: 0; transform: scale(.92); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { #auth .cc-card { animation: none; } }
#auth button { font-family: var(--font); cursor: pointer; }
#auth button:focus-visible, #auth input:focus-visible { outline: 3px solid #FFCC00; outline-offset: 2px; }

/* header: mark + title, language, step pills */
#auth .cc-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 14px; border-bottom: 2px dashed #E6D3B3; }
#auth .cc-brand { display: flex; align-items: center; gap: 14px; min-width: 0; }
#auth .cc-mark { position: relative; flex: none; width: 60px; height: 60px; border-radius: 18px; overflow: hidden; border: 2px solid #E6D3B3; background: linear-gradient(180deg, #BFE4F6 0%, #E5F3F7 55%, #FDE7C6 100%); }
#auth .cc-mark .ic { position: absolute; margin: 0; }
#auth .cc-mark-sky { width: 62px; height: 62px; right: -10px; bottom: -10px; }
#auth .cc-mark-palm { width: 46px; height: 46px; left: -6px; bottom: -4px; }
#auth .cc-brand h1 { margin: 0; font: 900 28px/1.1 var(--font); color: #1E6E64; }
#auth .cc-brand p { margin: 3px 0 0; font: 700 14px/1.3 var(--font); color: #9F7A52; }
#auth .cc-top-r { display: flex; align-items: center; gap: 14px; flex: none; }
#auth .cc-lang { display: flex; gap: 2px; background: #F3E6CF; border-radius: 50px; padding: 3px; }
#auth .cc-lang button { border: 0; background: none; color: #725D42; border-radius: 50px; padding: 5px 11px; font-weight: 800; font-size: 12px; }
#auth .cc-lang button.on { background: #FFFDF6; color: #1E6E64; box-shadow: 0 1px 3px rgba(61, 52, 40, .12); }
#auth .cc-steps { list-style: none; display: flex; align-items: center; gap: 6px; margin: 0; padding: 0; }
#auth .cc-step { display: flex; align-items: center; gap: 8px; border-radius: 50px; padding: 5px 15px 5px 5px; background: #FFFDF6; border: 2px solid #E6D3B3; color: #725D42; font-weight: 800; font-size: 14px; }
#auth .cc-step b { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: #F3E6CF; color: #794F27; font-weight: 900; font-size: 13px; }
#auth .cc-step.on { background: #1E6E64; border-color: #1E6E64; color: #FFFFFF; }
#auth .cc-step.on b { background: #FFFFFF; color: #1E6E64; }
#auth .cc-step.done b { background: #19C8B9; color: #FFFFFF; }
#auth .cc-step:disabled { cursor: default; }
#auth .cc-dash { width: 22px; border-top: 2px dashed #D9C29C; }

#auth .cc-main { padding: 18px 0; }
#auth .cc-label { display: block; font-weight: 800; font-size: 14px; color: #725D42; margin: 14px 4px 6px; text-shadow: none; }
#auth .cc-card input { width: 100%; border-radius: 50px; border: 2px solid #E6D3B3; background: #FFFDF6; color: #794F27; font: 700 16px var(--font); padding: 11px 18px; }
#auth .cc-card input:focus { outline: 3px solid #FFCC00; outline-offset: 1px; border-color: #F5C31C; }
#auth .cc-err { min-height: 0; margin: 8px 4px 0; color: #C2453F; font-weight: 800; font-size: 14px; }
#auth .cc-err:empty { display: none; }
#auth .cc-link { background: none; border: 0; padding: 6px 4px; color: #1E6E64; font-weight: 800; font-size: 14px; text-decoration: underline; text-underline-offset: 3px; align-self: flex-start; }
#auth .cc-chev { display: inline-block; width: 9px; height: 9px; border: solid currentColor; border-width: 0 0 3px 3px; border-radius: 1px; transform: rotate(45deg); }
#auth .cc-chev.r { transform: rotate(-135deg); }

/* mint game button with a pressed-down edge */
#auth .cc-mint, #auth .cc-go { border: 0; border-radius: 50px; background: #19C8B9; color: #FFFFFF; font-weight: 900; box-shadow: 0 5px 0 0 #11A89B; transition: transform .15s cubic-bezier(0.4, 0, 0.2, 1), box-shadow .15s; }
#auth .cc-mint:hover, #auth .cc-go:hover { background: #3DD4C6; transform: translateY(-1px); box-shadow: 0 6px 0 0 #11A89B; }
#auth .cc-mint:active, #auth .cc-go:active { transform: translateY(3px); box-shadow: 0 2px 0 0 #11A89B; }
#auth .cc-go:disabled { opacity: .6; }
#auth .cc-mint.sm { flex: none; padding: 0 18px; font-size: 15px; }

/* step 1: presets | live preview on a pedestal | tabs + tiles */
#auth .cc-s1 { display: grid; grid-template-columns: 250px minmax(260px, 1fr) 410px; grid-template-areas: "left center right"; gap: 20px; align-items: start; }
#auth .cc-left { grid-area: left; } #auth .cc-center { grid-area: center; } #auth .cc-right { grid-area: right; min-width: 0; }
#auth .cc-presets { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
#auth .cc-preset { position: relative; display: flex; flex-direction: column; align-items: center; padding: 0 0 6px; border-radius: 18px; border: 2px solid #E6D3B3; background: #FFFDF6; transition: transform .15s, border-color .15s; }
#auth .cc-preset:hover { transform: translateY(-2px); }
#auth .cc-preset-tag { align-self: stretch; background: #1E6E64; color: #FFF6E3; font-weight: 800; font-size: 14px; padding: 6px 0 5px; border-radius: 15px 15px 0 0; text-align: center; }
#auth .cc-preset-pic { width: 100%; max-width: 118px; height: auto; aspect-ratio: 118 / 150; }
#auth .cc-preset.on { border: 3px solid #19C8B9; box-shadow: 0 0 0 4px rgba(25, 200, 185, .16); }
#auth .cc-preset.on .cc-preset-tag { border-radius: 14px 14px 0 0; }
#auth .cc-name { display: flex; gap: 8px; }
#auth .cc-name input { min-width: 0; }

#auth .cc-stagebox { position: relative; width: 100%; max-width: 330px; margin: 0 auto; aspect-ratio: 300 / 420; }
#auth .cc-stagebox canvas { position: relative; display: block; width: 100%; height: 100%; }
#auth .cc-pedestal { position: absolute; left: 13%; right: 13%; bottom: 2.5%; height: 15%; border-radius: 50%; background: #E5CFA9; box-shadow: 0 10px 22px rgba(120, 88, 48, .2); }
#auth .cc-pedestal::before { content: ""; position: absolute; inset: 0 0 22% 0; border-radius: 50%; background: radial-gradient(ellipse at 50% 38%, #FFFFFF 0%, #FCF2DF 62%, #F3E2C3 100%); box-shadow: inset 0 -2px 0 rgba(255, 255, 255, .7); }
#auth .cc-turn { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 10px; font-weight: 800; font-size: 15px; color: #1E6E64; }
#auth .cc-sq { width: 46px; height: 46px; border-radius: 14px; border: 0; background: #1E6E64; color: #FFFFFF; display: grid; place-items: center; box-shadow: 0 4px 0 0 #155850; transition: transform .15s, box-shadow .15s; }
#auth .cc-sq:hover { transform: translateY(-1px); } #auth .cc-sq:active { transform: translateY(3px); box-shadow: 0 1px 0 0 #155850; }
#auth .cc-sq .cc-chev.l { margin-left: 4px; } #auth .cc-sq .cc-chev.r { margin-right: 4px; }

#auth .cc-tabs2 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
#auth .cc-pill { border-radius: 50px; border: 2px solid #E6D3B3; background: #FFFDF6; color: #725D42; font-weight: 800; font-size: 15px; padding: 9px 0; transition: background .15s, color .15s; }
#auth .cc-pill:hover { border-color: #3DD4C6; }
#auth .cc-pill.on { background: #1E6E64; border-color: #1E6E64; color: #FFFFFF; }
#auth .cc-body { margin-top: 12px; height: 470px; overflow-y: auto; padding: 8px 8px 8px; margin-left: -8px; margin-right: -8px; scrollbar-width: thin; scrollbar-color: #E6D3B3 transparent; }
#auth .cc-grid.heads { grid-template-columns: repeat(3, 1fr); max-height: 296px; overflow-y: auto; padding: 8px; margin: -8px -8px 8px; scrollbar-width: thin; scrollbar-color: #E6D3B3 transparent; }
#auth .cc-grid.heads .cc-pic { width: 90px; height: 90px; }
#auth .cc-grid.small { grid-template-columns: repeat(4, 1fr); gap: 8px; }
#auth .cc-grid.small .cc-pic { width: 62px; height: 62px; }
#auth .cc-grid.small .cc-tile { font-size: 12px; }
#auth .cc-well { display: flex; flex-wrap: wrap; gap: 10px; background: #F3E6CF; border-radius: 22px; padding: 12px 14px; }
#auth .cc-dot { position: relative; width: 40px; height: 40px; padding: 0; border-radius: 50%; border: 3px solid #FFFDF6; box-shadow: 0 0 0 1.5px #E0C9A2, inset 0 -3px 0 rgba(0, 0, 0, .12);
  background: radial-gradient(circle at 34% 30%, rgba(255, 255, 255, .72) 0 12%, rgba(255, 255, 255, 0) 36%), var(--c); transition: transform .15s; }
#auth .cc-dot:hover { transform: translateY(-2px); }
#auth .cc-dot.on { box-shadow: 0 0 0 3px #19C8B9, inset 0 -3px 0 rgba(0, 0, 0, .12); }
#auth .cc-dot .cc-check { width: 20px; height: 20px; top: -9px; right: -9px; }
#auth .cc-dot .cc-check::after { left: 5px; top: 1.5px; width: 4px; height: 9px; }
#auth .cc-well.big { gap: 14px; } #auth .cc-well.big .cc-dot { width: 54px; height: 54px; }

/* bottom bar */
#auth .cc-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0 20px; border-top: 2px dashed #E6D3B3; }
#auth .cc-out { display: inline-flex; align-items: center; gap: 10px; border: 2px solid #1E6E64; background: #FFFDF6; color: #1E6E64; border-radius: 50px; padding: 11px 22px 11px 18px; font-weight: 800; font-size: 16px; }
#auth .cc-out:hover { background: #FFFFFF; }
#auth .cc-hint { flex: 1; margin: 0; text-align: center; color: #9F927D; font-weight: 700; font-size: 14px; }
#auth .cc-go { display: inline-flex; align-items: center; gap: 12px; padding: 14px 26px 14px 30px; font-size: 17px; }

/* step 2: four starter towers, three floor plans */
#auth .cc-s2 { display: flex; flex-direction: column; gap: 10px; }
#auth .cc-s2 .cc-h2 { margin-top: 2px; }
#auth .cc-towers { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
#auth .cc-tower { position: relative; display: flex; flex-direction: column; padding: 0; text-align: left; border: 2px solid #E6D3B3; border-radius: 22px; background: #FFFDF6; color: #794F27; transition: transform .15s, border-color .15s; }
#auth .cc-tower:hover { transform: translateY(-2px); border-color: #3DD4C6; }
#auth .cc-tower-pic { display: grid; place-items: center; height: 118px; border-radius: 20px 20px 0 0; }
#auth .cc-tower-pic .cc-tower-ic { width: 104px; height: 104px; margin: 0; }
#auth .cc-tower-txt { display: flex; flex-direction: column; gap: 3px; padding: 10px 14px 12px; }
#auth .cc-tower-txt strong { font-weight: 900; font-size: 18px; color: #1E6E64; }
#auth .cc-tower-txt span { font-weight: 700; font-size: 13.5px; line-height: 1.35; color: #725D42; }
#auth .cc-tower-txt small { font-weight: 700; font-size: 12px; color: #9F927D; margin-top: 2px; }
#auth .cc-tower.on, #auth .cc-plan.on { border: 3px solid #19C8B9; box-shadow: 0 0 0 4px rgba(25, 200, 185, .16); }
#auth .cc-tower.on .cc-tower-pic { border-radius: 19px 19px 0 0; }
#auth .cc-plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
#auth .cc-plan { position: relative; display: flex; align-items: center; gap: 14px; padding: 10px 14px; text-align: left; border: 2px solid #E6D3B3; border-radius: 20px; background: #FFFDF6; color: #794F27; transition: transform .15s, border-color .15s; }
#auth .cc-plan:hover { transform: translateY(-2px); border-color: #3DD4C6; }
#auth .cc-plan-svg { flex: none; width: 128px; height: auto; }
#auth .cc-plan-txt { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
#auth .cc-plan-txt strong { display: flex; align-items: center; gap: 8px; font-weight: 900; font-size: 16px; color: #1E6E64; }
#auth .cc-plan-letter { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: #1E6E64; color: #FFFFFF; font-size: 13px; flex: none; }
#auth .cc-plan-txt > span { font-weight: 700; font-size: 13px; line-height: 1.35; color: #725D42; }
#auth .cc-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 2px 4px 0; font-weight: 700; font-size: 12.5px; color: #9F927D; }
#auth .cc-legend span { display: inline-flex; align-items: center; gap: 6px; }
#auth .cc-legend i { width: 12px; height: 12px; border-radius: 4px; }

/* step 3: account + summary; sign-in */
#auth .cc-s3 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 22px; max-width: 900px; width: 100%; margin: 0 auto; align-items: start; }
#auth .cc-summary { display: flex; align-items: center; gap: 18px; background: #FFFDF6; border: 2px solid #E6D3B3; border-radius: 24px; padding: 16px 20px; }
#auth .cc-sum-pic { flex: none; width: 150px; height: 190px; border-radius: 18px; background: radial-gradient(ellipse 60% 18% at 50% 90%, #F3E2C3, transparent 70%), #FBF3E4; }
#auth .cc-sum-txt { display: flex; flex-direction: column; gap: 6px; min-width: 0; font-weight: 700; color: #725D42; }
#auth .cc-sum-txt strong { font-weight: 900; font-size: 26px; color: #1E6E64; overflow-wrap: anywhere; }
#auth .cc-sum-txt .ic { width: 26px; height: 26px; margin: 0 4px 0 0; }
#auth .cc-account { display: flex; flex-direction: column; }
#auth .cc-h2 { margin: 0 4px 2px; font-weight: 900; font-size: 20px; color: #1E6E64; }
#auth .cc-signin .cc-main { padding: 8px 0 18px; }

/* phone: one column, big preview first, sticky back / next bar */
@media (max-width: 860px) {
  #auth.cc-on { padding: 10px 8px 0; place-items: start center; }
  #auth .cc-card { padding: 12px 12px 0; border-radius: 22px; }
  #auth .cc-top { flex-wrap: wrap; gap: 10px; padding-bottom: 10px; }
  #auth .cc-brand { gap: 10px; flex: 1 1 auto; }
  #auth .cc-mark { width: 44px; height: 44px; border-radius: 14px; }
  #auth .cc-mark-sky { width: 46px; height: 46px; } #auth .cc-mark-palm { width: 34px; height: 34px; }
  #auth .cc-brand h1 { font-size: 21px; } #auth .cc-brand p { font-size: 12px; }
  #auth .cc-top-r { width: 100%; justify-content: space-between; gap: 8px; }
  #auth .cc-steps { gap: 4px; }
  #auth .cc-step { padding: 3px; font-size: 13px; } #auth .cc-step.on { padding-right: 12px; }
  #auth .cc-step:not(.on) span { display: none; }
  #auth .cc-dash { width: 12px; }
  #auth .cc-main { padding: 12px 0; }
  #auth .cc-s1 { grid-template-columns: 1fr; grid-template-areas: "center" "left" "right"; gap: 12px; }
  #auth .cc-stagebox { max-width: 196px; }
  #auth .cc-turn { margin-top: 4px; gap: 12px; font-size: 14px; }
  #auth .cc-sq { width: 40px; height: 40px; border-radius: 12px; }
  #auth .cc-presets { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  #auth .cc-preset { flex-direction: row; padding: 0; overflow: hidden; }
  #auth .cc-preset-tag { align-self: stretch; writing-mode: vertical-rl; padding: 0 6px; border-radius: 15px 0 0 15px; font-size: 13px; display: grid; place-items: center; }
  #auth .cc-preset.on .cc-preset-tag { border-radius: 14px 0 0 14px; }
  #auth .cc-preset-pic { width: 64px; max-width: none; margin: 4px auto; }
  #auth .cc-preset .cc-check { top: 4px; right: 4px; }
  #auth .cc-label { margin-top: 10px; }
  #auth .cc-body { height: auto; overflow: visible; margin: 10px 0 0; padding: 4px 0; }
  #auth .cc-grid.heads { max-height: none; overflow: visible; margin: 0 0 8px; padding: 0; gap: 8px; }
  #auth .cc-grid.heads .cc-pic { width: 70px; height: 70px; }
  #auth .cc-grid.small { grid-template-columns: repeat(auto-fill, minmax(74px, 1fr)); }
  #auth .cc-grid.small .cc-pic { width: 54px; height: 54px; }
  #auth .cc-pill { font-size: 14px; padding: 8px 0; }
  #auth .cc-dot { width: 36px; height: 36px; }
  #auth .cc-bar { position: sticky; bottom: 0; z-index: 5; background: #FBF3E4; margin: 0 -12px; padding: 10px 12px calc(12px + env(safe-area-inset-bottom)); gap: 10px; border-radius: 0; box-shadow: 0 -6px 16px rgba(80, 55, 30, .08); }
  #auth .cc-hint { display: none; }
  #auth .cc-out { padding: 11px 16px 11px 14px; font-size: 15px; }
  #auth .cc-go { flex: 1; justify-content: center; padding: 13px 16px; font-size: 16px; }
  #auth .cc-s3 { grid-template-columns: 1fr; gap: 12px; }
  #auth .cc-towers { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  #auth .cc-tower-pic { height: 84px; } #auth .cc-tower-pic .cc-tower-ic { width: 76px; height: 76px; }
  #auth .cc-tower-txt { padding: 8px 10px 10px; } #auth .cc-tower-txt strong { font-size: 16px; } #auth .cc-tower-txt span { font-size: 12.5px; }
  #auth .cc-plans { grid-template-columns: 1fr; gap: 8px; }
  #auth .cc-plan { padding: 8px 12px; } #auth .cc-plan-svg { width: 96px; }
  #auth .cc-summary { padding: 12px; gap: 12px; }
  #auth .cc-sum-pic { width: 110px; height: 140px; }
}
#auth.cc-on { place-items: start center; }
#auth .cc-card { margin: auto 0; }
@media (min-width: 861px) { #auth .cc-card:not(.cc-signin) .cc-main { min-height: 548px; display: flex; flex-direction: column; justify-content: center; } }
#auth .cc-well:not(.big) { gap: 6px; } #auth .cc-well:not(.big) .cc-dot { width: 36px; height: 36px; }
