@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+JP:wght@400;500;600;700&display=swap");

:root {
  --bg: #f7f5f1;
  --surface: #ffffff;
  --ink: #1a1f27;
  --muted: #5a6573;
  --line: #d9d4cb;
  --accent: #0f3d63;
  --accent-soft: #e8eef4;
  --ok: #1f6b45;
  --err: #9b2c2c;
  --radius: 8px;
  --font: "IBM Plex Sans JP", "Hiragino Sans", "Noto Sans JP", sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--ink);
  background:
    linear-gradient(180deg, #eef2f6 0%, transparent 28%),
    var(--bg);
  line-height: 1.6;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.shell {
  width: min(880px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 1.25rem 0 3rem;
}

.app-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.35rem 0 1rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--line);
}
.app-brand {
  display: flex;
  align-items: baseline;
  gap: 0.65rem;
  min-width: 0;
}
.app-brand-mark {
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: 0.04em;
}
.app-brand-sub {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 500;
}
.app-account {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--muted);
  font-size: 0.9rem;
  flex-shrink: 0;
}
.text-btn {
  font: inherit;
  border: 0;
  background: transparent;
  color: var(--accent);
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1.5rem;
}
.login-card {
  width: min(420px, 100%);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem 1.6rem 1.6rem;
}
.brand {
  font-weight: 700;
  font-size: 1.85rem;
  letter-spacing: 0.04em;
  margin: 0 0 0.35rem;
}
.lead { margin: 0 0 1.25rem; color: var(--muted); }
.hint { margin: 1.2rem 0 0; color: var(--muted); font-size: 0.9rem; }
.steps {
  margin: 0 0 1.4rem;
  padding-left: 1.2rem;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

.choice-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem;
  margin: 0.5rem 0 1.5rem;
}
.choice {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  text-align: left;
  padding: 1.25rem 1.2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: inherit;
  font: inherit;
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.choice:hover {
  border-color: var(--accent);
  text-decoration: none;
  transform: translateY(-1px);
}
.choice-title {
  font-size: 1.15rem;
  font-weight: 700;
}
.choice.is-active {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
  background: #f3f7fb;
}
.choice[aria-pressed="true"] {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
  background: #f3f7fb;
}

.edit-pane-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.5rem;
}
.edit-pane-head h2 {
  margin: 0;
  font-size: 1.15rem;
}
.guide {
  margin: 0 0 0.85rem;
  color: var(--muted);
  font-size: 0.92rem;
}
.req {
  color: var(--err);
  font-weight: 700;
}
.opt-note {
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 500;
}

.btn, button:not(.chip):not(.text-btn):not(.choice) {
  font: inherit;
  cursor: pointer;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  border-radius: 6px;
  padding: 0.55rem 1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}
.btn.primary, button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.btn.ghost, button.ghost { background: transparent; }
button:disabled { opacity: 0.5; cursor: not-allowed; }

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin: 0 0 0.75rem;
  border-bottom: 1px solid var(--line);
}
.chip {
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  background: transparent;
  padding: 0.55rem 0.9rem;
  color: var(--muted);
  cursor: pointer;
  margin-bottom: -1px;
  font: inherit;
}
.chip[aria-pressed="true"] {
  background: transparent;
  border-bottom-color: var(--accent);
  color: var(--ink);
  font-weight: 600;
}

.event-list { display: grid; gap: 0; border-top: 1px solid var(--line); }
.event-row {
  display: grid;
  grid-template-columns: 5.5rem 7.5rem 1fr auto;
  gap: 0.75rem 1rem;
  align-items: center;
  padding: 0.85rem 0.15rem;
  border-bottom: 1px solid var(--line);
  color: inherit;
  text-decoration: none;
}
.event-row:hover {
  background: rgba(15, 61, 99, 0.04);
  text-decoration: none;
}
.event-row.inactive { opacity: 0.55; }
.event-row .session {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
}
.event-row .date {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  font-size: 0.95rem;
}
.event-row .speakers {
  min-width: 0;
  font-size: 0.98rem;
}
.event-row .speakers-empty { color: var(--muted); }
.event-row .go {
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
}

.topbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1.25rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--line);
}
.topbar h1 {
  font-size: 1.2rem;
  margin: 0;
  flex: 1 1 auto;
  font-weight: 700;
}
.topbar .user {
  color: var(--muted);
  font-size: 0.9rem;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem 1.3rem;
  margin: 0 0 1rem;
}
.panel h2 {
  margin: 0 0 0.8rem;
  font-size: 1.05rem;
}
.panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
}
.req-legend-inline {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
}
.label-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0.75rem 0 0.25rem;
  font-weight: 600;
  font-size: 0.92rem;
}
.label-line .field-hint {
  font-weight: 400;
  color: var(--muted);
  font-size: 0.82rem;
  text-align: right;
}
label:not(.label-line) { display: block; margin: 0.75rem 0 0.25rem; font-weight: 600; font-size: 0.92rem; }
input[type="text"], input[type="date"], input[type="time"], select, textarea {
  width: 100%;
  font: inherit;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}
textarea { min-height: 7rem; resize: vertical; }
textarea.notes-field { min-height: 4.2rem; }
.row { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: 0.8rem; }
.mute { color: var(--muted); font-size: 0.9rem; }
.msg {
  border-radius: 6px;
  padding: 0.7rem 0.9rem;
  margin: 0 0 1rem;
}
.msg.ok { background: #eaf6ef; color: var(--ok); }
.msg.err { background: #fdecec; color: var(--err); }
.msg.mute { background: #f0eee9; color: var(--muted); }
.msg a { font-weight: 600; }
.talk {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.8rem;
  margin: 0.7rem 0;
  background: #fcfcfa;
}
.talk-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}
.talk-head p { margin: 0; }
.btn.danger, button.danger { color: var(--err); border-color: #e2b6b6; }
.actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1rem; }
#submitMsg {
  margin-top: 1.25rem;
}

@media (max-width: 720px) {
  .choice-grid { grid-template-columns: 1fr; }
  .event-row {
    grid-template-columns: 4.5rem 1fr auto;
    grid-template-areas:
      "session date go"
      "speakers speakers speakers";
  }
  .event-row .session { grid-area: session; }
  .event-row .date { grid-area: date; }
  .event-row .speakers { grid-area: speakers; }
  .event-row .go { grid-area: go; }
}
