/* ==========================================================================
   Planning Alésia 7 Design system moderne
   ========================================================================== */

:root {
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --indigo-50: #eef0ff;
  --indigo-100: #e0e3ff;
  --indigo-400: #7C7FF2;
  --indigo-500: #4F46E5;
  --indigo-600: #4338CA;
  --indigo-700: #3730A3;

  --green-500: #10B981;
  --amber-500: #F59E0B;
  --red-500: #EF4444;
  --sky-500: #0EA5E9;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;

  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .06);
  --shadow-md: 0 4px 12px rgba(16, 24, 40, .08);
  --shadow-lg: 0 12px 32px rgba(16, 24, 40, .14);
  --shadow-focus: 0 0 0 3px rgba(79, 70, 229, .22);

  --ease: cubic-bezier(.4, 0, .2, 1);

  /* Light theme */
  --bg: #F5F6FB;
  --bg-rgb: 245, 246, 251;
  --surface: #FFFFFF;
  --surface-alt: #FAFBFF;
  --border: #E6E8F0;
  --border-strong: #D6D9E6;
  --text: #171A2B;
  --text-muted: #6B7089;
  --text-faint: #9498AD;
  --sidebar-bg: #14163A;
  --sidebar-text: #C7C9E6;
  --sidebar-text-active: #FFFFFF;
  --sidebar-hover: rgba(255, 255, 255, .06);
  --sidebar-active-bg: linear-gradient(135deg, var(--indigo-500), var(--indigo-600));
}

[data-theme="dark"] {
  --bg: #0B0D1A;
  --bg-rgb: 11, 13, 26;
  --surface: #14172B;
  --surface-alt: #191C33;
  --border: #262A47;
  --border-strong: #333861;
  --text: #EDEEFB;
  --text-muted: #9A9EC2;
  --text-faint: #6C7096;
  --sidebar-bg: #0A0B1C;
  --sidebar-text: #A9ADD6;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow-md: 0 4px 14px rgba(0, 0, 0, .35);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, .5);
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  transition: background .2s var(--ease), color .2s var(--ease);
  position: relative;
}

/* Image de fond décorative visible derrière les cartes/panneaux (qui restent opaques),
   avec une teinte qui s'adapte automatiquement au thème clair/sombre. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image: url('../assets/icons/hero.png');
  background-size: 500px auto;
  background-position: center 75%;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background: rgba(var(--bg-rgb), .88);
  transition: background .2s var(--ease);
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-weight: 700;
  letter-spacing: -.01em;
}

p {
  margin: 0;
}

button {
  font-family: inherit;
}

input,
select,
textarea {
  font-family: inherit;
}

::selection {
  background: var(--indigo-100);
  color: var(--indigo-700);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  background: var(--indigo-500);
  color: #fff;
  padding: 10px 16px;
  border-radius: 0 0 8px 0;
}

.skip-link:focus {
  left: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============ App shell ============ */
.app-shell {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 260px;
  flex-shrink: 0;
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  padding: 20px 16px;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 40;
}

.sidebar__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px 24px;
  color: #fff;
}

.sidebar__logo {
  width: 50px;
  height: 50px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;

  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.sidebar__logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.sidebar__brand-name {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -.01em;
}

.sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: var(--radius-md);
  background: transparent;
  border: none;
  color: var(--sidebar-text);
  font-size: 14.5px;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: background .15s var(--ease), color .15s var(--ease), transform .1s var(--ease);
}

.nav-item:hover {
  background: var(--sidebar-hover);
  color: #fff;
}

.nav-item:active {
  transform: scale(.98);
}

.nav-item__icon {
  display: flex;
  opacity: .85;
}

.nav-item--active {
  background: var(--sidebar-active-bg);
  color: var(--sidebar-text-active);
  box-shadow: var(--shadow-md);
}

.nav-item--active .nav-item__icon {
  opacity: 1;
}

.sidebar__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 10px 4px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  margin-top: 8px;
}

