@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');

/**
 * Esthete Creations - Dashboard Master Stylesheet (Left Sidebar & Poppins Edition)
 *
 * Design constraints:
 * - Font: "Poppins", sans-serif (modern geometric sans-serif)
 * - Dark theme: Deep matte backgrounds (#0A0B0F, #0E0F15, #13141D)
 * - Brand Primary: #EF3C51 (vibrant red/coral)
 * - OVERDUE ALERT RED: #EF3C51 (unmistakable overdue highlighting across total dashboard)
 * - Fixed left sidebar + isolated horizontal scroll only for task board (right side)
 * - Zero full-page overflow
 * - Crisp borders: 1px solid #212332
 */

:root {
  --bg-main: #0a0b0f;
  --bg-sidebar: #0e0f15;
  --bg-card: #13141d;
  --bg-card-hover: #181a25;
  --bg-input: #12131b;
  --bg-pill: #1a1b26;
  --bg-pill-active: #222433;

  --border-subtle: #212332;
  --border-focus: #3a3d52;

  --brand-primary: #ef3c51;
  --brand-primary-hover: #d82f43;
  --brand-primary-subtle: rgba(239, 60, 81, 0.12);
  --brand-primary-border: rgba(239, 60, 81, 0.4);

  --alert-red: #ef3c51;
  --alert-red-bg: rgba(239, 60, 81, 0.12);
  --alert-red-border: #ef3c51;

  --status-todo: #6b7280;
  --status-progress: #3b82f6;
  --status-review: #f59e0b;
  --status-done: #10b981;

  --priority-urgent: #ef3c51;
  --priority-high: #f97316;
  --priority-medium: #3b82f6;
  --priority-low: #6b7280;

  --text-main: #ffffff;
  --text-secondary: #9ea3b5;
  --text-muted: #65697b;
  --text-dark: #12131a;

  --font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-full: 9999px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font-family);
}

html, body {
  height: 100%;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-family);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font-family: var(--font-family);
  font-size: inherit;
  color: inherit;
}

/* ============================================================
   WORDPRESS ADMIN BAR ALIGNMENT FIX
   ============================================================ */
body.admin-bar .esthete-sidebar {
  top: 32px;
  height: calc(100vh - 32px);
}
body.admin-bar .main-topbar {
  top: 32px;
}
@media screen and (max-width: 782px) {
  body.admin-bar .esthete-sidebar {
    top: 46px;
    height: calc(100vh - 46px);
  }
  body.admin-bar .main-topbar {
    top: 46px;
  }
}

/* ============================================================
   GLOBAL INPUT FIELDS & FIXES (Prevent Text Turning Black)
   ============================================================ */
input[type="text"],
input[type="password"],
input[type="email"],
input[type="url"],
input[type="date"],
input[type="datetime-local"],
input[type="search"],
select,
textarea,
.form-control,
.topbar-search-input,
.filter-select {
  color: #ffffff !important;
  background-color: var(--bg-input) !important;
  border: 1px solid var(--border-subtle) !important;
  border-radius: var(--radius-md) !important;
  padding: 12px 16px !important;
  font-size: 13px !important;
  font-family: var(--font-family) !important;
  line-height: 1.5 !important;
  box-sizing: border-box !important;
  -webkit-text-fill-color: #ffffff !important;
  outline: none !important;
  transition: border-color 0.15s ease, background-color 0.15s ease !important;
}

input:focus,
select:focus,
textarea:focus,
.form-control:focus,
.topbar-search-input:focus,
.filter-select:focus {
  color: #ffffff !important;
  background-color: #161723 !important;
  border-color: var(--brand-primary) !important;
  -webkit-text-fill-color: #ffffff !important;
  outline: none !important;
  box-shadow: none !important;
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active,
textarea:-webkit-autofill,
select:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px #12131b inset !important;
  -webkit-text-fill-color: #ffffff !important;
  caret-color: #ffffff !important;
}

::placeholder {
  color: #65697b !important;
  opacity: 1 !important;
}

select option {
  background-color: #12131b !important;
  color: #ffffff !important;
  padding: 8px 12px !important;
}

/* Scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: var(--border-subtle);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* ============================================================
   MAIN APPLICATION LAYOUT (Left Sidebar Architecture)
   ============================================================ */
