:root {
  --bg: #f4f6f9;
  --surface: #ffffff;
  --surface-alt: #f8fafc;
  --border: #e2e8f0;
  --text: #0f172a;
  --text-muted: #64748b;
  --primary: #06c755;
  --primary-dark: #05a847;
  --primary-soft: #e6f9ed;
  --coral: #ff385c;
  --coral-soft: #fff0f3;
  --blue: #2563eb;
  --blue-soft: #eff6ff;
  --amber: #d97706;
  --amber-soft: #fffbeb;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 2px 10px rgba(15, 23, 42, 0.06);
  --shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.14);
}

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

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Meiryo", sans-serif;
  font-size: 14px;
  line-height: 1.5;
}

.hidden {
  display: none !important;
}

/* デモ・ローカルテスト用バー */
.demo-bar {
  background: #1e293b;
  color: #f8fafc;
  padding: 8px 14px;
  font-size: 12px;
  border-bottom: 2px solid #06c755;
}
.demo-bar-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.demo-bar-label {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.badge-demo {
  background: #06c755;
  color: #fff;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
}
.demo-hint {
  color: #cbd5e1;
}
.demo-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.btn-line {
  background: #06c755;
  color: #fff;
}
.btn-ghost-light {
  background: rgba(255, 255, 255, 0.1);
  color: #e2e8f0;
}
.btn-outline-light {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
}

/* ブート画面 */
.boot-screen {
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--text-muted);
}
.spinner {
  width: 34px;
  height: 34px;
  border: 3px solid #cbd5e1;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* トースト */
.toast-container {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}
.toast {
  background: #0f172a;
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  box-shadow: var(--shadow-lg);
  font-size: 13px;
  font-weight: 600;
  max-width: 360px;
  animation: slideIn 0.2s ease;
}
.toast.success { background: #047857; }
.toast.error { background: #be123c; }
.toast.info { background: #1d4ed8; }
@keyframes slideIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ヘッダー */
.app-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: sticky;
  top: 0;
  z-index: 40;
}
.header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), #049e43);
  color: #fff;
  font-weight: 800;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.store-title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.store-subtitle {
  margin: 0;
  font-size: 11px;
  color: var(--text-muted);
}
.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.staff-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 10px 3px 4px;
}
.avatar, .avatar-fallback {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.avatar-fallback {
  background: var(--primary-soft);
  color: var(--primary-dark);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.staff-pill-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.staff-pill-name {
  font-weight: 700;
  font-size: 12px;
}
.staff-pill-role {
  font-size: 10px;
  color: var(--text-muted);
}

/* コンテナ＆カード */
.container {
  max-width: 720px;
  margin: 14px auto;
  padding: 0 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.staff-container {
  padding-bottom: 92px;
}
.admin-container {
  max-width: 1320px;
  padding-bottom: 40px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}
.compact-card {
  padding: 12px 14px;
}
.card-center {
  text-align: center;
  padding: 28px 20px;
}
.card-login {
  max-width: 420px;
  margin: 24px auto;
  width: 100%;
}

/* ボタン＆入力 */
.btn {
  border: none;
  border-radius: var(--radius-sm);
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: transform 0.08s ease, background-color 0.15s ease, opacity 0.15s ease;
  font-family: inherit;
}
.btn:active { transform: scale(0.97); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-sm { padding: 6px 11px; font-size: 12px; border-radius: 7px; }
.btn-block { width: 100%; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-secondary { background: #e2e8f0; color: var(--text); }
.btn-secondary:hover { background: #cbd5e1; }
.btn-emerald { background: #059669; color: #fff; }
.btn-emerald:hover { background: #047857; }
.btn-danger { background: #e11d48; color: #fff; }
.btn-ghost { background: transparent; color: var(--text-muted); }
.btn-ghost:hover { background: var(--surface-alt); color: var(--text); }
.btn-ghost-dark { background: #f1f5f9; color: #334155; }
.btn-icon {
  background: transparent;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: var(--text-muted);
  padding: 4px 8px;
  border-radius: 6px;
}
.btn-icon-box {
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 8px;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn-icon-box:hover { background: var(--surface-alt); }

.input, .input-sm, select.input, select.input-sm {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 9px 11px;
  font-size: 14px;
  font-family: inherit;
  background: #fff;
  color: var(--text);
}
.input-sm, select.input-sm {
  width: auto;
  padding: 5px 9px;
  font-size: 12px;
  border-radius: 7px;
}
.input:focus, .input-sm:focus {
  outline: 2px solid rgba(6, 199, 85, 0.25);
  border-color: var(--primary);
}

.field { display: flex; flex-direction: column; gap: 5px; }
.field-label { font-size: 12px; font-weight: 700; color: var(--text); }
.form-stack { display: flex; flex-direction: column; gap: 12px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.muted { color: var(--text-muted); font-size: 13px; }
.error-text { color: #be123c; font-size: 13px; font-weight: 600; margin: 0; }
.hint-box {
  margin-top: 12px;
  padding: 10px;
  background: var(--surface-alt);
  border-radius: 8px;
  color: var(--text-muted);
}

/* アラートバナー */
.alert {
  border-radius: var(--radius);
  padding: 12px 14px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
.alert-success {
  background: var(--primary-soft);
  border: 1px solid #86efac;
  color: #065f46;
}
.alert-desc { margin: 2px 0 0; font-size: 12px; }

/* 期間切替・月ナビ */
.period-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}
.month-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}
.month-label {
  font-size: 16px;
  font-weight: 800;
  min-width: 96px;
  text-align: center;
}
.month-quick {
  display: flex;
  gap: 4px;
}
.chip-btn {
  border: 1px solid var(--border);
  background: var(--surface-alt);
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}
.chip-btn.active {
  background: var(--text);
  color: #fff;
  border-color: var(--text);
}
.submission-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
}
.submission-badge.submitted { background: var(--primary-soft); color: #047857; }
.submission-badge.pending { background: var(--amber-soft); color: var(--amber); }

.segmented-control {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: #f1f5f9;
  padding: 3px;
  border-radius: 10px;
  gap: 3px;
}
.segmented-control.compact {
  display: inline-grid;
}
.seg-btn {
  border: none;
  background: transparent;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  border-radius: 8px;
  cursor: pointer;
  white-space: nowrap;
}
.seg-btn.active {
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

/* モード・スタンプバー */
.mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.mode-tab {
  border: 1px solid var(--border);
  background: var(--surface-alt);
  padding: 8px 10px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  color: var(--text-muted);
}
.mode-tab.active {
  background: var(--text);
  color: #fff;
  border-color: var(--text);
}
.mode-hint {
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-muted);
}
.stamp-toolbar {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.stamp-buttons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.stamp-btn {
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 8px 6px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.stamp-btn.active {
  border-width: 2px;
  border-color: var(--text);
  background: var(--surface-alt);
}
.stamp-time-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  background: var(--primary-soft);
  padding: 8px 10px;
  border-radius: 8px;
}
.inline-field {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
}

/* カレンダーグリッド */
.calendar-card { padding: 10px; }
.calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.wk-sun { color: #e11d48; }
.wk-sat { color: #2563eb; }

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
}
.cal-spacer {
  min-height: 62px;
}
.cal-day {
  min-height: 68px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  padding: 5px 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  position: relative;
  transition: transform 0.08s ease, border-color 0.12s ease;
  user-select: none;
}
.cal-day:active { transform: scale(0.95); }
.cal-day.out-of-period {
  opacity: 0.32;
  background: #f1f5f9;
  cursor: not-allowed;
}
.cal-day.state-off {
  background: var(--coral-soft);
  border-color: #fda4af;
}
.cal-day.state-work {
  background: var(--primary-soft);
  border-color: #86efac;
}
.cal-day-num {
  font-size: 12px;
  font-weight: 800;
  align-self: flex-start;
  line-height: 1;
}
.cal-day.sun .cal-day-num { color: #e11d48; }
.cal-day.sat .cal-day-num { color: #2563eb; }

.cal-badge {
  font-size: 10px;
  font-weight: 800;
  padding: 2px 5px;
  border-radius: 5px;
  width: 100%;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cal-badge.off {
  background: var(--coral);
  color: #fff;
}
.cal-badge.work {
  background: var(--primary);
  color: #fff;
}
.cal-badge.empty {
  color: #cbd5e1;
  font-size: 14px;
  font-weight: 400;
}
.cal-time {
  font-size: 10px;
  font-weight: 700;
  color: #065f46;
  line-height: 1.1;
  text-align: center;
  word-break: break-all;
}
.cal-note-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #f59e0b;
}

/* 固定フッター */
.sticky-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-top: 1px solid var(--border);
  padding: 10px 14px;
  z-index: 35;
}
.sticky-footer-inner {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.summary-counts {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.count-chip {
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 7px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
}
.count-chip.work { background: var(--primary-soft); border-color: #bbf7d0; color: #065f46; }
.count-chip.off { background: var(--coral-soft); border-color: #fecdd3; color: #be123c; }
.btn-save {
  flex: 1;
  min-width: 170px;
  padding: 11px 18px;
}

/* モーダル & ボトムシート */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0;
}
@media (min-width: 640px) {
  .modal-backdrop {
    align-items: center;
    padding: 16px;
  }
}
.bottom-sheet, .modal-card {
  background: var(--surface);
  width: 100%;
  max-width: 480px;
  border-radius: 18px 18px 0 0;
  padding: 18px 16px 20px;
  box-shadow: var(--shadow-lg);
  max-height: 92vh;
  overflow-y: auto;
}
@media (min-width: 640px) {
  .bottom-sheet, .modal-card {
    border-radius: 16px;
  }
}
.sheet-header, .modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.sheet-header h3, .modal-header h3 {
  margin: 0;
  font-size: 18px;
}
.sheet-weekday {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}
.sheet-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}
.sheet-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.type-selector {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.type-btn {
  border: 2px solid var(--border);
  background: var(--surface);
  border-radius: 12px;
  padding: 10px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
}
.type-emoji { font-size: 18px; }
.type-label { font-size: 13px; font-weight: 800; }
.type-sub { font-size: 10px; color: var(--text-muted); }
.type-btn.type-off.active { border-color: var(--coral); background: var(--coral-soft); }
.type-btn.type-work.active { border-color: var(--primary); background: var(--primary-soft); }
.type-btn.type-clear.active { border-color: #64748b; background: #f1f5f9; }

.sheet-time-section {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.time-group { display: flex; flex-direction: column; gap: 6px; }
.badge-req {
  background: var(--primary-soft);
  color: #047857;
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 4px;
  margin-left: 4px;
}
.badge-opt {
  background: #e2e8f0;
  color: #475569;
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 4px;
  margin-left: 4px;
}
.time-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.time-chip {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 7px;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.time-chip.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.sheet-footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 16px;
}
.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 6px;
}
.checkbox-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  cursor: pointer;
}

/* 紐づけ候補 */
.icon-circle {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--blue-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin: 0 auto 10px;
}
.candidate-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 8px;
  margin: 16px 0;
}
.candidate-btn {
  border: 1px solid var(--border);
  background: var(--surface-alt);
  border-radius: 10px;
  padding: 10px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: left;
}
.candidate-btn:hover { border-color: var(--primary); background: var(--primary-soft); }
.divider { height: 1px; background: var(--border); margin: 14px 0; }

/* 管理者画面 */
.admin-nav {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 2px;
}
.admin-tab {
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 9px 14px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
}
.admin-tab.active {
  background: var(--text);
  color: #fff;
  border-color: var(--text);
}
.admin-panel {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.admin-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
.stat-box {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
}
.stat-label { font-size: 11px; color: var(--text-muted); font-weight: 600; }
.stat-value { font-size: 20px; font-weight: 800; margin-top: 2px; }

.unsubmitted-box {
  background: var(--amber-soft);
  border: 1px solid #fde68a;
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 12px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.unsubmitted-title { font-size: 12px; font-weight: 700; color: #92400e; }
.unsubmitted-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.unsubmitted-chip {
  background: #fff;
  border: 1px solid #fcd34d;
  color: #92400e;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
}

.export-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.export-label { font-size: 12px; font-weight: 700; color: var(--text-muted); }
.export-buttons { display: flex; flex-wrap: wrap; gap: 6px; }

.table-card { padding: 12px; }
.table-help { font-size: 11px; color: var(--text-muted); margin-bottom: 8px; }
.matrix-scroll, .table-scroll {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 10px;
}
.matrix-table {
  border-collapse: collapse;
  width: 100%;
  font-size: 11px;
  min-width: 780px;
}
.matrix-table th, .matrix-table td {
  border: 1px solid var(--border);
  padding: 5px 4px;
  text-align: center;
  white-space: nowrap;
}
.matrix-table thead th {
  background: var(--surface-alt);
  font-weight: 700;
  position: sticky;
  top: 0;
  z-index: 2;
}
.matrix-table .sticky-col {
  position: sticky;
  left: 0;
  background: var(--surface);
  z-index: 3;
  text-align: left;
  padding: 6px 10px;
  min-width: 155px;
  border-right: 2px solid #cbd5e1;
}
.matrix-table thead .sticky-col {
  z-index: 4;
  background: var(--surface-alt);
}
.matrix-staff-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.matrix-cell {
  cursor: pointer;
  min-width: 50px;
  height: 36px;
  transition: background-color 0.1s ease;
}
.matrix-cell:hover { filter: brightness(0.95); }
.matrix-cell.off { background: var(--coral-soft); color: #be123c; font-weight: 700; }
.matrix-cell.work { background: var(--primary-soft); color: #065f46; font-weight: 700; }
.matrix-cell.empty { color: #cbd5e1; }
.matrix-summary-row td { background: #f8fafc; font-weight: 700; }
.col-sun { background: #fff1f2 !important; color: #be123c; }
.col-sat { background: #eff6ff !important; color: #1d4ed8; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.data-table th, .data-table td {
  border-bottom: 1px solid var(--border);
  padding: 10px 10px;
  text-align: left;
  white-space: nowrap;
}
.data-table th { background: var(--surface-alt); font-size: 12px; color: var(--text-muted); }

.panel-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.panel-header h2 { margin: 0 0 4px; font-size: 16px; }
.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 12px;
}
.badge {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.badge-green { background: var(--primary-soft); color: #047857; }
.badge-amber { background: var(--amber-soft); color: #b45309; }
.badge-blue { background: var(--blue-soft); color: #1d4ed8; }
.badge-gray { background: #e2e8f0; color: #475569; }
.submissions-log {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.log-item {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  background: var(--surface-alt);
  border-radius: 8px;
  font-size: 12px;
}