.sidebar__status {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.save-indicator {
  font-size: 12px;
  color: var(--text-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  gap: 4px;
}

.save-indicator svg {
  color: var(--green-500);
  flex-shrink: 0;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .06);
}

.status-dot--online {
  background: var(--green-500);
}

.status-dot--offline {
  background: var(--red-500);
}

.app-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.mobile-topbar {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 30;
}

.mobile-topbar__brand {
  font-weight: 700;
  flex: 1;
}

.sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 11, 25, .5);
  z-index: 39;
  backdrop-filter: blur(2px);
}

main#main-content {
  flex: 1;
  padding: 32px 40px 64px;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
}

/* ============ Buttons / icons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -.005em;
  transition: all .15s var(--ease);
  background: var(--surface);
  color: var(--text);
}

.btn:active {
  transform: scale(.97);
}

.btn--primary {
  background: var(--indigo-500);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.btn--primary:hover {
  background: var(--indigo-600);
  box-shadow: var(--shadow-md);
}

.btn--ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn--ghost:hover {
  background: var(--surface-alt);
  border-color: var(--border-strong);
}

.btn--danger {
  background: var(--red-500);
  color: #fff;
}

.btn--danger:hover {
  background: #DC2626;
}

.btn--sm {
  padding: 7px 13px;
  font-size: 13px;
  border-radius: var(--radius-sm);
}

.btn:disabled {
  opacity: .5;
  cursor: not-allowed;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all .15s var(--ease);
}

.icon-btn:hover {
  background: var(--surface-alt);
  color: var(--text);
  border-color: var(--border);
}

.icon-btn--ghost {
  color: var(--sidebar-text);
}

.icon-btn--ghost:hover {
  background: var(--sidebar-hover);
  color: #fff;
}

.icon-btn--danger:hover {
  background: #FEF2F2;
  color: var(--red-500);
  border-color: #FCA5A5;
}

[data-theme="dark"] .icon-btn--danger:hover {
  background: rgba(239, 68, 68, .12);
}

.icon {
  display: block;
}

/* ============ Layout helpers ============ */
.view {
  display: none;
}

.view--active {
  display: block;
  animation: fade-in .25s var(--ease);
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(4px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.view-header {
  margin-bottom: 28px;
}

.view-header h1 {
  font-size: 26px;
}

.view-header__subtitle {
  color: var(--text-muted);
  margin-top: 6px;
  font-size: 14.5px;
}

.view-header--row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow-sm);
}

.panel h3 {
  font-size: 15px;
  margin-bottom: 14px;
}

/* ============ Empty states ============ */
.empty-state {
  text-align: center;
  padding: 56px 24px;
  border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--surface-alt);
}

.empty-state__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--indigo-50);
  color: var(--indigo-500);
}

[data-theme="dark"] .empty-state__icon {
  background: rgba(79, 70, 229, .15);
}

.empty-state h2 {
  font-size: 17px;
  margin-bottom: 6px;
}

.empty-state p {
  color: var(--text-muted);
  font-size: 14px;
  max-width: 420px;
  margin: 0 auto 18px;
}

.empty-state__actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

.empty-state .btn {
  margin-top: 4px;
}

/* ============ Dashboard ============ */
.dashboard-title-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.dashboard-title-row__name {
  font-size: 22px;
}

.dashboard-title-row__week {
  color: var(--text-muted);
  font-size: 14px;
  margin-top: 4px;
}

.dashboard-title-row__saved {
  color: var(--text-faint);
  font-size: 13px;
}

.stat-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: var(--shadow-sm);
  transition: transform .15s var(--ease), box-shadow .15s var(--ease);
}

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

.stat-card__icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--indigo-50);
  color: var(--indigo-500);
}

[data-theme="dark"] .stat-card__icon {
  background: rgba(79, 70, 229, .15);
}

.stat-card__value {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.1;
}

.stat-card__label {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 20px;
}

.hours-list,
.recent-list,
.planning-list,
.employee-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.hours-row {
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.hours-row:last-child {
  border-bottom: none;
}

.hours-row__name {
  font-size: 13.5px;
  font-weight: 600;
  margin-bottom: 6px;
  display: flex;
  justify-content: space-between;
}

.hours-row__value {
  color: var(--text-muted);
  font-weight: 500;
}

.hours-row__bar-wrap {
  height: 7px;
  background: var(--surface-alt);
  border-radius: 99px;
  overflow: hidden;
}

.hours-row__bar {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--indigo-500), var(--indigo-400));
}

