/* 明るい場所別UI (Claude最新UI) */
.free-app-body {
  background: #f8fafc;
  color: #1e293b;
}

.bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 16px;
  margin-bottom: 16px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.bar-title b {
  font-size: 1.05rem;
  color: #0f172a;
}

.quota {
  display: inline-block;
  background: #f1f5f9;
  color: #475569;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 9999px;
  border: 1px solid #cbd5e1;
}

.nav-bar {
  margin-bottom: 12px;
}

.back {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #334155;
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 0.95rem;
  cursor: pointer;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s ease;
}

.back:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
}

/* 13場所タイル グリッド (390pxで2列) */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  margin: 16px 0;
}

@media (max-width: 480px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}

.tile {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 14px 12px;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 84px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  width: 100%;
}

.tile:hover {
  border-color: #10b981;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.1);
}

.tile:active {
  transform: translateY(0);
}

.tile-top b {
  display: block;
  font-size: 1rem;
  color: #0f172a;
  margin-bottom: 2px;
}

.tile-top small {
  display: block;
  font-size: 0.8rem;
  color: #64748b;
  margin-bottom: 8px;
}

.meter {
  appearance: none;
  display: block;
  width: 100%;
  height: 6px;
  background: #e2e8f0;
  border-radius: 9999px;
  overflow: hidden;
}

.meter::-webkit-progress-bar {
  background: #e2e8f0;
}

.meter::-webkit-progress-value {
  background: #10b981;
}

.meter::-moz-progress-bar {
  background: #10b981;
}

.report-table .col-room, .report-table .col-area { width: 20%; }
.report-table .col-priority { width: 13%; }
.report-table .col-operation { width: 12%; }
.report-caption { margin-top: 14px; }

/* 確認項目画面 */
.area-header {
  margin: 12px 0 16px;
}

.area-header h3 {
  font-size: 1.25rem;
  margin: 0 0 4px 0;
  color: #0f172a;
}

.area-sub {
  font-size: 0.85rem;
  color: #64748b;
  margin: 0;
}

.items-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 14px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  margin: 0;
}

.item-check input[type="checkbox"] {
  width: 22px;
  height: 22px;
  margin-top: 2px;
  accent-color: #10b981;
  cursor: pointer;
}

.item-main {
  flex: 1;
  min-width: 0;
}

.item-title {
  font-weight: 600;
  font-size: 0.98rem;
  margin: 0 0 6px 0;
  color: #0f172a;
  cursor: pointer;
  line-height: 1.5;
}

.item-meta {
  margin-bottom: 6px;
}

.how {
  font-size: 0.85rem;
  color: #475569;
  margin: 4px 0;
  line-height: 1.5;
}

.ex {
  font-size: 0.85rem;
  color: #64748b;
  margin: 4px 0;
  line-height: 1.5;
  background: #f8fafc;
  padding: 4px 8px;
  border-radius: 4px;
  border-left: 3px solid #cbd5e1;
}

.item-action {
  align-self: flex-start;
}

.flag {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.flag:hover {
  background: #d1fae5;
  border-color: #6ee7b7;
}

/* FAB (書面を見るボタン) */
.fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 90;
  background: #059669;
  color: #ffffff;
  border: none;
  border-radius: 9999px;
  padding: 12px 22px;
  font-size: 0.95rem;
  font-weight: 600;
  box-shadow: 0 4px 16px rgba(5, 150, 105, 0.4);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.fab:hover {
  background: #047857;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(5, 150, 105, 0.5);
}

.fab:active {
  transform: translateY(0);
}

/* A4 指摘書 プレビュー */
.a4 {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 16px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  margin-top: 8px;
}

.a4-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  border-bottom: 2px solid #0f172a;
  padding-bottom: 8px;
  margin-bottom: 12px;
}

.a4-header h4 {
  font-size: 1.15rem;
  margin: 0;
  color: #0f172a;
}

.a4-badge {
  font-size: 0.8rem;
  color: #64748b;
  margin: 0;
}

.report-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.report-table th, .report-table td {
  border: 1px solid #cbd5e1;
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
}

.report-table th {
  background: #f1f5f9;
  color: #334155;
  font-weight: 600;
}

.report-table .empty {
  text-align: center;
  color: #64748b;
  padding: 24px;
}

.prio-tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
}

.prio-高 { background: #fee2e2; color: #991b1b; }
.prio-中 { background: #fef3c7; color: #92400e; }
.prio-低 { background: #e0f2fe; color: #075985; }

.del-btn {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
  border-radius: 4px;
  padding: 4px 8px;
  font-size: 0.8rem;
  cursor: pointer;
}

.del-btn:hover {
  background: #fee2e2;
}

/* ボトムシート (気になる点記録・上限案内) */
.sheet-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(2px);
}

.sheet {
  position: relative;
  background: #ffffff;
  border-radius: 16px 16px 0 0;
  padding: 20px 20px 24px;
  max-width: 580px;
  margin: 0 auto;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.15);
  animation: slideUp 0.2s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 8px;
}

.sheet-head b {
  font-size: 1.05rem;
  color: #0f172a;
}

.sheet-x {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
  padding: 0 4px;
}

.sheet-row {
  display: flex;
  gap: 12px;
}

.field-room { flex: 1; }
.field-prio { width: 7.5em; }

.sheet-err {
  color: #dc2626;
  font-size: 0.85rem;
  margin: 8px 0 0;
  padding: 6px 10px;
  background: #fef2f2;
  border-radius: 4px;
  border: 1px solid #fecaca;
}

.sheet-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.sheet-actions .go {
  flex: 1;
}

.paid {
  font-size: 0.95rem;
  color: #334155;
  line-height: 1.6;
  margin: 12px 0 16px;
}

.guide-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 16px;
  margin: 16px 0;
}

.inspection-cover { display: block; width: 100%; height: clamp(100px, 26vw, 150px); object-fit: cover; object-position: center 53%; border-radius: 12px; }
.tile-icon { pointer-events: none; width: 26px; height: 26px; flex: 0 0 26px; fill: none; stroke: currentColor; stroke-width: 1.45; stroke-linecap: round; stroke-linejoin: round; }
