:root {
  color-scheme: light;
  --bg: #f2f4f8;
  --surface: #ffffff;
  --surface2: #f7f9fc;
  --border: #e2e8f0;
  --accent: #d4600a;
  --accent-weak: #fff0e7;
  --accent2: #18a34a;
  --text: #1a202c;
  --text-muted: #64748b;
  --text-dim: #a0aab8;
  --gold: #b8860b;
  --danger: #b42318;
  --danger-bg: #fff1f0;
  --info: #1d4ed8;
  --info-bg: #eef4ff;
  --success: #166534;
  --success-bg: #dcfce7;
  --radius: 14px;
  --shadow: 0 1px 4px rgba(0, 0, 0, .05);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Noto Sans JP", -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", "YuGothic", Meiryo, sans-serif;
  font-size: 14px;
  line-height: 1.6;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 8px rgba(0, 0, 0, .06);
}

.app-header .dot {
  width: 7px;
  height: 7px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--accent2);
  box-shadow: 0 0 6px var(--accent2);
}

.app-header h1 {
  margin: 0;
  color: var(--accent);
  font-family: "Bebas Neue", "Noto Sans JP", sans-serif;
  font-size: 22px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 2px;
}

.app-header .sub {
  margin-top: 3px;
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.3;
}

main,
.container,
.page {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  padding: 16px 12px 32px;
}

.container > h1,
.page-title {
  margin: 0 0 14px;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.panel,
.message,
.itemspanel {
  margin-bottom: 16px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.message {
  text-align: center;
}

label {
  display: block;
  margin-bottom: 6px;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 16px;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}

input,
select {
  min-height: 44px;
  padding: 10px 12px;
}

textarea {
  min-height: 96px;
  padding: 12px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(212, 96, 10, .12);
}

input[readonly],
input.is-readonly {
  background: var(--surface2);
  color: var(--text-muted);
  cursor: not-allowed;
}

button,
.btn-add,
.btn-reserve,
.bubble-btn {
  border: none;
  border-radius: 10px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  transition: background .2s, border-color .2s, color .2s, box-shadow .2s;
}

button:disabled {
  opacity: .5;
  cursor: not-allowed;
}

.hidden {
  display: none !important;
}

.error {
  color: var(--danger);
  white-space: pre-wrap;
}

.success {
  color: var(--success);
  white-space: pre-wrap;
}

.hint,
.small,
.meta {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.7;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 12px;
}

.actions button {
  flex: 1 1 180px;
}

.status {
  padding: 12px;
  border-radius: 10px;
  font-weight: 700;
}

.status.ok,
.status.success {
  background: var(--success-bg);
  color: var(--success);
}

.status.error {
  background: var(--danger-bg);
  color: var(--danger);
}

.status.info {
  background: var(--info-bg);
  color: var(--info);
}

.badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 20px;
  background: var(--border);
  color: var(--text-muted);
  font-size: 11px;
}

.state-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 40px 16px;
  color: var(--text-dim);
}

.state-box .icon {
  font-size: 32px;
}

.state-box p {
  font-size: 13px;
  text-align: center;
}