.hours-row--empty {
  color: var(--text-faint);
  font-size: 13.5px;
  padding: 8px 0;
}

.link-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 13px 14px;
  margin-bottom: 6px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  cursor: pointer;
  font: inherit;
  color: var(--text);
  text-align: left;
  transition: background .15s var(--ease), border-color .15s var(--ease);
}

.link-row:hover {
  background: var(--surface);
  border-color: var(--indigo-500);
}

.link-row:last-child {
  margin-bottom: 0;
}

.link-row__name {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
}

.link-row__chevron {
  display: flex;
  align-items: center;
  color: var(--text-faint);
  flex-shrink: 0;
}

.link-row:hover .link-row__chevron {
  color: var(--indigo-500);
}

.link-row-empty {
  color: var(--text-faint);
  font-size: 13.5px;
  padding: 8px 0;
}

/* ============ Planning header / toolbar ============ */
.planning-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.planning-header__name {
  font-size: 22px;
}

.planning-header__subtitle {
  color: var(--text-muted);
  font-size: 13.5px;
  margin-top: 4px;
}

.planning-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.export-menu {
  position: relative;
}

.export-menu summary {
  list-style: none;
  cursor: pointer;
}

.export-menu summary::-webkit-details-marker {
  display: none;
}

.export-menu__list {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 20;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 6px;
  min-width: 200px;
  display: flex;
  flex-direction: column;
}

.export-menu__list button {
  background: none;
  border: none;
  text-align: left;
  padding: 9px 10px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  color: var(--text);
  cursor: pointer;
}

.export-menu__list button:hover {
  background: var(--surface-alt);
}

.week-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.week-nav__range {
  font-weight: 700;
  font-size: 14.5px;
  min-width: 220px;
}

.week-nav__date input {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 7px 10px;
  font-size: 13px;
  background: var(--surface);
  color: var(--text);
}

.filter-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 12px 14px;
  margin-bottom: 22px;
  box-shadow: var(--shadow-sm);
}

.search-field {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 220px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 8px 12px;
  background: var(--surface-alt);
  color: var(--text-muted);
}

.search-field input {
  border: none;
  background: transparent;
  outline: none;
  width: 100%;
  color: var(--text);
  font-size: 13.5px;
}

.search-field--block {
  margin-bottom: 20px;
  max-width: 420px;
}

.filter-bar select {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 8px 12px;
  background: var(--surface-alt);
  color: var(--text);
  font-size: 13.5px;
  cursor: pointer;
}

input,
select,
textarea {
  outline: none;
}

input:focus,
select:focus,
textarea:focus,
.search-field:focus-within {
  box-shadow: var(--shadow-focus);
  border-color: var(--indigo-400);
}

/* ============ Planning grid ============ */
.planning-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(180px, 1fr));
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
}

.day-column {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  min-height: 220px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.day-column--today {
  border-color: var(--indigo-400);
  box-shadow: 0 0 0 2px var(--indigo-100);
}

[data-theme="dark"] .day-column--today {
  box-shadow: 0 0 0 2px rgba(124, 127, 242, .25);
}

.day-column__header {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--surface-alt);
}

.day-column__name {
  font-weight: 700;
  font-size: 13px;
  text-transform: capitalize;
}

.day-column--today .day-column__name {
  color: var(--indigo-500);
}

.day-column__date {
  font-size: 11.5px;
  color: var(--text-muted);
}

.day-column__slots {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px;
  overflow-y: auto;
}

.day-column__empty {
  color: var(--text-faint);
  font-size: 12px;
  text-align: center;
  padding: 18px 4px;
}

.day-column__add {
  margin: 6px 10px 10px;
  padding: 8px;
  border-radius: var(--radius-sm);
  border: 1.5px dashed var(--border-strong);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all .15s var(--ease);
}

.day-column__add:hover {
  border-color: var(--indigo-400);
  color: var(--indigo-500);
  background: var(--indigo-50);
}

