/* ============================================
   DAILY MESSAGE ADMIN - Styles
   ============================================ */

:root {
  --primary: #6B0F1A;
  --primary-dark: #4A0A12;
  --primary-light: #8B1F2A;
  --secondary: #C9A961;
  --secondary-light: #E5D5A8;
  --background: #F8F6F1;
  --surface: #FFFFFF;
  --text: #2C2C2C;
  --text-light: #6B6B6B;
  --text-muted: #999999;
  --border: #E0DCD3;
  --success: #2C6B3F;
  --danger: #C0392B;
  --warning: #D4A017;

  --font-heading: 'Cinzel', serif;
  --font-body: 'Crimson Text', Georgia, serif;

  --sidebar-width: 260px;
  --transition: all 0.2s ease;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 4px 20px rgba(0, 0, 0, 0.12);
}

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

body {
  font-family: var(--font-body);
  background: var(--background);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  border: 2px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

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

.btn-primary:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

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

.btn-danger {
  background: var(--danger);
  color: white;
  border-color: var(--danger);
}

.btn-danger:hover {
  background: #A93226;
  border-color: #A93226;
}

.btn-small {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.btn-full {
  width: 100%;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Form Elements */
.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  border: 2px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(107, 15, 26, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-hint {
  display: block;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.image-preview-container {
  margin-top: 1rem;
}

.image-preview-container .preview-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.image-preview-container .preview-image-container {
  width: 100%;
  max-width: 400px;
  height: 200px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid var(--border);
  box-shadow: var(--shadow);
}

.image-preview-container .preview-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

@media (max-width: 600px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.checkbox-group {
  margin-top: 1rem;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  font-weight: normal;
}

.checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--primary);
}

.error-message {
  color: var(--danger);
  font-size: 0.9rem;
  margin: 0.5rem 0;
  padding: 0.75rem;
  background: rgba(192, 57, 43, 0.1);
  border-radius: 4px;
  display: none;
}

.error-message:not(:empty) {
  display: block;
}

.success-message {
  color: var(--success);
  font-size: 0.9rem;
  margin: 0.5rem 0;
  padding: 0.75rem;
  background: rgba(44, 107, 63, 0.1);
  border-radius: 4px;
  display: none;
}

.success-message:not(:empty) {
  display: block;
}

/* ============================================
   LOGIN SCREEN
   ============================================ */
#loginScreen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: linear-gradient(135deg, var(--background) 0%, #E8E4D9 100%);
}

.login-container {
  width: 100%;
  max-width: 400px;
  background: var(--surface);
  padding: 3rem 2.5rem;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}

.login-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.login-title {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.25rem;
}

.login-subtitle {
  font-size: 1rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

.login-form {
  margin-bottom: 2rem;
}

.back-link {
  display: block;
  text-align: center;
  color: var(--text-light);
  text-decoration: none;
  font-size: 0.9rem;
  transition: var(--transition);
}

.back-link:hover {
  color: var(--primary);
}

/* ============================================
   DASHBOARD LAYOUT
   ============================================ */
#dashboardScreen {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.sidebar {
  width: var(--sidebar-width);
  background: var(--primary-dark);
  color: white;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  z-index: 100;
}

.sidebar-header {
  padding: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--secondary-light);
}

.sidebar-badge {
  display: inline-block;
  font-size: 0.7rem;
  background: var(--secondary);
  color: var(--primary-dark);
  padding: 0.2rem 0.5rem;
  border-radius: 3px;
  margin-left: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
}

.sidebar-nav {
  flex: 1;
  padding: 1rem 0;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.875rem 1.5rem;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.7);
  font-family: var(--font-body);
  font-size: 1rem;
  text-align: left;
  cursor: pointer;
  transition: var(--transition);
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.1);
  color: white;
}

.nav-item.active {
  background: rgba(255, 255, 255, 0.15);
  color: var(--secondary-light);
  border-left: 3px solid var(--secondary);
}

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

