/* Custom Styles for Serene Flow Planner */

:root {
  --primary: #4d6055;
  --on-primary: #ffffff;
  --secondary: #51606f;
  --tertiary: #625772;
  --background: #f8f9fa;
  --surface: #ffffff;
  --surface-variant: #e1e3e4;
  --outline-variant: #c2c8c2;
}

/* Glassmorphism panel styling */
.glass-panel, .glass-card {
  background-color: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: 0px 4px 24px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.3s ease, transform 0.3s ease, border-color 0.3s ease;
}

.glass-card:hover {
  box-shadow: 0px 8px 32px rgba(0, 0, 0, 0.06);
}

/* Ambient Background Glows */
.ambient-glow-1 {
  position: fixed;
  top: -10%;
  left: -10%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, rgba(210, 232, 217, 0.45) 0%, rgba(248, 249, 250, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

.ambient-glow-2 {
  position: fixed;
  bottom: -20%;
  right: -10%;
  width: 60vw;
  height: 60vw;
  background: radial-gradient(circle, rgba(213, 228, 246, 0.4) 0%, rgba(248, 249, 250, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

/* Timeline Custom Connectors */
.timeline-dot {
  position: relative;
}

.timeline-dot::after {
  content: '';
  position: absolute;
  top: 24px;
  bottom: -32px;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  background-color: var(--surface-variant);
  z-index: -1;
}

.timeline-item:last-child .timeline-dot::after {
  display: none;
}

/* Custom Circular Checkbox */
.custom-checkbox {
  appearance: none;
  background-color: transparent;
  margin: 0;
  font: inherit;
  color: currentColor;
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid var(--outline-variant);
  border-radius: 50%;
  display: grid;
  place-content: center;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.custom-checkbox::before {
  content: "";
  width: 0.6rem;
  height: 0.6rem;
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
  transform: scale(0);
  transform-origin: center;
  transition: 120ms transform cubic-bezier(0.4, 0, 0.2, 1);
  background-color: var(--on-primary);
}

.custom-checkbox:checked {
  background-color: var(--primary);
  border-color: var(--primary);
}

.custom-checkbox:checked::before {
  transform: scale(1);
}

/* Task Strike-through Animation */
.task-item {
  transition: opacity 0.25s ease, transform 0.2s ease;
}

.task-item:has(.custom-checkbox:checked) .task-text {
  text-decoration: line-through;
  opacity: 0.45;
  transition: opacity 0.25s ease;
}

/* Scrollbars Clean styling */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}

.no-scrollbar {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #d9dadb;
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: #c2c8c2;
}

/* SideNavBar Transitions */
aside {
  transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), 
              width 0.4s cubic-bezier(0.25, 1, 0.5, 1),
              opacity 0.3s ease;
}

/* Main Content Area adjustments on Sidebar Collapse */
main, header {
  transition: margin-left 0.4s cubic-bezier(0.25, 1, 0.5, 1),
              padding-left 0.4s cubic-bezier(0.25, 1, 0.5, 1),
              width 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Floating Action Button for Collapsed Sidebar */
.float-expand-btn {
  position: fixed;
  left: 1rem;
  top: 1.5rem;
  z-index: 100;
  opacity: 0;
  transform: translateX(-20px) scale(0.9);
  transition: opacity 0.3s cubic-bezier(0.25, 1, 0.5, 1),
              transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  pointer-events: none;
}

.float-expand-btn.visible {
  opacity: 1;
  transform: translateX(0) scale(1);
  pointer-events: auto;
}

/* Hover micro-animations */
.button-hover-micro {
  transition: transform 0.15s cubic-bezier(0.25, 1, 0.5, 1), filter 0.15s ease;
}
.button-hover-micro:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}
.button-hover-micro:active {
  transform: translateY(1px);
}

/* User Profile Custom Avatar Overlay */
#userAvatarContainer {
  cursor: pointer;
  position: relative;
}

#userAvatarContainer::after {
  content: "Subir";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(77, 96, 85, 0.85); /* sage brand color */
  color: #ffffff;
  font-size: 8px;
  font-weight: 600;
  text-transform: uppercase;
  text-align: center;
  padding: 1px 0;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

#userAvatarContainer:hover::after {
  opacity: 1;
}

/* Task Cards by Category (Weekly View) */
.task-card-primary {
  background-color: rgba(210, 232, 217, 0.35); /* Sage */
  border: 1px solid rgba(77, 96, 85, 0.15);
  border-left: 4px solid #4d6055;
}
.task-card-primary:hover {
  background-color: rgba(210, 232, 217, 0.5);
  border-color: rgba(77, 96, 85, 0.25);
}

.task-card-secondary {
  background-color: rgba(213, 228, 246, 0.35); /* Dusty Blue */
  border: 1px solid rgba(81, 96, 111, 0.15);
  border-left: 4px solid #51606f;
}
.task-card-secondary:hover {
  background-color: rgba(213, 228, 246, 0.5);
  border-color: rgba(81, 96, 111, 0.25);
}

.task-card-tertiary {
  background-color: rgba(235, 221, 253, 0.3); /* Lavender */
  border: 1px solid rgba(98, 87, 114, 0.15);
  border-left: 4px solid #625772;
}
.task-card-tertiary:hover {
  background-color: rgba(235, 221, 253, 0.45);
  border-color: rgba(98, 87, 114, 0.25);
}

/* Opacity reduction for completed task cards */
.task-item:has(.custom-checkbox:checked) {
  opacity: 0.55;
}

.task-item {
  display: flex;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  min-width: 0;
}

.task-text {
  flex: 1;
  min-width: 0;
  word-break: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
}


/* Business Sections Navigation Tabs */
.business-tab-btn {
  position: relative;
  transition: color 0.2s ease;
}

.business-tab-btn::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--primary);
  transform: scaleX(0);
  transform-origin: bottom right;
  transition: transform 0.25s ease-out;
}

