/* T29 Staff Portal - Dark Theme CSS */
:root {
  --bg-dark: #0a0a0a;
  --bg-card: #111111;
  --bg-input: #1a1a1a;
  --border: #222222;
  --border-light: #333333;
  --accent: #FF2D55;
  --accent-hover: #e02550;
  --text-primary: #ffffff;
  --text-secondary: #888888;
  --text-muted: #666666;
  --success: #22c55e;
  --warning: #eab308;
  --danger: #ef4444;
  --info: #3b82f6;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.5;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Layout */
.has-sidebar {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 220px;
  height: 100vh;
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 1000;
  transform: translateX(0);
  transition: transform 0.3s;
}

.sidebar-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.logo {
  font-size: 2rem;
  font-weight: 900;
  color: var(--accent);
}

.logo-sub {
  font-size: 0.7rem;
  color: var(--text-secondary);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.nav-links {
  list-style: none;
  flex: 1;
  overflow-y: auto;
  padding: 1rem 0;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.5rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.nav-item:hover {
  background: rgba(255, 45, 85, 0.1);
  color: var(--text-primary);
  text-decoration: none;
}

.nav-icon { font-size: 1.1rem; }

.nav-logout { border-top: 1px solid var(--border); margin-top: auto; }

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.2);
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.9rem;
}

.user-name { font-size: 0.9rem; font-weight: 500; }
.user-role { font-size: 0.75rem; color: var(--text-secondary); text-transform: capitalize; }

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
}

.topbar {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 56px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  align-items: center;
  padding: 0 1rem;
  z-index: 998;
}

.hamburger {
  background: none;
  border: none;
  width: 40px;
  height: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  transition: transform 0.2s;
}

.topbar-title {
  flex: 1;
  text-align: center;
  font-weight: 600;
}

.topbar-role {
  font-size: 0.75rem;
  color: var(--text-secondary);
  text-transform: capitalize;
}

.main-content {
  flex: 1;
  margin-left: 220px;
  padding: 2rem;
  max-width: 1400px;
}

.main-public {
  max-width: 600px;
  margin: 0 auto;
  padding: 2rem;
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .sidebar-overlay.open {
    display: block;
  }
  .topbar {
    display: flex;
  }
  .main-content {
    margin-left: 0;
    padding: 1rem;
    padding-top: calc(56px + 1rem);
  }
}

/* Cards */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  margin-bottom: 1.5rem;
  overflow: hidden;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
}

.card-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.card-body {
  padding: 1rem 1.25rem;
}

/* Page Header */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.5rem;
  gap: 1rem;
  flex-wrap: wrap;
}

.page-header-left { display: flex; flex-direction: column; gap: 0.25rem; }
.page-title { font-size: 1.75rem; font-weight: 700; margin: 0; }
.page-subtitle { color: var(--text-secondary); font-size: 0.9rem; }
.page-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.back-link { color: var(--text-secondary); font-size: 0.9rem; }
.back-link:hover { color: var(--accent); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  border-radius: 0.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: background 0.2s, opacity 0.2s;
  text-decoration: none;
}

.btn:hover { text-decoration: none; }

.btn-primary {
  background: var(--accent);
  color: white;
}
.btn-primary:hover { background: var(--accent-hover); }

.btn-outline {
  background: transparent;
  border: 1px solid var(--border-light);
  color: var(--text-primary);
}
.btn-outline:hover { background: rgba(255, 255, 255, 0.05); }

.btn-danger {
  background: var(--danger);
  color: white;
}
.btn-danger:hover { background: #dc2626; }

.btn-sm { padding: 0.375rem 0.75rem; font-size: 0.8rem; }
.btn-full { width: 100%; }
.btn-icon { padding: 0.5rem; min-width: 36px; }

/* Forms */
.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.375rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.form-control {
  width: 100%;
  padding: 0.625rem 0.875rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  transition: border-color 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent);
}

.form-control-sm {
  padding: 0.375rem 0.625rem;
  font-size: 0.85rem;
}

.form-control::placeholder { color: var(--text-muted); }

textarea.form-control { resize: vertical; min-height: 80px; }

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.form-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.form-help {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.form-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
}