.sidebar-footer {
  padding: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.admin-info {
  margin-bottom: 1rem;
}

.admin-label {
  display: block;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.admin-name {
  display: block;
  font-weight: 600;
  color: var(--secondary-light);
}

.sidebar-footer .btn-outline {
  color: rgba(255, 255, 255, 0.8);
  border-color: rgba(255, 255, 255, 0.3);
}

.sidebar-footer .btn-outline:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
  color: white;
}

/* Main Panel */
.main-panel {
  flex: 1;
  margin-left: var(--sidebar-width);
  padding: 2rem;
  min-height: 100vh;
}

.view {
  max-width: 1200px;
  margin: 0 auto;
}

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

.view-title {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.25rem;
}

.view-subtitle {
  color: var(--text-light);
}

.view-actions {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

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

.stat-card {
  background: var(--surface);
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: var(--shadow);
  text-align: center;
  border: 1px solid var(--border);
}

.stat-value {
  display: block;
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.dashboard-section {
  margin-bottom: 2.5rem;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.today-quote-card {
  background: var(--surface);
  padding: 2rem;
  border-radius: 10px;
  border-left: 4px solid var(--secondary);
  box-shadow: var(--shadow);
}

.today-quote-text {
  font-size: 1.25rem;
  font-style: italic;
  color: var(--text);
  margin-bottom: 1rem;
  line-height: 1.6;
}

.today-quote-author {
  font-weight: 600;
  color: var(--primary);
}

.quick-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.action-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-body);
  font-size: 1rem;
}

.action-btn:hover {
  border-color: var(--primary);
  background: rgba(107, 15, 26, 0.02);
}

.action-icon {
  font-size: 1.25rem;
}

/* ============================================
   QUOTES LIST VIEW
   ============================================ */
.search-box input {
  padding: 0.6rem 1rem;
  font-size: 0.95rem;
  border: 2px solid var(--border);
  border-radius: 6px;
  width: 250px;
}

.filter-select {
  padding: 0.6rem 1rem;
  font-size: 0.95rem;
  border: 2px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  cursor: pointer;
}

.quotes-table-container {
  background: var(--surface);
  border-radius: 10px;
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-bottom: 1.5rem;
}

.quotes-table {
  width: 100%;
  border-collapse: collapse;
}

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

.quotes-table th {
  background: var(--background);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-light);
}

.quotes-table td {
  font-size: 0.95rem;
}

.quotes-table tbody tr:hover {
  background: rgba(107, 15, 26, 0.02);
}

.quotes-table .quote-preview {
  max-width: 300px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.quotes-table .status-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
}

.status-badge.active {
  background: rgba(44, 107, 63, 0.1);
  color: var(--success);
}

.status-badge.inactive {
  background: rgba(153, 153, 153, 0.1);
  color: var(--text-muted);
}

.table-actions {
  display: flex;
  gap: 0.5rem;
}

.table-actions button {
  padding: 0.4rem 0.75rem;
  font-size: 0.85rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--surface);
  cursor: pointer;
  transition: var(--transition);
}

.table-actions button:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.table-actions .delete-btn:hover {
  border-color: var(--danger);
  color: var(--danger);
}

.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}

.pagination button {
  padding: 0.5rem 1rem;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 4px;
  cursor: pointer;
  transition: var(--transition);
}

.pagination button:hover:not(:disabled) {
  border-color: var(--primary);
  color: var(--primary);
}

.pagination button.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.pagination button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ============================================
   ADD/EDIT QUOTE VIEW
   ============================================ */
.quote-form {
  background: var(--surface);
  padding: 2rem;
  border-radius: 10px;
  box-shadow: var(--shadow);
  max-width: 700px;
}

.form-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

/* ============================================
   CALENDAR VIEW
   ============================================ */
.admin-calendar {
  background: var(--surface);
  border-radius: 10px;
  box-shadow: var(--shadow);
  overflow: hidden;
  max-width: 800px;
}

.admin-calendar-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  padding: 1.5rem;
  background: var(--primary);
}

.admin-calendar-month {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  color: var(--secondary-light);
  min-width: 200px;
  text-align: center;
}

.admin-calendar-nav .nav-btn {
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: white;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.admin-calendar-nav .nav-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
}

.admin-calendar-grid {
  padding: 1px;
  background: var(--border);
}

.admin-calendar-header {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  background: var(--background);
}