[data-theme="dark"] .day-column__add:hover {
  background: rgba(79, 70, 229, .12);
}

.slot-card {
  position: relative;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 10px 10px 10px 12px;
  cursor: pointer;
  transition: all .15s var(--ease);
  overflow: hidden;
}

.slot-card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}

.slot-card__bar {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--indigo-500);
}

.slot-card__row1 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.slot-card__employee {
  font-size: 12.5px;
  font-weight: 700;
}

.slot-card__time {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 600;
}

.slot-card__content {
  margin-top: 3px;
}

.slot-card__meta {
  font-size: 11px;
  color: var(--text-muted);
}

.slot-card__note {
  font-size: 11px;
  color: var(--text-faint);
  font-style: italic;
  margin-top: 2px;
}

.slot-card__badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 99px;
  background: var(--indigo-100);
  color: var(--indigo-700);
  margin-top: 4px;
}

[data-theme="dark"] .slot-card__badge {
  background: rgba(79, 70, 229, .2);
  color: var(--indigo-400);
}

.slot-card__actions {
  display: flex;
  gap: 4px;
  margin-top: 6px;
  opacity: 0;
  transition: opacity .15s var(--ease);
}

.slot-card:hover .slot-card__actions,
.slot-card:focus-within .slot-card__actions {
  opacity: 1;
}

.slot-card__actions .icon-btn {
  width: 26px;
  height: 26px;
}

.slot-card--conflict {
  border-color: var(--red-500);
  background: #FEF2F2;
}

[data-theme="dark"] .slot-card--conflict {
  background: rgba(239, 68, 68, .1);
}

.slot-card__conflict {
  color: var(--red-500);
  font-size: 10.5px;
  font-weight: 700;
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ============ Team / employee cards ============ */
.employee-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 14px;
}

.employee-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .15s var(--ease), transform .15s var(--ease);
}

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

.employee-card__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--avatar-color, var(--indigo-500));
  color: #fff;
  font-weight: 700;
  font-size: 14px;
}

.employee-card__info {
  flex: 1;
  min-width: 0;
}

/* Petit avatar rond réutilisé dans les listes (dashboard, créneaux, vue par employé) */
.avatar-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  min-width: 22px;
  border-radius: 50%;
  background: var(--avatar-color, var(--indigo-500));
  color: #fff;
  font-weight: 700;
  font-size: 10px;
  line-height: 1;
}

.avatar-dot--lg {
  width: 48px;
  height: 48px;
  min-width: 48px;
  font-size: 16px;
}

/* ============ Vue "Par employé" ============ */
.byemployee-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.byemployee-header__info {
  flex: 1;
  min-width: 0;
}

.byemployee-select {
  font-size: 16px;
  font-weight: 700;
  border: none;
  background: transparent;
  padding: 2px 0;
  color: var(--text);
  cursor: pointer;
}
/* =========================================================
   FIX SELECT "PAR EMPLOYÉ" — thème sombre
   ========================================================= */

.byemployee-select {
  font-size: 16px;
  font-weight: 700;
  border: none;
  background: var(--surface);
  color: var(--text);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;

  /* Indique au navigateur que le contrôle est sombre */
  color-scheme: dark;
}

.byemployee-select option {
  background-color: #14172B !important;
  color: #EDEEFB !important;
}

/* Quand l'application est en thème clair */
[data-theme="light"] .byemployee-select {
  color-scheme: light;
}

[data-theme="light"] .byemployee-select option {
  background-color: #FFFFFF !important;
  color: #171A2B !important;
}

/* Thème sombre */
[data-theme="dark"] .byemployee-select {
  color-scheme: dark;
}

