/* CleanFlow Pulse · Ops Console
   Desktop-first layout with sidebar and industrial ops theme. */

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Inter", sans-serif;
}

/* Layout */
.app-shell {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  height: 100vh;
  background: radial-gradient(circle at top left, #1f2937 0, #020617 45%, #020617 100%);
}

/* SIDEBAR */
.sidebar {
  border-right: 1px solid rgba(15, 23, 42, 1);
  background: radial-gradient(circle at top, #020617 0, #020617 50%, #020617 100%);
  padding: 14px 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.sidebar-header {
  padding: 10px 10px 8px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.9), rgba(30, 64, 175, 0.35));
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.65);
}

.sidebar-nav {
  margin-top: 6px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.75rem;
  color: rgb(156 163 175);
  background: transparent;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease, color 0.12s ease,
    transform 0.05s ease;
}

.nav-item:hover {
  background: rgba(15, 23, 42, 0.7);
  border-color: rgba(51, 65, 85, 0.8);
  color: rgb(226 232 240);
}

.nav-item:active {
  transform: scale(0.97);
}

.nav-item-active {
  background: linear-gradient(90deg, #facc15, #f97316);
  border-color: #facc15;
  color: #111827;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.6);
}

.nav-icon {
  width: 1.2rem;
  text-align: center;
  font-size: 0.95rem;
}

.sidebar-footer {
  padding: 6px 8px;
  border-radius: 10px;
  border: 1px dashed rgba(148, 163, 184, 0.3);
  background: rgba(15, 23, 42, 0.7);
}

/* MAIN */
.main {
  display: flex;
  flex-direction: column;
  padding: 14px 14px;
  gap: 10px;
}

.main-header {
  border-radius: 14px;
  padding: 10px 14px;
  background: radial-gradient(circle at top right, rgba(34, 197, 94, 0.08), rgba(15, 23, 42, 0.9));
  border: 1px solid rgba(55, 65, 81, 0.9);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Panels / sections */
.panel {
  border-radius: 14px;
  padding: 14px 14px 12px;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(51, 65, 85, 0.95);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.7);
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

/* Text styles */
.eyebrow {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: rgb(148 163 184);
}

/* Fields */
.field-label {
  font-size: 0.7rem;
  color: rgb(148 163 184);
  margin-bottom: 2px;
}

.field-input,
.field-textarea {
  width: 100%;
  border-radius: 0.6rem;
  border: 1px solid rgba(55, 65, 81, 0.9);
  background: rgba(15, 23, 42, 0.9);
  color: rgb(226 232 240);
  font-size: 0.8rem;
  padding: 6px 8px;
}

.field-input::placeholder,
.field-textarea::placeholder {
  color: rgb(100 116 139);
}

.field-textarea {
  resize: vertical;
}

/* Buttons */
.btn-primary {
  border-radius: 999px;
  border: none;
  background: linear-gradient(90deg, #facc15, #f97316);
  color: #111827;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 7px 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.75);
  transition: transform 0.08s ease, box-shadow 0.12s ease;
}

.btn-primary:active {
  transform: scale(0.97);
  box-shadow: 0 5px 18px rgba(0, 0, 0, 0.8);
}

.btn-secondary {
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.9);
  color: rgb(226 232 240);
  font-size: 0.8rem;
  padding: 7px 12px;
  cursor: pointer;
  transition: background 0.1s ease, transform 0.05s ease;
}

.btn-secondary:hover {
  background: rgba(15, 23, 42, 0.9);
}

.btn-secondary:active {
  transform: scale(0.97);
}

.btn-danger {
  border-radius: 999px;
  border: none;
  background: linear-gradient(90deg, #ef4444, #b91c1c);
  color: #f9fafb;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
  transition: transform 0.08s ease, box-shadow 0.12s ease;
}

.btn-danger:active {
  transform: scale(0.97);
  box-shadow: 0 5px 18px rgba(0, 0, 0, 0.8);
}

.btn-danger-outline {
  border-radius: 999px;
  border: 1px solid rgba(239, 68, 68, 0.7);
  background: transparent;
  color: rgb(248 113 113);
  cursor: pointer;
  transition: background 0.1s ease, transform 0.05s ease;
}

.btn-danger-outline:hover {
  background: rgba(127, 29, 29, 0.3);
}

.btn-danger-outline:active {
  transform: scale(0.97);
}

/* Views */
.view {
  display: none;
  margin-top: 4px;
}

.view-visible {
  display: block;
}

/* Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.data-table thead {
  background: rgba(15, 23, 42, 0.9);
}

.data-table th,
.data-table td {
  padding: 6px 8px;
  border-bottom: 1px solid rgba(30, 41, 59, 0.9);
}

.data-table th {
  text-align: left;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgb(148 163 184);
}

.data-table tbody tr:nth-child(even) {
  background: rgba(15, 23, 42, 0.7);
}

.data-table tbody tr:hover {
  background: rgba(17, 24, 39, 0.85);
}

.empty-cell {
  text-align: center;
  color: rgb(100 116 139);
  font-size: 0.75rem;
}

/* Notes */
.note-item {
  border-radius: 10px;
  border: 1px solid rgba(51, 65, 85, 0.9);
  background: rgba(15, 23, 42, 0.95);
  padding: 6px 7px;
}

.note-meta {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  font-size: 0.67rem;
  color: rgb(148 163 184);
  margin-bottom: 3px;
}

.note-tag {
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(55, 65, 81, 0.9);
}

.note-text {
  font-size: 0.76rem;
  color: rgb(226 232 240);
}

.empty-note {
  font-size: 0.75rem;
  color: rgb(100 116 139);
}

/* Photos */
.photos-grid {
  background: radial-gradient(circle at top, rgba(15, 23, 42, 0.9), #020617);
  border-radius: 12px;
  padding: 10px;
  border: 1px solid rgba(31, 41, 55, 0.9);
}

.photo-card {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(31, 41, 55, 1);
  background: rgba(15, 23, 42, 0.9);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.8);
}

.photo-thumb img {
  width: 100%;
  height: 80px;
  object-fit: cover;
  display: block;
}

.photo-meta {
  padding: 4px 6px 6px;
}

.photo-time {
  font-size: 0.68rem;
  color: rgb(148 163 184);
}

.photo-caption {
  font-size: 0.76rem;
  color: rgb(226 232 240);
  margin-top: 2px;
}

.empty-photos {
  font-size: 0.75rem;
  color: rgb(100 116 139);
}

/* Checklist */
.check-card {
  border-radius: 10px;
  border: 1px solid rgba(55, 65, 81, 0.95);
  background: rgba(15, 23, 42, 0.95);
  padding: 7px 8px 7px;
}

.empty-checklist {
  font-size: 0.75rem;
  color: rgb(100 116 139);
}

/* Toast */
.toast {
  position: fixed;
  right: 18px;
  bottom: 16px;
  z-index: 50;
}

.toast-inner {
  background: rgba(15, 23, 42, 0.98);
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.7);
  padding: 5px 11px;
  font-size: 0.72rem;
  color: rgb(226 232 240);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.85);
}

/* Simple desktop focus: we don't optimize for very narrow screens */
@media (max-width: 800px) {
  .app-shell {
    grid-template-columns: 220px minmax(0, 1fr);
  }
}
