/* 催促ちゃん  saisoku-chan.jp
   生成りの便箋と、くすんだ赤。本文は最小14px(12pxはコピーライトのみ)。 */
:root{
  --paper:#FBF6EE; --letter:#FFFDF7; --white:#FFFFFF;
  --ink:#3B2F2A; --sub:#5E4E46; --line:#C9B8A8;
  --accent:#B8405A; --accent-hover:#A5364F; --accent-deep:#8C2F45; --blush:#F8DCE1;
  --maru:'Zen Maru Gothic','Hiragino Maru Gothic ProN','Yu Gothic',sans-serif;
  --tegaki:'Klee One','Zen Maru Gothic','Hiragino Mincho ProN',serif;
}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--paper);color:var(--ink);font-family:var(--maru);font-size:16px;line-height:1.7}
img{max-width:100%;height:auto}
a{color:var(--accent-deep)} a:hover{color:#6E2335}
rt{font-size:.6em;font-weight:500;letter-spacing:0}
[hidden]{display:none !important}
:focus-visible{outline:3px solid var(--accent);outline-offset:3px;border-radius:6px}
/* 画面の切りかえで読み上げ位置を動かすための focus。枠は出さない */
[tabindex="-1"]:focus{outline:none}

.page{max-width:430px;min-height:100vh;min-height:100dvh;margin:0 auto;padding:28px 24px 24px;display:flex;flex-direction:column;gap:20px}
.stack{display:flex;flex-direction:column;gap:20px}
.stack--tight{gap:12px}

/* なまえ */
.brand__name{margin:0;font-size:30px;font-weight:700;letter-spacing:.04em;line-height:1.9}
.brand__tag{margin:0;font-size:14px;color:var(--sub)}
.title{margin:0;font-size:24px;font-weight:700;letter-spacing:.04em;line-height:1.9}
.lead{margin:0;font-size:14px;color:var(--sub)}
.h2{margin:0;font-size:16px;font-weight:700}
.small{margin:0;font-size:14px;line-height:1.8;color:var(--sub)}

/* 催促ちゃんと ふきだし */
.chara{display:flex;align-items:center;gap:12px}
.chara__img{width:100px;flex-shrink:0}
.chara--center{flex-direction:column;gap:14px}
.chara--center .chara__img{width:200px}
.chara--mid .chara__img{width:180px}
.bubble{flex-grow:1;margin:0;background:var(--white);border:1.5px solid var(--ink);border-radius:18px;padding:12px 14px;font-size:15px;line-height:1.7}
.chara--center .bubble{align-self:stretch;font-size:17px;line-height:1.8;padding:14px 18px}
/* 手紙のすぐ下で、だれの言葉かを はっきりさせる:絵 → しっぽつきの ふきだし */
.chara--says{gap:16px}
.chara--says .chara__img{width:150px}
.chara--says .bubble{position:relative}
.chara--says .bubble::before{content:"";position:absolute;left:50%;top:-9px;width:16px;height:16px;margin-left:-8px;background:var(--white);border-left:1.5px solid var(--ink);border-top:1.5px solid var(--ink);transform:rotate(45deg);border-top-left-radius:3px}

/* ひらく前の絵:2枚を 2秒おきに フェードで切りかえる(同じ枠で切ってあるので位置はずれない) */
.swap{position:relative}
.swap img{position:absolute;inset:0;width:100%;height:100%}
.swap__a{animation:swap-a 4s ease-in-out infinite}
.swap__b{animation:swap-b 4s ease-in-out infinite}
@keyframes swap-a{0%,42%{opacity:1}50%,92%{opacity:0}100%{opacity:1}}
@keyframes swap-b{0%,42%{opacity:0}50%,92%{opacity:1}100%{opacity:0}}
@media (prefers-reduced-motion:reduce){.swap__a{animation:none;opacity:0}.swap__b{animation:none;opacity:1}}

/* 入力 */
.field{display:flex;flex-direction:column;gap:6px}
.field label{font-size:15px;font-weight:700}
.field label span{font-weight:400;color:var(--sub)}
.field input{height:52px;padding:0 14px;font:inherit;font-size:16px;color:var(--ink);background:var(--white);border:1.5px solid var(--ink);border-radius:12px;width:100%}
.field input::placeholder{color:#7A6A61}
.field input[aria-invalid="true"]{border-color:var(--accent);background:#FFF6F7}
.field .hint{font-size:14px;color:var(--sub)}
.field .error{font-size:14px;color:var(--accent-deep);font-weight:700}

/* ボタン */
.btn{display:flex;align-items:center;justify-content:center;width:100%;min-height:56px;padding:8px 18px;border-radius:28px;border:none;background:var(--accent);color:#fff;font:inherit;font-size:17px;font-weight:700;text-decoration:none;text-align:center;cursor:pointer}
.btn:hover{color:#fff;background:var(--accent-hover)}
.btn--line{min-height:52px;border-radius:26px;border:1.5px solid var(--ink);background:var(--white);color:var(--ink);font-size:16px}
.btn--line:hover{background:var(--paper);color:var(--ink)}
.btn--dark{min-height:52px;border-radius:26px;background:var(--ink);font-size:16px}
.btn--dark:hover{background:#2A211D}
.btn--small{width:auto;flex-shrink:0;white-space:nowrap;min-height:44px;padding:0 18px;border-radius:22px;font-size:15px}
.btn--text{width:auto;min-height:44px;padding:0 16px;background:transparent;color:#4A3A35;font-size:15px;font-weight:400;text-decoration:underline;align-self:center}
.btn--text:hover{background:transparent;color:var(--ink)}
.row2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.row3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}

/* おてがみ(便箋) */
.letter{background:var(--letter);border:1.5px solid var(--ink);border-radius:10px;padding:22px 22px 18px;display:flex;flex-direction:column;gap:14px;font-family:var(--tegaki)}
.letter__to{margin:0;font-size:21px;font-weight:600}
.letter__row{display:flex;flex-direction:column;gap:2px;padding-bottom:12px;border-bottom:1.5px dashed var(--line)}
.letter__row:last-of-type{border-bottom:none;padding-bottom:0}
.letter__label{font-size:14px;color:var(--sub)}
.letter__value{font-size:20px;overflow-wrap:anywhere}
.letter__value--amount{font-size:34px;font-weight:600;line-height:1.3}
.letter__value--pay{font-size:18px;line-height:1.6}
.letter__from{margin:0;font-size:15px;text-align:right;line-height:1.6}
.letter__from small{font-size:14px;color:var(--sub)}
.letter--mini{padding:18px 20px;gap:8px}
.letter--mini .letter__to{font-size:18px}
.letter--mini .mini-what{font-size:17px;overflow-wrap:anywhere}
.letter--mini .mini-amount{font-size:28px;font-weight:600}
.letter--mini a{font-family:var(--maru);font-size:15px;font-weight:700;min-height:44px;display:flex;align-items:center}

/* 封筒(この画面の主役。ひらく動きはここだけ) */
.envelope{display:flex;flex-direction:column;align-items:center;gap:12px;width:100%;padding:8px 0 0;border:none;background:transparent;color:var(--ink);font:inherit;cursor:pointer}
.envelope svg{width:264px;max-width:80%;height:auto;display:block}
.envelope__label{display:flex;align-items:center;justify-content:center;min-height:56px;width:100%;border-radius:28px;background:var(--accent);color:#fff;font-size:17px;font-weight:700}
.envelope:hover .envelope__label{background:var(--accent-hover)}
.reveal{animation:rise .5s ease-out both}
@keyframes rise{from{opacity:0;transform:translateY(18px)}to{opacity:1;transform:none}}
@media (prefers-reduced-motion:reduce){.reveal{animation:none}}

/* かこみ */
.card{background:var(--white);border:1.5px solid var(--ink);border-radius:16px;padding:18px;display:flex;flex-direction:column;gap:12px}
.card--blush{background:var(--blush);border:none;padding:20px}
.card__title{margin:0;font-size:18px;font-weight:700;line-height:1.6}
.card p{margin:0;font-size:15px;line-height:1.8}
.quote{background:var(--paper);border-radius:12px;padding:14px 16px;font-size:16px;line-height:1.8;overflow-wrap:anywhere}
.replybox{background:var(--white);border:1.5px solid var(--ink);border-radius:12px;padding:14px 16px;font-size:16px;line-height:1.8;overflow-wrap:anywhere}

/* トークでの見えかた */
.preview{display:flex;gap:12px;align-items:center;background:var(--white);border:1.5px solid var(--line);border-radius:14px;padding:12px}
.preview__thumb{width:64px;height:64px;flex-shrink:0;border-radius:10px;background:var(--blush);display:flex;align-items:center;justify-content:center}
.preview__title{font-size:15px;font-weight:700;line-height:1.5}
.preview__domain{font-size:14px;color:var(--sub)}
.copyrow{display:flex;gap:10px;align-items:center;background:var(--white);border:1.5px solid var(--ink);border-radius:12px;padding:8px 8px 8px 14px}
.copyrow__text{flex-grow:1;font-size:16px;line-height:1.6}

/* メモ帳 */
.totals{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.total{background:var(--white);border:1.5px solid var(--ink);border-radius:14px;padding:14px 16px}
.total--done{background:var(--blush);border-color:transparent}
.total__label{font-size:14px;color:var(--sub)}
.total--done .total__label{color:#4A3A35}
.total__value{font-size:24px;font-weight:700}
.entry{background:var(--letter);border:1.5px solid var(--ink);border-radius:12px;padding:18px;display:flex;flex-direction:column;gap:10px}
.entry__head{display:flex;justify-content:space-between;align-items:baseline;gap:12px;font-family:var(--tegaki)}
.entry__to{font-size:19px;font-weight:600;overflow-wrap:anywhere}
.entry__what{font-size:16px;overflow-wrap:anywhere}
.entry__amount{font-size:26px;font-weight:600;white-space:nowrap}
.entry__meta{display:flex;justify-content:space-between;align-items:center;gap:12px;font-size:14px;color:var(--sub)}
.entry__meta button{min-height:44px;padding:0 8px;border:none;background:transparent;color:var(--sub);font:inherit;font-size:14px;text-decoration:underline;cursor:pointer}
.entry--done{background:var(--white);border:1.5px dashed var(--line);flex-direction:row;justify-content:space-between;align-items:center;padding:16px 18px;font-family:var(--tegaki)}
.entry--done .entry__to{font-size:18px}
.entry--done .entry__what{font-size:15px}
.entry--done .entry__amount{font-size:22px;display:flex;align-items:center;gap:8px}
.stamp{transform:rotate(-8deg);border:2.5px solid var(--accent-deep);border-radius:10px;padding:6px 10px;color:var(--accent-deep);font-size:16px;font-weight:600;text-align:center;line-height:1.4;flex-shrink:0}
.sumrow{display:flex;justify-content:space-between;align-items:baseline;gap:12px;padding:0 4px;font-size:15px}
.sumrow strong{font-size:24px;white-space:nowrap}
.tip{min-height:72px;padding:0 2px;border-radius:14px;border:1.5px solid var(--ink);background:var(--white);color:var(--ink);font:inherit;font-size:14px;font-weight:700;line-height:1.5;text-decoration:none;display:flex;align-items:center;justify-content:center;text-align:center}
.tip:hover{background:var(--paper);color:var(--ink)}

/* よみもの(このサービスについて・表記) */
.prose h2{margin:12px 0 0;font-size:18px}
.prose p,.prose li{font-size:16px;line-height:1.9;margin:0}
.prose ul{margin:0;padding-left:1.3em;display:flex;flex-direction:column;gap:6px}
.deftable{width:100%;border-collapse:collapse;font-size:15px;line-height:1.8}
.deftable th,.deftable td{border-top:1.5px dashed var(--line);padding:12px 0;text-align:left;vertical-align:top}
.deftable th{width:36%;padding-right:12px;font-weight:700}

/* フッター */
.foot{margin-top:auto;display:flex;flex-direction:column;gap:12px}
.foot__ai{margin:0;font-size:14px;line-height:1.8;color:var(--sub)}
.foot__links{padding-top:16px;border-top:1.5px dashed var(--line);display:flex;flex-wrap:wrap;gap:4px 18px;font-size:14px}
.foot__links a{min-height:44px;display:inline-flex;align-items:center}
.foot__copy{margin:0;font-size:12px;color:var(--sub);text-align:center}

.toast{position:fixed;left:50%;bottom:24px;transform:translateX(-50%);background:var(--ink);color:#fff;font-size:15px;padding:12px 20px;border-radius:24px;z-index:10;max-width:90vw}

/* ===== かかりごとの色(催促ちゃん=くすんだ赤 / 督促くん=くすんだ青 / 催告さん=墨) ===== */
[data-level="2"]{--accent:#47597F; --accent-hover:#3C4C6E; --accent-deep:#35435F; --blush:#DEE3EE}
[data-level="3"]{--accent:#3A3F47; --accent-hover:#2E3238; --accent-deep:#2B2F35; --blush:#E6E4E0; --paper:#F5F3EF}
body[data-level="3"]{background:var(--paper)}
.seal{fill:var(--accent-deep)}
[data-level="3"] .letter{border-radius:4px}
[data-level="3"] .letter,[data-level="3"] .bubble{font-family:var(--maru)}
[data-level="3"] .bubble{border-radius:8px}

/* よみとった金額 */
.field .hint--read{font-weight:700;color:var(--ink)}
.field .hint--ng{color:var(--accent-deep)}
.field input[type="date"]{-webkit-appearance:none;appearance:none}

.btn--mid{min-height:52px;font-size:16px}
.btn--reply{font-size:15px;padding:8px 6px}

/* おてがみ:2通目からの追記 */
.letter__note{margin:0;font-size:14px;color:var(--sub)}
.letter__row--due{border-bottom-style:solid !important}
.letter__value--due{font-size:24px;font-weight:600;color:var(--accent-deep)}

/* ひきつぎ */
.handoff{display:flex;align-items:center;gap:12px;padding-top:12px;border-top:1.5px dashed var(--line)}
.handoff__img{width:56px;flex-shrink:0}
.handoff__btn{flex:1}
.handoff--end{align-items:flex-start}
.handoff--end a{font-size:15px;font-weight:700;min-height:44px;display:inline-flex;align-items:center}
.handoff__say{margin:0;font-size:15px;line-height:1.7}
.relay{display:flex;flex-direction:column;gap:4px}
.relay__from .chara__img{width:84px;opacity:.85}
.relay__from .bubble{font-size:14px}
.relay__pass{align-self:center;color:var(--accent-deep);animation:pass .9s ease-out .35s both}
.relay__to{animation:rise .6s ease-out .9s both}
@keyframes pass{from{opacity:0;transform:translateY(-22px) rotate(-8deg)}to{opacity:1;transform:none}}
@media (prefers-reduced-motion:reduce){.relay__pass,.relay__to{animation:none}}

/* 3人の かかり */
.cast{display:flex;flex-direction:column;gap:16px}
.cast__one{display:flex;align-items:center;gap:14px}
.cast__one img{width:92px;flex-shrink:0}
.cast__one h3{margin:0;font-size:17px;line-height:1.9}
.cast__one h3 small{margin-left:10px;font-size:14px;font-weight:500;color:var(--sub)}
.cast__one p{font-size:15px;line-height:1.8}
/* つくったひと */
.maker{display:flex;align-items:flex-end;gap:16px}
.maker img{width:88px;flex-shrink:0}
.maker p{font-size:15px;line-height:1.8}
.maker strong{font-size:17px}
/* リンクに見えるボタン */
.linklike{align-self:flex-start;min-height:44px;padding:0;border:none;background:none;font:inherit;font-size:15px;font-weight:700;color:var(--accent-deep);text-decoration:underline;text-align:left;cursor:pointer}

/* あいてに見える画面(上に重ねる) */
.modal{position:fixed;inset:0;z-index:50;display:flex;align-items:center;justify-content:center;padding:max(12px,env(safe-area-inset-top)) 12px max(12px,env(safe-area-inset-bottom));background:rgba(59,47,42,.55)}
.modal[hidden]{display:none}
.modal__box{display:flex;flex-direction:column;gap:12px;width:100%;max-width:430px;height:100%;max-height:820px;padding:14px;background:var(--paper);border:1.5px solid var(--ink);border-radius:18px}
.modal__bar{display:flex;align-items:center;justify-content:space-between;gap:12px}
.modal__frame{flex:1 1 auto;min-height:0;width:100%;border:1.5px solid var(--line,#C9B8A8);border-radius:12px;background:var(--paper)}
body.is-modal{overflow:hidden}
.prose li a,.prose p a{font-weight:700}
.entry__meta button{white-space:nowrap;flex-shrink:0}

/* ===== ひきつぎは目立たせない:ひらいた人にだけ見せる ===== */
.more{border-top:1.5px dashed var(--line);padding-top:4px}
.more summary{min-height:44px;display:flex;align-items:center;font-size:14px;color:var(--sub);text-decoration:underline;cursor:pointer;list-style:none}
.more summary::-webkit-details-marker{display:none}
.more__box{display:flex;flex-direction:column;gap:10px;padding-bottom:4px}
.more .handoff{border-top:none;padding-top:0}
.handoff__txt{flex:1;min-width:0}
.handoff__name{font-size:16px;font-weight:700;line-height:1.9}
.handoff__role{font-size:14px;color:var(--sub);line-height:1.6}
.handoff--end a{margin-right:16px}
.more__link{font-size:14px;min-height:44px;display:inline-flex;align-items:center}
.quiet{text-align:center}

/* ===== 「かえして」の だんだん:下へ行くほど、線が太く、色が重くなる ===== */
.dan{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}
.dan__step{--w:3px;position:relative;padding:4px 0 32px 22px;border-left:var(--w) solid var(--accent);display:flex;flex-direction:column;gap:12px}
.dan__step[data-level="2"]{--w:5px;margin-left:10px}
.dan__step[data-level="3"]{--w:7px;margin-left:20px}
.dan__step--court{--w:10px;--accent:#1F1B1A;--accent-deep:#1F1B1A;margin-left:30px}
.dan__step--last{--w:14px;margin-left:40px;padding-bottom:8px}
.dan__head{display:flex;align-items:center;justify-content:space-between;gap:12px}
.dan__no{font-size:14px;font-weight:700;color:var(--accent-deep)}
.dan__meter{display:inline-flex;gap:4px}
.dan__meter i{width:16px;height:8px;border-radius:2px;border:1.5px solid var(--accent-deep)}
.dan__meter i.on{background:var(--accent-deep)}
.dan__term{margin:0;font-size:26px;font-weight:700;letter-spacing:.04em;line-height:1.9;color:var(--accent-deep)}
.dan__step p,.dan__step li{margin:0;font-size:16px;line-height:1.9}
.dan__step ul{margin:0;padding-left:1.3em;display:flex;flex-direction:column;gap:8px}
.dan__step a{font-weight:700}
.dan__step .bubble{font-size:15px;line-height:1.7}
.dan__step .chara__img{width:84px}
.dan__caution{background:var(--blush);border-radius:12px;padding:14px 16px;font-size:15px !important;line-height:1.8 !important}
.dan__three{display:flex;align-items:flex-end;gap:6px}
.dan__three img{width:56px}
.letter--mini .linklike{font-family:var(--maru)}
