/* Local Dive Admin Cockpit — shared styles
   - kintone / Notion 風シンプル UI
   - Tailwind CDN を併用、ここでは差分のみ定義 */

:root {
  --ld-primary: #047857;       /* emerald-700 */
  --ld-primary-soft: #d1fae5;  /* emerald-100 */
  --ld-accent: #b45309;        /* amber-700 */
  --ld-bg: #f9fafb;
  --ld-border: #e5e7eb;
  --ld-text: #1f2937;
  --ld-muted: #6b7280;
}

body {
  -webkit-font-smoothing: antialiased;
}

/* ===== サイドバー ===== */
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 20px;
  color: #374151;
  border-left: 3px solid transparent;
  transition: background .12s, color .12s, border-color .12s;
  text-decoration: none;
  font-size: 13px;
}
.nav-item:hover {
  background: #f3f4f6;
  color: var(--ld-primary);
}
.nav-item.nav-active {
  background: var(--ld-primary-soft);
  color: var(--ld-primary);
  border-left-color: var(--ld-primary);
  font-weight: 600;
}
.nav-icon {
  display: inline-block;
  width: 18px;
  text-align: center;
  font-size: 11px;
  color: var(--ld-muted);
}
.nav-active .nav-icon {
  color: var(--ld-primary);
}

/* ===== KPI カード ===== */
.kpi-card {
  background: white;
  border-radius: 10px;
  padding: 18px 20px;
  border: 1px solid var(--ld-border);
  box-shadow: 0 1px 2px rgba(0,0,0,0.02);
}
.kpi-label {
  font-size: 12px;
  color: var(--ld-muted);
  margin-bottom: 6px;
}
.kpi-value {
  font-size: 26px;
  font-weight: 700;
  color: var(--ld-text);
  line-height: 1.1;
}
.kpi-delta {
  font-size: 11px;
  margin-top: 6px;
}
.kpi-up { color: #059669; }
.kpi-down { color: #dc2626; }
.kpi-flat { color: var(--ld-muted); }

/* ===== カード ===== */
.card {
  background: white;
  border-radius: 10px;
  border: 1px solid var(--ld-border);
  padding: 20px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.02);
}
.card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--ld-text);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.card-title .badge {
  background: var(--ld-primary-soft);
  color: var(--ld-primary);
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 99px;
  font-weight: 600;
}

/* ===== テーブル ===== */
.tbl {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.tbl th {
  background: #f3f4f6;
  text-align: left;
  padding: 10px 12px;
  color: var(--ld-muted);
  font-weight: 500;
  font-size: 11px;
  border-bottom: 1px solid var(--ld-border);
}
.tbl td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--ld-border);
  color: var(--ld-text);
}
.tbl tr:last-child td { border-bottom: 0; }
.tbl tr:hover td { background: #fafbfc; }

/* ===== ステータスバッジ ===== */
.badge-pill {
  display: inline-block;
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 99px;
  font-weight: 600;
}
.badge-green { background: #d1fae5; color: #047857; }
.badge-amber { background: #fef3c7; color: #b45309; }
.badge-red   { background: #fee2e2; color: #b91c1c; }
.badge-blue  { background: #dbeafe; color: #1d4ed8; }
.badge-gray  { background: #f3f4f6; color: #4b5563; }
.badge-pink  { background: #fce7f3; color: #be185d; }

/* ===== ボタン ===== */
.btn {
  display: inline-block;
  padding: 7px 14px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  text-decoration: none;
}
.btn-primary {
  background: var(--ld-primary);
  color: white;
}
.btn-primary:hover { background: #065f46; }
.btn-ghost {
  background: white;
  color: var(--ld-text);
  border-color: var(--ld-border);
}
.btn-ghost:hover { background: #f9fafb; }
.btn-amber {
  background: var(--ld-accent);
  color: white;
}

/* ===== アップグレード CTA ===== */
.upgrade-banner {
  background: linear-gradient(135deg, #047857 0%, #065f46 100%);
  color: white;
  border-radius: 12px;
  padding: 22px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 4px 14px rgba(4,120,87,.25);
}
.upgrade-banner h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 4px;
}
.upgrade-banner p {
  font-size: 12px;
  opacity: 0.85;
}
.upgrade-banner .btn {
  background: white;
  color: var(--ld-primary);
}

/* ===== タイムライン ===== */
.timeline-item {
  display: flex;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--ld-border);
}
.timeline-item:last-child { border-bottom: 0; }
.timeline-dot {
  width: 8px;
  height: 8px;
  border-radius: 99px;
  background: var(--ld-primary);
  margin-top: 6px;
  flex-shrink: 0;
}
.timeline-time {
  font-size: 11px;
  color: var(--ld-muted);
}

/* ===== ミニチャート / プログレス ===== */
.progress-bar {
  width: 100%;
  height: 6px;
  background: #f3f4f6;
  border-radius: 99px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: var(--ld-primary);
  border-radius: 99px;
}
.progress-fill.amber { background: var(--ld-accent); }
.progress-fill.red { background: #dc2626; }

/* ===== セクション見出し ===== */
.section-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--ld-text);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-title::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 14px;
  background: var(--ld-primary);
  border-radius: 2px;
}

/* ===== タブ ===== */
.tab-bar {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--ld-border);
  margin-bottom: 16px;
}
.tab {
  padding: 8px 14px;
  font-size: 13px;
  color: var(--ld-muted);
  border-bottom: 2px solid transparent;
  cursor: pointer;
}
.tab.active {
  color: var(--ld-primary);
  border-bottom-color: var(--ld-primary);
  font-weight: 600;
}

/* ===== ユーティリティ ===== */
.dim { color: var(--ld-muted); }
.divider { border-top: 1px solid var(--ld-border); margin: 16px 0; }