.checkbox-label, .radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.9rem;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 0.5rem;
}

.checkbox-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.radio-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

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

.data-table th,
.data-table td {
  padding: 0.875rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.data-table th {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.data-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.row-past { opacity: 0.6; }
.row-checked-in { background: rgba(34, 197, 94, 0.1); }
.row-checked-out { background: rgba(255, 255, 255, 0.02); }

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.625rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: capitalize;
}

.badge-green { background: rgba(34, 197, 94, 0.2); color: var(--success); }
.badge-yellow { background: rgba(234, 179, 8, 0.2); color: var(--warning); }
.badge-red { background: rgba(239, 68, 68, 0.2); color: var(--danger); }
.badge-blue { background: rgba(59, 130, 246, 0.2); color: var(--info); }
.badge-gray { background: rgba(255, 255, 255, 0.1); color: var(--text-secondary); }

.tag {
  display: inline-flex;
  padding: 0.125rem 0.5rem;
  background: rgba(255, 45, 85, 0.15);
  border-radius: 0.25rem;
  font-size: 0.75rem;
  color: var(--accent);
  margin-right: 0.25rem;
}

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 1.25rem;
  text-align: center;
}

.stat-card--alert {
  border-color: var(--accent);
  background: rgba(255, 45, 85, 0.1);
}

.stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-primary);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

/* Quick Actions */
.action-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 1rem;
}

.action-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  text-decoration: none;
  transition: border-color 0.2s, transform 0.2s;
}

.action-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  text-decoration: none;
}

.action-icon { font-size: 1.75rem; }
.action-label { font-size: 0.85rem; color: var(--text-primary); }

.section-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

/* Filters */
.filters-bar {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 1rem;
  margin-bottom: 1rem;
}

.filters-form {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.filter-input, .filter-select {
  padding: 0.5rem 0.75rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 0.9rem;
}

.filter-input { flex: 1; min-width: 150px; }

/* Dropdowns */
.dropdown { position: relative; display: inline-block; }

.dropdown-menu {
  position: absolute;
  right: 0;
  top: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  min-width: 150px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  z-index: 100;
  display: none;
}

.dropdown-menu.open { display: block; }

.dropdown-menu a,
.dropdown-menu button {
  display: block;
  width: 100%;
  padding: 0.625rem 1rem;
  text-align: left;
  color: var(--text-primary);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
}

.dropdown-menu a:hover,
.dropdown-menu button:hover {
  background: rgba(255, 255, 255, 0.05);
  text-decoration: none;
}

.dropdown-item-danger { color: var(--danger) !important; }

/* Staff List */
.staff-name-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-primary);
}

.staff-name-link:hover { color: var(--accent); }

.avatar-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  flex-shrink: 0;
}

.avatar-large {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
}

/* Profile/Detail Layout */
.detail-grid {
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: 1.5rem;
}

@media (max-width: 1024px) {
  .detail-grid {
    grid-template-columns: 1fr;
  }
}

.profile-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem;
}

.profile-info { flex: 1; }
.profile-badges { display: flex; gap: 0.5rem; margin-bottom: 0.5rem; }
.profile-tags { display: flex; flex-wrap: wrap; gap: 0.25rem; }

.detail-list { padding: 0 1.25rem 1.25rem; }

.detail-row {
  display: flex;
  justify-content: space-between;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
}

.detail-row:last-child { border-bottom: none; }
.detail-label { color: var(--text-secondary); font-size: 0.9rem; }
.detail-value { font-weight: 500; }

/* Shifts */
.shift-list { max-height: 400px; overflow-y: auto; }

.shift-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: var(--text-primary);
}

.shift-item:hover { background: rgba(255, 255, 255, 0.02); }
.shift-date { font-weight: 500; min-width: 100px; }
.shift-meta { flex: 1; font-size: 0.85rem; color: var(--text-secondary); }
.shift-actions-bar { display: flex; gap: 1rem; margin-bottom: 1.5rem; flex-wrap: wrap; }

.date-cell { display: flex; flex-direction: column; }
.date-day { font-size: 0.75rem; color: var(--text-secondary); text-transform: uppercase; }
.date-full { font-weight: 500; }

