/* 맛집 도장깨기 — 외근 맛집 도장 투어
   종이(한지) 바탕 · 먹색 글자 · 인주 빨강은 도장과 강조에만. 밝은 테마 하나로 간다. */

@font-face{font-family:"Pretendard";src:url("fonts/PretendardVariable.woff2") format("woff2");font-weight:45 920;font-display:swap}

:root{
  color-scheme:light;
  --paper:#F5F0E8; --paper-2:#EFE8DD; --card:#FFFFFF; --card-2:#FCF9F4;
  --ink:#221E1A; --ink-2:#4A433C; --muted:#857C72; --muted-2:#ADA49A;
  --line:#E6DED2; --line-2:#F0EAE1;
  --red:#C8352B; --red-dk:#A2271F; --red-soft:#FBEAE6;
  --gold:#E3A034; --green:#3E7A55; --green-soft:#E7F2EB; --amber-soft:#FBF1DF;
  --r-sm:8px; --r:12px; --r-lg:18px;
  --shadow:0 1px 2px rgba(34,30,26,.05),0 6px 18px rgba(34,30,26,.05);
  --shadow-lg:0 18px 50px rgba(34,30,26,.18);
  --f:"Pretendard",-apple-system,BlinkMacSystemFont,"Apple SD Gothic Neo","Malgun Gothic",system-ui,sans-serif;
  --f-serif:var(--f);
  /* 지역 색 — 화성 서해, 평택 벽돌, 안성 들녘, 오산 자두, 천안 호두 */
  --r-hs:#2E6E8E; --r-pt:#B4513A; --r-as:#5D7D38; --r-os:#7B4D8D; --r-ca:#A97A22;
  --tabbar-h:64px;
}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
html,body{margin:0}
body{background:var(--paper);color:var(--ink);font-family:var(--f);font-size:15px;line-height:1.55;letter-spacing:-.005em;
     -webkit-font-smoothing:antialiased;font-variant-numeric:tabular-nums}
