/* Page-specific styles for index.html — see css/base.css for shared rules. */

.wrap {
  width: 100%;
  max-width: 720px;
}
header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.today {
  color: var(--muted);
  font-size: 0.9rem;
}
.today strong { color: var(--text); }

.cards {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 4px;
}
.card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--row);
  border-top: 1px solid var(--border);
  min-height: 64px;
}

.thumb {
  position: relative;
  width: 48px;
  height: 48px;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--panel);
  border: 1px solid var(--border);
}
.thumb-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--muted);
}

.card-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.card-meta {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--muted);
}
.card-date {
  color: var(--good);
  font-weight: 700;
  font-size: 0.95rem;
}
.card-date .dow {
  color: var(--muted);
  font-weight: 400;
  font-size: 0.85em;
  margin-left: 4px;
}

.empty {
  text-align: center;
  color: var(--muted);
  padding: 32px 16px;
}

footer {
  margin-top: 12px;
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 0.85rem;
}

.report-btn {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: 8px;
  color: var(--muted);
  font-size: 1.1rem;
  padding: 0;
}
.report-btn:active { background: var(--row-alt); }

.sheet-panel {
  width: 100%;
  max-width: 480px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 20px 16px;
}
.sheet-title {
  font-weight: 700;
  margin-bottom: 12px;
  word-break: break-word;
}
.sheet-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}
.sheet-option {
  text-align: left;
  background: var(--row);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 14px;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 500;
}
.sheet-option:active { background: var(--row-alt); }
.sheet-cancel {
  width: 100%;
  background: transparent;
  border: none;
  color: var(--muted);
  padding: 12px;
  font-weight: 600;
}

.fab {
  position: fixed;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--accent);
  color: #0b1320;
  border: none;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  z-index: 50;
}
.fab:active { filter: brightness(0.9); }

.request-form label {
  display: block;
  font-size: 0.85rem;
  color: var(--muted);
  margin: 12px 0 4px;
}
.request-form label:first-child { margin-top: 0; }
.request-form input,
.request-form textarea {
  width: 100%;
  background: var(--row);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 12px;
  font-size: 16px; /* prevents iOS auto-zoom on focus */
  font-family: inherit;
}
.request-form textarea { resize: vertical; min-height: 60px; }
.request-actions {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}
.request-actions button {
  flex: 1;
  padding: 12px;
  border-radius: 8px;
  border: none;
  font-weight: 600;
}
.request-submit { background: var(--accent); color: #0b1320; }
.request-cancel { background: var(--row); color: var(--text); border: 1px solid var(--border) !important; }
.request-error { color: var(--danger); font-size: 0.85rem; margin-top: 8px; min-height: 1.2em; }