.esthete-app-layout {
  display: flex;
  min-height: 100vh;
  width: 100vw;
  max-width: 100vw;
  background-color: var(--bg-main);
  overflow-x: hidden;
}

/* ============================================================
   LEFT SIDEBAR (Fixed, Never Shrinks)
   ============================================================ */
.esthete-sidebar {
  width: 260px !important;
  min-width: 260px !important;
  max-width: 260px !important;
  flex: 0 0 260px !important;
  background-color: var(--bg-sidebar);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 100;
}

.sidebar-top {
  padding: 24px 18px;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  padding-left: 6px;
}

.sidebar-logo {
  height: 28px;
  width: auto;
  display: block;
}

.sidebar-badge {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: 2px 7px;
  border-radius: 4px;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sidebar-nav-group-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding: 8px 10px 4px;
  text-transform: uppercase;
}

.sidebar-nav-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
}

.sidebar-nav-item:hover {
  color: var(--text-main);
  background-color: rgba(255, 255, 255, 0.03);
}

.sidebar-nav-item.active {
  color: #ffffff;
  background-color: var(--bg-pill-active);
  font-weight: 600;
  border-color: rgba(255, 255, 255, 0.06);
}

.sidebar-nav-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--text-muted);
  transition: color 0.15s;
}

.sidebar-nav-item.active .sidebar-nav-icon,
.sidebar-nav-item:hover .sidebar-nav-icon {
  color: var(--brand-primary);
}

.sidebar-nav-label {
  flex: 1;
}

.sidebar-nav-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: var(--bg-card);
  color: var(--text-muted);
}

.sidebar-nav-badge.badge-overdue {
  background-color: var(--brand-primary);
  color: #ffffff;
}

/* Sidebar Bottom */
.sidebar-bottom {
  padding: 16px 18px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 12px;
  background-color: var(--bg-sidebar);
}

.sidebar-overdue-alert {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  background-color: var(--alert-red-bg);
  border: 1px solid var(--alert-red-border);
  border-radius: var(--radius-md);
  color: var(--alert-red);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  animation: pulse-border 2s infinite;
}

@keyframes pulse-border {
  0%, 100% { border-color: var(--alert-red); }
  50% { border-color: rgba(239, 60, 81, 0.4); }
}

.overdue-pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--alert-red);
  flex-shrink: 0;
}

.sidebar-user-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
}

.sidebar-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  background-color: var(--bg-main);
  flex-shrink: 0;
}

.sidebar-user-info {
  flex: 1;
  min-width: 0;
}

.sidebar-user-name {
  font-size: 12px;
  font-weight: 600;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-user-role {
  font-size: 10px;
  color: var(--text-muted);
}

.btn-logout {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  transition: color 0.15s;
}

.btn-logout:hover {
  color: var(--brand-primary);
}

/* ============================================================
   MAIN APPLICATION WORKSPACE (Right Side Container)
   ============================================================ */
.esthete-main-wrap {
  flex: 1 1 0%;
  min-width: 0 !important;
  width: calc(100vw - 260px);
  max-width: calc(100vw - 260px);
  display: flex;
  flex-direction: column;
  background-color: var(--bg-main);
  overflow-x: hidden;
}

/* Top Action Header */
.main-topbar {
  height: 68px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  background-color: var(--bg-main);
  gap: 20px;
  position: sticky;
  top: 0;
  z-index: 50;
}

.topbar-search-wrap {
  position: relative;
  width: 380px;
  max-width: 100%;
}

.topbar-search-input {
  width: 100%;
  padding-left: 42px !important;
}

.topbar-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  pointer-events: none;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Buttons */
.btn-primary {
  background-color: var(--brand-primary);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-md);
  padding: 10px 18px;
  font-size: 12px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: background-color 0.15s;
}

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

.btn-secondary {
  background-color: var(--bg-card);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 18px;
  font-size: 12px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}

.btn-secondary:hover {
  border-color: var(--border-focus);
  color: var(--text-main);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 11px;
  border-radius: var(--radius-sm);
}

.btn-danger {
  background-color: var(--alert-red-bg);
  color: var(--alert-red);
  border: 1px solid var(--alert-red-border);
}

