/* Inbox Modern Styles */

.inbox-wrap {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 20px;
  padding: 20px 0 60px;
  align-items: start;
}

@media (max-width: 700px) {
  .inbox-wrap {
    grid-template-columns: 1fr;
  }
}

/* Sidebar Navigation */
.sidebar-nav {
  background: #fff;
  border: 1px solid #E5E0D8;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
  position: sticky;
  top: 80px;
}

.snav-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  font-size: 14px;
  font-weight: 600;
  border-left: 3px solid transparent;
  transition: 0.15s;
  cursor: pointer;
}

.snav-item:hover,
.snav-item.active {
  background: #f0fdf4;
  border-left-color: #2C5F2D;
  color: #1A3A1B;
}

.snav-item.active {
  font-weight: 800;
}

.snav-badge {
  background: #dc2626;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
}

/* Message Card */
.msg-card {
  background: #fff;
  border: 1px solid #E5E0D8;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
}

.msg-head {
  padding: 14px 18px;
  border-bottom: 1px solid #E5E0D8;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.msg-head h2 {
  font-family: 'Fraunces', serif;
  font-size: 20px;
  color: #1A3A1B;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Message Table */
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th {
  padding: 9px 14px;
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  color: #6b7280;
  border-bottom: 1px solid #E5E0D8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: #fafafa;
}

td {
  padding: 12px 14px;
  border-bottom: 1px solid #f3f4f6;
  vertical-align: middle;
}

tr:last-child td {
  border-bottom: none;
}

tr.unread td {
  background: #fefce8;
}

tr.unread .msg-subj {
  font-weight: 800;
}

tr:hover td {
  background: #f9fafb;
}

.msg-subj {
  color: #111827;
  font-weight: 600;
}

.msg-preview {
  font-size: 12px;
  color: #6b7280;
  margin-top: 2px;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.msg-who {
  font-weight: 700;
  font-size: 13px;
}

.msg-prof {
  font-size: 11px;
  color: #6b7280;
}

.unread-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #dc2626;
  display: inline-block;
  margin-right: 4px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: 0.15s;
  text-decoration: none;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-g {
  background: #2C5F2D;
  color: #fff;
}

.btn-g:hover {
  background: #4A8F4B;
}

.btn-outline {
  background: #fff;
  border: 1.5px solid #E5E0D8;
  color: #374151;
}

.btn-outline:hover {
  background: #f9fafb;
}

.btn-danger {
  background: #fff;
  border: 1.5px solid #fca5a5;
  color: #dc2626;
}

.btn-danger:hover {
  background: #fef2f2;
}

.btn-sm {
  padding: 5px 10px;
  font-size: 12px;
}

/* Compose Form */
.compose-form {
  background: #fff;
  border: 1px solid #E5E0D8;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
}

.compose-form h2 {
  font-family: 'Fraunces', serif;
  font-size: 22px;
  color: #1A3A1B;
  margin-bottom: 20px;
}

.field {
  margin-bottom: 14px;
}

.field label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #374151;
  margin-bottom: 5px;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 10px 13px;
  border: 1.5px solid #E5E0D8;
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: #2C5F2D;
  box-shadow: 0 0 0 3px rgba(44, 95, 45, 0.1);
}

.field textarea {
  resize: vertical;
  min-height: 120px;
}

/* Alerts */
.alert {
  padding: 11px 15px;
  border-radius: 10px;
  margin-bottom: 14px;
  font-size: 14px;
  font-weight: 500;
}

.alert.ok {
  background: rgba(22, 163, 74, 0.08);
  border: 1px solid rgba(22, 163, 74, 0.2);
  color: #15803d;
}

.alert.err {
  background: rgba(220, 38, 38, 0.08);
  border: 1px solid rgba(220, 38, 38, 0.2);
  color: #dc2626;
}

/* Search Bar */
.search-bar {
  display: flex;
  gap: 8px;
}

.search-bar input {
  flex: 1;
  padding: 8px 13px;
  border: 1.5px solid #E5E0D8;
  border-radius: 10px;
  font-size: 13px;
  font-family: inherit;
  outline: none;
}

.search-bar input:focus {
  border-color: #2C5F2D;
}

/* Empty State */
.empty {
  text-align: center;
  padding: 50px;
  color: #6b7280;
}

.empty i {
  font-size: 40px;
  opacity: 0.3;
  display: block;
  margin-bottom: 12px;
}
