/* Modern Theme CSS */
:root {
  --primary-color: #6366f1;
  --primary-dark: #4f46e5;
  --secondary-color: #f1f5f9;
  --accent-color: #06b6d4;
  --success-color: #10b981;
  --warning-color: #f59e0b;
  --danger-color: #ef4444;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --text-light: #94a3b8;
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-tertiary: #e2e8f0;
  --border-color: #e2e8f0;
  --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-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
}

* {
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  margin: 0;
  padding: 20px;
  min-height: 100vh;
  color: var(--text-primary);
  line-height: 1.6;
}

/* Theme Toggle Styles */
.theme-toggle-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 15px;
}

.theme-toggle {
  display: inline-block;
  position: relative;
  cursor: pointer;
}

.theme-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: relative;
  display: inline-block;
  min-width: 230px;
  height: 40px;
  background: var(--bg-primary);
  border-radius: var(--radius-xl);
  transition: all 0.3s ease;
  box-shadow: var(--shadow-md);
  border: 2px solid var(--border-color);
}

.slider:before {
  position: absolute;
  content: "";
  height: 32px;
  min-width: 99px;
  left: 2px;
  top: 2px;
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  transition: all 0.3s ease;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

input:checked + .slider:before {
  transform: translateX(125%);
  background: linear-gradient(135deg, var(--accent-color), #0891b2);
}

.slider-text {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  font-weight: 500;
  transition: all 0.3s ease;
  pointer-events: none;
}

.slider-text.classic {
  left: 8px;
  color: var(--bg-primary);
}

.slider-text.modern {
  right: 8px;
  color: var(--text-secondary);
}

input:checked + .slider .slider-text.classic {
  color: var(--text-secondary);
}

input:checked + .slider .slider-text.modern {
  color: var(--bg-primary);
}

/* Calendar Styles */
.calendar-container {
  max-width: 1200px;
  margin: 0 auto;
  background: var(--bg-primary);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  backdrop-filter: blur(10px);
  width: 100%;
  box-sizing: border-box;
}

#calendar {
  width: 100%;
  font-family: inherit;
}

.calendar-header {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: white;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.calendar-header h2 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
  flex: 1;
  text-align: center;
}

.nav-btn {
  background: rgba(255, 255, 255, 0.2) !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  border-radius: var(--radius-md) !important;
  color: white !important;
  font-weight: 500 !important;
  font-size: 1.5rem !important;
  width: 40px !important;
  height: 40px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
}

.nav-btn:hover {
  background: rgba(255, 255, 255, 0.3) !important;
  transform: translateY(-1px);
}

.header-buttons {
  display: flex;
  gap: 10px;
}

.today-btn, .logout-btn {
  background: rgba(255, 255, 255, 0.2) !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  border-radius: var(--radius-md) !important;
  color: white !important;
  font-weight: 500 !important;
  padding: 8px 16px !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
}

.today-btn:hover, .logout-btn:hover {
  background: rgba(255, 255, 255, 0.3) !important;
  transform: translateY(-1px);
}

.logout-btn {
  background: linear-gradient(135deg, #dc3545, #c82333) !important;
  border: 1px solid rgba(220, 53, 69, 0.3) !important;
}

.logout-btn:hover {
  background: linear-gradient(135deg, #c82333, #a71e2a) !important;
}

.calendar-grid {
  padding: 20px;
}

.weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
  margin-bottom: 10px;
}

.weekday {
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-weight: 600;
  text-align: center;
  padding: 12px 8px;
  border-radius: var(--radius-sm);
}

.days-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}

.day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 1px solid var(--border-color);
  min-height: 60px;
}

.day.empty {
  cursor: default;
  border: none;
}