/* Messages */
.messages-page .main-content { padding: 0; max-width: none; }

.messages-container {
  display: grid;
  grid-template-columns: 300px 1fr;
  height: calc(100vh - 56px);
}

@media (max-width: 768px) {
  .messages-container {
    grid-template-columns: 1fr;
  }
  .threads-panel { display: none; }
  .threads-panel.show { display: block; }
}

.threads-panel {
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}

.threads-header {
  padding: 1rem;
  border-bottom: 1px solid var(--border);
}

.threads-header h3 { font-size: 1rem; margin: 0; }

.threads-list { flex: 1; overflow-y: auto; }

.thread-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: var(--text-primary);
}

.thread-item:hover { background: rgba(255, 255, 255, 0.02); }
.thread-item--active { background: rgba(255, 45, 85, 0.1); border-left: 3px solid var(--accent); }
.thread-item--unread { font-weight: 600; }

.thread-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 600;
  flex-shrink: 0;
}

.thread-info { flex: 1; min-width: 0; }
.thread-name { font-size: 0.9rem; }
.thread-preview { font-size: 0.8rem; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.thread-badge {
  background: var(--accent);
  color: white;
  font-size: 0.7rem;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
}

.messages-panel {
  display: flex;
  flex-direction: column;
  background: var(--bg-dark);
}

.messages-header {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--bg-card);
}

.messages-header h3 { margin: 0; font-size: 1rem; }