.admin-calendar-header span {
  padding: 0.75rem;
  text-align: center;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-light);
}

.admin-calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
  background: var(--border);
}

.admin-calendar-day {
  aspect-ratio: 1.2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  background: var(--surface);
  cursor: pointer;
  transition: var(--transition);
  padding: 0.5rem;
}

.admin-calendar-day:hover {
  background: var(--background);
}

.admin-calendar-day.empty {
  background: var(--background);
  cursor: default;
}

.admin-calendar-day .day-number {
  font-weight: 600;
  font-size: 1rem;
}

.admin-calendar-day {
  position: relative;
}

.admin-calendar-day .day-indicator {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  bottom: 4px;
}

.admin-calendar-day .day-indicator.scheduled-indicator {
  background: var(--secondary);
  left: 4px;
}

.admin-calendar-day .day-indicator.displayed-indicator {
  background: var(--success);
  left: 16px;
}

.admin-calendar-day .day-indicator.today-indicator {
  background: var(--primary);
  border: 2px solid white;
  width: 10px;
  height: 10px;
  bottom: 2px;
  right: 4px;
}

.admin-calendar-day.today {
  background: var(--secondary-light);
}

.admin-calendar-day.today .day-number {
  color: var(--primary);
  font-weight: 700;
}

.calendar-legend {
  display: flex;
  gap: 2rem;
  justify-content: center;
  padding: 1.5rem;
  margin-top: 1rem;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-light);
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.legend-dot.scheduled {
  background: var(--secondary);
}

.legend-dot.displayed {
  background: var(--success);
}

.legend-dot.today {
  background: var(--secondary-light);
  border: 2px solid var(--primary);
}

/* Calendar Quote Preview */
.calendar-quote-preview {
  background: var(--surface);
  border-radius: 10px;
  box-shadow: var(--shadow);
  margin-top: 1.5rem;
  max-width: 800px;
  overflow: hidden;
  animation: slideDown 0.3s ease;
  position: relative;
  min-height: 400px;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: var(--primary);
  color: white;
}

.preview-date {
  font-family: var(--font-heading);
  font-size: 1rem;
  color: var(--secondary-light);
}

.preview-close {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
  transition: var(--transition);
}

.preview-close:hover {
  color: white;
}

.preview-content {
  padding: 1.5rem;
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}

.preview-text-content {
  flex: 1;
  min-width: 0;
}

.preview-image-container {
  flex-shrink: 0;
  width: 200px;
  height: 150px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid var(--border);
  box-shadow: var(--shadow);
}

.preview-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Responsive: stack image below on smaller screens */
@media (max-width: 768px) {
  .preview-content {
    flex-direction: column;
  }
  
  .preview-image-container {
    width: 100%;
    max-width: 300px;
    height: 200px;
    align-self: center;
  }
}

.preview-quote-text {
  font-size: 1.2rem;
  font-style: italic;
  color: var(--text);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.preview-quote-author {
  display: block;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.75rem;
}

.preview-scripture {
  font-size: 0.9rem;
  color: var(--text-light);
  font-style: italic;
}

.preview-actions {
  padding: 0 1.5rem 1.5rem;
}

.no-quote-message {
  text-align: center;
  color: var(--text-muted);
  font-style: italic;
  padding: 1rem;
}

.admin-calendar-day.selected {
  background: var(--primary);
}

.admin-calendar-day.selected .day-number {
  color: white;
}

.admin-calendar-day.selected .day-indicator {
  background: white;
}

/* Countdown Timer */
.countdown-section {
  background: var(--surface);
  border-radius: 10px;
  box-shadow: var(--shadow);
  padding: 2rem;
  margin-bottom: 1.5rem;
  max-width: 800px;
  text-align: center;
}

.countdown-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1.5rem;
}

.countdown-timer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.countdown-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 80px;
}

.countdown-value {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
  background: var(--background);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  min-width: 90px;
}

.countdown-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-top: 0.5rem;
}

.countdown-separator {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--secondary);
  padding-bottom: 1.5rem;
}

.countdown-date {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--text-light);
}

/* ============================================
   MODAL
   ============================================ */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
}

