/* 더시드 계정 화면 — 로그인 · 가입 · 내 계정 · 앱 연동 (2026-10-29)
   새 홈과 같은 어두운 바탕 · 유리. 글자 · 버튼은 애니메이션이 끝나기 전에도 보이고 눌림 */
:root {
  --bg: #05070d; --fg: #f2f4f8; --sub: rgba(242,244,248,.62); --faint: rgba(242,244,248,.38);
  --blue: #8fd3f4; --gold: #d6a55c; --red: #ff8a80; --ok: #7ee0a8;
  --line: rgba(255,255,255,.12); --field: rgba(255,255,255,.05); --field-hi: rgba(255,255,255,.08);
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif;
  --ease: cubic-bezier(.22,1,.36,1);
}
* { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body { min-height: 100vh; min-height: 100dvh; background: var(--bg); color: var(--fg); font-family: var(--sans); word-break: keep-all;
  -webkit-font-smoothing: antialiased; display: flex; flex-direction: column; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* 바탕 — 새 홈과 같은 빛 번짐 */
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden;
  background: radial-gradient(circle at 1px 1px, rgba(255,255,255,.06) 1px, transparent 0) 0 0 / 28px 28px, var(--bg); }
.bg i { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .45; }
.bg i:nth-child(1) { width: 50vmax; height: 50vmax; left: -18vmax; top: -16vmax; background: radial-gradient(circle, #2c7fb8, transparent 65%); }
.bg i:nth-child(2) { width: 44vmax; height: 44vmax; right: -16vmax; bottom: -18vmax; background: radial-gradient(circle, #a8732f, transparent 65%); }

/* 위 막대 */
.top { position: sticky; top: 0; z-index: 5; height: 52px; display: flex; align-items: center; gap: 26px; padding: 0 max(16px, calc(50% - 560px));
  background: rgba(5,7,13,.7); -webkit-backdrop-filter: blur(20px) saturate(170%); backdrop-filter: blur(20px) saturate(170%);
  border-bottom: 1px solid rgba(255,255,255,.07); font-size: 14px; }
.top .logo { display: flex; align-items: center; gap: 9px; font-weight: 700; letter-spacing: .08em; }
.top .logo img { width: 18px; }
.top nav { display: flex; gap: 22px; color: var(--sub); }
.top nav a { transition: color .2s; } .top nav a:hover { color: var(--fg); }
.top .who { margin-left: auto; color: var(--sub); transition: color .2s; display: flex; align-items: center; gap: 8px; }
.top .who:hover { color: var(--fg); }
.top .who .dot { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 700; color: #05070d;
  background: linear-gradient(135deg, var(--blue), var(--gold)); }
@media (max-width: 640px) { .top { gap: 14px; } .top nav { display: none; } }

/* 가운데 카드 */
main { flex: 1; display: grid; place-items: start center; padding: clamp(32px, 9vh, 88px) 16px 64px; }
.card { width: 100%; max-width: 420px; padding: 36px 32px 30px; border-radius: 24px;
  background: linear-gradient(160deg, rgba(255,255,255,.08), rgba(255,255,255,.03));
  border: 1px solid var(--line); box-shadow: inset 0 1px 0 rgba(255,255,255,.16), 0 30px 80px rgba(0,0,0,.45);
  -webkit-backdrop-filter: blur(28px) saturate(160%); backdrop-filter: blur(28px) saturate(160%);
  animation: up .6s var(--ease) both; }
.card.wide { max-width: 560px; }
@keyframes up { from { opacity: 0; transform: translateY(10px); } }
@media (max-width: 480px) { .card { padding: 28px 20px 24px; border-radius: 20px; } }
.emb { width: 40px; margin-bottom: 18px; filter: drop-shadow(0 0 14px rgba(143,211,244,.4)); }
h1 { font-size: 26px; font-weight: 700; letter-spacing: -.01em; line-height: 1.25; }
.lead { margin-top: 8px; font-size: 14.5px; line-height: 1.6; color: var(--sub); }

/* 알림 띠 */
.note { margin-top: 18px; padding: 12px 14px; border-radius: 12px; font-size: 13.5px; line-height: 1.55;
  background: rgba(143,211,244,.08); border: 1px solid rgba(143,211,244,.22); color: var(--fg); }
.note.bad { background: rgba(255,138,128,.08); border-color: rgba(255,138,128,.28); }
.note.ok { background: rgba(126,224,168,.08); border-color: rgba(126,224,168,.28); }
.note[hidden] { display: none; }

/* 칸 */
form { margin-top: 24px; display: grid; gap: 16px; }
.field { display: grid; gap: 7px; }
.field > span { font-size: 13px; font-weight: 500; color: var(--sub); display: flex; justify-content: space-between; align-items: baseline; }
.field > span small { font-size: 12px; color: var(--faint); font-weight: 400; }
.input { position: relative; }
.input input { width: 100%; height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--field);
  font-size: 16px; outline: none; transition: border-color .2s, background .2s, box-shadow .2s; }
.input input::placeholder { color: var(--faint); }
.input input:hover { background: var(--field-hi); }
.input input:focus { border-color: rgba(143,211,244,.7); background: var(--field-hi); box-shadow: 0 0 0 4px rgba(143,211,244,.14); }
.input input[aria-invalid="true"] { border-color: rgba(255,138,128,.7); box-shadow: 0 0 0 4px rgba(255,138,128,.1); }
.input input:disabled { opacity: .5; }
.input .eye { position: absolute; right: 6px; top: 6px; height: 36px; padding: 0 10px; border: 0; border-radius: 8px; background: none;
  font-size: 12.5px; color: var(--sub); cursor: pointer; }
.input .eye:hover { color: var(--fg); background: rgba(255,255,255,.06); }
.input:has(.eye) input { padding-right: 64px; }
.err { min-height: 0; font-size: 12.5px; color: var(--red); line-height: 1.45; }
.err:empty { display: none; }
.hint { font-size: 12.5px; color: var(--faint); line-height: 1.45; }

/* 동의 */
.agree { display: grid; gap: 2px; padding: 6px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255,255,255,.025); }
.check { display: flex; align-items: center; gap: 11px; padding: 9px 8px; border-radius: 9px; cursor: pointer; font-size: 14px; }
.check:hover { background: rgba(255,255,255,.04); }
.check.all { font-weight: 700; border-bottom: 1px solid rgba(255,255,255,.07); border-radius: 9px 9px 0 0; padding-bottom: 11px; margin-bottom: 4px; }
.check input { appearance: none; -webkit-appearance: none; flex: 0 0 auto; width: 20px; height: 20px; border-radius: 6px; border: 1.5px solid rgba(255,255,255,.3);
  display: grid; place-items: center; cursor: pointer; transition: background .15s, border-color .15s; }
.check input::after { content: ''; width: 10px; height: 6px; border: solid #05070d; border-width: 0 0 2px 2px; transform: rotate(-45deg) translate(1px, -1px) scale(0); transition: transform .2s var(--ease); }
.check input:checked { background: var(--blue); border-color: var(--blue); }
.check input:checked::after { transform: rotate(-45deg) translate(1px, -1px) scale(1); }
.check input:focus-visible { box-shadow: 0 0 0 3px rgba(143,211,244,.35); }
.check em { font-style: normal; font-size: 12px; color: var(--faint); }
.check em.must { color: var(--blue); }
.check .view { margin-left: auto; font-size: 12.5px; color: var(--faint); background: none; border: 0; cursor: pointer; padding: 4px 6px; border-radius: 6px; }
.check .view:hover { color: var(--fg); background: rgba(255,255,255,.06); }

/* 버튼 */
.btn { position: relative; display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; height: 50px; border-radius: 999px; border: 0;
  font-size: 15.5px; font-weight: 700; cursor: pointer; transition: transform .12s, filter .2s, opacity .2s, background .2s; }
.btn:active { transform: scale(.98); }
.btn:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }
.btn.main { background: linear-gradient(135deg, #b7e4fa, var(--blue)); color: #05070d; }
.btn.main:hover:not([disabled]) { filter: brightness(1.06); }
.btn.line { background: rgba(255,255,255,.06); border: 1px solid var(--line); color: var(--fg); }
.btn.line:hover:not([disabled]) { background: rgba(255,255,255,.1); }
.btn.danger { background: rgba(255,138,128,.12); border: 1px solid rgba(255,138,128,.3); color: var(--red); }
/* 카카오 — 공식 디자인 가이드: 바탕 #FEE500, 글자 85% 검정, 말풍선 심볼 */
.btn.kakao { background: #fee500; color: rgba(0,0,0,.85); }
.btn.kakao:hover:not([disabled]) { filter: brightness(.97); }
.btn.kakao svg { width: 18px; height: 18px; }
.btn.busy { color: transparent !important; pointer-events: none; }
.btn.busy::after { content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(5,7,13,.25); border-top-color: #05070d; animation: spin .7s linear infinite; }
.btn.line.busy::after { border-color: rgba(255,255,255,.2); border-top-color: #fff; }
@keyframes spin { to { transform: rotate(360deg); } }

.or { display: flex; align-items: center; gap: 12px; margin: 22px 0 0; font-size: 12px; color: var(--faint); font-family: var(--mono); letter-spacing: .14em; }
.or::before, .or::after { content: ''; flex: 1; height: 1px; background: rgba(255,255,255,.1); }
.links { margin-top: 22px; display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 16px; font-size: 13.5px; color: var(--sub); }
.links a, .links button { color: var(--sub); background: none; border: 0; cursor: pointer; padding: 2px 0; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(255,255,255,.2); transition: color .2s; }
.links a:hover, .links button:hover { color: var(--fg); }
.links .strong { color: var(--fg); font-weight: 600; }

/* 내 계정 — 묶음 */
.section { margin-top: 28px; }
.section h2 { font-family: var(--mono); font-size: 11.5px; font-weight: 700; letter-spacing: .2em; color: var(--blue); margin-bottom: 10px; }
.rows { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: rgba(255,255,255,.025); }
.row { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 12px 16px; border-top: 1px solid rgba(255,255,255,.06); font-size: 14.5px; }
.row:first-child { border-top: 0; }
.row .k { width: 92px; flex: 0 0 auto; font-size: 13px; color: var(--sub); }
.row .v { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.row .v small { display: block; font-size: 12px; color: var(--faint); margin-top: 2px; }
.row .act { margin-left: auto; flex: 0 0 auto; font-size: 13px; color: var(--blue); background: none; border: 0; cursor: pointer; padding: 6px 8px; border-radius: 8px; }
.row .act:hover { background: rgba(143,211,244,.1); }
.row .act.bad { color: var(--red); } .row .act.bad:hover { background: rgba(255,138,128,.1); }
.row form { margin: 0; flex: 1; display: flex; gap: 8px; align-items: flex-start; flex-wrap: wrap; }
.row form .input { flex: 1; min-width: 160px; }
.row form .input input { height: 40px; font-size: 15px; }
.row form .err { flex-basis: 100%; }
.row form .mini { height: 40px; padding: 0 14px; border-radius: 10px; border: 0; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.row form .mini.go { background: var(--blue); color: #05070d; } .row form .mini.no { background: rgba(255,255,255,.07); color: var(--sub); }
.tag { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; padding: 3px 9px; border-radius: 999px; background: rgba(255,255,255,.06); color: var(--sub); }
.tag.on::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 6px var(--ok); }
.switch { appearance: none; -webkit-appearance: none; width: 42px; height: 25px; border-radius: 999px; background: rgba(255,255,255,.14); position: relative; cursor: pointer; transition: background .2s; flex: 0 0 auto; margin-left: auto; }
.switch::after { content: ''; position: absolute; left: 3px; top: 3px; width: 19px; height: 19px; border-radius: 50%; background: #fff; transition: transform .25s var(--ease); box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.switch:checked { background: var(--blue); } .switch:checked::after { transform: translateX(17px); }
.switch:focus-visible { box-shadow: 0 0 0 3px rgba(143,211,244,.35); outline: none; }
.empty { padding: 18px 16px; font-size: 13.5px; color: var(--faint); }

/* 아래에서 올라오는 시트 (약관 보기 · 확인) */
dialog { width: min(520px, calc(100vw - 24px)); max-height: min(80vh, 640px); padding: 0; border: 1px solid var(--line); border-radius: 22px; color: var(--fg);
  background: rgba(14,17,26,.96); box-shadow: 0 30px 90px rgba(0,0,0,.6); }
dialog::backdrop { background: rgba(0,0,0,.55); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
dialog[open] { animation: up .35s var(--ease); }
dialog .in { padding: 26px 24px 20px; overflow: auto; max-height: inherit; }
dialog h3 { font-size: 18px; margin-bottom: 12px; }
dialog .doc { font-size: 13.5px; line-height: 1.75; color: var(--sub); }
dialog .doc h4 { color: var(--fg); font-size: 14px; margin: 14px 0 4px; }
dialog .doc .draft { display: inline-block; font-family: var(--mono); font-size: 11px; color: var(--gold); border: 1px solid rgba(214,165,92,.4); border-radius: 6px; padding: 2px 7px; margin-bottom: 8px; }
dialog .foot { display: flex; gap: 8px; margin-top: 18px; }
dialog .foot .btn { height: 44px; font-size: 14.5px; }

/* 앱 연동 화면 */
.pair { display: flex; align-items: center; justify-content: center; gap: 14px; margin-bottom: 20px; }
.pair .ic { width: 52px; height: 52px; border-radius: 15px; display: grid; place-items: center; background: rgba(255,255,255,.07); border: 1px solid var(--line); font-weight: 700; font-size: 20px; }
.pair .ic img { width: 30px; }
.pair .wire { width: 46px; height: 2px; border-radius: 2px; background: linear-gradient(90deg, var(--blue), var(--gold)); position: relative; overflow: hidden; }
.pair .wire::after { content: ''; position: absolute; inset: 0; width: 12px; background: #fff; filter: blur(2px); animation: run 1.6s ease-in-out infinite; }
@keyframes run { from { transform: translateX(-14px); } to { transform: translateX(48px); } }
.scopes { margin-top: 18px; display: grid; gap: 8px; }
.scopes li { list-style: none; display: flex; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 12px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.07); font-size: 14px; }
.scopes li::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 8px var(--blue); }
.scopes { padding: 0; }
.btns { margin-top: 22px; display: grid; gap: 10px; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01s !important; transition-duration: .01s !important; } }
