/* ==========================================================================
   CSS Variables & Core Reset
   ========================================================================== */
:root {
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  
  /* Color Palette (Clean Light Mode) */
  --bg-app: #f8fafc;
  --bg-card: #ffffff;
  --bg-input: #f8fafc;
  --bg-hover: #f1f5f9;
  
  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --primary-light: #e0e7ff;
  
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  
  --border: #e2e8f0;
  --border-focus: #cbd5e1;
  
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;
  --error: #ef4444;
  --error-light: #fef2f2;
  
  /* Shadows & Radius */
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-indigo: 0 0 0 4px rgba(79, 70, 229, 0.15);
  
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;
  
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-app);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 20px;
}

/* ==========================================================================
   Layout Containers
   ========================================================================== */
.app-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.narrow-container {
  max-width: 800px;
}

.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--bg-card);
  padding: 16px 24px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

.header-centered {
  justify-content: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.25rem;
}

.logo-centered {
  justify-content: center;
  margin-bottom: 20px;
}

.logo-icon {
  color: var(--primary);
  width: 28px;
  height: 28px;
}

.accent-text {
  color: var(--primary);
}

.badge-admin {
  background-color: var(--text-main);
  color: white;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-left: 6px;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn-logout {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  background-color: var(--bg-card);
  padding: 8px 16px;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.85rem;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.btn-logout:hover {
  background-color: var(--error-light);
  color: var(--error);
  border-color: var(--error);
}

.btn-logout svg {
  width: 16px;
  height: 16px;
}

/* ==========================================================================
   Common Card Styling
   ========================================================================== */
.card {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 28px;
}

.card-header {
  margin-bottom: 24px;
}

.card-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.card-header p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ==========================================================================
   Forms & Controls
   ========================================================================== */
.form-group {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-main);
}

label .optional {
  font-weight: 400;
  color: var(--text-light);
  font-size: 0.8rem;
}

label .required {
  color: var(--error);
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 12px;
  color: var(--text-light);
  width: 18px;
  height: 18px;
  pointer-events: none;
}

input[type="text"],
input[type="email"],
input[type="password"],
textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  background-color: var(--bg-input);
  color: var(--text-main);
  transition: var(--transition);
  outline: none;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
textarea:focus {
  border-color: var(--primary);
  background-color: var(--bg-card);
  box-shadow: var(--shadow-indigo);
}

.input-wrapper input {
  padding-left: 40px;
}

textarea {
  resize: vertical;
}

/* ==========================================================================
   Media Attachments Layout
   ========================================================================== */
.attachments-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

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

.attachment-box {
  background-color: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
}

.attachment-box label {
  margin-bottom: 8px;
}

/* Upload Screenshot Box */
.upload-zone {
  position: relative;
  border: 2px dashed var(--border);
  border-radius: var(--radius-sm);
  background-color: var(--bg-card);
  height: 160px;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  cursor: pointer;
  overflow: hidden;
  transition: var(--transition);
}

.upload-zone:hover {
  border-color: var(--primary);
}

.file-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.upload-prompt {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
}

.upload-icon {
  width: 32px;
  height: 32px;
  color: var(--text-light);
  margin-bottom: 8px;
}

.upload-main-text {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-main);
}