.messages-body {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.message-bubble {
  max-width: 70%;
  padding: 0.75rem 1rem;
  border-radius: 1rem;
}

.message-inbound {
  align-self: flex-start;
  background: var(--bg-card);
  border-bottom-left-radius: 0.25rem;
}

.message-outbound {
  align-self: flex-end;
  background: var(--accent);
  border-bottom-right-radius: 0.25rem;
}

.message-body { font-size: 0.95rem; word-wrap: break-word; }
.message-meta { display: flex; gap: 0.5rem; margin-top: 0.25rem; font-size: 0.75rem; opacity: 0.7; }
.message-time { }
.message-status { }

.messages-reply {
  display: flex;
  gap: 0.5rem;
  padding: 1rem;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
}

.messages-reply input { flex: 1; }

.messages-empty {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}

.message-thread {
  max-height: 300px;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Bulletin */
.posts-list { display: flex; flex-direction: column; gap: 1rem; }

.post-card { padding: 1.25rem; }
.post-card--pinned { border-color: var(--accent); }

.post-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.75rem; }
.post-meta { display: flex; align-items: center; gap: 0.5rem; }
.pin-icon { margin-right: 0.25rem; }
.post-date { font-size: 0.8rem; color: var(--text-secondary); }
.post-stats { font-size: 0.8rem; color: var(--text-secondary); }
.read-count { }

.post-title { font-size: 1.1rem; margin-bottom: 0.5rem; }
.post-excerpt { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 0.75rem; }
.post-image-thumb { max-width: 200px; border-radius: 0.5rem; margin-bottom: 0.75rem; }
.post-author { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.75rem; }
.post-actions { display: flex; gap: 0.5rem; }

/* Board (staff view) */
.board-posts { display: flex; flex-direction: column; gap: 1.5rem; }

.board-card { padding: 1.5rem; }
.board-card--pinned { border-color: var(--accent); }
.board-card--read { opacity: 0.7; }

.pin-banner {
  background: var(--accent);
  color: white;
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
  margin: -1.5rem -1.5rem 1rem;
  text-align: center;
}

.board-header { display: flex; justify-content: space-between; margin-bottom: 0.75rem; }
.board-date { font-size: 0.8rem; color: var(--text-secondary); }
.board-title { font-size: 1.25rem; margin-bottom: 0.75rem; }
.board-image { max-width: 100%; border-radius: 0.5rem; margin-bottom: 1rem; }
.board-body { color: var(--text-secondary); line-height: 1.6; margin-bottom: 1rem; }
.board-footer { display: flex; justify-content: space-between; align-items: center; }
.board-author { font-size: 0.85rem; color: var(--text-muted); font-style: italic; }
.read-badge { color: var(--success); font-size: 0.9rem; }

/* Tabs */
.tabs {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.tab {
  padding: 0.75rem 1.25rem;
  color: var(--text-secondary);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  font-size: 0.9rem;
}

.tab:hover { color: var(--text-primary); }
.tab--active { color: var(--accent); border-bottom-color: var(--accent); }

/* Applications */
.applications-list { display: flex; flex-direction: column; gap: 1rem; }

.application-card { padding: 1.25rem; }
.application-header { display: flex; justify-content: space-between; margin-bottom: 1rem; }
.application-name { font-size: 1.1rem; margin: 0; }
.application-contact { font-size: 0.85rem; color: var(--text-secondary); display: flex; gap: 1rem; }
.application-date { font-size: 0.8rem; color: var(--text-muted); }

.availability-grid {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.avail-label { font-size: 0.85rem; color: var(--text-secondary); }

.avail-day {
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.8rem;
}

.avail-yes { background: rgba(34, 197, 94, 0.2); color: var(--success); }
.avail-no { background: rgba(255, 255, 255, 0.05); color: var(--text-muted); text-decoration: line-through; }

.availability-grid-large {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  padding: 1rem;
}

.avail-item {
  text-align: center;
  padding: 1rem;
  border-radius: 0.5rem;
}

.avail-item .avail-day { font-size: 1rem; font-weight: 600; margin-bottom: 0.25rem; }
.avail-item .avail-status { font-size: 0.8rem; }

.application-section { margin-bottom: 1rem; }
.application-section strong { display: block; color: var(--text-secondary); font-size: 0.85rem; margin-bottom: 0.25rem; }
.application-section p { font-size: 0.9rem; }

.application-actions { display: flex; gap: 0.5rem; }
.application-review { font-size: 0.8rem; color: var(--text-muted); }

/* Attractions */
.attraction-card { margin-bottom: 1rem; }
.attraction-card--inactive { opacity: 0.6; }
.attraction-code { font-size: 0.75rem; color: var(--accent); font-weight: 600; }
.attraction-name { font-size: 1.1rem; margin: 0.25rem 0; }
.attraction-desc { font-size: 0.85rem; color: var(--text-secondary); margin: 0; }
.attraction-actions { display: flex; gap: 0.5rem; align-items: center; }

.zones-section { padding: 1rem 1.25rem; border-top: 1px solid var(--border); }
.zones-section h4 { font-size: 0.9rem; margin-bottom: 0.75rem; color: var(--text-secondary); }
.zones-list { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }

.zone-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.75rem;
  background: var(--bg-input);
  border-radius: 0.375rem;
  font-size: 0.85rem;
}

.zone-name { font-weight: 500; }
.zone-capacity { font-size: 0.75rem; color: var(--text-muted); }

/* Time Tracking */
.date-nav { margin-bottom: 1.5rem; }
.date-form { display: flex; gap: 0.5rem; }

/* Documents */
.upload-form {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
  padding: 0 0 1rem;
}

.doc-list { display: flex; flex-direction: column; gap: 0.5rem; }

.doc-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  background: var(--bg-input);
  border-radius: 0.5rem;
}

.doc-type {
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  min-width: 80px;
}

.doc-name { flex: 1; font-size: 0.9rem; }

.signature-img {
  max-width: 200px;
  background: white;
  border-radius: 0.25rem;
  padding: 0.5rem;
}

/* Incidents */
.staff-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 0.75rem;
  background: var(--bg-input);
  border-radius: 9999px;
  font-size: 0.85rem;
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
}

.staff-chip:hover { background: var(--border-light); }

.involved-staff { display: flex; flex-wrap: wrap; }

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1100;
}

.modal-content {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 1.5rem;
  max-width: 400px;
  width: 90%;
}

.modal-content h3 { margin-bottom: 1rem; }

