/* 마음 처방전 화면 꾸밈.
   밑그림: 늦은 밤, 불 하나 켜 둔 조용한 방. 흰색과 검정을 쓰지 않고, 딱딱한 테두리 대신 부드러운 면과 옅은 그림자로 나눈다.
   밝은 화면과 어두운 화면은 theme.js가 <html data-theme="light|dark">로 정한다(밤 9시~아침 6시는 어두운 화면).
   글자 대비는 모든 조합이 4.5:1 이상, 누르는 곳의 테두리는 3:1 이상이 되게 골랐다. 누르는 곳은 모두 44px 이상. */
:root{
  --bg:#F6F1E7; --surface:#FFFBF3; --ink:#2F2A25; --muted:#675E55; --line:#E6DCCB; --edge:#8C8070;
  --accent:#3D6A55; --accent-ink:#FFFBF3; --soft:#E4ECDF; --warn:#6B4A12; --warn-bg:#F4E8CF; --care-bg:#F3E4D6;
  --glow:rgba(255,205,140,.40); --shadow:0 1px 2px rgba(90,70,40,.05),0 8px 24px rgba(90,70,40,.07);
  --display:"Gowun Batang","Noto Serif KR",Batang,serif;
  /* 본문은 기기에 이미 들어 있는 글꼴을 쓴다(내려받을 것이 없어 가장 빠르다). 제목용 고운바탕만 사이트 안(fonts.css)에서 불러온다. */
  --body:system-ui,-apple-system,"Apple SD Gothic Neo","Pretendard","Noto Sans KR","Malgun Gothic",sans-serif;
  --r-s:12px; --r-m:18px; --r-l:26px;
}
:root[data-theme="dark"]{
  --bg:#1F1B18; --surface:#2A2520; --ink:#EEE5D8; --muted:#B5AA9B; --line:#3B342D; --edge:#857A6C;
  --accent:#A9CBAE; --accent-ink:#1F1B18; --soft:#2F3B32; --warn:#EACF9B; --warn-bg:#3A2F1D; --care-bg:#3A2B22;
  --glow:rgba(255,180,100,.14); --shadow:0 1px 2px rgba(0,0,0,.22),0 10px 28px rgba(0,0,0,.20);
  color-scheme:dark;
}

*{box-sizing:border-box}
/* 기본 글자 16px → 17px. 사용자가 휴대전화에서 글자를 키워 두면 같이 커진다 */
html{font-size:106.25%;-webkit-text-size-adjust:100%;background:var(--bg);scroll-behavior:smooth}
/* word-break:keep-all = 낱말 중간에서 줄이 끊기지 않게 */
body{margin:0;background:var(--bg);color:var(--ink);font-family:var(--body);font-size:1rem;line-height:1.75;
  word-break:keep-all;overflow-wrap:break-word;padding-inline:20px;padding-block:6px 40px;min-height:100vh;position:relative;
  -webkit-font-smoothing:antialiased;-webkit-tap-highlight-color:transparent}
/* 화면 위쪽에 등불처럼 번지는 옅은 빛. 그림 파일 없이 색으로만 만든다 */
body::before{content:"";position:absolute;inset:0 0 auto 0;height:520px;pointer-events:none;z-index:0;
  background:radial-gradient(ellipse 80% 100% at 50% -12%,var(--glow),transparent 72%)}
::selection{background:var(--soft);color:var(--ink)}
.wrap{max-width:560px;margin-inline:auto;display:flex;flex-direction:column;gap:34px;position:relative;z-index:1}
h1,h2,h3{font-family:var(--display);font-weight:700;text-wrap:balance;margin:0;line-height:1.4;letter-spacing:-.01em}
h1{font-size:clamp(1.7rem,6.200vw,2.250rem);line-height:1.32}
h2{font-size:1.2rem}
p{margin:0}
a{color:var(--accent);text-underline-offset:3px}
.muted{color:var(--muted)} .small{font-size:.875rem;line-height:1.65}
[hidden]{display:none!important}
:focus-visible{outline:3px solid var(--accent);outline-offset:3px;border-radius:8px}
main:focus{outline:none}
.skip{position:absolute;left:-999px;top:8px;background:var(--accent);color:var(--accent-ink);padding:10px 16px;border-radius:999px;z-index:10;text-decoration:none}
.skip:focus{left:16px}
/* 작은 선 그림 */
.ic{width:1.15em;height:1.15em;flex:none;fill:none;stroke:currentColor;stroke-width:1.700;stroke-linecap:round;stroke-linejoin:round}