.upload-sub-text {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.upload-preview-container {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

#upload-preview {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.remove-upload-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  background-color: rgba(15, 23, 42, 0.7);
  color: white;
  border: none;
  border-radius: var(--radius-full);
  width: 26px;
  height: 26px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: var(--transition);
  z-index: 10;
}

.remove-upload-btn:hover {
  background-color: var(--error);
}

.remove-upload-btn svg {
  width: 14px;
  height: 14px;
}

/* Audio Recording Box */
.audio-zone {
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  height: 160px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 16px;
  position: relative;
}

.audio-state-idle {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.audio-action-btn {
  background-color: var(--primary-light);
  color: var(--primary);
  border: none;
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  margin-bottom: 8px;
  transition: var(--transition);
}

.audio-action-btn:hover {
  transform: scale(1.08);
  background-color: var(--primary);
  color: white;
}

.audio-action-btn svg {
  width: 20px;
  height: 20px;
}

.audio-main-text {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-main);
}

.audio-sub-text {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Recording State */
.audio-state-recording {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.record-pulse-wrapper {
  position: relative;
  width: 36px;
  height: 36px;
  margin-bottom: 6px;
}

.mic-icon-red {
  background-color: var(--error);
  color: white;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  z-index: 2;
}

.mic-icon-red svg {
  width: 16px;
  height: 16px;
}

.pulse-ring {
  border: 3px solid var(--error);
  border-radius: var(--radius-full);
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  animation: pulse-animation 1.5s infinite ease-out;
  z-index: 1;
}

@keyframes pulse-animation {
  0% {
    transform: scale(1);
    opacity: 0.6;
  }
  100% {
    transform: scale(1.6);
    opacity: 0;
  }
}

.record-timer {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
  font-variant-numeric: tabular-nums;
}

.audio-recording-text {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.audio-recording-controls {
  display: flex;
  gap: 10px;
}

.control-btn {
  display: flex;
  align-items: center;
  gap: 4px;
  border: none;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.75rem;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.cancel-btn {
  background-color: var(--error-light);
  color: var(--error);
}

.cancel-btn:hover {
  background-color: var(--error);
  color: white;
}

.stop-btn {
  background-color: var(--text-main);
  color: white;
}

.stop-btn:hover {
  background-color: #000;
}

/* Playback State & Custom Player */
.audio-state-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.inline-player {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-hover);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px;
  width: 100%;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  align-items: center;
}

.player-controls-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
}

.player-control-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 30px;
  height: 30px;
  border-radius: var(--radius-full);
  transition: var(--transition);
}

.player-control-btn:hover {
  background-color: var(--border);
  color: var(--text-main);
}

.player-control-btn svg {
  width: 16px;
  height: 16px;
}

.player-play-btn {
  background-color: var(--primary);
  color: white;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: var(--transition);
}

.player-play-btn:hover {
  background-color: var(--primary-hover);
  transform: scale(1.05);
}

.player-play-btn svg {
  width: 14px;
  height: 14px;
}

.player-timeline-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.player-current-time,
.player-duration {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  min-width: 32px;
}

.player-slider {
  flex-grow: 1;
  height: 4px;
  border-radius: var(--radius-full);
  background-color: var(--border);
  outline: none;
  accent-color: var(--primary);
  cursor: pointer;
}

.player-delete-btn {
  background-color: transparent;
  color: var(--text-light);
  border: none;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  transition: var(--transition);
}

.player-delete-btn:hover {
  color: var(--error);
}

.player-delete-btn svg {
  width: 16px;
  height: 16px;
}

.audio-preview-help {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Form Actions */
.submit-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  background-color: var(--primary);
  color: white;
  border: none;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  padding: 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.submit-btn:hover {
  background-color: var(--primary-hover);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.submit-btn svg {
  width: 18px;
  height: 18px;
}

/* ==========================================================================
   Success Screen Overlay
   ========================================================================== */
.success-screen {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px 20px;
}

.success-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  padding: 40px;
  text-align: center;
  max-width: 480px;
  width: 100%;
  animation: scale-up 0.3s ease-out;
}

@keyframes scale-up {
  0% { transform: scale(0.95); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.success-checkmark {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}

.check-icon-wrapper {
  background-color: var(--success-light);
  color: var(--success);
  width: 64px;
  height: 64px;
  border-radius: var(--radius-full);
  display: flex;
  justify-content: center;
  align-items: center;
  border: 2px solid var(--success);
}

.check-icon {
  width: 32px;
  height: 32px;
}

.success-card h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 12px;
}

.success-card p {
  color: var(--text-muted);
  margin-bottom: 24px;
  font-size: 0.95rem;
}

.btn-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background-color: var(--bg-hover);
  color: var(--text-main);
  border: 1px solid var(--border);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  margin: 0 auto;
}

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

/* ==========================================================================
   Login view styling
   ========================================================================== */
.login-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 90vh;
  width: 100%;
}

.login-card {
  max-width: 420px;
  width: 100%;
  box-shadow: var(--shadow-lg);
  animation: scale-up 0.3s ease-out;
}

.login-header {
  text-align: center;
  margin-bottom: 24px;
}

.login-header h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.login-header p {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.error-banner {
  background-color: var(--error-light);
  color: var(--error);
  border: 1px solid var(--error);
  font-size: 0.85rem;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  text-align: center;
  font-weight: 500;
}

/* ==========================================================================
   Admin Grid Layout
   ========================================================================== */
.admin-grid {
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 20px;
  min-height: 580px;
  height: calc(100vh - 120px);
}

@media (max-width: 900px) {
  .admin-grid {
    grid-template-columns: 1fr;
    height: auto;
  }
}

.admin-sidebar {
  display: flex;
  flex-direction: column;
  padding: 20px !important;
  gap: 16px;
  height: 100%;
}

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

.sidebar-header h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-main);
}

.report-count-badge {
  background-color: var(--primary-light);
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.search-filter-box {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 10px;
  color: var(--text-light);
  width: 16px;
  height: 16px;
}

#report-search {
  padding-left: 36px;
  font-size: 0.85rem;
  border-radius: var(--radius-sm);
  padding-top: 10px;
  padding-bottom: 10px;
}

.filter-tabs {
  display: flex;
  background-color: var(--bg-hover);
  padding: 2px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.filter-tab-btn {
  flex: 1;
  border: none;
  background: none;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.75rem;
  color: var(--text-muted);
  padding: 6px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.filter-tab-btn.active {
  background-color: var(--bg-card);
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
  font-weight: 600;
}

.reports-list {
  flex-grow: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-right: 2px;
}

/* Scrollbar styling for reports list */
.reports-list::-webkit-scrollbar {
  width: 4px;
}
.reports-list::-webkit-scrollbar-track {
  background: transparent;
}
.reports-list::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: var(--radius-full);
}

/* Report Item Card */
.report-item {
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.report-item:hover {
  border-color: var(--primary);
  background-color: var(--bg-hover);
}

.report-item.active {
  border-color: var(--primary);
  background-color: var(--primary-light);
}

.report-item-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}

.report-sender {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.report-date {
  font-size: 0.7rem;
  color: var(--text-light);
  white-space: nowrap;
}

.report-desc-snippet {
  font-size: 0.8rem;
  color: var(--text-muted);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.report-item-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 4px;
}

.attachment-indicators {
  display: flex;
  gap: 6px;
  color: var(--text-light);
}

.attachment-indicators svg {
  width: 14px;
  height: 14px;
}

.status-badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: var(--radius-full);
}

.status-pending {
  background-color: var(--warning-light);
  color: var(--warning);
}

.status-replied {
  background-color: var(--success-light);
  color: var(--success);
}

/* ==========================================================================
   Admin Detail View Panel
   ========================================================================== */
.admin-detail-view {
  padding: 0 !important;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.detail-empty-state {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  height: 100%;
  padding: 40px;
  color: var(--text-muted);
}

.empty-icon {
  width: 48px;
  height: 48px;
  color: var(--text-light);
  margin-bottom: 16px;
}

.detail-empty-state h3 {
  font-size: 1.15rem;
  color: var(--text-main);
  margin-bottom: 4px;
}

.detail-empty-state p {
  font-size: 0.85rem;
}

/* Detail Active Content */
.detail-content {
  display: flex;
  flex-direction: column;
  height: 100%;
}

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

.sender-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sender-avatar {
  background-color: var(--primary-light);
  color: var(--primary);
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: 700;
  font-size: 1.1rem;
}

.sender-info h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
}

.sender-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.detail-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.detail-date {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}

.detail-date svg {
  width: 12px;
  height: 12px;
}

/* Detail Body Scrollable Area */
.detail-body {
  flex-grow: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Scrollbar styling for detail body */
.detail-body::-webkit-scrollbar {
  width: 4px;
}
.detail-body::-webkit-scrollbar-track {
  background: transparent;
}
.detail-body::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: var(--radius-full);
}

.detail-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.detail-section h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.desc-box {
  background-color: var(--bg-app);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px;
  font-size: 0.95rem;
  color: var(--text-main);
  white-space: pre-wrap;
}

/* Detail Media Preview Cards */
.detail-media-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

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

.media-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background-color: var(--bg-app);
  display: flex;
  flex-direction: column;
}

.media-type-badge {
  background-color: var(--bg-hover);
  border-bottom: 1px solid var(--border);
  padding: 8px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.media-type-badge svg {
  width: 14px;
  height: 14px;
}

.clickable-image {
  max-height: 140px;
  width: 100%;
  object-fit: cover;
  cursor: zoom-in;
  transition: var(--transition);
}

.clickable-image:hover {
  opacity: 0.9;
}

.detail-audio-player {
  margin: 16px;
  box-shadow: none;
}

/* Detail Reply Form */
.detail-reply-section {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.detail-reply-section h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

#admin-reply-text {
  background-color: var(--bg-card);
  border-color: var(--border);
  margin-bottom: 12px;
}

.reply-submit-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  align-self: flex-end;
  background-color: var(--success);
  color: white;
  border: none;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.reply-submit-btn:hover {
  background-color: #059669;
}

.reply-submit-btn svg {
  width: 16px;
  height: 16px;
}

/* Sent Reply View styling */
.sent-reply-box {
  background-color: var(--success-light);
  border: 1px solid var(--success);
  border-radius: var(--radius-sm);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sent-reply-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--success);
}

.sent-reply-header span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.reply-date {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 400;
}

#sent-reply-text {
  font-size: 0.9rem;
  color: var(--text-main);
  white-space: pre-wrap;
}

