:root {
  --primary: #B4572E;
  --primary-hover: #96421F;
  --primary-subtle: rgba(180, 87, 46, 0.08);
  --secondary: #4A6B53;
  --secondary-hover: #37523e;
  --secondary-subtle: rgba(74, 107, 83, 0.10);
  --gold: #D9822B;
  --gold-subtle: rgba(217, 130, 43, 0.12);
  --bg: #FAF8F4;
  --card: #FFFFFF;
  --card-hover: #FDFBF8;
  --border: #E8E4DC;
  --border-strong: #D5CEBF;
  --text: #1E2022;
  --text-muted: #6B665D;
  --text-faint: #9E988D;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, .font-heading {
  font-family: 'Plus Jakarta Sans', sans-serif;
  letter-spacing: -0.02em;
}

/* Custom scrollbars */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: #D8D2C5;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #BDB5A4;
}

/* Drag overlay */
.drag-overlay {
  transition: all 0.2s ease-in-out;
}

/* File card hover & selected */
.file-card {
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  user-select: none;
}
.file-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(30, 32, 34, 0.06);
  border-color: var(--primary);
}
.file-card.selected {
  border-color: var(--primary);
  background-color: var(--primary-subtle);
}

/* Kanban column */
.kanban-col {
  min-height: calc(100vh - 240px);
  background-color: #F4EFEB;
  border-radius: var(--radius-md);
  padding: 14px;
}

/* Kanban task card */
.task-card {
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  cursor: grab;
}
.task-card:active {
  cursor: grabbing;
}
.task-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(30, 32, 34, 0.08);
}

/* Docx Document Page Styling (Clean A4 Paper look) */
.docx-wrapper {
  background: transparent !important;
  padding: 0 !important;
  width: 100% !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
}

.docx-wrapper > section.docx {
  background: #FFFFFF !important;
  box-shadow: 0 4px 25px rgba(30, 32, 34, 0.08) !important;
  border: 1px solid #D5CEBF !important;
  border-radius: 4px !important;
  padding: 48px 56px !important;
  margin: 15px auto 40px auto !important;
  width: 100% !important;
  max-width: 820px !important;
  min-height: 850px !important;
  box-sizing: border-box !important;
  color: #1E2022 !important;
}

.docx-wrapper > section.docx p {
  margin-bottom: 0.8em !important;
  line-height: 1.6 !important;
}

/* Excel preview table */
.excel-table-container {
  overflow-x: auto;
  max-height: 70vh;
}
.excel-table {
  border-collapse: collapse;
  width: 100%;
  font-size: 13px;
  background: white;
}
.excel-table th, .excel-table td {
  border: 1px solid #D5CEBF;
  padding: 8px 12px;
  text-align: left;
}
.excel-table th {
  background-color: #F5F2EB;
  font-weight: 600;
  position: sticky;
  top: 0;
  z-index: 10;
}
.excel-table tr:hover {
  background-color: #FAF8F4;
}

/* Resize Handles */
#preview-resize-left::after, #preview-resize-right::after {
  content: '';
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 40px;
  background-color: #D5CEBF;
  border-radius: 999px;
  opacity: 0.5;
  transition: opacity 0.15s, background-color 0.15s, transform 0.15s;
}
#preview-resize-left::after { left: 4px; }
#preview-resize-right::after { right: 4px; }
#preview-resize-left:hover::after, #preview-resize-right:hover::after {
  background-color: var(--primary);
  opacity: 1;
  transform: translateY(-50%) scaleY(1.2);
}

/* Modal animation */
.modal-enter {
  animation: modalFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.97) translateY(8px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}