.modal-content {
  position: relative;
  background: var(--surface);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  max-width: 600px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-small {
  max-width: 400px;
}

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

.modal-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  color: var(--primary);
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-light);
  cursor: pointer;
  padding: 0.5rem;
  line-height: 1;
}

.modal-close:hover {
  color: var(--text);
}

.modal-body {
  padding: 1.5rem;
}

.modal-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 1.5rem;
}

/* ============================================
   SETTINGS VIEW
   ============================================ */
.settings-section {
  background: var(--surface);
  padding: 2rem;
  border-radius: 10px;
  box-shadow: var(--shadow);
  margin-bottom: 2rem;
  max-width: 500px;
}

.settings-form {
  max-width: 100%;
}

.info-card {
  background: var(--background);
  border-radius: 8px;
  padding: 1rem;
}

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

.info-row:last-child {
  border-bottom: none;
}

.info-label {
  color: var(--text-light);
  font-size: 0.9rem;
}

.info-value {
  font-weight: 600;
  color: var(--text);
}

/* ============================================
   DELETE MODAL STYLES
   ============================================ */
.delete-warning {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--danger);
  margin-bottom: 1rem;
}

.delete-preview {
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.delete-preview-quote {
  font-style: italic;
  color: var(--text);
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.delete-preview-author {
  font-weight: 600;
  color: var(--primary);
  font-size: 0.9rem;
}

.delete-note {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

/* Swap Modal Styles */
.swap-instruction {
  margin-bottom: 1rem;
  color: var(--text);
}

.swap-preview {
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1rem;
  margin-bottom: 1.5rem;
}

.swap-quotes-list {
  max-height: 300px;
  overflow-y: auto;
  margin-bottom: 1rem;
}

.swap-quote-item,
.swap-quote-option {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: 6px;
  padding: 1rem;
  margin-bottom: 0.75rem;
  cursor: pointer;
  transition: var(--transition);
}

.swap-quote-option:hover {
  border-color: var(--primary);
  background: rgba(107, 15, 26, 0.02);
}

.swap-quote-option.selected {
  border-color: var(--primary);
  background: rgba(107, 15, 26, 0.05);
}

.swap-quote-text {
  font-style: italic;
  color: var(--text);
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.swap-quote-author {
  font-weight: 600;
  color: var(--primary);
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.swap-quote-date {
  font-size: 0.85rem;
  color: var(--text-light);
}

.modal-large {
  max-width: 650px;
}

/* ============================================
   MESSAGES VIEW STYLES
   ============================================ */
.messages-container {
  max-width: 1000px;
}

.messages-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.message-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.message-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.message-card.message-unread {
  border-left: 4px solid var(--primary);
  background: linear-gradient(90deg, rgba(107, 15, 26, 0.05) 0%, var(--surface) 2%);
}

.message-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.message-meta {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex: 1;
}

.message-name {
  font-weight: 600;
  color: var(--primary);
  font-size: 1.1rem;
}

.message-email {
  color: var(--text-light);
  font-size: 0.9rem;
  text-decoration: none;
}

.message-email:hover {
  color: var(--primary);
  text-decoration: underline;
}

.message-date {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 0.25rem;
}

.unread-badge {
  display: inline-block;
  background: var(--primary);
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  margin-left: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.message-actions {
  display: flex;
  gap: 0.5rem;
}

.btn-mark-read,
.btn-reply {
  background: var(--background);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
  text-decoration: none;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-mark-read:hover {
  background: var(--success);
  border-color: var(--success);
  color: white;
}

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

.message-subject {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--text);
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.message-body {
  color: var(--text);
  line-height: 1.7;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.message-read {
  opacity: 0.85;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 900px) {
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .main-panel {
    margin-left: 0;
  }

  .quotes-table-container {
    overflow-x: auto;
  }

  .quotes-table {
    min-width: 700px;
  }
}

@media (max-width: 600px) {
  .main-panel {
    padding: 1rem;
  }

  .view-header {
    margin-bottom: 1.5rem;
  }

  .view-actions {
    flex-direction: column;
  }

  .search-box input {
    width: 100%;
  }

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

  .quick-actions {
    flex-direction: column;
  }

  .action-btn {
    width: 100%;
  }
}