/* ==========================================================================
   Image Lightbox Modal
   ========================================================================== */
.lightbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(15, 23, 42, 0.9);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  animation: fade-in 0.2s ease-out;
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.lightbox-modal img {
  max-width: 90%;
  max-height: 85%;
  border-radius: var(--radius-sm);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  animation: scale-up 0.2s ease-out;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  padding: 8px;
  transition: var(--transition);
}

.lightbox-close:hover {
  transform: rotate(90deg);
  color: var(--error);
}

.lightbox-close svg {
  width: 32px;
  height: 32px;
}

/* ==========================================================================
   Utility Classes
   ========================================================================== */
.hidden {
  display: none !important;
}

.view-section {
  display: none;
}

.view-section.active {
  display: block;
}

/* ==========================================================================
   Toast Warning Styles
   ========================================================================== */
.toast-warning {
  position: fixed;
  top: 24px;
  right: 24px;
  background-color: #fffbeb;
  color: #b45309;
  border: 1px solid #f59e0b;
  padding: 16px 20px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 10000;
  max-width: 420px;
  animation: slide-in-right 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.toast-warning.fade-out {
  animation: slide-out-right 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.toast-warning svg {
  width: 20px;
  height: 20px;
  color: #d97706;
  flex-shrink: 0;
}

.toast-warning-text {
  font-size: 0.875rem;
  font-weight: 500;
}

@keyframes slide-in-right {
  from {
    transform: translateX(120%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slide-out-right {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(120%);
    opacity: 0;
  }
}

/* ==========================================================================
   Language Selector Styles
   ========================================================================== */
.lang-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  background-color: var(--bg-hover);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.lang-btn {
  background: none;
  border: none;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
  transition: var(--transition);
}

.lang-btn:hover {
  color: var(--text-main);
}

.lang-btn.active {
  color: var(--primary);
  background-color: var(--bg-card);
  box-shadow: var(--shadow-sm);
}

.lang-divider {
  font-size: 0.75rem;
  color: var(--text-light);
}

/* ==========================================================================
   Footer Styles
   ========================================================================== */
.app-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--bg-card);
  padding: 14px 24px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  margin-top: 10px;
}

.footer-stats {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

.footer-stats strong {
  color: var(--text-main);
  font-weight: 700;
}

.footer-admin-link {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
}

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

/* ==========================================================================
   Form Card Wrapper (Centering Form inside 1200px container)
   ========================================================================== */
.form-card-wrapper {
  max-width: 800px;
  margin: 0 auto;
  width: 100%;
}