[data-theme="dark"] .byemployee-select option {
  background-color: #14172B !important;
  color: #EDEEFB !important;
}
.emp-week-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.emp-week-list__day {
  display: flex;
  gap: 12px;
  padding: 6px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.emp-week-list__day:last-child {
  border-bottom: none;
}

.emp-week-list__dayname {
  width: 90px;
  flex-shrink: 0;
  font-weight: 600;
}

.emp-week-list__slots {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.emp-week-list__pos,
.emp-week-list__pause {
  color: var(--text-muted);
}

.emp-week-list__off {
  color: var(--text-faint);
  font-style: italic;
}

.emp-month-summary {
  display: flex;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.emp-month-summary__stat {
  flex: 1;
  min-width: 160px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 14px;
}

.emp-month-summary__stat--overtime {
  border-color: var(--amber-500);
  background: color-mix(in srgb, var(--amber-500) 8%, transparent);
}

.emp-month-summary__value {
  display: block;
  font-size: 20px;
  font-weight: 800;
}

.emp-month-summary__label {
  font-size: 12px;
  color: var(--text-muted);
}

.emp-week-breakdown {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.emp-week-breakdown__row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  background: var(--surface-alt);
}

.emp-week-breakdown__row--over {
  background: color-mix(in srgb, var(--amber-500) 12%, transparent);
  color: var(--amber-500);
}

.employee-card__name {
  font-weight: 700;
  font-size: 14.5px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.employee-card__meta {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 3px;
}

.employee-card__contact {
  font-size: 12px;
  color: var(--text-faint);
  margin-top: 3px;
}

.employee-card__actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  padding: 1px 5px;
  border-radius: 5px;
}

.badge--polyvalent {
  background: var(--amber-500);
  color: #fff;
}

/* ============ Plannings list ============ */
.planning-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 18px;
  margin-bottom: 10px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .15s var(--ease);
}

.planning-row:hover {
  box-shadow: var(--shadow-md);
}

.planning-row__name {
  font-weight: 700;
  font-size: 14.5px;
}

.planning-row__meta {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 3px;
}

.planning-row__updated {
  font-size: 11.5px;
  color: var(--text-faint);
  margin-top: 2px;
}

.planning-row__actions {
  display: flex;
  gap: 6px;
}

/* ============ Modèles de semaine ============ */
.template-list {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  max-height: 260px;
  overflow-y: auto;
}

.template-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  margin-bottom: 8px;
}

.template-row__name {
  font-weight: 600;
  font-size: 13.5px;
}

.template-row__meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.template-row__actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.template-row__empty {
  color: var(--text-muted);
  font-size: 13px;
  padding: 10px 0;
  list-style: none;
}

.modal-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 16px 0;
}

/* ============ Forms ============ */
.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  font-size: 14px;
  background: var(--surface-alt);
  color: var(--text);
  transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}

.field-hint {
  font-size: 12px;
  color: var(--text-faint);
  margin-top: 6px;
}

.field-error {
  font-size: 12px;
  color: var(--red-500);
  margin-top: 5px;
  min-height: 14px;
}

.form-row {
  display: grid;
  gap: 14px;
  margin-bottom: 0;
}

.form-row--2 {
  grid-template-columns: 1fr 1fr;
}

.form-row--3 {
  grid-template-columns: 1fr 1fr 1fr;
}

.position-chips,
.color-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.position-chip {
  border: 1px solid var(--border);
  background: var(--surface-alt);
  color: var(--text-muted);
  padding: 7px 13px;
  border-radius: 99px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s var(--ease);
}

.position-chip:hover {
  border-color: var(--indigo-400);
}

.position-chip--selected {
  background: var(--indigo-500);
  color: #fff;
  border-color: var(--indigo-500);
}

.color-swatch {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  background: var(--swatch);
  transition: transform .15s var(--ease);
  position: relative;
}

.color-swatch:hover {
  transform: scale(1.1);
}

.color-swatch--selected {
  border-color: var(--text);
  box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--swatch);
}

/* ============ Modal ============ */
.modal-root {
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
}

.modal-root--open {
  pointer-events: auto;
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 11, 25, .55);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  animation: overlay-in .18s var(--ease) forwards;
}

@keyframes overlay-in {
  to {
    opacity: 1;
  }
}

.modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  transform: translateY(10px) scale(.98);
  opacity: 0;
  animation: modal-in .2s var(--ease) forwards;
}

@keyframes modal-in {
  to {
    transform: none;
    opacity: 1;
  }
}

