/* Custom FullCalendar Overrides for LexPro Design System */
/* Minimal, clean calendar inspired by Anthropic/Claude aesthetic */

/* Calendar Container */
.fc {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--ink, #1A1A1A);
}

/* Toolbar */
.fc .fc-toolbar {
  margin-bottom: 1.5rem;
  padding: 0;
}

.fc .fc-toolbar-title {
  font-family: 'Libre Baskerville', 'Fraunces', serif;
  font-size: 1.875rem;
  font-weight: 400;
  color: var(--ink, #1A1A1A);
  letter-spacing: -0.025em;
}

@media (min-width: 768px) {
  .fc .fc-toolbar-title {
    font-size: 2.25rem;
  }
}

/* Buttons */
.fc .fc-button {
  background-color: var(--ink, #1A1A1A);
  border-color: var(--ink, #1A1A1A);
  color: white;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.375rem;
  transition: all 0.2s;
}

.fc .fc-button:hover {
  background-color: rgba(26, 26, 26, 0.9);
}

.fc .fc-button:disabled {
  opacity: 0.5;
}

.fc .fc-button-primary:not(:disabled).fc-button-active {
  background-color: var(--ink, #1A1A1A);
}

/* Calendar Grid */
.fc .fc-daygrid-day {
  background-color: white;
  border-color: rgba(232, 228, 221, 0.2);
}

.fc .fc-daygrid-day:hover {
  background-color: rgba(245, 242, 237, 0.3);
}

.fc .fc-daygrid-day.fc-day-today {
  background-color: rgba(245, 158, 11, 0.05);
}

/* Day Headers */
.fc .fc-col-header-cell {
  padding: 0.75rem 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(102, 102, 102, 0.6);
  border-color: rgba(232, 228, 221, 0.2);
}

/* Day Numbers */
.fc .fc-daygrid-day-number {
  padding: 0.5rem;
  font-size: 0.875rem;
  font-weight: 300;
  color: var(--ink, #1A1A1A);
}

.fc .fc-daygrid-day.fc-day-today .fc-daygrid-day-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  background-color: var(--ink, #1A1A1A);
  color: white;
  border-radius: 50%;
  font-weight: 500;
}

/* Events */
.fc .fc-event {
  border: none;
  border-left: 2px solid currentColor;
  border-radius: 0.25rem;
  padding: 0.25rem 0.5rem;
  margin-bottom: 0.125rem;
  font-size: 0.75rem;
  font-weight: 400;
  cursor: pointer;
  transition: all 0.2s;
}

.fc .fc-event:hover {
  opacity: 0.85;
  transform: translateY(-1px);
}

.fc .fc-event-time {
  font-size: 0.625rem;
  font-weight: 300;
  opacity: 0.7;
}

.fc .fc-event-title {
  font-weight: 400;
}

/* Time Grid (Week/Day views) */
.fc .fc-timegrid-slot {
  height: 3rem;
  border-color: rgba(232, 228, 221, 0.15);
}

.fc .fc-timegrid-slot-label {
  font-size: 0.75rem;
  color: rgba(102, 102, 102, 0.6);
}

/* Scrollbar for time grid */
.fc-scroller::-webkit-scrollbar {
  width: 8px;
}

.fc-scroller::-webkit-scrollbar-track {
  background: rgba(232, 228, 221, 0.1);
  border-radius: 4px;
}

.fc-scroller::-webkit-scrollbar-thumb {
  background: rgba(232, 228, 221, 0.3);
  border-radius: 4px;
}

.fc-scroller::-webkit-scrollbar-thumb:hover {
  background: rgba(232, 228, 221, 0.5);
}

/* Loading State */
.fc .fc-h-event .fc-event-main {
  color: inherit;
}

/* Responsive */
@media (max-width: 768px) {
  .fc .fc-toolbar {
    flex-direction: column;
    gap: 1rem;
  }

  .fc .fc-toolbar-title {
    font-size: 1.5rem;
  }

  .fc .fc-button {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
  }

  .fc .fc-event {
    font-size: 0.625rem;
    padding: 0.125rem 0.25rem;
  }
}

.fc-theme-standard .fc-scrollgrid {
  border: 1px solid rgba(232, 228, 221, 0.3);
}

.fc-theme-standard td,
.fc-theme-standard th {
  border: 1px solid rgba(232, 228, 221, 0.2);
}

/* Header styling */
.fc .fc-toolbar {
  margin-bottom: 1.5rem;
  gap: 1rem;
}

.fc .fc-toolbar-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: #1A1A1A;
  font-family: 'Libre Baskerville', serif;
}

.fc .fc-toolbar-chunk {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.fc .fc-button-primary {
  background-color: #1A1A1A;
  border: 1px solid #1A1A1A;
  color: white;
  font-size: 0.875rem;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-weight: 500;
  transition: all 0.2s;
  text-transform: capitalize;
}

.fc .fc-button-primary:hover {
  background-color: rgba(26, 26, 26, 0.9);
  border-color: rgba(26, 26, 26, 0.9);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.fc .fc-button-primary:not(:disabled).fc-button-active,
.fc .fc-button-primary:not(:disabled):active {
  background-color: #1A1A1A;
  border-color: #1A1A1A;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.fc .fc-button-primary:disabled {
  background-color: rgba(26, 26, 26, 0.3);
  border-color: rgba(26, 26, 26, 0.3);
  cursor: not-allowed;
}

.fc .fc-button-primary:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
}

/* Button group spacing */
.fc .fc-button-group {
  display: inline-flex;
  gap: 0.25rem;
}

.fc .fc-button-group > .fc-button {
  margin: 0;
}

.fc .fc-button-group > .fc-button:first-child {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.fc .fc-button-group > .fc-button:last-child {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.fc .fc-button-group > .fc-button:not(:first-child):not(:last-child) {
  border-radius: 0;
}

/* Day headers */
.fc-col-header-cell {
  background-color: #F5F2ED;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: rgba(102, 102, 102, 0.8);
  padding: 0.75rem 0.5rem;
}

/* Day cells */
.fc .fc-daygrid-day-top {
  padding: 0.5rem;
}

.fc .fc-daygrid-day-number {
  color: #1A1A1A;
  font-weight: 500;
  padding: 0.25rem 0.5rem;
}

.fc .fc-day-today {
  background-color: rgba(245, 242, 237, 0.5) !important;
}

.fc .fc-day-today .fc-daygrid-day-number {
  background-color: #1A1A1A;
  color: white;
  border-radius: 50%;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

/* Events */
.fc-event {
  border-radius: 0.375rem;
  padding: 0.25rem 0.5rem;
  margin: 0.125rem 0;
  border: none;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s;
}

.fc-event:hover {
  opacity: 0.85;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.fc-event-title {
  font-weight: 500;
}

.fc-event-time {
  font-weight: 400;
  font-size: 0.75rem;
}

/* Time grid specific styles */
.fc-timegrid-slot {
  height: 3rem;
}

.fc-timegrid-slot-label {
  font-size: 0.75rem;
  color: rgba(102, 102, 102, 0.7);
  font-weight: 500;
}

.fc-timegrid-event {
  border-radius: 0.375rem;
  padding: 0.25rem 0.5rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .fc .fc-toolbar {
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1rem;
  }

  .fc .fc-toolbar-chunk {
    display: flex;
    justify-content: center;
    width: 100%;
  }

  .fc .fc-toolbar-title {
    font-size: 1.25rem;
    text-align: center;
  }

  .fc .fc-button-primary {
    font-size: 0.75rem;
    padding: 0.375rem 0.75rem;
  }

  /* Make view buttons more compact on mobile */
  .fc .fc-button-group {
    gap: 0.125rem;
  }

  /* Ensure today button is visible */
  .fc .fc-toolbar-chunk:first-child {
    order: 2;
  }

  .fc .fc-toolbar-chunk:nth-child(2) {
    order: 1;
  }

  .fc .fc-toolbar-chunk:last-child {
    order: 3;
  }
}

/* Loading state */
.fc .fc-loading {
  background-color: rgba(245, 242, 237, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* More link */
.fc .fc-more-link {
  color: #1A1A1A;
  font-weight: 500;
  font-size: 0.75rem;
  padding: 0.125rem 0.25rem;
  border-radius: 0.25rem;
  transition: background-color 0.2s;
}

.fc .fc-more-link:hover {
  background-color: rgba(245, 242, 237, 0.8);
  text-decoration: none;
}

/* Popover for more events */
.fc .fc-popover {
  border-radius: 0.75rem;
  border: 1px solid rgba(232, 228, 221, 0.3);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.fc .fc-popover-header {
  background-color: #F5F2ED;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem 0.75rem 0 0;
  font-weight: 600;
  color: #1A1A1A;
}

.fc .fc-popover-body {
  padding: 0.5rem;
}
