.eco-pro-portal-body {
  background: #f5f7fb;
}

.eco-pro-portal-body #page,
.eco-pro-portal-body .site {
  background: transparent;
}

.eco-pro-portal-body .site-main,
.eco-pro-portal-body #primary {
  padding: 0;
  max-width: 100% !important;
  width: 100% !important;
}

.eco-pro-portal-body .content-area,
.eco-pro-portal-body .site-content,
.eco-pro-portal-body .ast-container,
.eco-pro-portal-body .ast-plain-container,
.eco-pro-portal-body .entry-content-wrap,
.eco-pro-portal-body .entry-content,
.eco-pro-portal-body .elementor,
.eco-pro-portal-body .elementor-widget-container,
.eco-pro-portal-body .elementor-section-wrap,
.eco-pro-portal-body .elementor-section,
.eco-pro-portal-body .elementor-container,
.eco-pro-portal-body .elementor-column,
.eco-pro-portal-body .elementor-widget-wrap,
.eco-pro-portal-body .e-con,
.eco-pro-portal-body .e-con-inner,
.eco-pro-portal-body .e-parent,
.eco-pro-portal-body .e-child {
  max-width: 100% !important;
  width: 100% !important;
}

.eco-pro-portal-body .elementor-section.elementor-section-boxed > .elementor-container {
  max-width: 100% !important;
}

.eco-pro-portal-body .elementor-column-gap-default > .elementor-column > .elementor-element-populated {
  padding: 0 !important;
}

.eco-pro-portal {
  font-family: system-ui, -apple-system, sans-serif;
  color: #0f172a;
  padding: 32px 36px 64px;
  max-width: 1400px;
  margin: 0 auto;
}

.eco-pro-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  background: linear-gradient(135deg, #0f172a 0%, #1d4ed8 100%);
  color: #fff;
  padding: 32px;
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.25);
  margin-bottom: 28px;
}

.eco-pro-hero__eyebrow {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.eco-pro-hero h1 {
  margin: 12px 0 8px;
  font-size: 30px;
}

.eco-pro-hero p {
  margin: 0;
  color: rgba(255, 255, 255, 0.75);
  max-width: 420px;
}

.eco-pro-button {
  background: #fff;
  color: #1d4ed8;
  border: none;
  padding: 12px 18px;
  font-weight: 700;
  border-radius: 14px;
  cursor: pointer;
}

.eco-pro-grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(12, minmax(0, 1fr));
}

.eco-pro-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 22px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.eco-pro-kpis {
  grid-column: span 7;
}

.eco-pro-activity {
  grid-column: span 5;
}

.eco-pro-list,
.eco-pro-calendar,
.eco-pro-detail {
  grid-column: span 12;
}

.eco-pro-kpis__grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
}

.eco-pro-kpi {
  background: #f8fafc;
  border-radius: 16px;
  padding: 16px;
}

.eco-pro-kpi span {
  display: block;
  color: #64748b;
  font-size: 13px;
  margin-bottom: 6px;
}

.eco-pro-kpi strong {
  font-size: 22px;
}

.eco-pro-progress {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.eco-pro-progress__bar {
  flex: 1;
  height: 10px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
}

.eco-pro-progress__bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #22c55e 0%, #0ea5e9 100%);
}

.eco-pro-activity ul {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.eco-pro-activity li {
  background: #f8fafc;
  border-radius: 14px;
  padding: 12px 16px;
}

.eco-pro-activity span {
  display: block;
  font-size: 12px;
  color: #64748b;
}

.eco-pro-activity strong {
  font-size: 14px;
}

.eco-pro-list__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}

.eco-pro-filters {
  display: flex;
  gap: 12px;
}

.eco-pro-filters label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: #64748b;
}

.eco-pro-filters select {
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  background: #fff;
  min-width: 140px;
}

.eco-pro-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  margin-bottom: 12px;
}

.eco-pro-row h3 {
  margin: 0 0 6px;
  font-size: 16px;
}

.eco-pro-row p {
  margin: 0;
  color: #64748b;
  font-size: 13px;
}

.eco-pro-row__meta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.eco-pro-pill {
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: #e2e8f0;
}

.eco-pro-pill--en-cours {
  background: rgba(14, 165, 233, 0.15);
  color: #0284c7;
}

.eco-pro-pill--termine {
  background: rgba(34, 197, 94, 0.15);
  color: #16a34a;
}

