/* つぎいく（旧サークルノート） — 掲示板寄りの顔（決め 9: docs/circle/design.md）。紺 #14213d の表紙と、オレンジ #ff6b35 の帯・札。ほかのサービスとは色もロゴも揃えない（決め 1）。
   スマホ幅 390 が本番。文字は 16px を基準に、小さくても 12px。入力の欄の文字は 16px 以上（iPhone の Safari は 16px 未満の欄に触ると画面を拡大する。test.mjs が見る）。
   style 属性と innerHTML は使わない（CSP は inline を許さない） */
:root {
  --bg: #f2f4f7; --card: #ffffff; --ink: #14213d; --sub: #6b7280; --navy: #14213d; --acc: #ff6b35; --onacc: #ffffff; --line: #e5e7eb; --soft: #fff1eb; --danger: #b4452f; --ok: #2f7d4f;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: "Hiragino Kaku Gothic ProN", "Noto Sans JP", system-ui, sans-serif; font-size: 16px; line-height: 1.5; }
main { max-width: 560px; margin: 0 auto; padding: 0 14px 120px; }
a { color: var(--navy); }
button, input, textarea, select { font: inherit; color: inherit; }
[hidden] { display: none !important; }

/* 表紙（紺）。上の行に名前と呼び名・[ログアウト]、サークルのページではサークル名・人数・幹事・頭文字の丸 */
.hero { background: var(--navy); color: #fff; padding: 14px 18px 22px; border-radius: 0 0 26px 26px; }
.hero > * { max-width: 532px; margin-left: auto; margin-right: auto; }
.hero .top { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 13px; }
.brand { font-size: 15px; font-weight: 700; color: #fff; opacity: .85; text-decoration: none; letter-spacing: .04em; display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.brand img { width: 22px; height: 22px; border-radius: 5px; }   /* 顔の絵（icon-180.png を 22px に。地つきの角丸の札として。2026-10-27） */
.who { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #fff; opacity: .85; min-width: 0; }
.who .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 140px; }
.hero .btn.plain { border-color: rgba(255, 255, 255, .45); color: #fff; background: transparent; }
.hero .ttl { display: flex; align-items: center; gap: 10px; margin: 14px 0 2px; }   /* サークルの絵と名前（2026-10-27） */
.hero .ttl h1 { margin: 0; min-width: 0; }
.hero-art { flex: 0 0 auto; width: 44px; height: 44px; border-radius: 10px; background: #fff; display: inline-flex; align-items: center; justify-content: center; }   /* 紺の表紙に紺の線は消えるので白の地の札（頭の icon-180 の札と同じ作り） */
.hero-art .ic { width: 34px; height: 34px; display: block; }
.hero h1 { color: #fff; font-size: 30px; font-weight: 800; margin: 14px 0 2px; letter-spacing: .02em; line-break: strict; overflow-wrap: anywhere; }
.hero .n { font-size: 13px; opacity: .8; overflow-wrap: anywhere; }
.hero .lnk { color: #fff; opacity: .8; }
.hero .acts { margin: 2px 0 0; }
.avs { display: flex; flex-wrap: wrap; margin-top: 12px; padding-left: 8px; }
.av { width: 34px; height: 34px; border-radius: 50%; background: #fff; color: var(--navy); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; border: 2px solid var(--navy); margin-left: -8px; margin-bottom: 4px; padding: 0; overflow: hidden; }
.av.more { background: var(--line); font-size: 12px; }
.av.add { background: var(--acc); color: #fff; cursor: pointer; }

h1 { font-size: 24px; font-weight: 800; margin: 12px 0 4px; line-break: strict; overflow-wrap: anywhere; }
h2 { font-size: 14px; color: var(--sub); font-weight: 700; margin: 22px 4px 8px; letter-spacing: .1em; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
h2 .cnt { font-weight: 500; letter-spacing: 0; }
.sub { color: var(--sub); font-size: 14px; margin: 4px 0 0; }
.hint { color: var(--sub); font-size: 13px; margin: 6px 0; overflow-wrap: anywhere; }
.empty { color: var(--sub); margin: 8px 4px; font-size: 14px; }

/* 上の帯（一言・失敗の一言・確かめ。日本語のキーボードで下が隠れるので上） */
.band { position: fixed; top: 0; left: 0; right: 0; z-index: 10; padding: 12px 16px; padding-top: calc(12px + env(safe-area-inset-top)); background: var(--acc); color: var(--onacc); font-size: 15px; font-weight: 700; text-align: center; box-shadow: 0 2px 10px rgba(20, 33, 61, .2); }
.band.bad { background: var(--danger); }
.band.note { background: var(--soft); color: var(--ink); font-weight: 500; }
.band.ask { background: var(--card); color: var(--ink); border-bottom: 3px solid var(--acc); text-align: left; font-weight: 500; }
.band.ask .acts { display: flex; gap: 8px; margin-top: 8px; }

/* 札。main はオレンジ、navy は紺（ログインの 2 札を見分ける）、add は点線の丸、go は幅いっぱいのオレンジ */
.btn { display: inline-block; padding: 11px 16px; border-radius: 999px; border: 1.5px solid var(--navy); background: var(--card); color: var(--navy); font-size: 15px; font-weight: 700; cursor: pointer; text-decoration: none; text-align: center; }
.btn.main { background: var(--acc); border-color: var(--acc); color: var(--onacc); }
.btn.navy { background: var(--navy); border-color: var(--navy); color: var(--onacc); }
.btn.small { padding: 6px 12px; font-size: 13px; }
.btn.plain { border-color: var(--line); color: var(--ink); font-weight: 500; }
.btn.warn { border-color: var(--danger); color: var(--danger); font-weight: 500; }
.btn.add { border: 1.5px dashed var(--sub); color: var(--sub); font-size: 14px; padding: 9px 14px; margin: 4px 0 0; }
.btn.add::before { content: "＋ "; }
.btn.go { display: block; width: 100%; padding: 14px; border-radius: 14px; background: var(--acc); border-color: var(--acc); color: var(--onacc); font-size: 17px; font-weight: 800; }
.btn.go.on { background: #e85a26; border-color: #e85a26; }
.btn:disabled { opacity: .5; cursor: default; }
.btn.block { display: block; width: 100%; }
.lnk { background: none; border: 0; padding: 0; color: var(--navy); text-decoration: underline; cursor: pointer; font-size: 14px; }
.lnk.warn { color: var(--danger); }
.acts { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

/* 入口・招待・見られないとき: 白いカード */
.intro { margin: 18px 0; padding: 18px 16px; background: var(--card); border-radius: 18px; box-shadow: 0 8px 24px rgba(20, 33, 61, .08); }
.intro h1 { margin-top: 0; }
.intro p { margin: 0 0 12px; }
.intro ul { margin: 0 0 14px; padding-left: 20px; color: var(--sub); font-size: 14px; }
.logins { display: grid; gap: 10px; }
.logins .btn { padding: 13px 16px; font-size: 16px; }
.list { list-style: none; margin: 0; padding: 0; }
.list li, .card { background: var(--card); border-radius: 16px; padding: 12px 16px; margin-bottom: 8px; box-shadow: 0 2px 8px rgba(20, 33, 61, .05); }
.row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.row .t { font-weight: 700; font-size: 17px; text-decoration: none; color: var(--ink); overflow-wrap: anywhere; flex: 1; min-width: 0; }
.li-art { width: 26px; height: 26px; vertical-align: -7px; margin-right: 8px; }   /* 入口の一覧の行の小さな絵（白の札の上なので地は要らない） */
.tag { font-size: 12px; color: var(--acc); background: var(--soft); border-radius: 999px; padding: 2px 8px; margin-left: 6px; display: inline-block; white-space: nowrap; vertical-align: middle; font-weight: 700; }
.tag.me { color: #fff; background: var(--navy); }

/* 欄（1 行の文・日付・選択）。文字は 16px */
.f { margin: 0 0 10px; }
.f label { display: block; font-size: 13px; color: var(--sub); margin-bottom: 4px; }
.f input, .f select { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); font-size: 16px; }
.f.two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.f .lbl { display: block; font-size: 13px; color: var(--sub); margin-bottom: 4px; }
.form { background: var(--soft); border-radius: 16px; padding: 12px 14px; margin: 8px 0 14px; }
/* 絵を選ぶ（かえるまでの格子と同じ作り。2026-10-27）: 今の絵と「選ぶ」の札、押すとその場に 50 枚＋「なし」の格子（幅 390 で 5 列、1 つ 52px 以上） */
.artpick { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; }
.artpick .ic, .artbtn .ic { width: 36px; height: 36px; object-fit: contain; display: block; }
.ic.none { display: inline-flex; align-items: center; justify-content: center; font-size: 12px; color: var(--sub); border: 1px dashed var(--sub); border-radius: 8px; }
.artpick .artname { font-size: 14px; }
.artpick .artlbl { font-size: 13px; color: var(--acc); font-weight: 700; }
.artgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 6px; margin-top: 8px; padding: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; }
.artbtn { padding: 4px; border: 2px solid transparent; border-radius: 10px; background: var(--card); cursor: pointer; display: flex; align-items: center; justify-content: center; min-height: 52px; }
.artbtn.on { border-color: var(--acc); background: var(--soft); }

/* 活動の札。先のものは上にオレンジの帯（日付を大きく）、白い本文に場所・一言・行く人の札・幅いっぱいの [行く] */
.ev { padding: 0 !important; overflow: hidden; box-shadow: 0 8px 24px rgba(20, 33, 61, .08) !important; border-radius: 18px !important; }
.ev .head { background: var(--acc); color: #fff; padding: 12px 16px; display: flex; align-items: baseline; gap: 10px; }
.ev .dt { font-weight: 800; font-size: 30px; line-height: 1; }
.ev .slot { font-weight: 700; font-size: 14px; }
.ev .ev-art { margin-left: auto; align-self: center; width: 40px; height: 40px; border-radius: 9px; background: #fff; display: inline-flex; align-items: center; justify-content: center; }   /* 絵: 橙の帯の右に白の地の札（2026-10-27） */
.ev .ev-art .ic { width: 30px; height: 30px; display: block; }
.ev .body { padding: 14px 16px 16px; }
.ev .pl { font-size: 22px; font-weight: 800; margin: 0; overflow-wrap: anywhere; line-height: 1.3; }
.ev .pl a { color: var(--ink); text-decoration-color: #c8ccd4; text-underline-offset: 4px; }
.ev .d { display: flex; flex-wrap: wrap; gap: 2px 10px; color: var(--sub); font-size: 14px; margin: 4px 0 10px; }
.ev .note { white-space: pre-wrap; overflow-wrap: anywhere; }
.ev .by { font-size: 13px; }
.ev .going { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; margin: 0 0 12px; }
.ev .going b { color: var(--sub); font-weight: 700; }
.ev .going .sep { display: none; }   /* 「行く人 1: さうな」の「:」。文としては残し、札の並びでは出さない */
.chip { background: var(--soft); color: var(--acc); border-radius: 999px; padding: 4px 10px; font-size: 13px; font-weight: 700; overflow-wrap: anywhere; }
.chip.me { background: var(--navy); color: #fff; }
.ev .acts { margin-top: 10px; }
.ev .acts .btn.go { margin-bottom: 2px; }
/* 済んだもの: 左に日付、右に場所と来た人 */
.ev.past { display: grid; grid-template-columns: 64px 1fr; column-gap: 10px; align-items: start; padding: 12px 16px !important; box-shadow: 0 2px 8px rgba(20, 33, 61, .05) !important; border-radius: 16px !important; }
.ev.past .head { background: none; color: var(--navy); padding: 2px 0 0; display: block; }
.ev.past .dt { font-size: 15px; line-height: 1.25; display: block; }
.ev.past .slot { display: block; color: var(--sub); font-size: 12px; margin-top: 2px; }
.ev.past .body { padding: 0; min-width: 0; }
.ev.past .pl { font-size: 17px; font-weight: 700; }
.ev.past .pl-art { width: 20px; height: 20px; vertical-align: -4px; margin-right: 5px; }   /* これまでの行: 場所の前に小さく */
.ev.past .d { margin: 2px 0 4px; font-size: 13px; }
.ev.past .by { font-size: 12px; }
.ev.past .came { font-size: 13px; color: var(--sub); overflow-wrap: anywhere; }
.ev.past .came b { color: var(--navy); }
.ev.past .came .lnk { margin-left: 4px; font-size: 12px; }
.ev.past .acts { margin-top: 8px; }

/* 行ってみたい: 左に名前と挙げた人、右に [行った] の丸い札。行ったものは薄く・打ち消し線 */
.want { display: grid; grid-template-columns: 1fr auto; align-items: center; column-gap: 10px; }
.want .nm { font-weight: 700; font-size: 17px; overflow-wrap: anywhere; }
.want .nm a { color: var(--ink); text-decoration-color: #c8ccd4; text-underline-offset: 4px; }
.want .by { color: var(--sub); font-size: 12px; }
.want .acts { grid-column: 2; grid-row: 1 / 3; justify-content: flex-end; flex-wrap: nowrap; }
.want.done { opacity: .55; }
.want.done .nm { font-weight: 700; text-decoration: line-through; }

/* メンバー */
.mem .nm { overflow-wrap: anywhere; font-weight: 700; }
.mem .acts { flex-wrap: nowrap; }
.invite { margin: 10px 0 0; background: var(--card); border-radius: 16px; padding: 12px 16px; box-shadow: 0 2px 8px rgba(20, 33, 61, .05); }
.invite .hint { margin-top: 0; }
.invite input { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); font-size: 16px; margin-bottom: 8px; }

/* 下の小さなもの（呼び名・ほかの口を結ぶ・抜ける・退会） */
.settings { margin: 36px 0 0; padding-top: 12px; border-top: 1px solid var(--line); }
.settings h3 { font-size: 13px; color: var(--sub); margin: 14px 0 6px; font-weight: 700; letter-spacing: .1em; }
.settings input { flex: 1; min-width: 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); font-size: 16px; }
.foot { margin-top: 40px; color: var(--sub); font-size: 13px; text-align: center; }
.foot a { color: var(--sub); }

/* 文書（プライバシー・規約） */
.doc h1 { font-size: 22px; margin-top: 20px; }
.doc h2 { display: block; font-size: 16px; color: var(--ink); margin: 22px 0 6px; letter-spacing: 0; }
.doc .updated { font-size: 13px; color: var(--sub); }
.doc table { border-collapse: collapse; width: 100%; font-size: 14px; background: var(--card); }
.doc th, .doc td { border: 1px solid var(--line); padding: 6px 8px; text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.doc th { background: var(--soft); }