/* 맨 위 줄: 휴대전화에서는 이름만, 넓은 화면에서는 설명글과 메뉴가 함께 보인다 */
.top{display:flex;justify-content:space-between;align-items:center;gap:8px;padding-top:6px;min-height:56px}
.brand{color:var(--ink);text-decoration:none;min-height:48px;display:inline-flex;align-items:center;gap:9px;white-space:nowrap}
.mark{width:30px;height:30px;flex:none}
.mark circle{fill:var(--soft)} .mark path{fill:var(--accent)} .mark .dot{fill:var(--surface)}
.brand-ko{font-family:var(--display);font-weight:700;font-size:1.14rem;letter-spacing:-.01em}
.brand-tag{display:none;font-size:.8rem;color:var(--muted);padding-left:12px;margin-left:4px;border-left:1px solid var(--line)}
.brand-en{font-weight:500;font-size:.68rem;letter-spacing:.14em;text-transform:uppercase;color:var(--muted)}
.nav-top{display:none;gap:2px;margin-right:-12px}
.nav-top a{color:var(--muted);text-decoration:none;font-size:.92rem;min-height:44px;padding:0 14px;display:inline-flex;align-items:center;border-radius:999px;white-space:nowrap}
.nav-top a:hover{color:var(--ink)}
.nav-top a[aria-current="page"]{color:var(--ink);font-weight:600;background:var(--soft)}
/* 설명글은 자리가 넉넉한 화면에서만 보인다. 좁으면 이름과 메뉴가 먼저다 */
@media (min-width:760px){ .nav-top{display:flex} }
@media (min-width:1000px){ .brand-tag{display:inline} }
/* 아래 붙박이 메뉴: 휴대전화에서 엄지가 닿는 자리 */
.tabbar{position:fixed;left:0;right:0;bottom:0;z-index:15;display:grid;grid-template-columns:repeat(4,1fr);background:var(--surface);border-top:1px solid var(--line);
  padding:4px 6px calc(4px + env(safe-area-inset-bottom));box-shadow:0 -6px 20px rgba(60,45,25,.06)}
.tabbar a{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;min-height:52px;color:var(--muted);text-decoration:none;font-size:.7rem;border-radius:14px}
.tabbar .ic{width:22px;height:22px}
.tabbar a[aria-current="page"]{color:var(--accent);font-weight:600}
body{padding-bottom:calc(92px + env(safe-area-inset-bottom))}
@media (min-width:760px){ .tabbar{display:none} body{padding-bottom:64px} }
.crumb{margin-block:-14px -12px}
.back{display:inline-flex;align-items:center;gap:6px;min-height:44px;font-size:.9rem;text-decoration:none;color:var(--muted)}
.back:hover{color:var(--ink)}