.btn-danger:hover {
  background-color: var(--alert-red);
  color: #ffffff;
}

/* ============================================================
   INNER WORKSPACE CONTENT (Airy & Uncongested)
   ============================================================ */
.esthete-content {
  flex: 1;
  padding: 32px 36px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  overflow-x: hidden;
}

.tab-pane {
  display: none;
  width: 100%;
  min-width: 0;
}

.tab-pane.active {
  display: block;
}

/* Section Header */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  gap: 16px;
}

.section-title-wrap {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.section-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.01em;
}

.section-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
}

.section-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ============================================================
   OVERDUE RED ALERT BANNER
   ============================================================ */
.overdue-alert-banner {
  background-color: var(--alert-red-bg);
  border: 1px solid var(--alert-red-border);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.overdue-banner-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.overdue-icon-box {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-md);
  background-color: var(--alert-red);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  flex-shrink: 0;
}

.overdue-banner-text h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--alert-red);
  letter-spacing: 0.02em;
}

.overdue-banner-text p {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
}

/* ============================================================
   METRIC STATS CARDS (Spacious & Clean)
   ============================================================ */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 18px;
  margin-bottom: 32px;
}

.stat-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: border-color 0.15s;
}

.stat-card:hover {
  border-color: var(--border-focus);
}

.stat-card.stat-card-overdue {
  border-color: var(--alert-red);
  background: linear-gradient(180deg, rgba(239, 60, 81, 0.08) 0%, var(--bg-card) 100%);
}

.stat-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.stat-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
}

.stat-icon {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

.stat-card-overdue .stat-icon {
  color: var(--alert-red);
}

.stat-value {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-main);
  line-height: 1.1;
  margin-bottom: 8px;
}

.stat-value.value-red {
  color: var(--alert-red);
}

.stat-footer {
  font-size: 12px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.stat-footer .badge-overdue-tag {
  background-color: var(--alert-red);
  color: #ffffff;
  padding: 2px 7px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 10px;
}

/* ============================================================
   OVERVIEW SPLIT LAYOUT (Active Projects + Action Center)
   ============================================================ */
.overview-split-layout {
  display: grid;
  grid-template-columns: 1.8fr 1.2fr;
  gap: 28px;
}

.projects-list-vertical {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.urgent-tasks-vertical {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ============================================================
   PROJECTS MODULE (Cards & Grid)
   ============================================================ */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 20px;
}

.project-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: border-color 0.15s;
}

.project-card:hover {
  border-color: var(--border-focus);
}

.project-card.project-overdue {
  border-color: var(--alert-red-border);
}

.project-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 14px;
  gap: 12px;
}

.project-client-name {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 3px;
}

.project-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.35;
}

.project-status-pill {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  text-transform: capitalize;
  white-space: nowrap;
}

.status-in_progress {
  background-color: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
}
.status-planning {
  background-color: rgba(107, 114, 128, 0.15);
  color: #9ca3af;
  border: 1px solid rgba(107, 114, 128, 0.3);
}
.status-in_review {
  background-color: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}
.status-completed {
  background-color: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}
.status-on_hold {
  background-color: rgba(156, 163, 175, 0.15);
  color: #d1d5db;
  border: 1px solid rgba(156, 163, 175, 0.3);
}

.project-meta-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.project-meta-item {
  display: flex;
  align-items: center;
  gap: 4px;
}

.meta-overdue {
  color: var(--alert-red);
  font-weight: 700;
}

.project-progress-wrap {
  margin-bottom: 18px;
}

.progress-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 7px;
}

.progress-bar-bg {
  height: 6px;
  background-color: var(--bg-main);
  border-radius: var(--radius-full);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
}

.progress-bar-fill {
  height: 100%;
  background-color: var(--brand-primary);
  border-radius: var(--radius-full);
  transition: width 0.3s ease;
}

.progress-bar-fill.fill-green {
  background-color: var(--status-done);
}

.project-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
  font-size: 12px;
}

.drive-btn-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  font-size: 12px;
  transition: color 0.15s;
}

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

.card-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ============================================================
   TASKS MODULE (Kanban & Notion Table)
   ============================================================ */