/* Alerts */
.alert {
  padding: 0.875rem 1rem;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.alert-error {
  background: rgba(239, 68, 68, 0.2);
  color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.alert-success {
  background: rgba(34, 197, 94, 0.2);
  color: var(--success);
  border: 1px solid rgba(34, 197, 94, 0.3);
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 2rem;
  color: var(--text-muted);
}

/* Danger Zone */
.danger-zone {
  border-color: var(--danger);
}

.danger-zone .card-header {
  background: rgba(239, 68, 68, 0.1);
}

.danger-zone .card-title {
  color: var(--danger);
}

/* Text utilities */
.text-muted { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.result-count { font-size: 0.85rem; color: var(--text-muted); margin-top: 0.5rem; }

/* Bulk actions */
.bulk-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(255, 45, 85, 0.1);
  border: 1px solid var(--accent);
  border-radius: 0.5rem;
  margin-bottom: 1rem;
}

.bulk-count { font-weight: 500; }

/* Inline forms */
.inline-form {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

/* Char counter */
.char-counter {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: right;
  margin-top: 0.25rem;
}

/* Login Page */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a0a0e 100%);
}

.login-container {
  width: 100%;
  max-width: 360px;
  padding: 2rem;
}

.login-logo {
  text-align: center;
  margin-bottom: 2rem;
}

.login-logo-text {
  font-size: 4rem;
  font-weight: 900;
  color: var(--accent);
}

.login-logo-sub {
  font-size: 0.8rem;
  color: var(--text-secondary);
  letter-spacing: 0.3em;
}

.login-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 2rem;
}

.login-title {
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  text-align: center;
}

.login-form .form-group { margin-bottom: 1.25rem; }

.login-footer {
  text-align: center;
  margin-top: 1.5rem;
}

.login-footer a {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Apply Page */
.apply-page {
  min-height: 100vh;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a0a0e 100%);
  padding: 2rem 1rem;
}

.apply-container {
  max-width: 500px;
  margin: 0 auto;
}

.apply-logo {
  text-align: center;
  margin-bottom: 2rem;
}

.apply-logo-text {
  font-size: 3rem;
  font-weight: 900;
  color: var(--accent);
}

.apply-logo-sub {
  font-size: 0.9rem;
  color: var(--text-secondary);
  letter-spacing: 0.2em;
}

.apply-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 2rem;
}

.apply-intro {
  text-align: center;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.apply-success {
  text-align: center;
}

.apply-success h1 {
  color: var(--success);
  margin-bottom: 1rem;
}

.apply-success p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.apply-footer {
  text-align: center;
  margin-top: 1.5rem;
}

.apply-footer a {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Current image preview */
.current-image {
  margin-top: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.current-image img {
  max-width: 100px;
  border-radius: 0.25rem;
}

.current-image span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* SMS list on dashboard */
.sms-list { padding: 0; }

.sms-item {
  padding: 0.875rem 1.25rem;
  border-bottom: 1px solid var(--border);
}

.sms-item:last-child { border-bottom: none; }
.sms-item--unread { background: rgba(255, 45, 85, 0.05); }

.sms-from { font-weight: 500; margin-bottom: 0.25rem; }
.sms-body { font-size: 0.9rem; color: var(--text-secondary); margin-bottom: 0.25rem; }
.sms-time { font-size: 0.8rem; color: var(--text-muted); }

/* Shift summary */
.shift-summary { padding: 1rem 1.25rem; }
.shift-info { display: flex; gap: 1rem; align-items: center; margin-bottom: 0.5rem; }
.shift-label { font-weight: 600; }
.shift-time { color: var(--text-secondary); }
.shift-count { font-size: 0.9rem; color: var(--text-muted); }

/* Quick actions section */
.quick-actions { margin-bottom: 1.5rem; }

/* Forms within cards */
.form-card .card {
  margin-bottom: 1.5rem;
}

.form-card .card-body {
  padding: 1.25rem;
}

/* Table card */
.table-card {
  overflow-x: auto;
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .form-grid {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .action-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .page-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .filters-form {
    flex-direction: column;
    align-items: stretch;
  }

  .filter-input {
    width: 100%;
  }

  .data-table {
    font-size: 0.85rem;
  }

  .data-table th,
  .data-table td {
    padding: 0.625rem 0.5rem;
  }

  .availability-grid-large {
    grid-template-columns: 1fr;
  }
}