/* 화면이 바뀔 때 천천히 떠오르듯 나타난다 */
main{display:flex;flex-direction:column;gap:22px}
@media (prefers-reduced-motion:no-preference){
  main.in>*{animation:rise .600s cubic-bezier(.2,.7,.2,1) both}
  main.in>*:nth-child(2){animation-delay:.07s} main.in>*:nth-child(3){animation-delay:.14s}
  main.in>*:nth-child(4){animation-delay:.21s} main.in>*:nth-child(n+5){animation-delay:.28s}
  @keyframes rise{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
  .btn,.chip,.item,.fold,.rest-invite,nav a{transition:border-color .25s,background-color .25s,box-shadow .25s,transform .25s,color .25s}
  .item:active,.btn:active,.chip:active,.rest-invite:active{transform:scale(.985)}
  .ic{transition:transform .25s}
  .item:hover .more .ic,.chip:hover>.ic,.btn:hover>.ic,.rest-invite:hover>.ic:last-child{transform:translateX(3px)}
}

/* 맞이하는 말과 큰 제목 */
.hero{display:flex;flex-direction:column;gap:12px;padding-top:10px}
.greet{font-family:var(--display);font-size:1.02rem;color:var(--accent);line-height:1.6}
.lead{color:var(--muted);font-size:1.02rem;line-height:1.8;max-width:34em}
/* 마지막 줄에 낱말 하나만 남지 않게 */
p,li,dd{text-wrap:pretty}
.eyebrow{font-family:var(--body);font-size:.82rem;font-weight:600;letter-spacing:.02em;color:var(--muted);margin:0}

/* 글 쓰는 칸: 종이 한 장처럼. 단추가 칸 안에 들어 있다 */
.composer{background:var(--surface);border:1.500px solid var(--line);border-radius:var(--r-l);box-shadow:var(--shadow);padding:6px 6px 10px;display:flex;flex-direction:column}
.composer:focus-within{border-color:var(--accent)}
textarea{font:inherit;width:100%;min-height:104px;padding:16px 16px 8px;border:0;border-radius:var(--r-m);background:none;color:var(--ink);resize:none;line-height:1.75;display:block}
textarea::placeholder{color:var(--muted);opacity:.85}
textarea:focus{outline:none}
.composer-foot{display:flex;align-items:center;justify-content:space-between;gap:10px 12px;flex-wrap:wrap;padding:0 6px 0 14px}
.composer-foot .small{display:inline-flex;align-items:center;gap:6px}
.composer-foot .btn{margin-left:auto}
.examples{margin-top:-8px}
.examples .chip{font-size:.875rem;min-height:44px;padding:6px 14px;color:var(--muted);background:none;cursor:pointer}

/* 단추: 색을 채운 단추는 한 화면에 하나만. 높이는 48px 이상 */
.btn{font:inherit;font-weight:600;background:var(--accent);color:var(--accent-ink);border:1.500px solid var(--accent);border-radius:999px;
  min-height:50px;padding:10px 22px;cursor:pointer;text-decoration:none;display:inline-flex;align-items:center;justify-content:center;gap:8px;text-align:center;line-height:1.3}
.btn:hover{box-shadow:var(--shadow)}
.btn.ghost{background:none;color:var(--accent)}
.btn.plain{background:var(--surface);color:var(--ink);border-color:var(--line);font-weight:500}
.btn.quiet{background:none;border-color:transparent;color:var(--accent);font-weight:500;padding-inline:10px;min-height:44px;text-decoration:underline;text-underline-offset:4px;text-decoration-thickness:1px;box-shadow:none}
.btn.wide{width:100%}
.btn:disabled{color:var(--muted);border-color:transparent;text-decoration:none;cursor:default}
.row{display:flex;gap:10px;flex-wrap:wrap;align-items:center}
.row.two{display:grid;grid-template-columns:1fr}
@media (min-width:420px){ .row.two{grid-template-columns:1fr 1fr} .row.two>:only-child{grid-column:1/-1} }
.stack{display:flex;flex-direction:column;gap:12px}

/* 고르기 단추 */
.chips{display:flex;flex-wrap:wrap;gap:8px}
.chip{font:inherit;font-size:.95rem;line-height:1.4;background:var(--surface);color:var(--ink);border:1.500px solid var(--line);border-radius:999px;
  min-height:44px;padding:8px 16px;text-decoration:none;display:inline-flex;align-items:center;gap:10px}
.chip:hover{border-color:var(--edge)}
/* 기계가 권한 상황: 색을 채우지 않고 초록 테두리만 둘러, 위기 안내나 '찾기' 단추보다 소리가 작게 한다 */
.chip.pick{border-color:var(--accent);font-weight:600}
.linklike{font:inherit;color:var(--accent);background:none;border:0;padding:10px 2px;margin:-10px 0;cursor:pointer;text-decoration:underline;text-underline-offset:4px;text-decoration-thickness:1px}
.nw{white-space:nowrap}
.chips.col{flex-direction:column;flex-wrap:nowrap}
.chips.col .chip{border-radius:var(--r-m);min-height:52px;justify-content:space-between;padding:10px 16px 10px 18px;font-weight:500}
.chips.col .chip>.ic{color:var(--accent)}

/* 접어 두는 칸: 누르면 펼쳐진다 */
.fold{border:1.500px solid var(--line);border-radius:var(--r-m);background:var(--surface)}
.fold>summary{list-style:none;cursor:pointer;min-height:54px;padding:10px 18px;display:flex;align-items:center;gap:12px;font-weight:600;border-radius:var(--r-m)}
.fold>summary::-webkit-details-marker{display:none}
.fold>summary::after{content:"";width:9px;height:9px;border-right:1.800px solid var(--accent);border-bottom:1.800px solid var(--accent);transform:rotate(45deg);margin:-4px 4px 0 0;flex:none}
.fold[open]>summary::after{transform:rotate(-135deg);margin-top:4px}
.fold>summary .count{font-size:.85rem;font-weight:400;color:var(--muted);margin-left:auto}
.fold>summary>span:only-child{margin-right:auto}
.fold>.chips{padding:0 10px 12px}
.fold>.chips .chip{background:var(--bg);border-color:transparent}
/* 테두리 없이 글자만 보이는 접기(고르기 펼침, 더 보기) */
.fold.bare{border:0;background:none}
.fold.bare>summary{padding-inline:2px;min-height:48px;color:var(--accent);font-weight:600;justify-content:flex-start;gap:10px}
.fold.bare>summary>span:only-child{margin-right:0}
.fold.bare>.stack,.fold.bare>.list{padding-top:8px}
.fold.bare .fold>summary{color:var(--ink)}

/* 한 줄 정리: "이럴 때"는 작고 조용하게, "이렇게"는 가장 크게 */
.when{font-size:.95rem;line-height:1.5;color:var(--muted);font-weight:500;text-wrap:balance}
.do{font-family:var(--display);font-weight:700;font-size:1.2rem;line-height:1.55;color:var(--ink);text-wrap:pretty;letter-spacing:-.01em}
.tag{display:inline-block;font-family:var(--body);font-size:.78rem;font-weight:600;line-height:1;color:var(--accent);background:var(--soft);border-radius:999px;padding:6px 11px;margin-right:8px;vertical-align:.12em;letter-spacing:0}

/* 목록: 테두리 대신 부드러운 면과 옅은 그림자 */
.list{display:flex;flex-direction:column;gap:12px}
.item{display:flex;flex-direction:column;gap:8px;padding:20px 20px 16px;border:1.500px solid transparent;border-radius:var(--r-l);background:var(--surface);color:inherit;text-decoration:none;box-shadow:var(--shadow)}
.item:hover,.item:focus-visible{border-color:var(--line)}
.item .do{font-size:1.17rem}
.item-sub{font-size:.85rem;line-height:1.5;color:var(--muted);display:flex;justify-content:space-between;align-items:flex-end;gap:8px;padding-top:6px;border-top:1px solid var(--line);margin-top:auto}
.item .do{margin-bottom:4px}
.more{display:inline-flex;align-items:center;gap:4px;color:var(--accent);font-weight:600;white-space:nowrap}

/* 아무것도 읽고 싶지 않은 사람을 위한 초대 */
.rest-invite{display:flex;align-items:center;gap:14px;padding:16px 18px;border-radius:var(--r-l);background:var(--soft);color:var(--ink);text-decoration:none}
.rest-invite>.ic:first-child{width:26px;height:26px;color:var(--accent)}
.rest-invite>span{display:flex;flex-direction:column;line-height:1.5;margin-right:auto}
.rest-invite>span>span{font-size:.9rem;color:var(--muted)}
.rest-invite>.ic:last-child{color:var(--accent)}

/* 세 가지 약속 */
.promises{list-style:none;margin:6px 0 0;padding:22px 0 0;display:grid;gap:18px;border-top:1px solid var(--line)}
.promises li{display:flex;gap:14px;align-items:flex-start}
.promises .ic{width:22px;height:22px;color:var(--accent);margin-top:3px}
.promises strong{display:block;font-family:var(--display);font-size:1.02rem}
.promises span{font-size:.9rem;color:var(--muted);line-height:1.65}
@media (min-width:640px){ .promises{grid-template-columns:repeat(3,1fr)} .promises li{flex-direction:column;gap:8px} }

/* 답 화면 */
.slip{background:var(--surface);border-radius:var(--r-l);padding:26px 22px 20px;display:flex;flex-direction:column;gap:22px;box-shadow:var(--shadow)}
.slip-head{display:flex;justify-content:space-between;align-items:baseline;gap:12px;font-size:.85rem;font-weight:500;color:var(--muted);font-variant-numeric:tabular-nums}
.slip-head>span:last-child:not(:first-child){white-space:nowrap}
.line{display:flex;flex-direction:column;gap:14px;padding-block:4px 2px}
.line .when{font-size:1rem}
.line .do{font-size:clamp(1.42rem,5.400vw,1.72rem);line-height:1.5;text-wrap:balance}
.line .tag{display:table;margin:0 0 9px}
.asker{font-size:1rem;line-height:1.8}
.gist{font-size:1.05rem;line-height:1.95}
.part{display:flex;flex-direction:column;gap:10px;border-top:1px solid var(--line);padding-top:20px}
/* 인용: 원문 그대로의 말. 큰 따옴표 하나를 머리에 얹는다 */
blockquote{margin:8px 0 0;font-family:var(--display);font-size:1.1rem;line-height:1.75;background:var(--soft);border-radius:var(--r-m);padding:14px 20px 18px;position:relative}
blockquote::before{content:"\201C";display:block;font-size:2.4rem;line-height:1;height:.55em;color:var(--accent);opacity:.7;margin-left:-2px}
.video{aspect-ratio:16/9;width:100%;max-width:100%;border:0;border-radius:var(--r-m);background:var(--soft)}
.note{font-size:.875rem;line-height:1.65;color:var(--muted);background:var(--bg);border-radius:var(--r-s);padding:10px 14px}
.ask{display:flex;flex-wrap:wrap;align-items:center;gap:0 4px;border-top:1px solid var(--line);padding-top:10px}
.ask>span{font-size:.875rem;color:var(--muted);flex-basis:100%;padding-top:4px}
.ask>.btn.quiet{margin-left:-10px;margin-right:12px;font-size:.92rem}

/* 읽고 난 뒤의 마무리 */
.closing{background:var(--soft);border-radius:var(--r-l);padding:28px 20px 22px;display:flex;flex-direction:column;align-items:center;gap:8px;text-align:center}
.closing h2{font-size:1.2rem}
.closing .row{justify-content:center;margin-top:10px}

/* 알림 칸: 무거운 이야기가 나오는 글에만 쓴다 */
.notice{background:var(--warn-bg);color:var(--warn);padding:12px 16px;border-radius:var(--r-m);font-size:.9rem;line-height:1.65}
.tel{font-weight:600;white-space:nowrap}

/* 위기 안내: 경고색을 쓰지 않는다. 따뜻한 바탕 + 누르면 전화가 걸리는 큰 단추 */
.notice.care{background:var(--care-bg);color:var(--ink);border-radius:var(--r-l);padding:20px 18px 18px;font-size:1rem;display:flex;flex-direction:column;gap:14px}
.care-lead{font-family:var(--display);font-weight:700;font-size:1.1rem;line-height:1.6}
.care-tels{display:flex;flex-direction:column;gap:8px}
.care-tels .tel{display:flex;align-items:center;gap:14px;min-height:64px;padding:10px 16px;background:var(--surface);border-radius:var(--r-m);color:var(--ink);text-decoration:none;white-space:normal;box-shadow:var(--shadow)}
.care-tels .tel>.ic{width:22px;height:22px;color:var(--accent)}
.care-tels .tel>span{display:flex;flex-direction:column}
.care-tels .tel strong{font-size:1.25rem;line-height:1.3;color:var(--accent);white-space:nowrap;font-variant-numeric:tabular-nums}
.care-tels .tel span span{font-size:.85rem;font-weight:400;line-height:1.4;color:var(--muted)}

/* 상담 창구 */
.box{border-radius:var(--r-l);padding:22px 20px;background:var(--surface);box-shadow:var(--shadow)}
.help{margin:6px 0 0;padding:0;list-style:none;display:flex;flex-direction:column}
/* 설명이 좁은 칸에 몇 글자씩 접히지 않게, 자리가 모자라면 단추가 설명 아래로 내려간다 */
.help li{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px 14px;padding:12px 0;border-top:1px solid var(--line)}
.help li>div{display:flex;flex-direction:column;line-height:1.5;min-width:0;flex:1 1 15em}
.help .tel{display:inline-flex;align-items:center;min-height:44px;padding:0 14px;border-radius:999px;background:var(--soft);color:var(--accent);text-decoration:none;font-variant-numeric:tabular-nums;flex:none}

/* 소개: 약속 목록 */
ol.rules{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}
ol.rules li{display:flex;gap:16px;padding:18px 0;border-top:1px solid var(--line)}
ol.rules .num{font-family:var(--display);font-size:.95rem;color:var(--accent);font-variant-numeric:tabular-nums;padding-top:2px}
ol.rules strong{font-family:var(--display);font-size:1.08rem}
ol.rules p{color:var(--muted);font-size:.95rem;line-height:1.75;margin-top:4px}

/* 빈 서랍 */
.empty{display:flex;flex-direction:column;align-items:center;gap:8px;text-align:center;padding:36px 20px;background:var(--surface);border-radius:var(--r-l);box-shadow:var(--shadow)}
.empty{max-width:660px;width:100%;margin-inline:auto}
.empty>.ic{width:36px;height:36px;color:var(--accent);margin-bottom:6px}
.empty .btn{margin-top:12px}

/* 쉬어 가기: 동그라미가 천천히 커졌다 작아진다. 4초 들이쉬고 6초 내쉰다 */
.rest{display:flex;flex-direction:column;align-items:center;gap:22px;text-align:center;padding-block:14px 6px}
.rest .lead{margin-inline:auto}
.breath{width:min(66vw,260px);aspect-ratio:1;border-radius:50%;display:grid;place-items:center;position:relative;margin-block:8px}
.breath::before,.breath::after{content:"";position:absolute;inset:0;border-radius:50%;transform:scale(.600)}
.breath::before{background:radial-gradient(circle at 50% 42%,var(--glow),var(--soft) 72%)}
.breath::after{border:1.500px solid var(--accent);opacity:.25}
.breath span{position:relative;font-family:var(--display);font-size:1.2rem;font-weight:700}
@media (prefers-reduced-motion:no-preference){
  .breath.on::before{animation:breathe 10s ease-in-out infinite}
  .breath.on::after{animation:breathe 10s ease-in-out infinite;animation-delay:.25s}
  @keyframes breathe{0%{transform:scale(.600)}40%{transform:scale(1)}100%{transform:scale(.600)}}
}

/* 화면 아래에 잠깐 뜨는 알림 */
/* 휴대전화에서는 아래 붙박이 메뉴 위에 뜬다. 좌우를 화면에 맞춰 글이 여러 줄로 접히지 않게 한다 */
.toast{position:fixed;left:16px;right:16px;bottom:calc(84px + env(safe-area-inset-bottom));margin-inline:auto;width:fit-content;max-width:calc(100vw - 32px);transform:translateY(16px);
  background:var(--ink);color:var(--bg);padding:12px 20px;border-radius:22px;font-size:.9rem;line-height:1.5;text-align:center;opacity:0;pointer-events:none;z-index:20;box-shadow:var(--shadow)}
.toast.on{opacity:1;transform:none}
@media (min-width:760px){ .toast{bottom:28px} }
@media (prefers-reduced-motion:no-preference){ .toast{transition:opacity .300s,transform .300s} }

/* 맨 아래: 누가 운영하는지, 어디로 말을 걸 수 있는지, 무엇을 지키는지로 가는 길 */
.foot{border-top:1px solid var(--line);padding-top:28px;margin-top:18px;display:flex;flex-direction:column;gap:14px}
.foot-top{display:flex;flex-direction:column;gap:18px}
.foot-name{display:flex;align-items:center;gap:8px;font-family:var(--display);font-weight:700;font-size:1.05rem;margin-bottom:4px}
.foot-name .mark{width:24px;height:24px}
.foot-name .brand-en{font-family:var(--body);padding-top:2px}
.foot-links{display:flex;flex-wrap:wrap;gap:0 4px;margin-left:-10px}
.foot-links a{display:inline-flex;align-items:center;min-height:44px;padding:0 10px;font-size:.9rem;color:var(--ink);text-decoration:none;border-radius:10px}
.foot-links a:hover{text-decoration:underline;text-underline-offset:4px}
.foot .tel{display:inline-block;padding:10px 8px;min-width:44px;text-align:center}
.foot a[href^="mailto"],.prose a[href^="mailto"]{white-space:nowrap}
.foot-row{display:flex;justify-content:space-between;align-items:center;gap:6px 16px;flex-wrap:wrap}
.foot-row .btn.quiet{margin-left:-10px;font-size:.875rem;color:var(--muted);text-decoration:none}
.foot-links a{white-space:nowrap}
@media (min-width:1100px){ .foot-top{flex-direction:row;justify-content:space-between;align-items:flex-start} .foot-links{margin:0 -10px 0 0;justify-content:flex-end;flex-wrap:nowrap} }
/* 글 속의 작은 링크도 손가락으로 누르기 쉽게 위아래로 누르는 자리를 넓힌다(글줄 높이는 그대로) */
main .small a:not(.tel):not(.btn),.meta a,.foot-row a{padding-block:10px}

@media (min-width:640px){
  body{padding-block:22px 64px}
  .wrap{gap:44px}
  .slip{padding:36px 34px 26px}
  .hero{padding-top:22px}
}
/* 큰 화면(컴퓨터)에서는 글자와 폭을 함께 키워, 휴대전화 화면을 그대로 늘린 것처럼 보이지 않게 한다 */
@media (min-width:960px){
  html{font-size:118.75%}
  body{padding-block:30px 80px}
  body::before{height:640px}
  .wrap{max-width:660px;gap:52px}
  .hero{padding-top:36px;gap:16px}
  main{gap:26px}
}

/* ── 넓은 화면 구성: 휴대전화 화면을 늘린 것이 아니라 두 단으로 짠다 ── */
.layout{display:flex;flex-direction:column;gap:26px}
.side{display:flex;flex-direction:column;gap:22px}
.home{display:flex;flex-direction:column;gap:26px}
.home-main,.home-side{display:flex;flex-direction:column;gap:22px;min-width:0}
.list.grid{display:grid;grid-template-columns:1fr;gap:12px}
.stack.big{gap:44px}
.below{min-width:0}
@media (min-width:1000px){
  /* 머리글과 맨 아래는 모든 화면에서 같은 폭이다. 읽는 글만 있는 화면은 본문만 좁혀 가운데에 둔다 */
  .wrap{max-width:1120px}
  .wrap:not(.wide)>main{max-width:660px;width:100%;margin-inline:auto}
  .layout{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:48px;align-items:start}
  .layout>.below{grid-column:1}
  .side{position:sticky;top:24px}
  .home{display:grid;grid-template-columns:minmax(0,1.200fr) minmax(0,.800fr);gap:72px;align-items:start;padding-top:12px}
  .home-side{padding-top:20px}
  .list.grid{grid-template-columns:1fr 1fr;gap:16px}
  .nav-top{margin-right:0}
  .slip{max-width:none}
  .hero{max-width:760px}
}

/* 옆 칸이 있는 화면은 폭이 넉넉해질 때까지 답 카드를 한 줄에 하나씩 놓는다(좁은 카드에서 글이 서너 줄로 접힌다) */
@media (min-width:1000px) and (max-width:1199px){ .layout .list.grid{grid-template-columns:1fr} }

/* 그림: 한 가지 선 굵기, 둥근 선 끝. 색은 화면 밝기에 따라 바뀐다 */
.art{width:100%;height:auto;display:block;fill:none;stroke:var(--edge);stroke-width:1.800;stroke-linecap:round;stroke-linejoin:round}
.art .glow{fill:var(--glow);stroke:none}
.art .soft{fill:var(--soft)}
.art .paper{fill:var(--surface)}
.art-wrap{max-width:320px;margin-inline:auto;width:100%}
.art-wrap.small{max-width:170px;margin:0 0 4px -8px}
.home-side .art-wrap{display:none}
@media (min-width:1000px){ .home-side .art-wrap{display:block;max-width:300px} }
.rest .art-wrap{max-width:260px}

/* 묶음 이름 옆의 작은 그림 */
.eyebrow.group{display:inline-flex;align-items:center;gap:6px;color:var(--accent)}
.fold>summary>.ic{color:var(--accent);width:20px;height:20px}
.chip .count{font-size:.8rem;color:var(--muted);font-variant-numeric:tabular-nums;margin-left:auto;padding-left:6px}

/* 답 화면의 머리: 누가 답했는지와 한 줄 */
.by{font-size:.9rem;color:var(--muted);line-height:1.6}
.by a{color:var(--ink);font-weight:600;text-decoration:none;border-bottom:1px solid var(--line)}
.by a:hover{border-color:var(--accent)}
h1.do{margin:0}
blockquote footer{margin-top:8px;font-family:var(--body)}
.meta{margin:4px 0 0;display:grid;gap:10px;font-size:.875rem;line-height:1.65;color:var(--muted)}
.meta>div{display:grid;grid-template-columns:3.200em 1fr;gap:10px}
.meta dt{font-weight:600;color:var(--ink)}
.meta dd{margin:0;min-width:0}
.meta a{white-space:nowrap}
/* 영상 덮개: 유튜브의 요란한 미리보기 그림 대신 차분한 단추. 누르면 그때 영상을 불러온다 */
.video-cover{font:inherit;color:var(--ink);text-align:left;width:100%;display:flex;align-items:center;gap:16px;padding:18px;border:1.500px solid var(--line);border-radius:var(--r-m);background:var(--soft);cursor:pointer}
.video-cover:hover{border-color:var(--accent)}
.video-cover .play{width:54px;height:54px;border-radius:50%;background:var(--accent);color:var(--accent-ink);display:grid;place-items:center;flex:none}
.video-cover .play .ic{width:24px;height:24px;fill:currentColor;stroke:none;margin-left:3px}
.video-cover>span:last-child{display:flex;flex-direction:column;line-height:1.5}
.video-cover>span:last-child>span{font-size:.875rem;color:var(--muted)}
.who-box p{display:flex;flex-direction:column;line-height:1.5}
.who-name{font-family:var(--display);font-weight:700;font-size:1.15rem;color:var(--ink);text-decoration:none}
.who-name:hover{color:var(--accent)}
.list.compact .item{padding:16px 18px 12px;box-shadow:none;border-color:var(--line)}
.list.compact .item .do{font-size:1.02rem}
ul.plain{list-style:none;margin:0;padding:0;font-size:.9rem;line-height:1.9}

/* 답한 사람 목록 */
.people{display:grid;grid-template-columns:repeat(auto-fill,minmax(270px,1fr));gap:12px}
.person{display:grid;grid-template-columns:1fr auto;gap:2px 12px;align-items:center;align-content:center;padding:16px 18px;background:var(--surface);border-radius:var(--r-m);box-shadow:var(--shadow);color:inherit;text-decoration:none;border:1.500px solid transparent}
.person:hover{border-color:var(--line)}
.person strong{font-family:var(--display);font-size:1.05rem}
.person .small{grid-column:1;line-height:1.5}
.person .count{grid-row:1/3;grid-column:2;font-size:.85rem;color:var(--accent);font-weight:600;background:var(--soft);border-radius:999px;padding:4px 10px}

/* 찾아보기 */
.search{display:flex;align-items:center;gap:10px;background:var(--surface);border:1.500px solid var(--edge);border-radius:999px;padding:4px 8px 4px 18px;box-shadow:var(--shadow);max-width:640px}
.search:focus-within{border-color:var(--accent);outline:3px solid var(--accent);outline-offset:2px}
.search>.ic{color:var(--muted);width:20px;height:20px}
.search input{font:inherit;flex:1;min-width:0;border:0;background:none;color:var(--ink);min-height:48px}
.search input:focus{outline:none}
.search input::placeholder{color:var(--muted);opacity:.85}
#hits{display:flex;flex-direction:column;gap:12px}
#hits:empty{display:none}
.groups{display:grid;grid-template-columns:1fr;gap:26px}
.find-group{display:flex;flex-direction:column;gap:10px}
@media (min-width:700px){ .groups{grid-template-columns:1fr 1fr;gap:30px 36px} }
/* 갈래가 다섯이라 격자로 놓으면 한 칸이 빈다. 넓은 화면에서는 세 단으로 흘려 높이를 맞춘다 */
@media (min-width:1000px){ .groups{display:block;columns:3;column-gap:36px} .find-group{break-inside:avoid;margin-bottom:34px} }

/* 내 서랍: 답과 '빼기' 단추 */
.kept{display:flex;flex-direction:column;gap:0}
.kept .item{flex:1}
.kept .remove{align-self:flex-end;font-size:.85rem;color:var(--muted);text-decoration:none;gap:4px}
.kept .remove .ic{width:14px;height:14px}

/* 소개 화면들 */
.subnav{display:flex;flex-wrap:wrap;gap:6px}
.subnav a{flex:none;display:inline-flex;align-items:center;min-height:44px;padding:0 16px;border-radius:999px;border:1.500px solid var(--line);background:var(--surface);color:var(--ink);text-decoration:none;font-size:.9rem}
.subnav a[aria-current="page"]{background:var(--accent);border-color:var(--accent);color:var(--accent-ink);font-weight:600}
.facts{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:1fr 1fr;gap:10px}
.facts li{background:var(--surface);border-radius:var(--r-m);padding:16px 18px;box-shadow:var(--shadow);display:flex;flex-direction:column}
.facts strong{font-family:var(--display);font-size:1.700rem;line-height:1.2;color:var(--accent);font-variant-numeric:tabular-nums}
.facts span{font-size:.85rem;color:var(--muted)}
@media (min-width:560px){ .facts{grid-template-columns:repeat(4,1fr)} }
.prose{display:flex;flex-direction:column;gap:14px;max-width:38em}
.prose h2{font-size:1.2rem;margin-top:18px;padding-top:22px;border-top:1px solid var(--line)}
.prose h2:first-child{margin-top:0;padding-top:0;border-top:0}
.prose ul,.prose ol{margin:0;padding-left:1.200em;display:flex;flex-direction:column;gap:8px}
.prose li{line-height:1.8}
.contact{display:inline-flex;align-items:center;gap:10px;font-size:1.1rem;font-weight:600;background:var(--soft);border-radius:999px;padding:10px 20px;align-self:flex-start}
.contact .ic{color:var(--accent)}
.changes{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;max-width:40em}
.changes>li{display:grid;grid-template-columns:1fr;gap:6px;padding:20px 0;border-top:1px solid var(--line)}
.changes time{font-family:var(--display);font-weight:700;color:var(--accent);font-variant-numeric:tabular-nums}
.changes ul{margin:0;padding-left:1.200em;display:flex;flex-direction:column;gap:6px}
@media (min-width:640px){ .changes>li{grid-template-columns:8em 1fr} }
.rest-invite.plain{background:var(--surface);box-shadow:var(--shadow)}