[hidden]{display:none!important}
a{color:inherit;text-decoration:none}
button,input,select,textarea{font:inherit;color:inherit}
button{cursor:pointer;background:none;border:0;padding:0}
img{max-width:100%;display:block}
::selection{background:#F4D9C8}
.sr{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
:focus-visible{outline:2px solid var(--ink);outline-offset:2px;border-radius:6px}

/* ───────── 틀 */
.shell{display:grid;grid-template-columns:252px minmax(0,1fr);min-height:100vh}
.side{position:sticky;top:0;height:100vh;display:flex;flex-direction:column;gap:22px;padding:26px 18px 18px;
      background:var(--card-2);border-right:1px solid var(--line);overflow-y:auto}
.main{min-width:0;padding:30px 40px 72px;max-width:1360px;width:100%}
.topbar,.tabbar{display:none}

.brand{display:flex;align-items:center;gap:11px;padding:0 6px}
.brand-mark{width:40px;height:40px;flex:none;color:var(--red)}
.brand-t{display:flex;flex-direction:column;line-height:1.15}
.brand-t b{font-family:var(--f-serif);font-weight:800;font-size:18px;letter-spacing:-.02em}
.brand-t span{font-size:11.5px;color:var(--muted);margin-top:3px;letter-spacing:.01em}

.nav{display:flex;flex-direction:column;gap:2px}
.nav a{display:flex;align-items:center;gap:12px;height:42px;padding:0 12px;border-radius:10px;color:var(--ink-2);font-weight:550;font-size:14.5px}
.nav a svg{width:20px;height:20px;flex:none;color:var(--muted)}
.nav a:hover{background:var(--paper-2)}
.nav a.on{background:var(--ink);color:#fff}
.nav a.on svg{color:#fff}
.nav a .cnt{margin-left:auto;font-size:12px;font-weight:600;color:var(--muted)}
.nav a.on .cnt{color:#D9D2C8}

.side-h{font-size:11.5px;font-weight:650;color:var(--muted);letter-spacing:.08em;padding:0 12px;margin-bottom:8px}
.reg-prog{display:flex;flex-direction:column;gap:4px}
.reg-prog a{display:grid;grid-template-columns:10px 1fr auto;align-items:center;gap:10px;padding:7px 12px;border-radius:9px;font-size:13.5px;color:var(--ink-2)}
.reg-prog a:hover{background:var(--paper-2)}
.reg-prog .dot{width:8px;height:8px;border-radius:50%}
.reg-prog .n{font-size:12px;color:var(--muted);font-weight:600}
.reg-prog .bar{grid-column:2/4;height:3px;border-radius:2px;background:var(--line);overflow:hidden;margin-top:2px}
.reg-prog .bar i{display:block;height:100%;border-radius:2px}

.side-foot{margin-top:auto;display:flex;align-items:center;gap:10px;padding:12px;border-radius:12px;background:var(--card);border:1px solid var(--line)}
.side-foot .who{display:flex;flex-direction:column;min-width:0;line-height:1.25}
.side-foot .who b{font-size:13.5px}
.side-foot .who span{font-size:11.5px;color:var(--muted)}
.side-foot .out{margin-left:auto;color:var(--muted);font-size:12.5px;padding:6px 8px;border-radius:8px}
.side-foot .out:hover{background:var(--paper-2);color:var(--ink)}

.av{width:32px;height:32px;border-radius:50%;display:inline-grid;place-items:center;flex:none;color:#fff;font-size:13px;font-weight:700;letter-spacing:-.02em}
.av.sm{width:24px;height:24px;font-size:11px}
.av.xs{width:20px;height:20px;font-size:10px}
.avs{display:inline-flex}
.avs .av{box-shadow:0 0 0 2px var(--card)}
.avs .av+.av{margin-left:-6px}

/* ───────── 머리 */
.ph{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin-bottom:22px;flex-wrap:wrap}
.ph h1{margin:0;font-family:var(--f-serif);font-weight:800;font-size:30px;letter-spacing:-.04em;line-height:1.2;text-wrap:balance}
.ph p{margin:6px 0 0;color:var(--muted);font-size:14px}
.ph .tools{display:flex;gap:8px;flex-wrap:wrap}
.eyebrow{font-size:12px;font-weight:650;letter-spacing:.08em;color:var(--red);margin-bottom:6px}

/* ───────── 버튼·칩 */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:7px;height:40px;padding:0 16px;border-radius:11px;font-weight:650;font-size:14px;
     border:1px solid var(--line);background:var(--card);color:var(--ink);white-space:nowrap;transition:background .12s,border-color .12s,transform .08s}
.btn:hover{border-color:#D4CABC;background:var(--card-2)}
.btn:active{transform:translateY(1px)}
.btn svg{width:18px;height:18px;flex:none}
.btn.pri{background:var(--ink);border-color:var(--ink);color:#fff}
.btn.pri:hover{background:#3A332C}
.btn.red{background:var(--red);border-color:var(--red);color:#fff}
.btn.red:hover{background:var(--red-dk)}
.btn.ghost{border-color:transparent;background:transparent;color:var(--ink-2)}
.btn.ghost:hover{background:var(--paper-2)}
.btn.sm{height:32px;padding:0 11px;font-size:13px;border-radius:9px}
.btn.lg{height:48px;padding:0 22px;font-size:15.5px;border-radius:13px}
.btn.block{width:100%}
.btn[disabled]{opacity:.45;pointer-events:none}
.btn.on{background:var(--red-soft);border-color:#F0C4BB;color:var(--red-dk)}

.chip{display:inline-flex;align-items:center;gap:5px;height:24px;padding:0 9px;border-radius:999px;background:var(--paper-2);color:var(--ink-2);font-size:12px;font-weight:600;white-space:nowrap}
.chip.line{background:transparent;box-shadow:inset 0 0 0 1px var(--line)}
.chip.red{background:var(--red-soft);color:var(--red-dk)}
.chip.green{background:var(--green-soft);color:var(--green)}
.chip.amber{background:var(--amber-soft);color:#93641A}
.chip .dot{width:7px;height:7px;border-radius:50%}

.seg{display:inline-flex;gap:3px;padding:3px;border-radius:12px;background:var(--paper-2)}
.seg button{height:32px;padding:0 13px;border-radius:9px;font-size:13.5px;font-weight:600;color:var(--ink-2);white-space:nowrap}
.seg button.on{background:var(--card);color:var(--ink);box-shadow:0 1px 3px rgba(34,30,26,.12)}

.regs{display:flex;gap:8px;flex-wrap:wrap}
.reg{display:inline-flex;align-items:center;gap:8px;height:40px;padding:0 15px 0 12px;border-radius:999px;background:var(--card);border:1px solid var(--line);font-weight:650;font-size:14.5px;color:var(--ink-2)}
.reg .dot{width:9px;height:9px;border-radius:50%}
.reg:hover{border-color:#D4CABC}
.reg.on{color:#fff;border-color:transparent}
.reg.on .dot{background:#fff!important;opacity:.85}
.reg small{font-size:12px;font-weight:600;opacity:.7}

/* ───────── 카드 */
.card{background:var(--card);border:1px solid var(--line);border-radius:var(--r-lg);box-shadow:var(--shadow)}
.card-h{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:18px 20px 0}
.card-h h2{margin:0;font-size:16px;font-weight:750;letter-spacing:-.015em}
.card-h a,.card-h button.link{font-size:13px;color:var(--muted);font-weight:600}
.card-h a:hover,.card-h button.link:hover{color:var(--ink)}
.card-b{padding:16px 20px 20px}

/* ───────── 홈 */
.home{display:grid;grid-template-columns:minmax(0,7fr) minmax(0,5fr);gap:20px;align-items:start}
.home .col{display:flex;flex-direction:column;gap:20px;min-width:0}
.greet{margin-bottom:22px}
.greet h1{margin:0 0 14px;font-family:var(--f-serif);font-weight:800;font-size:30px;letter-spacing:-.03em;line-height:1.25;text-wrap:balance}
.greet h1 em{font-style:normal;color:var(--red)}

.next-empty{display:flex;flex-direction:column;align-items:flex-start;gap:12px;padding:6px 0 4px;color:var(--muted);font-size:14px}
.next-empty b{color:var(--ink);font-size:15px}
.next-list{display:flex;flex-direction:column;gap:10px}
.next-item{display:grid;grid-template-columns:44px minmax(0,1fr) auto;align-items:center;gap:12px;padding:12px;border-radius:14px;background:var(--card-2);border:1px solid var(--line-2)}
.next-item .nm{font-weight:700;font-size:15px;line-height:1.3}
.next-item .mt{font-size:12.5px;color:var(--muted);margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.next-item .act{display:flex;align-items:center;gap:6px}
.vote{display:inline-flex;align-items:center;gap:6px;height:34px;padding:0 10px 0 8px;border-radius:999px;border:1px solid var(--line);background:var(--card);font-size:13px;font-weight:700;color:var(--ink-2)}
.vote svg{width:17px;height:17px}
.vote.on{background:var(--red-soft);border-color:#F0C4BB;color:var(--red-dk)}
.decided{position:relative;overflow:hidden;padding:20px;border-radius:16px;background:var(--ink);color:#fff}
.decided .lab{font-size:12px;font-weight:650;letter-spacing:.08em;color:#E9B7A9}
.decided .nm{font-family:var(--f-serif);font-weight:800;font-size:26px;letter-spacing:-.03em;margin:6px 0 4px;line-height:1.2}
.decided .mt{color:#CFC6BA;font-size:13.5px}
.decided .row{display:flex;gap:8px;flex-wrap:wrap;margin-top:16px}
.decided .btn{background:rgba(255,255,255,.1);border-color:rgba(255,255,255,.16);color:#fff}
.decided .btn:hover{background:rgba(255,255,255,.18)}
.decided .btn.red{background:var(--red);border-color:var(--red)}
.decided .stamp-bg{position:absolute;right:-18px;top:-18px;width:150px;height:150px;color:rgba(255,255,255,.06);transform:rotate(-12deg)}

/* 뽑기 */
.pick{position:relative}
.pick .opts{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.reel{position:relative;height:96px;margin:16px 0 14px;border-radius:14px;background:var(--card-2);border:1px dashed #D9CFC1;overflow:hidden;display:grid;place-items:center;text-align:center}
.reel .nm{font-family:var(--f-serif);font-weight:800;font-size:25px;letter-spacing:-.03em;line-height:1.2;padding:0 16px}
.reel .mt{font-size:12.5px;color:var(--muted);margin-top:4px}
.reel.rolling .nm{filter:blur(.4px);opacity:.85}
.reel .ph-t{color:var(--muted-2);font-size:14px}
.reel::before,.reel::after{content:"";position:absolute;left:0;right:0;height:22px;pointer-events:none}
.reel::before{top:0;background:linear-gradient(var(--card-2),transparent)}
.reel::after{bottom:0;background:linear-gradient(transparent,var(--card-2))}
.pick .row{display:flex;gap:8px;flex-wrap:wrap}

/* 도장 현황 */
.prog-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px}
.ring{display:flex;flex-direction:column;align-items:center;gap:6px;padding:12px 4px 10px;border-radius:14px;color:var(--ink-2)}
.ring:hover{background:var(--card-2)}
.ring svg{width:64px;height:64px}
.ring b{font-size:13.5px;font-weight:700}
.ring span{font-size:12px;color:var(--muted);margin-top:-4px}
.totals{display:flex;gap:18px;flex-wrap:wrap;margin-top:6px;padding-top:14px;border-top:1px solid var(--line-2)}
.totals div{display:flex;flex-direction:column}
.totals b{font-size:20px;font-weight:750;letter-spacing:-.02em}
.totals span{font-size:12px;color:var(--muted)}

/* 피드 */
.feed{display:flex;flex-direction:column}
.feed-i{display:grid;grid-template-columns:auto minmax(0,1fr);gap:12px;padding:13px 0;border-top:1px solid var(--line-2)}
.feed-i:first-child{border-top:0;padding-top:2px}
.feed-i .t{font-size:14px;line-height:1.45}
.feed-i .t b{font-weight:700}
.feed-i .t a{font-weight:700}
.feed-i .t a:hover{text-decoration:underline;text-underline-offset:3px}
.feed-i .s{font-size:12.5px;color:var(--muted);margin-top:2px;display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.feed-i q{display:block;margin-top:6px;font-size:13.5px;color:var(--ink-2);quotes:none;padding-left:10px;border-left:2px solid var(--line)}
.empty{padding:26px 8px;text-align:center;color:var(--muted);font-size:14px}
.empty svg{width:44px;height:44px;color:var(--muted-2);margin:0 auto 8px}

/* ───────── 탐색 */
.explore{display:grid;grid-template-columns:minmax(360px,460px) minmax(0,1fr);gap:22px;align-items:start}
.list-col{min-width:0;display:flex;flex-direction:column;gap:12px}
.search{position:relative}
.search input{width:100%;height:46px;padding:0 44px 0 44px;border-radius:13px;border:1px solid var(--line);background:var(--card);font-size:15px;outline:0;transition:border-color .12s,box-shadow .12s}
.search input:focus{border-color:#BFB3A3;box-shadow:0 0 0 4px rgba(34,30,26,.06)}
.search svg{position:absolute;left:14px;top:50%;width:19px;height:19px;transform:translateY(-50%);color:var(--muted)}
.search .x{position:absolute;right:8px;top:50%;transform:translateY(-50%);width:30px;height:30px;border-radius:8px;color:var(--muted);display:grid;place-items:center}
.search .x:hover{background:var(--paper-2)}
.filters{display:flex;flex-direction:column;gap:10px}
.fl-row{display:flex;gap:6px;overflow-x:auto;scrollbar-width:none;padding-bottom:2px;margin:0 -2px;padding-left:2px}
.fl-row::-webkit-scrollbar{display:none}
.fbtn{flex:none;display:inline-flex;align-items:center;gap:6px;height:32px;padding:0 12px;border-radius:999px;border:1px solid var(--line);background:var(--card);font-size:13px;font-weight:600;color:var(--ink-2)}
.fbtn:hover{border-color:#D4CABC}
.fbtn .dot{width:7px;height:7px;border-radius:50%}
.fbtn.on{background:var(--ink);border-color:var(--ink);color:#fff}
.fbtn.on .dot{background:#fff!important}
.fl-meta{display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:13px;color:var(--muted)}
.fl-meta b{color:var(--ink);font-weight:700}
.fl-meta select{height:32px;border:1px solid var(--line);border-radius:9px;background:var(--card);padding:0 28px 0 10px;font-size:13px;font-weight:600;color:var(--ink-2);appearance:none;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23857C72' stroke-width='2.4'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 9px center}

.plist{display:flex;flex-direction:column;background:var(--card);border:1px solid var(--line);border-radius:var(--r-lg);box-shadow:var(--shadow);overflow:hidden}
.pc{position:relative;display:grid;grid-template-columns:46px minmax(0,1fr) auto;gap:13px;align-items:center;padding:14px 16px;border-top:1px solid var(--line-2);text-align:left;width:100%;transition:background .1s}
.pc:first-child{border-top:0}
.pc:hover{background:#FDFAF5}
.pc.sel{background:#FBF5EC}
.pc.sel::before{content:"";position:absolute;left:0;top:10px;bottom:10px;width:3px;border-radius:0 3px 3px 0;background:var(--ink)}
.pc .nm{display:flex;align-items:center;gap:7px;font-weight:700;font-size:15px;line-height:1.3;min-width:0}
.pc .nm span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.pc .mt{display:block;font-size:12.5px;color:var(--muted);margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.pc .tg{display:flex;gap:5px;margin-top:7px;flex-wrap:wrap}
.pc .rt{display:flex;flex-direction:column;align-items:flex-end;gap:4px;min-width:48px}
.score{display:inline-flex;align-items:center;gap:3px;font-weight:750;font-size:14px;white-space:nowrap}
.score svg{width:14px;height:14px;color:var(--gold);flex:none}
.pc .score{font-weight:750;font-size:14px;display:flex;align-items:center;gap:3px}
.pc .score svg{width:14px;height:14px;color:var(--gold)}
.pc .score small{font-size:11.5px;color:var(--muted);font-weight:600}
.pc .stamp-mini{width:38px;height:38px;color:var(--red)}
.more{padding:14px;text-align:center}

/* 분류 글자 배지 — 노포 간판처럼 한 글자 */
.cb{width:46px;height:46px;border-radius:13px;display:grid;place-items:center;flex:none;font-family:var(--f-serif);font-weight:800;font-size:19px;letter-spacing:-.04em;
    background:var(--cb-bg,#F1ECE4);color:var(--cb-fg,#5A5047);box-shadow:inset 0 0 0 1px rgba(34,30,26,.05)}
.cb.lg{width:64px;height:64px;font-size:27px;border-radius:17px}
.cb.sm{width:38px;height:38px;font-size:16px;border-radius:11px}

/* ───────── 상세 */
.detail{min-width:0}
.dpanel{position:sticky;top:24px;max-height:calc(100vh - 48px);overflow-y:auto;scrollbar-width:thin}
.d-hero{padding:24px 24px 20px;border-bottom:1px solid var(--line-2);position:relative}
.d-hero .top{display:flex;gap:16px;align-items:flex-start}
.d-hero h2{margin:0;font-family:var(--f-serif);font-weight:800;font-size:27px;letter-spacing:-.035em;line-height:1.22;text-wrap:balance}
.d-hero .sub{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:8px;color:var(--muted);font-size:13.5px}
.d-hero .acts{display:flex;gap:8px;flex-wrap:wrap;margin-top:18px}
.d-hero .stamp-big{position:absolute;right:20px;top:16px;width:92px;height:92px;color:var(--red);transform:rotate(-9deg);opacity:.92;pointer-events:none}
.d-sec{padding:20px 24px;border-top:1px solid var(--line-2)}
.d-sec:first-of-type{border-top:0}
.d-sec h3{margin:0 0 12px;font-size:14px;font-weight:750;letter-spacing:-.01em;display:flex;align-items:center;justify-content:space-between;gap:10px}
.d-sec h3 .link{font-size:12.5px;color:var(--muted);font-weight:600}
.info{display:grid;grid-template-columns:76px minmax(0,1fr);gap:9px 14px;margin:0;font-size:14px}
.info dt{color:var(--muted);font-size:13px;padding-top:1px}
.info dd{margin:0;color:var(--ink);word-break:keep-all;overflow-wrap:anywhere}
.info dd .copy{margin-left:6px;font-size:12px;color:var(--muted);text-decoration:underline;text-underline-offset:3px}
.note{font-size:14px;color:var(--ink-2);line-height:1.65;word-break:keep-all}
.srcs{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px}
.srcs a{font-size:12px;color:var(--muted);padding:3px 9px;border-radius:999px;background:var(--paper-2);max-width:240px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.srcs a:hover{color:var(--ink)}
.caution{display:flex;gap:10px;padding:12px 14px;border-radius:12px;background:var(--amber-soft);color:#7A5418;font-size:13.5px;line-height:1.55;margin-bottom:12px}
.caution svg{width:18px;height:18px;flex:none;margin-top:1px}

.revs{display:flex;flex-direction:column;gap:10px}
.rev{display:grid;grid-template-columns:auto minmax(0,1fr);gap:12px;padding:14px;border-radius:14px;background:var(--card-2);border:1px solid var(--line-2)}
.rev .h{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.rev .h b{font-size:14px}
.rev .h time{font-size:12px;color:var(--muted)}
.rev p{margin:6px 0 0;font-size:14px;color:var(--ink-2);line-height:1.6;word-break:keep-all}
.avg{display:flex;align-items:center;gap:14px;padding:4px 0 14px}
.avg .big{font-size:38px;font-weight:800;letter-spacing:-.04em;line-height:1}
.avg .big small{font-size:15px;color:var(--muted);font-weight:600;margin-left:3px}
.avg .meta{font-size:13px;color:var(--muted)}
.stars{display:inline-flex;gap:1px;color:var(--gold)}
.stars svg{width:15px;height:15px}
.stars .off{color:#E4DCD0}
.again{font-size:12px;font-weight:700;padding:2px 8px;border-radius:999px}
.again.a{background:var(--green-soft);color:var(--green)}
.again.m{background:var(--paper-2);color:var(--ink-2)}
.again.n{background:var(--red-soft);color:var(--red-dk)}

.visits{display:flex;flex-direction:column;gap:0}
.visit{display:grid;grid-template-columns:62px minmax(0,1fr);gap:12px;padding:12px 0;border-top:1px solid var(--line-2)}
.visit:first-child{border-top:0;padding-top:0}
.visit .dt{font-weight:750;font-size:14px}
.visit .dt small{display:block;font-size:11.5px;color:var(--muted);font-weight:600}
.visit .bd{font-size:13.5px;color:var(--ink-2);display:flex;flex-direction:column;gap:6px}
.photos{display:flex;gap:6px;flex-wrap:wrap}
.photos button{width:72px;height:72px;border-radius:10px;overflow:hidden;background:var(--paper-2)}
.photos img{width:100%;height:100%;object-fit:cover}

.d-empty{display:grid;place-items:center;text-align:center;min-height:420px;padding:40px;color:var(--muted)}
.d-empty .stamp-ghost{width:120px;height:120px;color:#E3D9CB;margin:0 auto 14px;transform:rotate(-8deg)}
.d-empty b{display:block;color:var(--ink);font-size:16px;margin-bottom:4px}

.back{display:inline-flex;align-items:center;gap:6px;height:36px;padding:0 10px 0 6px;border-radius:9px;color:var(--ink-2);font-weight:600;font-size:14px;margin:-6px 0 10px -6px}
.back:hover{background:var(--paper-2)}
.back svg{width:20px;height:20px}

/* ───────── 도장첩 */
.book-h{display:flex;align-items:center;gap:16px;flex-wrap:wrap;margin-bottom:18px}
.book-h .big{font-size:15px;color:var(--muted)}
.book-h .big b{font-size:26px;color:var(--ink);font-weight:800;letter-spacing:-.03em;margin-right:2px}
.book{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:12px}
.slot{position:relative;display:flex;flex-direction:column;justify-content:space-between;min-height:132px;padding:13px 13px 12px;border-radius:15px;background:var(--card);border:1px solid var(--line);text-align:left;overflow:hidden;transition:transform .12s,box-shadow .12s}
.slot:hover{transform:translateY(-2px);box-shadow:var(--shadow)}
.slot .no{font-size:11px;color:var(--muted-2);font-weight:700;letter-spacing:.04em}
.slot .nm{display:block;font-weight:700;font-size:14px;line-height:1.35;margin-top:6px;word-break:keep-all;position:relative;z-index:1;padding-right:6px}
.slot .mt{display:block;font-size:11.5px;color:var(--muted);margin-top:3px;position:relative;z-index:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.slot .ring-ph{position:absolute;right:-12px;top:-12px;width:76px;height:76px;color:#EEE7DC}
.slot.done{background:#FFFCF8}
.slot.done .nm{padding-right:46px}
.slot.done .stamp-s{position:absolute;right:-4px;top:-6px;width:80px;height:80px;color:var(--red);opacity:.88;transform:rotate(-10deg);mix-blend-mode:multiply}
.slot.done .rt{position:relative;z-index:1;margin-top:8px;display:flex;align-items:center;gap:4px;font-size:12.5px;font-weight:700}
.slot.done .rt svg{width:13px;height:13px;color:var(--gold)}

/* ───────── 기록 */
.stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:20px}
.stat{padding:16px 18px;border-radius:16px;background:var(--card);border:1px solid var(--line)}
.stat span{font-size:12.5px;color:var(--muted);font-weight:600}
.stat b{display:block;font-size:26px;font-weight:800;letter-spacing:-.03em;margin-top:4px}
.stat b small{font-size:13px;color:var(--muted);font-weight:600;margin-left:2px}
.log-grid{display:grid;grid-template-columns:minmax(0,7fr) minmax(0,5fr);gap:20px;align-items:start}
.tl{display:flex;flex-direction:column}
.tl-month{font-size:12.5px;font-weight:750;color:var(--muted);letter-spacing:.04em;padding:16px 0 6px}
.tl-month:first-child{padding-top:0}
.tl-i{display:grid;grid-template-columns:46px minmax(0,1fr) auto;gap:12px;align-items:center;padding:12px 0;border-top:1px solid var(--line-2)}
.tl-i .nm{font-weight:700;font-size:14.5px}
.tl-i .mt{font-size:12.5px;color:var(--muted);margin-top:2px}
.bars{display:flex;flex-direction:column;gap:10px}
.bars .b{display:grid;grid-template-columns:72px minmax(0,1fr) 34px;gap:10px;align-items:center;font-size:13px}
.bars .b span{color:var(--ink-2)}
.bars .b em{font-style:normal;text-align:right;color:var(--muted);font-weight:650}
.bars .tr{height:9px;border-radius:5px;background:var(--paper-2);overflow:hidden}
.bars .tr i{display:block;height:100%;border-radius:5px}

/* ───────── 시트(모달) */
.scrim{position:fixed;inset:0;z-index:80;background:rgba(28,24,20,.42);display:grid;place-items:center;padding:24px;opacity:0;transition:opacity .16s}
.scrim.on{opacity:1}
.sheet{width:min(540px,100%);max-height:calc(100vh - 48px);overflow-y:auto;background:var(--card);border-radius:22px;box-shadow:var(--shadow-lg);transform:translateY(12px);transition:transform .2s cubic-bezier(.2,.8,.2,1)}
.scrim.on .sheet{transform:none}
.sheet-h{display:flex;align-items:flex-start;gap:12px;padding:22px 22px 0}
.sheet-h h2{margin:0;font-size:18px;font-weight:750;letter-spacing:-.02em;line-height:1.35}
.sheet-h p{margin:3px 0 0;font-size:13px;color:var(--muted)}
.sheet-h .x{margin-left:auto;width:34px;height:34px;border-radius:10px;display:grid;place-items:center;color:var(--muted);flex:none}
.sheet-h .x:hover{background:var(--paper-2);color:var(--ink)}
.sheet-h .x svg{width:20px;height:20px}
.sheet-b{padding:18px 22px 22px;display:flex;flex-direction:column;gap:18px}
.sheet-f{display:flex;gap:8px;justify-content:flex-end;padding:0 22px 22px}
.grab{display:none}

.field{display:flex;flex-direction:column;gap:8px}
.field>label,.field>.lb{font-size:13px;font-weight:700;color:var(--ink-2)}
.field .hint{font-size:12px;color:var(--muted);font-weight:500}
.in{width:100%;height:44px;padding:0 13px;border-radius:11px;border:1px solid var(--line);background:var(--card);font-size:15px;outline:0}
textarea.in{height:auto;min-height:92px;padding:11px 13px;resize:vertical;line-height:1.55}
select.in{appearance:none;padding-right:34px;background:var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23857C72' stroke-width='2.2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center}
.in:focus{border-color:#BFB3A3;box-shadow:0 0 0 4px rgba(34,30,26,.06)}
.row2{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.star-in{display:flex;gap:4px}
.star-in button{width:46px;height:46px;border-radius:12px;display:grid;place-items:center;color:#E2D9CC;transition:transform .08s,color .1s}
.star-in button svg{width:34px;height:34px}
.star-in button.on{color:var(--gold)}
.star-in button:active{transform:scale(.92)}
.star-lab{font-size:13px;color:var(--muted);font-weight:600;min-height:20px}
.opt3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.opt3 button{height:44px;border-radius:11px;border:1px solid var(--line);font-weight:650;font-size:14px;color:var(--ink-2);background:var(--card)}
.opt3 button.on{border-color:var(--ink);background:var(--ink);color:#fff}
.who-pick{display:flex;gap:8px;flex-wrap:wrap}
.who-pick button{display:inline-flex;align-items:center;gap:7px;height:38px;padding:0 13px 0 6px;border-radius:999px;border:1px solid var(--line);font-weight:650;font-size:13.5px;background:var(--card)}
.who-pick button.on{border-color:var(--ink);box-shadow:inset 0 0 0 1px var(--ink)}
.up{display:flex;gap:8px;flex-wrap:wrap}
.up label{width:76px;height:76px;border-radius:12px;border:1.5px dashed #D3C8B9;display:grid;place-items:center;color:var(--muted);cursor:pointer}
.up label svg{width:24px;height:24px}
.up .th{position:relative;width:76px;height:76px;border-radius:12px;overflow:hidden;background:var(--paper-2)}
.up .th img{width:100%;height:100%;object-fit:cover}
.up .th button{position:absolute;right:4px;top:4px;width:22px;height:22px;border-radius:50%;background:rgba(0,0,0,.55);color:#fff;display:grid;place-items:center}
.up .th button svg{width:12px;height:12px}
.err{color:var(--red-dk);font-size:13px;font-weight:600}

/* 사진 보기 */
.lightbox{position:fixed;inset:0;z-index:95;background:rgba(15,13,11,.9);display:grid;place-items:center;padding:20px}
.lightbox img{max-width:min(1100px,100%);max-height:calc(100vh - 80px);border-radius:12px}
.lightbox button{position:absolute;right:16px;top:16px;width:42px;height:42px;border-radius:50%;background:rgba(255,255,255,.12);color:#fff;display:grid;place-items:center}

/* 알림 */
.toast{position:fixed;left:50%;bottom:28px;transform:translate(-50%,20px);z-index:120;background:var(--ink);color:#fff;font-size:14px;font-weight:600;
       padding:12px 18px;border-radius:13px;box-shadow:var(--shadow-lg);opacity:0;transition:opacity .18s,transform .18s;pointer-events:none;max-width:calc(100vw - 32px)}
.toast.on{opacity:1;transform:translate(-50%,0)}

/* 도장 찍힘 효과 */
@keyframes thump{0%{transform:scale(1.6) rotate(-20deg);opacity:0}55%{transform:scale(.94) rotate(-9deg);opacity:1}100%{transform:scale(1) rotate(-9deg);opacity:.92}}
.thump{animation:thump .5s cubic-bezier(.2,.9,.3,1.2) both}
@media (prefers-reduced-motion:reduce){.thump{animation:none}.scrim,.sheet,.toast{transition:none}}

/* 로그인 */
.auth{min-height:100vh;display:grid;place-items:center;padding:32px 16px}
.auth-card{width:min(400px,100%);padding:34px 30px 30px;background:var(--card);border:1px solid var(--line);border-radius:24px;box-shadow:var(--shadow)}
.auth-card .brand{padding:0;margin-bottom:24px}
.auth-card h1{margin:0 0 6px;font-size:20px;font-weight:750;letter-spacing:-.02em}
.auth-card p{margin:0 0 22px;color:var(--muted);font-size:14px}
.auth-card form{display:flex;flex-direction:column;gap:14px}
.auth-card .foot{margin-top:18px;font-size:12.5px;color:var(--muted);text-align:center}

/* ───────── 좁은 화면 */
@media (max-width:1180px){
  .main{padding:26px 26px 64px}
  .explore{grid-template-columns:minmax(330px,400px) minmax(0,1fr)}
  .stats{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:1023px){
  body{font-size:15px}
  .shell{display:block}
  .side{display:none}
  .main{padding:14px 16px calc(var(--tabbar-h) + 28px + env(safe-area-inset-bottom,0px));max-width:none}
  .topbar{display:flex;position:sticky;top:0;z-index:40;align-items:center;gap:10px;height:56px;padding:0 12px 0 14px;
          padding-top:env(safe-area-inset-top,0px);height:calc(56px + env(safe-area-inset-top,0px));
          background:rgba(245,240,232,.88);-webkit-backdrop-filter:saturate(1.4) blur(14px);backdrop-filter:saturate(1.4) blur(14px);border-bottom:1px solid rgba(230,222,210,.7)}
  .topbar .brand{padding:0;gap:9px}
  .topbar .brand-mark{width:30px;height:30px}
  .topbar .brand-t b{font-size:16px}
  .topbar .brand-t span{display:none}
  .topbar .sp{flex:1}
  .topbar .reg-pill{display:inline-flex;align-items:center;gap:7px;height:34px;padding:0 12px 0 10px;border-radius:999px;background:var(--card);border:1px solid var(--line);font-weight:700;font-size:13.5px}
  .topbar .reg-pill .dot{width:8px;height:8px;border-radius:50%}
  .tabbar{display:grid;grid-template-columns:repeat(4,1fr);position:fixed;left:0;right:0;bottom:0;z-index:50;height:calc(var(--tabbar-h) + env(safe-area-inset-bottom,0px));
          padding-bottom:env(safe-area-inset-bottom,0px);background:rgba(255,253,249,.94);-webkit-backdrop-filter:saturate(1.4) blur(14px);backdrop-filter:saturate(1.4) blur(14px);border-top:1px solid var(--line)}
  .tabbar a{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;font-size:11px;font-weight:650;color:var(--muted)}
  .tabbar a svg{width:23px;height:23px}
  .tabbar a.on{color:var(--ink)}
  .tabbar a.on svg{color:var(--red)}
  .ph{margin-bottom:16px}
  .ph h1{font-size:24px}
  .greet h1{font-size:24px;margin-bottom:12px}
  .home{grid-template-columns:1fr;gap:16px}
  .home .col{gap:16px}
  .explore{display:block}
  .detail-col{display:none}
  .dpanel{position:static;max-height:none;overflow:visible}
  .log-grid{grid-template-columns:1fr;gap:16px}
  .regs{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;margin:0 -16px;padding:0 16px 2px}
  .regs::-webkit-scrollbar{display:none}
  .reg{flex:none}
  .scrim{place-items:end center;padding:0}
  .sheet{width:100%;max-height:calc(100vh - 40px);border-radius:22px 22px 0 0;transform:translateY(40px);padding-bottom:env(safe-area-inset-bottom,0px)}
  .grab{display:block;width:40px;height:5px;border-radius:3px;background:#DCD3C6;margin:9px auto 0}
  .sheet-h{padding-top:12px}
  .toast{bottom:calc(var(--tabbar-h) + 16px + env(safe-area-inset-bottom,0px))}
}
@media (max-width:640px){
  .card-h{padding:16px 16px 0}
  .card-b{padding:14px 16px 16px}
  .prog-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:2px}
  .ring svg{width:52px;height:52px}
  .ring b{font-size:12.5px}
  .ring span{font-size:11px}
  .d-hero{padding:4px 2px 18px}
  .d-hero h2{font-size:24px}
  .d-hero .stamp-big{width:78px;height:78px;right:2px;top:-4px}
  .d-sec{padding:18px 2px}
  .dpanel.card{background:transparent;border:0;box-shadow:none}
  .book{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .slot{min-height:118px}
  .stats{gap:10px}
  .stat{padding:13px 14px}
  .stat b{font-size:22px}
  .row2{grid-template-columns:1fr}
  .star-in button{width:44px;height:44px}
  .decided .nm{font-size:23px}
  .next-item{grid-template-columns:38px minmax(0,1fr)}
  .next-item .cb{width:38px;height:38px;font-size:16px;border-radius:11px}
  .next-item .act{grid-column:1/-1;justify-content:flex-end;padding-top:2px}
  .reel .nm{font-size:22px}
}
