/* 生成物。編集しない。正本は design/tokens.json と style/base.css。 */
:root {
  --blue: #0A78BD;
  --navy: #0F1419;
  --muted: #536471;
  --line: #E7ECEF;
  --surface: #F1F2F4;
  --white: #FFFFFF;
  --page: #FFFFFF;
  --card: #FFFFFF;
  --notice-bg: #FFF4D6;
  --notice-line: #E0B93C;
  --notice-ink: #8A6D1F;
  --success: #16A34A;
  --success-soft: #E8F6EE;
  --font-sans: -apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,'Hiragino Kaku Gothic ProN','Hiragino Sans','Noto Sans JP','Noto Sans CJK JP','Yu Gothic',Meiryo,sans-serif;
  --font-rounded: 'Hiragino Maru Gothic ProN','Hiragino Maru Gothic Pro','Noto Sans JP','Noto Sans CJK JP','Yu Gothic',Meiryo,sans-serif;
}

/* ぽいメモのWebページ共通スタイル。
   色・書体は デザイン/tokens.json から生成される :root の変数だけを使う。
   このファイルに色の実値を書かない。テーマはライト固定。 */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--page);
  color: var(--navy);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.8;
  letter-spacing: 0.01em;
}

/* 余白はこのコンテナだけが持つ。外側の要素は余白を持たない。 */
.shell {
  max-width: 34rem;
  margin-inline: auto;
  padding-inline: 1.25rem;
}

.site-head {
  border-bottom: 1px solid var(--line);
}

.site-head .shell {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding-block: 1.1rem;
}

.brand {
  font-family: var(--font-rounded);
  font-size: 1.1875rem;
  font-weight: 800;
  color: var(--blue);
}

main {
  padding-block: 2.5rem 2.75rem;
}

h1 {
  margin: 0 0 0.75rem;
  font-family: var(--font-rounded);
  font-size: 1.625rem;
  line-height: 1.45;
  font-weight: 800;
}

h2 {
  margin: 0 0 0.75rem;
  font-family: var(--font-rounded);
  font-size: 1.125rem;
  line-height: 1.6;
  font-weight: 800;
}

p {
  margin: 0 0 1rem;
}

p:last-child {
  margin-bottom: 0;
}

a {
  color: var(--blue);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

a:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
  border-radius: 2px;
}

.note {
  color: var(--muted);
  font-size: 0.875rem;
}

/* 成否や状態を示す印。装飾ではなく状態の理解に使う。 */
.state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: 1.25rem;
  border-radius: 50%;
  background: var(--success-soft);
  color: var(--success);
}

/* 主要操作。タップ領域は44px以上を確保する。 */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.75rem 1.75rem;
  border: 1px solid var(--blue);
  border-radius: 999px;
  background: var(--blue);
  color: var(--white);
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  text-decoration: none;
  filter: brightness(1.06);
}

.button:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}

/* ── ヒーロー ───────────────────────────────── */

.hero {
  text-align: center;
}

.hero .cta {
  margin: 1.5rem 0 0.75rem;
}

/* アプリ画面。横スワイプで切り替える。実機のスクリーンショットが用意できるまでの
   仮枠で、差し替えるときは各 .shot-screen の中身を画像に置き換える。 */
.shots {
  --slide: 13.5rem;
  display: flex;
  align-items: stretch;
  gap: 0.75rem;
  margin-top: 2.25rem;
  padding-inline: calc((100% - var(--slide)) / 2);
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  /* 端を薄くして、前後の画面が後ろに控えて見えるようにする。 */
  -webkit-mask-image: linear-gradient(
    to right,
    transparent 0,
    #000 10%,
    #000 90%,
    transparent 100%
  );
  mask-image: linear-gradient(to right, transparent 0, #000 10%, #000 90%, transparent 100%);
}

.shots::-webkit-scrollbar {
  display: none;
}

.shot {
  display: flex;
  flex: 0 0 var(--slide);
  padding: 0.375rem;
  border-radius: 2rem;
  background: #1f2326;
  box-shadow: 0 14px 34px rgba(15, 20, 25, 0.18);
  scroll-snap-align: center;
}

.shot-screen {
  flex: 1;
  padding: 1.25rem 0.75rem 0.5rem;
  border-radius: 1.625rem;
  background: var(--white);
  text-align: left;
}

.shot-head {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--line);
}

.shot-head img {
  width: 1.125rem;
  height: 1.125rem;
  border-radius: 0.3rem;
}

.shot-head span {
  font-family: var(--font-rounded);
  font-size: 0.875rem;
  font-weight: 800;
  color: var(--blue);
}

.post {
  display: grid;
  grid-template-columns: 1.625rem 1fr;
  gap: 0.5rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--line);
}

.post:last-child {
  padding-bottom: 0.25rem;
  border-bottom: 0;
}

.post .avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.625rem;
  height: 1.625rem;
  border-radius: 50%;
  background: #dcebf7;
  color: var(--blue);
  font-size: 0.6875rem;
  font-weight: 700;
}

.post .who {
  font-size: 0.6875rem;
  line-height: 1.4;
  color: var(--muted);
}

.post .who b {
  margin-right: 0.25rem;
  color: var(--navy);
}

.post .body {
  margin: 0.15rem 0 0;
  font-size: 0.75rem;
  line-height: 1.6;
}

.post .acts {
  display: flex;
  gap: 1rem;
  margin-top: 0.3rem;
  font-size: 0.625rem;
  color: var(--muted);
}

/* 投稿画面・検索画面のモック */

.shot-head .pill {
  margin-left: auto;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 1.5rem;
  padding: 0.15rem 0.8rem;
  border-radius: 999px;
  background: var(--blue);
  color: var(--white);
  font-family: var(--font-sans);
  font-size: 0.625rem;
  font-weight: 700;
  line-height: 1.4;
}

.compose {
  margin: 1rem 0 0;
  font-size: 0.8125rem;
  line-height: 1.7;
}

.search {
  margin: 1rem 0 0.25rem;
  padding: 0.45rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 0.6rem;
  background: var(--surface);
  font-size: 0.75rem;
}

.hit {
  margin: 0;
  padding: 0.55rem 0;
  border-top: 1px solid var(--line);
  font-size: 0.75rem;
  line-height: 1.6;
}

/* ── できること ─────────────────────────────── */

.features {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}

.features dl {
  margin: 0;
}

.features dl > div {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: 0.75rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
}

.features dl > div:last-child {
  border-bottom: 0;
}

.features dt {
  font-size: 0.875rem;
  font-weight: 800;
  color: var(--blue);
}

.features dd {
  margin: 0;
  font-size: 0.9375rem;
}

/* ── ニュースレターの登録 ─────────────────────── */

.signup {
  margin-top: 2.5rem;
  padding: 1.75rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--surface);
}

.signup form {
  margin: 1.25rem 0 0.75rem;
}

.field {
  margin: 0 0 1rem;
}

label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--muted);
}

/* 16px未満だとiOSが自動ズームするため、1remを下回らない。 */
input[type="email"] {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.7rem 1rem;
  border: 1px solid var(--line);
  border-radius: 0.625rem;
  background: var(--white);
  color: var(--navy);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.5;
}

input[type="email"]:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
  border-color: var(--blue);
}

button[type="submit"] {
  width: 100%;
}

/* ── フッター ───────────────────────────────── */

.site-foot {
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.site-foot .shell {
  padding-block: 1.1rem;
  font-size: 0.75rem;
  color: var(--muted);
}

.site-foot p {
  margin: 0;
}

@media (min-width: 30rem) {
  h1 {
    font-size: 1.875rem;
  }
}