.eco-pro-pill--bloque {
  background: rgba(239, 68, 68, 0.15);
  color: #dc2626;
}

.eco-pro-progress__mini {
  font-weight: 700;
  color: #0f172a;
}

.eco-pro-link {
  background: none;
  border: none;
  color: #2563eb;
  font-weight: 700;
  cursor: pointer;
  padding: 0;
}

.eco-pro-calendar__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.eco-pro-calendar__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.eco-pro-calendar__day {
  background: #f8fafc;
  border-radius: 14px;
  padding: 12px;
  min-height: 110px;
  display: grid;
  gap: 8px;
}

.eco-pro-calendar__day.is-today {
  border: 2px solid #2563eb;
}

.eco-pro-calendar__day h4 {
  margin: 0;
  font-size: 13px;
  color: #475569;
}

.eco-pro-calendar__event {
  background: #fff;
  border-radius: 12px;
  padding: 8px 10px;
  font-size: 12px;
  border: 1px solid #e2e8f0;
}

/* Planning par semaine */
.eco-pro-week-section {
  margin-bottom: 28px;
}

.eco-pro-week-header {
  margin: 0 0 16px 0;
  font-size: 18px;
  font-weight: 600;
  color: #1d4ed8;
  padding-bottom: 12px;
  border-bottom: 2px solid #e2e8f0;
}

.eco-pro-week-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.eco-pro-day-column {
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  padding: 16px;
  transition: all 0.2s ease;
}

.eco-pro-day-column.is-today {
  border-color: #2563eb;
  border-width: 2px;
  background: #f0f9ff;
}

.eco-pro-day-title {
  margin: 0 0 12px 0;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.eco-pro-installation {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 12px;
}

.eco-pro-installation:hover {
  border-color: #2563eb;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
  background: #f0f9ff;
}

.eco-pro-installation:last-of-type {
  margin-bottom: 0;
}

.eco-pro-installation__number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: #2563eb;
  color: #fff;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}

.eco-pro-installation__text {
  flex: 1;
  color: #0f172a;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.eco-pro-day-overflow {
  background: #fef3c7;
  color: #b45309;
  font-size: 11px;
  font-weight: 600;
  padding: 6px 10px;
  border-radius: 8px;
  margin-top: 8px;
  text-align: center;
}

/* Navigation semaines */
.eco-pro-week-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 20px;
}

.eco-pro-week-nav button {
  background: #fff;
  border: 2px solid #e2e8f0;
  color: #0f172a;
  padding: 10px 16px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  transition: all 0.2s ease;
}

.eco-pro-week-nav button:hover:not(:disabled) {
  border-color: #2563eb;
  color: #2563eb;
  background: #f0f9ff;
}