.day.has-data {
  background: linear-gradient(135deg, var(--success-color), #059669);
  color: white;
  font-weight: 600;
}

.day.no-data {
  background: linear-gradient(135deg, var(--bg-tertiary), #cbd5e1);
  color: var(--text-secondary);
}

.day.today {
  border: 3px solid var(--warning-color) !important;
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.3);
  font-weight: 700;
}

.day.today.has-data {
  background: linear-gradient(135deg, var(--success-color), #059669);
  color: white;
}

.day.today.no-data {
  background: linear-gradient(135deg, var(--warning-color), #d97706);
  color: white;
}

.day:hover:not(.empty) {
  transform: scale(1.05);
  box-shadow: var(--shadow-md);
  z-index: 1;
}

.day.has-data:hover {
  background: linear-gradient(135deg, #059669, #047857);
}

.day.no-data:hover {
  background: linear-gradient(135deg, #cbd5e1, #94a3b8);
}

/* Responsive design */
@media (max-width: 768px) {
  .calendar-header {
    flex-direction: column;
    gap: 15px;
  }
  
  .calendar-header h2 {
    order: -1;
  }
  
  .header-buttons {
    order: 1;
  }
  
  .nav-btn {
    width: 35px !important;
    height: 35px !important;
    font-size: 1.2rem !important;
  }
  
  .day {
    min-height: 50px;
    font-size: 14px;
  }
  
  .weekday {
    padding: 8px 4px;
    font-size: 14px;
  }
}

/* Button Styles */
button {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
  font-family: inherit;
  min-width: 3rem;
  margin: 0.5rem !important;
}

button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

button:active {
  transform: translateY(0);
}

#home-button {
  background: linear-gradient(135deg, var(--text-secondary), var(--text-light));
}

#pie_chart_button {
  background: linear-gradient(135deg, var(--accent-color), #0891b2);
}

#continue-button {
  background: linear-gradient(135deg, var(--danger-color), #dc2626) !important;
  margin: 10px auto 0px !important;
  display: block;
}

/* Container Styles */
.container {
  display: flex;
  gap: 20px;
  max-width: 1400px;
  margin: 150px auto 0;
}

.left, .right {
  background: var(--bg-primary);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 20px;
}

.left {
  flex: 1;
  min-width: 300px;
}

.right {
  flex: 2;
  min-width: 400px;
}

/* Block Styles */
.block {
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  margin-bottom: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
}

.block .header {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: white;
  padding: 15px 20px;
  margin: 0;
}

.block .header h3 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
}

.block ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.block li {
  padding: 12px 20px;
  border-bottom: 1px solid var(--border-color);
  transition: all 0.3s ease;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
}

.block li:hover {
  background: var(--bg-primary);
  transform: translateX(5px);
}

.block li:last-child {
  border-bottom: none;
}

.block li span {
  flex: 1;
}

/* Input Styles */
input[type="text"], input[type="time"] {
  background: var(--bg-primary);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 10px 15px;
  font-family: inherit;
  font-size: 14px;
  transition: all 0.3s ease;
  color: var(--text-primary);
}

input[type="text"]:focus, input[type="time"]:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* Table Styles */
#table_header {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: white;
  padding: 20px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  margin-bottom: 0;
}

#table_header p {
  font-size: 1.3rem;
  font-weight: 600;
  margin: 0 0 15px 0;
}

#time_add {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

#time_add label {
  font-weight: 500;
  font-size: 14px;
}

#time_add input {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: var(--text-primary);
}

#time_add button {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

#time_add button:hover {
  background: rgba(255, 255, 255, 0.3);
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-primary);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  overflow: hidden;
}

table td {
  padding: 8px 15px;
  border-bottom: 1px solid var(--border-color);
  font-size: 14px;
  transition: all 0.3s ease;
}

table td:first-child {
  background: var(--bg-secondary);
  font-weight: 600;
  color: var(--text-secondary);
  width: 80px;
  text-align: center;
}

table tr:hover td {
  background: var(--bg-secondary);
}

/* Time Overlay Styles */
#time_overlay_holder {
  position: relative;
}

#time_overlay {
  position: absolute;
  border-radius: var(--radius-md);
  border: 2px solid rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(5px);
  color: white;
  font-weight: 600;
  padding: 8px;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
}

#time_overlay:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

#time_delete_button {
  background: var(--danger-color);
  color: white;
  border: none;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  font-size: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: 8px;
  transition: all 0.3s ease;
}

#time_delete_button:hover {
  background: #dc2626;
  transform: scale(1.1);
}

/* Pie Chart Overlay */
#pie_chart_overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

#pie_chart_container {
  background: var(--bg-primary);
  border-radius: var(--radius-xl);
  padding: 30px;
  box-shadow: var(--shadow-xl);
  max-width: 90vw;
  max-height: 90vh;
  position: absolute;
  top: 150px;
}

#close_pie_chart_button {
  background: linear-gradient(135deg, var(--text-secondary), var(--text-light));
  margin-top: 20px;
  width: 100%;
}

/* Responsive Design */
@media (max-width: 768px) {
  .container {
    flex-direction: column;
  }
  
  .left, .right {
    min-width: auto;
  }
  
  header {
    flex-direction: column;
    text-align: center;
  }
  
  #time_add {
    flex-direction: column;
    align-items: stretch;
  }
  
  .theme-toggle-container {
    position: fixed;
    bottom: 10px;
    right: 10px;
    z-index: 1000;
  }
  
  .slider {
    width: 100px;
    height: 35px;
  }
  
  .slider:before {
    width: 46px;
    height: 27px;
  }
  
  input:checked + .slider:before {
    transform: translateX(46px);
  }
}