.view-toggle-bar {
  display: flex;
  align-items: center;
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 3px;
  gap: 3px;
}

.view-toggle-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.view-toggle-btn.active {
  background-color: var(--bg-pill-active);
  color: var(--text-main);
  font-weight: 600;
}

/* Filters Row */
.filters-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
  background-color: var(--bg-sidebar);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 12px 18px;
}

.filter-select {
  padding: 8px 14px !important;
  font-size: 12px !important;
}

.filter-overdue-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s;
}

.filter-overdue-toggle.active {
  background-color: var(--alert-red-bg);
  border-color: var(--alert-red-border);
  color: var(--alert-red);
  font-weight: 600;
}

/* ============================================================
   KANBAN BOARD (ISOLATED HORIZONTAL SCROLL - RIGHT SIDE ONLY)
   ============================================================ */
#tab-tasks {
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

#kanbanViewContainer {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  padding-bottom: 24px;
  margin-bottom: 20px;
  -webkit-overflow-scrolling: touch;
}

/* Dedicated horizontal scrollbar for Kanban board */
#kanbanViewContainer::-webkit-scrollbar {
  height: 8px;
}
#kanbanViewContainer::-webkit-scrollbar-track {
  background: #0d0e14;
  border-radius: 9999px;
}
#kanbanViewContainer::-webkit-scrollbar-thumb {
  background: #252736;
  border-radius: 9999px;
}
#kanbanViewContainer::-webkit-scrollbar-thumb:hover {
  background: var(--brand-primary);
}

.kanban-board {
  display: flex !important;
  flex-direction: row !important;
  gap: 20px !important;
  align-items: flex-start !important;
  width: max-content !important;
  min-width: 100%;
  padding-right: 16px;
}

.kanban-column {
  width: 310px !important;
  min-width: 310px !important;
  max-width: 310px !important;
  flex: 0 0 310px !important;
  background-color: var(--bg-sidebar);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 16px;
  min-height: 560px;
  display: flex;
  flex-direction: column;
}

.kanban-col-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-subtle);
}

.kanban-col-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-main);
}

.kanban-col-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.dot-todo { background-color: var(--status-todo); }
.dot-progress { background-color: var(--status-progress); }
.dot-review { background-color: var(--status-review); }
.dot-done { background-color: var(--status-done); }

.kanban-count-pill {
  font-size: 11px;
  font-weight: 600;
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 1px 7px;
  border-radius: var(--radius-full);
}

.kanban-tasks-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

/* Kanban Task Card */
.task-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  cursor: grab;
  transition: border-color 0.15s, background-color 0.15s;
}

.task-card:hover {
  border-color: var(--border-focus);
  background-color: var(--bg-card-hover);
}

.task-card.dragging {
  opacity: 0.4;
  cursor: grabbing;
}

/* OVERDUE TASK CARD - RED HIGHLIGHT! */
.task-card.task-overdue {
  border-color: var(--alert-red) !important;
  background-color: rgba(239, 60, 81, 0.06);
}

.task-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 8px;
}

.task-project-tag {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.priority-pill {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
}

.priority-urgent {
  background-color: rgba(239, 60, 81, 0.15);
  color: var(--priority-urgent);
  border: 1px solid rgba(239, 60, 81, 0.4);
}
.priority-high {
  background-color: rgba(249, 115, 22, 0.15);
  color: var(--priority-high);
}
.priority-medium {
  background-color: rgba(59, 130, 246, 0.15);
  color: var(--priority-medium);
}
.priority-low {
  background-color: rgba(107, 114, 128, 0.15);
  color: var(--priority-low);
}

.task-card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.4;
  margin-bottom: 8px;
}

.task-card-desc {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.45;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.task-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid var(--border-subtle);
  gap: 8px;
}

.task-assignee {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--text-secondary);
}

.role-tag {
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  background: var(--bg-main);
  color: var(--text-muted);
  padding: 2px 5px;
  border-radius: 4px;
}

/* OVERDUE DEADLINE BADGE - BRIGHT RED! */
.task-deadline-pill {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.task-deadline-pill.deadline-overdue {
  background-color: var(--alert-red);
  color: #ffffff;
  padding: 2px 7px;
  border-radius: var(--radius-sm);
  font-weight: 700;
}

/* Notion Table View */
.notion-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}