.modal--sm {
  max-width: 420px;
}

.modal--md {
  max-width: 560px;
}

.modal--lg {
  max-width: 780px;
}

.modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.modal__header h2 {
  font-size: 17px;
}

.modal__subtitle {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.modal__body {
  padding: 22px;
  overflow-y: auto;
}

.modal__message {
  font-size: 14.5px;
  color: var(--text-muted);
  line-height: 1.6;
}

.modal__footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 22px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
  background: var(--surface-alt);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

/* ============ Toasts ============ */
.toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 360px;
}

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  box-shadow: var(--shadow-lg);
  font-size: 13.5px;
  font-weight: 500;
  transform: translateX(20px);
  opacity: 0;
  transition: all .22s var(--ease);
  cursor: pointer;
}

.toast--visible {
  transform: none;
  opacity: 1;
}

.toast--success svg {
  color: var(--green-500);
}

.toast--error svg {
  color: var(--red-500);
}

.toast--warning svg {
  color: var(--amber-500);
}

.toast--info svg {
  color: var(--sky-500);
}

.toast__msg {
  flex: 1;
}

.toast__action {
  flex-shrink: 0;
  background: none;
  border: none;
  color: var(--indigo-500);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
}

.toast__action:hover {
  text-decoration: underline;
}

/* ============ Settings view ============ */
.settings-panel {
  max-width: 640px;
}

.settings-panel .panel {
  margin-bottom: 18px;
}

.settings-panel .panel h3 {
  margin-bottom: 4px;
}

.settings-panel .panel__hint {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.logo-uploader {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo-uploader__preview {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-md);
  border: 1px dashed var(--border-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--surface-alt);
  flex-shrink: 0;
}

.logo-uploader__preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.logo-uploader__actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.kbd-hint {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11.5px;
  color: var(--text-faint);
}

.kbd-hint kbd {
  background: var(--surface-alt);
  border: 1px solid var(--border-strong);
  border-radius: 4px;
  padding: 1px 6px;
  font-family: inherit;
  font-size: 11px;
}

/* ============ Congés employés ============ */
.leave-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 10px;
}

.leave-list__empty {
  font-size: 12.5px;
  color: var(--text-faint);
}

.leave-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  font-size: 12.5px;
}

.leave-add-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.leave-add-row input[type="date"] {
  flex: 0 0 auto;
  width: auto;
}

.leave-add-row input[type="text"] {
  flex: 1;
  min-width: 140px;
}

.icon-btn--sm {
  width: 22px;
  height: 22px;
}

.day-column__leave-banner {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--amber-500);
  background: color-mix(in srgb, var(--amber-500) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--amber-500) 30%, transparent);
  border-radius: var(--radius-sm);
  padding: 5px 8px;
  margin-bottom: 8px;
}

.overtime-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--red-500);
  background: color-mix(in srgb, var(--red-500) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--red-500) 28%, transparent);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  margin-bottom: 14px;
}

.overtime-banner strong {
  font-weight: 700;
}

.hours-row--overtime .hours-row__value {
  color: var(--red-500);
  font-weight: 700;
}

.hours-row--overtime .hours-row__bar {
  background: var(--red-500) !important;
}

.slot-card--leave-conflict .slot-card__bar {
  background: var(--amber-500) !important;
}

.slot-card__conflict--leave {
  color: var(--amber-500);
}

.slot-card--dragging {
  opacity: 0.4;
}

.day-column--drop-target {
  outline: 2px dashed var(--indigo-500);
  outline-offset: -2px;
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--indigo-500) 6%, transparent);
}

.slot-card {
  cursor: grab;
}

.slot-card:active {
  cursor: grabbing;
}

/* ============ Redimensionnement d'un créneau (glisser-déposer) ============ */
.slot-resize-handle {
  position: absolute;
  left: 8px;
  right: 8px;
  height: 9px;
  z-index: 3;
  cursor: ns-resize;
  touch-action: none;
}

.slot-resize-handle::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 28px;
  height: 3px;
  border-radius: 2px;
  background: var(--border-strong);
  opacity: 0;
  transition: opacity .15s var(--ease);
}