.business-tab-btn.active {
  color: var(--primary);
  font-weight: 600;
}

.business-tab-btn.active::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

/* CRM and Kanban Board Layouts */
.crm-table th {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--secondary);
  border-bottom: 2px solid rgba(225, 227, 228, 0.6);
  padding: 12px 16px;
  text-align: left;
}

.crm-table td {
  padding: 14px 16px;
  font-size: 13px;
  border-bottom: 1px solid rgba(225, 227, 228, 0.4);
}

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

.kanban-col {
  background: rgba(243, 244, 245, 0.45);
  border: 1px solid rgba(225, 227, 228, 0.5);
  border-radius: 1.25rem;
}

.deal-card {
  background: #ffffff;
  border: 1px solid rgba(225, 227, 228, 0.6);
  box-shadow: 0px 2px 8px rgba(0, 0, 0, 0.02);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.deal-card:hover {
  transform: translateY(-2px);
  box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.04);
  border-color: rgba(77, 96, 85, 0.25);
}

/* Premium Segmented Tab Controls */
.segmented-control {
  background-color: rgba(237, 238, 239, 0.65);
  border: 1px solid rgba(225, 227, 228, 0.4);
  padding: 4px;
  border-radius: 1rem;
  display: inline-flex;
  gap: 4px;
}

.segmented-tab-btn {
  padding: 8px 20px;
  font-size: 13px;
  font-weight: 500;
  color: var(--secondary);
  border-radius: 0.75rem;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.segmented-tab-btn:hover {
  color: var(--primary);
}

.segmented-tab-btn.active {
  background-color: #ffffff;
  color: var(--primary);
  font-weight: 600;
  box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.04);
}

/* Contract Type Badges */
.badge-mensual {
  background-color: rgba(213, 228, 246, 0.55); /* Dusty Blue */
  color: #3a4857;
}

.badge-proyecto {
  background-color: rgba(235, 221, 253, 0.55); /* Lavender */
  color: #4c425c;
}