/* Checkbox Styles */
input[type="checkbox"] {
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: var(--bg-primary);
  cursor: pointer;
  position: relative;
  transition: all 0.3s ease;
}

input[type="checkbox"]:checked {
  background: linear-gradient(135deg, var(--success-color), #059669);
  border-color: var(--success-color);
}

input[type="checkbox"]:checked::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 12px;
  font-weight: bold;
}

/* Appearing message styles */
#appearing {
  background: var(--bg-primary);
  border: 2px solid var(--danger-color);
  border-radius: var(--radius-md);
  padding: 15px;
  box-shadow: var(--shadow-md);
}

#messageSave {
  color: var(--danger-color) !important;
  font-weight: 600;
  margin: 0 0 10px 0;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideIn {
  from { transform: translateX(-100%); }
  to { transform: translateX(0); }
}

.block, .calendar-container, header {
  animation: fadeIn 0.6s ease-out;
}

.block li {
  animation: slideIn 0.4s ease-out;
}

/* Logout button positioning */
.logout-button {
  background: linear-gradient(135deg, #dc3545, #c82333);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 25px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
  transition: all 0.3s ease;
}

.logout-button:hover {
  background: linear-gradient(135deg, #c82333, #a71e2a);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(220, 53, 69, 0.4);
}

.logout-button:active {
  transform: translateY(0);
}

.fc-view-harness {
  width: 100% !important;
  overflow: hidden !important;
}

.fc-scrollgrid {
  width: 100% !important;
  max-width: 100% !important;
  table-layout: auto !important;
}

.fc-scrollgrid-sync-table {
  width: 100% !important;
  max-width: 100% !important;
}

/* Header Styles for Day View */
header {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: white;
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--shadow-lg);
  margin-top: 30px !important;
  position: fixed;
  top: 0px;
  left: 5%;
  z-index: 9999;
  width: 88%;
  margin: auto;
  border-radius: var(--radius-lg);
}

.header-title {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}

.header-title h1, .header-title h2 {
  margin: 0;
  color: white;
}

.header-title h1 {
  font-size: 1.5rem;
  font-weight: 600;
}

.header-title h2 {
  font-size: 1.2rem;
  font-weight: 400;
  opacity: 0.9;
}

.header-buttons {
  display: flex;
  gap: 10px;
  align-items: center;
}

header button {
  background: rgba(255, 255, 255, 0.2) !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  border-radius: var(--radius-md) !important;
  color: white !important;
  font-weight: 500 !important;
  padding: 10px 20px !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
  font-size: 1rem !important;
}

header button:hover {
  background: rgba(255, 255, 255, 0.3) !important;
  transform: translateY(-1px);
}

header .logout-button {
  background: linear-gradient(135deg, #dc3545, #c82333) !important;
  border: 1px solid rgba(220, 53, 69, 0.3) !important;
}

header .logout-button:hover {
  background: linear-gradient(135deg, #c82333, #a71e2a) !important;
}

#appearing {
  display: flex;
  align-items: center;
  background: var(--bg-primary);
  border: 2px solid var(--danger-color);
  border-radius: var(--radius-md);
  padding: 15px;
  box-shadow: var(--shadow-md);
}

#messageSave {
  color: var(--danger-color) !important;
  font-weight: 600;
  margin: 0 10px 0 0;
}

/* Calendar Modal Styles */
.calendar-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  animation: fadeIn 0.3s ease-out;
}

.calendar-modal.show {
  display: flex;
}

.calendar-modal-content {
  background: var(--bg-primary);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  max-width: 90vw;
  max-height: 90vh;
  width: 600px;
  overflow: hidden;
  animation: slideIn 0.3s ease-out;
}

.calendar-modal-header {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: white;
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.calendar-modal-header h3 {
  margin: 0;
  font-size: 1.3rem;
  font-weight: 600;
}

.calendar-modal-close {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  width: 35px;
  min-width: 35px;
  height: 35px;
  padding: 0;
  color: white;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.calendar-modal-close:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: scale(1.1);
}

.calendar-modal-body {
  padding: 20px;
  max-height: 70vh;
  overflow-y: auto;
}

.modal-content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
}