.slot-card:hover .slot-resize-handle::after {
  opacity: 0.9;
}

.slot-resize-handle--top {
  top: -2px;
}

.slot-resize-handle--bottom {
  bottom: -2px;
}

.slot-card--resizing {
  box-shadow: 0 0 0 2px var(--indigo-500);
  z-index: 5;
}

.slot-card--resizing .slot-resize-handle::after {
  opacity: 1;
  background: var(--indigo-500);
}

.slot-card__conflict--rest {
  color: var(--amber-500);
}

/* ============ Historique d'activité ============ */
.activity-log {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 50vh;
  overflow-y: auto;
}

.activity-log__row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 4px;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.activity-log__row:last-child {
  border-bottom: none;
}

.activity-log__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--indigo-500);
  flex-shrink: 0;
}

.activity-log__msg {
  flex: 1;
  color: var(--text);
}

.activity-log__time {
  font-size: 11.5px;
  color: var(--text-faint);
  flex-shrink: 0;
  white-space: nowrap;
}

/* ============ Scrollbars ============ */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 99px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-faint);
}

/* ============ Responsive ============ */
@media (max-width: 1100px) {
  .stat-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 880px) {
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    transform: translateX(-100%);
    transition: transform .25s var(--ease);
    box-shadow: var(--shadow-lg);
  }

  body.sidebar-open .sidebar {
    transform: translateX(0);
  }

  body.sidebar-open .sidebar-overlay {
    display: block;
  }

  .sidebar-overlay[hidden] {
    display: none;
  }

  .mobile-topbar {
    display: flex;
  }

  main#main-content {
    padding: 20px 16px 48px;
  }

  .form-row--2,
  .form-row--3 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .stat-cards {
    grid-template-columns: 1fr 1fr;
  }

  .planning-grid {
    grid-auto-flow: column;
    grid-template-columns: none;
    grid-auto-columns: minmax(200px, 1fr);
  }

  .planning-header__actions {
    width: 100%;
  }

  .view-header--row {
    flex-direction: column;
  }
}

/* ============ Print ============ */
@media print {

  .sidebar,
  .mobile-topbar,
  .planning-header__actions,
  .week-nav,
  .filter-bar,
  .toast-container,
  .day-column__add,
  .slot-card__actions,
  .sig-d {
    display: none !important;
  }

  main#main-content {
    padding: 0;
    max-width: none;
  }

  .planning-grid {
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
  }

  .day-column {
    box-shadow: none;
    break-inside: avoid;
  }

  body {
    background: #fff;
  }

  .modal-root {
    display: none !important;
  }

  body.print-preview-mode .modal-root {
    display: block !important;
    position: static !important;
    background: none !important;
  }

  body.print-preview-mode .modal-overlay {
    position: static !important;
    background: none !important;
    padding: 0 !important;
  }

  body.print-preview-mode .modal {
    box-shadow: none !important;
    border: none !important;
    max-height: none !important;
    max-width: none !important;
    width: 100% !important;
  }

  body.print-preview-mode .modal__header,
  body.print-preview-mode .modal__footer {
    display: none !important;
  }

  body.print-preview-mode #main-content {
    display: none !important;
  }
}

/* ============ Aperçu avant impression ============ */
.print-preview {
  background: #fff;
  color: #0F172A;
  padding: 4px;
}

.print-preview__header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 12px;
  border-bottom: 2px solid #0F172A;
  padding-bottom: 8px;
}

.print-preview__title {
  font-size: 18px;
  font-weight: 700;
}

.print-preview__meta {
  font-size: 12px;
  color: #475569;
}

.print-preview__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.print-preview__day {
  border: 1px solid #CBD5E1;
  border-radius: 8px;
  padding: 8px;
  break-inside: avoid;
}

.print-preview__day h4 {
  font-size: 12px;
  margin-bottom: 6px;
  border-bottom: 1px solid #E2E8F0;
  padding-bottom: 4px;
}