.eco-pro-week-nav button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.eco-pro-detail__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.eco-pro-detail__dates {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.eco-pro-detail__dates span {
  display: block;
  font-size: 12px;
  color: #64748b;
}

.eco-pro-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.eco-pro-step {
  background: #f8fafc;
  border-radius: 14px;
  padding: 12px;
  text-align: center;
  border: 1px solid transparent;
}

.eco-pro-step.is-active {
  border-color: #2563eb;
  background: rgba(37, 99, 235, 0.12);
}

.eco-pro-step span {
  font-weight: 700;
  font-size: 18px;
  display: block;
}

.eco-pro-detail__gallery {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
}

.eco-pro-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.eco-pro-photo {
  border-radius: 16px;
  background: linear-gradient(135deg, #e2e8f0 0%, #f8fafc 100%);
  padding: 18px;
  min-height: 110px;
  display: grid;
  align-content: end;
  gap: 4px;
}

.eco-pro-photo strong {
  font-size: 13px;
}

.eco-pro-photo span {
  font-size: 11px;
  color: #64748b;
}

.eco-pro-reports h3 {
  margin-top: 0;
}

.eco-pro-remark {
  margin-top: 10px;
  background: #f8fafc;
  padding: 12px;
  border-radius: 12px;
  font-size: 13px;
}

.eco-pro-login {
  min-height: calc(100vh - 120px);
  display: grid;
  place-items: center;
  padding: 40px 16px 60px;
  gap: 16px;
}

.eco-pro-login__brand {
  text-align: center;
}

.eco-pro-login__logo {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: linear-gradient(135deg, #1d4ed8 0%, #38bdf8 100%);
  margin: 0 auto 12px;
}

.eco-pro-login__card {
  background: #fff;
  border-radius: 20px;
  padding: 24px;
  width: min(480px, 100%);
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.08);
}

.eco-pro-login__form label {
  font-size: 13px;
}

.eco-pro-login__form input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
}

@media (width <= 1024px) {
  .eco-pro-hero {
    flex-direction: column;
  }

  .eco-pro-kpis {
    grid-column: span 12;
  }

  .eco-pro-activity {
    grid-column: span 12;
  }

  .eco-pro-kpis__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .eco-pro-calendar__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .eco-pro-detail__gallery {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   CALENDRIER - STYLES SPÉCIFIQUES AU PORTAIL
   ============================================ */

.card.calendar-block {
  position: relative;
  display: flex;
  flex-direction: column;
}

.card.calendar-block .card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
}

.card.calendar-block h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
}

/* Bouton d'agrandissement du calendrier */
.btn-expand {
  background: transparent;
  border: 1px solid #d1d5db;
  width: 32px;
  height: 32px;
  border-radius: 4px;
  cursor: pointer;
  color: #6b7280;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  padding: 0;
}

.btn-expand:hover {
  background: #f3f4f6;
  color: #111827;
  border-color: #9ca3af;
}

.btn-expand svg {
  width: 18px;
  height: 18px;
}

/* Conteneur du calendrier s'adapte au bloc */
.eco-calendar-container {
  flex: 1;
  min-height: 360px;
  overflow: hidden;
}

.eco-calendar-container.eco-fullscreen-overlay {
  position: fixed;
  inset: 0 0 0 0;
  z-index: 10000;
  width: 100vw;
  height: 100vh;
  min-height: auto;
  background: white;
  border-radius: 0;
}

.eco-calendar.fullscreen .eco-calendar-header {
  position: sticky;
  top: 0;
  background: white;
  border-bottom: 1px solid #e5e7eb;
  padding: 16px 24px;
  z-index: 10001;
}

.eco-calendar.fullscreen .eco-calendar-body {
  padding: 24px;
}

/* Filtre du calendrier pour admin */
.calendar-filters {
  background: #f9fafb;
  border-bottom: 1px solid #e5e7eb;
  padding: 12px 16px;
}

.calendar-filters label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #6b7280;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.calendar-filters select {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  font-size: 13px;
  color: #111827;
  background: white;
  cursor: pointer;
  transition: all 0.2s;
}

.calendar-filters select:hover {
  border-color: #9ca3af;
}

.calendar-filters select:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

@media (width <= 640px) {
  .eco-pro-portal {
    padding: 20px;
  }

  .eco-pro-filters {
    flex-direction: column;
    width: 100%;
  }

  .eco-pro-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .eco-pro-calendar__grid {
    grid-template-columns: 1fr;
  }

  .eco-calendar-container.eco-fullscreen-overlay {
    width: 100vw;
    height: 100vh;
  }
}

/* ============================================
   SIMPLE CALENDAR STYLES
   ============================================ */

.simple-calendar {
  width: 100%;
  font-family: system-ui, -apple-system, sans-serif;
}

.simple-calendar .cal-prev,
.simple-calendar .cal-next {
  transition: all 0.2s !important;
}

.simple-calendar .cal-prev:hover,
.simple-calendar .cal-next:hover {
  background: #e5e7eb !important;
  border-color: #9ca3af !important;
}

.simple-calendar .cal-day {
  transition: all 0.2s !important;
  font-size: 12px !important;
}

.simple-calendar .cal-day:hover {
  background: #e0f2fe !important;
}

.cal-popover {
  min-width: 300px;
  max-width: 400px;
}

.cal-popover a {
  text-decoration: none !important;
}

.cal-popover a:hover {
  text-decoration: underline !important;
}

.btn-expand {
  background: transparent !important;
  border: 1px solid #d1d5db !important;
  width: 32px !important;
  height: 32px !important;
  border-radius: 4px !important;
  cursor: pointer !important;
  color: #6b7280 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: all 0.2s !important;
  padding: 0 !important;
}

.btn-expand:hover {
  background: #f3f4f6 !important;
  color: #111827 !important;
  border-color: #9ca3af !important;
}

.calendar-block {
  display: flex !important;
  flex-direction: column !important;
}

.calendar-block .card-head {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
}

.calendar-block .card-head h3 {
  margin: 0 !important;
}
