:root {
  color-scheme: light;
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-muted: #f5f5f5;
  --line: #e2e2e2;
  --line-strong: #c9c9c9;
  --ink: #26312d;
  --muted: #6b746f;
  --accent: #22735d;
  --accent-strong: #155f4b;
  --accent-soft: #dceee7;
  --gold-soft: #fff0c8;
  --coral: #bc5d4f;
  --pop-ink: #162722;
  --pop-yellow: #ffe466;
  --pop-mint: #dbfff1;
  --danger: #a74336;
  --shadow: 0 18px 54px rgba(32, 43, 38, 0.12);
  --radius: 8px;
  --font: "LINE Seed JP", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-width: 320px;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  letter-spacing: 0;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
}

button,
textarea {
  font: inherit;
  letter-spacing: 0;
}

button {
  cursor: pointer;
}

a {
  color: var(--accent-strong);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.app-shell {
  width: min(920px, calc(100% - 40px));
  margin: 0 auto;
  padding: 20px 0 48px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
}

.brand:hover {
  text-decoration: none;
}

.brand-mark {
  display: block;
  width: 48px;
  height: 48px;
  overflow: hidden;
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-name {
  display: block;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.15;
}

.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.profile-label {
  max-width: 180px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.main-layout {
  display: grid;
  gap: 18px;
  padding-top: 28px;
}

.panel {
  display: grid;
  gap: 20px;
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.panel-head {
  display: grid;
  gap: 10px;
}

.eyebrow {
  margin: 0;
  color: var(--coral);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.2;
}

h1 {
  margin: 0;
  max-width: 720px;
  color: var(--ink);
  font-size: clamp(26px, 3.6vw, 38px);
  font-weight: 800;
  line-height: 1.14;
  overflow-wrap: anywhere;
}

.signed-out-box {
  display: grid;
  gap: 22px;
  justify-items: start;
  padding: 0;
}

.signed-out-box p,
.signed-out-box ol {
  margin: 0;
}

.landing-copy {
  display: grid;
  gap: 16px;
  justify-items: start;
}

.landing-lead {
  color: var(--ink);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.9;
}

.landing-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.landing-visual {
  width: 100%;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-muted);
}

.landing-visual img {
  display: block;
  width: 100%;
  height: auto;
}

.landing-example {
  display: grid;
  gap: 12px;
  width: 100%;
  padding: 18px 20px;
  border: 2px solid var(--pop-ink);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 7px 7px 0 rgba(22, 39, 34, 0.1);
}

.example-label {
  color: var(--coral);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.2;
}

.example-body {
  color: var(--ink);
  font-size: clamp(19px, 2.8vw, 26px);
  font-weight: 800;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.example-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.example-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-muted);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.landing-steps {
  display: grid;
  width: 100%;
  gap: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.landing-steps li {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 16px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}

.landing-steps strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

.landing-steps span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.7;
}

.create-form {
  display: grid;
  gap: 12px;
}

.create-form label {
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

textarea {
  width: 100%;
  min-height: 210px;
  resize: vertical;
  padding: 16px 18px;
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.75;
}

textarea:focus {
  border-color: var(--pop-ink);
  outline: 3px solid rgba(67, 183, 232, 0.32);
  outline-offset: 2px;
}

.form-actions,
.response-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.primary-button,
.secondary-button,
.ghost-button,
.danger-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border: 2px solid var(--line);
  border-radius: var(--radius);
  color: var(--pop-ink);
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
}

.primary-button {
  border-color: var(--pop-ink);
  background: var(--pop-ink);
  color: #ffffff;
}

.primary-button:hover {
  background: #0c1713;
  text-decoration: none;
}

.secondary-button {
  border-color: var(--pop-ink);
  background: var(--pop-yellow);
}

.ghost-button {
  background: #ffffff;
}

.danger-button {
  background: #ffffff;
  color: var(--danger);
}

.secondary-button:hover,
.ghost-button:hover,
.danger-button:hover {
  border-color: var(--pop-ink);
  background: #fff7d0;
  text-decoration: none;
}

.primary-button:disabled,
.secondary-button:disabled,
.danger-button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.post-card {
  display: grid;
  gap: 18px;
  padding: clamp(18px, 3vw, 26px);
  border: 2px solid var(--pop-ink);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 7px 7px 0 rgba(22, 39, 34, 0.12);
}

.post-body {
  margin: 0;
  color: var(--ink);
  font-size: clamp(21px, 3vw, 30px);
  font-weight: 800;
  line-height: 1.5;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.post-meta span {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-muted);
}

.response-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
}

.response-panel strong {
  display: block;
  margin: 0 0 5px;
  font-size: 18px;
  font-weight: 800;
}

.muted {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.7;
}

.people-list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 36px;
}

.person-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--pop-mint);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.empty-text {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.form-error {
  min-height: 22px;
  margin: 0;
  color: var(--danger);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.6;
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 10;
  max-width: min(360px, calc(100vw - 36px));
  margin: 0;
  padding: 14px 16px;
  border: 2px solid var(--pop-ink);
  border-radius: var(--radius);
  background: var(--pop-ink);
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.5;
  box-shadow: var(--shadow);
  transform: translateY(120%);
  transition: transform 160ms ease;
}

.toast.is-visible {
  transform: translateY(0);
}

@media (max-width: 640px) {
  .app-shell {
    width: min(100% - 24px, 860px);
    padding-top: 12px;
  }

  .topbar {
    align-items: flex-start;
    flex-direction: column;
    padding-bottom: 14px;
  }

  .topbar-actions,
  .response-actions,
  .form-actions {
    width: 100%;
  }

  .primary-button,
  .secondary-button,
  .ghost-button,
  .danger-button {
    width: 100%;
  }

  .panel {
    padding: 22px 18px;
  }

  .response-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .landing-steps li {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }
}