.notion-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 13px;
  min-width: 800px;
}

.notion-table th {
  background-color: var(--bg-sidebar);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.notion-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  vertical-align: middle;
}

.notion-table tr:hover td {
  background-color: var(--bg-card-hover);
}

.notion-table tr.row-overdue td {
  background-color: rgba(239, 60, 81, 0.05);
}

.notion-table tr.row-overdue td:first-child {
  border-left: 3px solid var(--alert-red);
}

.table-task-title {
  color: var(--text-main);
  font-weight: 600;
}

/* ============================================================
   CLIENT DOCUMENTS MODULE
   ============================================================ */
.docs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 20px;
}

.doc-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.doc-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 14px;
}

.doc-client {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.doc-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.35;
  margin-top: 3px;
}

.doc-category-badge {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  background-color: var(--bg-main);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
}

.doc-notes {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 18px;
}

.doc-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
}

.btn-drive-open {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: var(--bg-main);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  padding: 8px 14px;
  border-radius: var(--radius-md);
  font-size: 12px;
  font-weight: 600;
  transition: all 0.15s;
}

.btn-drive-open:hover {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

/* ============================================================
   CREDENTIALS VAULT MODULE (Encrypted)
   ============================================================ */
.vault-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 20px;
}

.vault-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
}

.vault-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 16px;
}

.vault-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
}

.vault-service-type {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  background-color: var(--bg-pill-active);
  color: var(--text-secondary);
  padding: 3px 9px;
  border-radius: var(--radius-sm);
}

.vault-fields {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 18px;
}

.vault-row {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.vault-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.vault-copy-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 9px 12px;
}

.vault-value-text {
  font-family: monospace;
  font-size: 12px;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vault-actions-inline {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-vault-icon {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s;
}

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

.vault-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
  font-size: 11px;
  color: var(--text-muted);
  margin-top: auto;
}

/* ============================================================
   TEAM & ROLES MODULE
   ============================================================ */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.team-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 26px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.team-avatar-lg {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 14px;
  border: 2px solid var(--border-subtle);
}

.team-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.team-role {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--brand-primary);
  background-color: var(--brand-primary-subtle);
  border: 1px solid var(--brand-primary-border);
  padding: 3px 11px;
  border-radius: var(--radius-full);
  margin-bottom: 8px;
}

.team-email {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.team-stats-row {
  display: flex;
  align-items: center;
  justify-content: space-around;
  width: 100%;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
}

.team-stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.team-stat-num {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-main);
}

.team-stat-num.overdue-count {
  color: var(--alert-red);
}

.team-stat-lbl {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
}

/* ============================================================
   MODALS & FORMS
   ============================================================ */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(6, 7, 10, 0.85);
  backdrop-filter: blur(4px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.modal-overlay.active {
  display: flex;
}

.modal-dialog {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 580px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

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

.modal-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
}

.modal-close-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

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

.modal-body {
  padding: 24px 26px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding: 18px 26px;
  border-top: 1px solid var(--border-subtle);
  background-color: var(--bg-sidebar);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

/* ============================================================
   FRONTEND LOGIN SCREEN (Dark & Branded)
   ============================================================ */
.esthete-login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background-color: var(--bg-main);
}

.login-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 38px 34px;
  width: 100%;
  max-width: 420px;
  display: flex;
  flex-direction: column;
}

.login-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 26px;
}

.login-logo {
  height: 38px;
  width: auto;
  margin-bottom: 14px;
}

.login-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-main);
}

.login-subtitle {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.quick-login-box {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quick-login-title {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  text-align: center;
}

.quick-login-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

/* Toast Notice */
.toast-notice {
  position: fixed;
  bottom: 28px;
  right: 28px;
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-main);
  z-index: 2000;
  transform: translateY(100px);
  opacity: 0;
  transition: transform 0.2s, opacity 0.2s;
  pointer-events: none;
}

.toast-notice.show {
  transform: translateY(0);
  opacity: 1;
}

.toast-notice.toast-success {
  border-left: 3px solid var(--status-done);
}

.toast-notice.toast-error {
  border-left: 3px solid var(--alert-red);
}