.print-preview__slot {
  font-size: 10.5px;
  margin-bottom: 6px;
  padding: 4px 6px;
  border-left: 3px solid var(--slot-color, #4F46E5);
  background: #F8FAFC;
  border-radius: 4px;
}

.print-preview__slot strong {
  display: block;
}

.print-preview__empty {
  font-size: 10.5px;
  color: #94A3B8;
}

/* ============ Signature développeur ============ */
.glass {
  background: rgba(20, 23, 43, .72);
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  border: 1px solid rgba(124, 127, 242, .22);
}

[data-theme="light"] .glass {
  background: rgba(255, 255, 255, .78);
  border: 1px solid rgba(79, 70, 229, .16);
}

.sig-d {
  width: 100%;
  margin: 4px 0 14px;
  padding: 10px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: flex-start;
  gap: 9px;
  flex-wrap: wrap;
  box-shadow: none;
}

.sig-aw {
  position: relative;
  flex-shrink: 0;
}

.sig-ar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  padding: 2px;
  background: linear-gradient(135deg, var(--indigo-500), var(--indigo-400));
}

.sig-ai {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
}

.sig-ai img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.sig-st {
  position: absolute;
  right: -1px;
  bottom: -1px;
  z-index: 2;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--green-500);
  border: 2px solid var(--sidebar-bg);
  box-shadow: 0 0 0 0 rgba(16, 185, 129, .6);
  animation: sig-pulse 2.2s infinite;
}

@keyframes sig-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, .55);
  }

  70% {
    box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

.sig-inf {
  flex: 1;
  min-width: 120px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.sig-nm {
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  white-space: normal;
}

.sig-nm a {
  color: var(--indigo-400);
  text-decoration: none;
}

.sig-nm a:hover {
  text-decoration: underline;
}

.sig-tg {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.sig-t {
  font-size: 9px;
  font-weight: 600;
  color: var(--indigo-400);
  background: rgba(124, 127, 242, .16);
  border-radius: 99px;
  padding: 1.5px 5px;
  white-space: nowrap;
}

.sig-cr {
  font-size: 9px;
  color: var(--text-faint);
  white-space: normal;
}

.sig-ac {
  width: 100%;
}

.sig-mt {
  display: flex;
  align-items: center;
}

.sig-mi {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--sidebar-text);
}

.sig-mi svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ============================================================
   À copier-coller à la fin de css/style.css
   Ajouts pour : vue Mois, badge "proche du plafond", bouton d'installation
   ============================================================ */

/* ---------- Badge "proche du plafond d'heures" (dashboard) ---------- */
.hours-row--near-limit .hours-row__value,
.hours-row--near-limit .hours-row__name {
  color: #D97706;
  /* orange, distinct du rouge "dépassement" */
}

.hours-row--near-limit .icon {
  color: #D97706;
}

/* ---------- Vue Mois ---------- */
.month-weekday-row {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
  margin: 16px 0 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-faint, #9CA3AF);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: .03em;
}

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

.month-cell {
  min-height: 84px;
  border: 1px solid var(--border, #26293F);
  background: var(--panel-bg, #14172B);
  border-radius: 10px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  cursor: pointer;
  color: inherit;
  font: inherit;
  text-align: left;
  transition: border-color .15s ease, transform .1s ease;
}

.month-cell:hover {
  border-color: var(--indigo, #4F46E5);
  transform: translateY(-1px);
}

.month-cell--muted {
  opacity: .4;
}

.month-cell--today {
  border-color: var(--indigo, #4F46E5);
  box-shadow: 0 0 0 1px var(--indigo, #4F46E5) inset;
}

.month-cell--has-data {
  background: var(--panel-bg-strong, #191C33);
}

.month-cell__date {
  font-weight: 700;
  font-size: 13px;
}

.month-cell__info {
  font-size: 11px;
  color: var(--text-muted, #9A9EC2);
  line-height: 1.3;
}

/* Cible mobile : grille plus compacte */
@media (max-width: 640px) {
  .month-cell {
    min-height: 64px;
    padding: 6px;
  }

  .month-cell__info {
    display: none;
  }

  .month-cell--has-data::after {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--indigo, #4F46E5);
  }
}

.btn-home {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 10px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-home:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(99, 102, 241, 0.3);
}