/* Mini Calendar Styles */
.mini-calendar {
  /* margin-bottom removed for grid layout */
}

.mini-calendar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.mini-calendar-nav {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-weight: 500;
  padding: 8px 12px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.mini-calendar-nav:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-1px);
}

.mini-calendar-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.mini-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  margin-bottom: 10px;
}

.mini-calendar-weekday {
  background: var(--bg-secondary);
  color: var(--text-secondary);
  font-weight: 600;
  text-align: center;
  padding: 8px 4px;
  border-radius: var(--radius-sm);
  font-size: 12px;
}

.mini-calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}

.mini-calendar-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 1px solid var(--border-color);
  min-height: 35px;
  font-size: 14px;
  position: relative;
}

.mini-calendar-day.empty {
  cursor: default;
  border: none;
  background: transparent;
}

.mini-calendar-day.today {
  border: 2px solid var(--warning-color) !important;
  font-weight: 700;
}

.mini-calendar-day:hover:not(.empty) {
  transform: scale(1.1);
  box-shadow: var(--shadow-md);
  z-index: 1;
}

.mini-calendar-day.colored {
  color: white;
  font-weight: 600;
}

.mini-calendar-day.colored:hover {
  opacity: 0.8;
}

/* Color Legend Styles */
.color-legend {
  /* border-top removed for side-by-side layout */
  padding-top: 0;
}

.color-legend-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.color-legend-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.add-color-btn {
  background: linear-gradient(135deg, var(--success-color), #059669);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  padding: 8px 16px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
}

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

.color-legend-items {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.color-legend-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.color-legend-item:hover {
  background: var(--bg-primary);
  transform: translateX(5px);
}

.color-legend-swatch {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  flex-shrink: 0;
}

.color-legend-description {
  flex: 1;
  font-size: 14px;
  color: var(--text-primary);
}

.color-legend-actions {
  display: flex;
  gap: 5px;
}

.color-legend-edit,
.color-legend-delete {
  background: none;
  border: none;
  border-radius: var(--radius-sm);
  width: 25px;
  height: 25px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  font-size: 12px;
}

.color-legend-edit {
  color: var(--primary-color);
}

.color-legend-edit:hover {
  background: var(--primary-color);
  color: white;
}

.color-legend-delete {
  color: var(--danger-color);
}

.color-legend-delete:hover {
  background: var(--danger-color);
  color: white;
}

/* Add Color Form */
.add-color-form {
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 15px;
  margin-top: 15px;
  border: 1px solid var(--border-color);
  display: none;
}

.add-color-form.show {
  display: block;
  animation: slideIn 0.3s ease-out;
  margin-bottom: 10px;
}

.add-color-form-group {
  display: flex;
  gap: 10px;
  align-items: end;
}

.add-color-form-group label {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.add-color-form-group input {
  background: var(--bg-primary);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-family: inherit;
  font-size: 14px;
  transition: all 0.3s ease;
  color: var(--text-primary);
  height: 45px;
}

.add-color-form-group input:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.color-preview {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border-color);
  background: var(--bg-primary);
  display: none;
}

.add-color-form-actions {
  display: flex;
  gap: 10px;
  margin-top: 15px;
}

.add-color-form-actions button {
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  border: none;
}

.add-color-save {
  background: linear-gradient(135deg, var(--success-color), #059669);
  color: white;
}

.add-color-save:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.add-color-cancel {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
}

.add-color-cancel:hover {
  background: var(--text-secondary);
  color: white;
}

/* Calendar Button */
.calendar-toggle-btn {
  position: fixed;
  bottom: 80px;
  right: 20px;
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  color: white;
  border: none;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  font-size: 24px;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  transition: all 0.3s ease;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.calendar-toggle-btn:hover {
  transform: translateY(-3px) scale(1.1);
  box-shadow: var(--shadow-xl);
}

.calendar-toggle-btn:active {
  transform: translateY(-1px) scale(1.05);
}

/* Responsive Design for Modal */
@media (max-width: 768px) {
  .calendar-modal-content {
    width: 95vw;
    max-height: 95vh;
  }
  
  .calendar-modal-body {
    padding: 15px;
  }
  
  .modal-content-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .mini-calendar-day {
    min-height: 30px;
    font-size: 12px;
  }
  
  .color-legend-item {
    padding: 8px;
  }
  
  .add-color-form-group {
    flex-direction: column;
    align-items: stretch;
  }
  
  .calendar-toggle-btn {
    bottom: 70px;
    right: 15px;
    width: 50px;
    height: 50px;
    font-size: 20px;
  }
} 