/* ═══════════════════════════════════════════════════
   PREMIUM EVENT CALENDAR — 2026 Design
   Inspired by Google Calendar / Apple Calendar / Vuesax
   ═══════════════════════════════════════════════════ */

/* Container — calBox is the positioning parent */
#calBox{
  display: flex !important;
  flex-direction: column;
  position: relative;
}
#calBox > h3{
  flex-shrink: 0;
}
#MyCalendar{
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
  margin: 0 auto;
  padding: 4px 0 0;
  box-sizing: border-box;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  position: relative;
}

/* ── Header: arrows + month title (flexbox row) ── */
#MyCalendar .cal-nav-row{
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin: 0;
  padding: 0;
  flex-shrink: 0;
}

#MyCalendar .cal-nav-row button.arrow,
#MyCalendar .cal-nav-row h4{
  height: 36px;
  line-height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-decoration: none;
  margin: 0;
  padding: 0;
  float: none;
  box-sizing: border-box;
}

#MyCalendar .cal-nav-row button.arrow{
  width: 36px;
  min-width: 36px;
  font-size: 18px;
  color: #888;
  border-radius: 50%;
  transition: all 0.2s ease;
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: inherit;
  line-height: 1;
}
#MyCalendar .cal-nav-row button.arrow:hover{
  color: #fff;
  background: #cc0000;
  transform: scale(1.05);
}

#MyCalendar .cal-nav-row h4{
  flex: 1;
  font-size: 15px;
  font-weight: 700;
  color: #1a1a1a;
  letter-spacing: 0.3px;
  border: none;
  overflow: hidden;
  margin-bottom: 0;
}

/* ── Day name headers (Lu Ma Mi Ju Vi Sá Do) ── */
ul#dias,
ul#fechas{
  width: 100%;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  list-style: none;
  padding: 0;
  margin: 0;
  float: none;
  clear: both;
  height: auto;
  flex-shrink: 0;
}

ul#dias{
  margin-top: 10px;
  margin-bottom: 4px;
  padding-bottom: 8px;
  border-bottom: none;
}

ul#dias li{
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  color: #666;
  letter-spacing: 0.3px;
  padding: 3px 0;
  height: auto;
  line-height: 1;
  float: none;
  margin: 0;
  width: auto;
  background: rgba(204,0,0,0.04);
  border-radius: 8px;
  margin: 0 1px;
}

/* ── Date grid ── */
ul#fechas{
  gap: 2px 0;
  padding-top: 4px;
  position: relative;
}

ul#fechas li{
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: #333;
  padding: 0;
  margin: 0;
  width: auto;
  height: 32px;
  line-height: 32px;
  border-radius: 50%;
  cursor: default;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
  position: relative;
  float: none;
}

/* Hover on date cells (only those with title attribute = real days) */
ul#fechas li[title]:hover{
  background: rgba(0,0,0,0.06);
}

/* ── TODAY: outlined circle, subtle ── */
ul#fechas li.today{
  background: transparent;
  color: #cc0000;
  font-weight: 700;
  border: 2px solid #cc0000;
  line-height: 28px;
}
ul#fechas li.today:hover{
  background: rgba(204,0,0,0.06);
  transform: scale(1.08);
}

/* ── EVENT days: subtle red circle with white number ── */
ul#fechas li.red{
  background: #cc0000;
  color: #fff;
  font-weight: 700;
  border-radius: 50%;
}
ul#fechas li.red:hover{
  background: #b30000;
  transform: scale(1.08);
}
ul#fechas li.red a{
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  display: block;
  width: 100%;
  height: 100%;
  line-height: 32px;
  border-radius: 50%;
}
ul#fechas li.red a:hover{
  color: #fff;
}

/* Today + Event combined: filled red with stronger shadow */
ul#fechas li.today.red{
  background: #cc0000;
  color: #fff;
  border-color: #cc0000;
  box-shadow: 0 1px 6px rgba(204,0,0,0.35);
  line-height: 28px;
}
ul#fechas li.today.red a,
.activeDay{
  color: #fff;
  line-height: 28px;
}

/* (eventPulse animation removed — using solid circles now) */

/* ── Event count badge — positioned at bottom of #calBox ── */
.cal-events-badge{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 0 10px;
  background: #cc0000;
  border-radius: 1ex;
  clear: both;
  animation: badgeSlideIn 0.4s ease;
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.2s ease;
  margin-top: auto;
  align-self: center;
  width: 80%;
  height: 30px;
  box-sizing: border-box;
  flex-shrink: 0;
}
.cal-events-badge:hover{
  opacity: 0.88;
}
.cal-badge-icon{
  font-size: 11px;
  color: rgba(255,255,255,0.85);
  line-height: 1;
}
.cal-badge-count{
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  line-height: 1;
  letter-spacing: -0.3px;
}
.cal-badge-text{
  font-size: 10px;
  font-weight: 500;
  color: rgba(255,255,255,0.85);
  line-height: 1.2;
}

@keyframes badgeSlideIn{
  from{ opacity: 0; transform: translateY(6px); }
  to{ opacity: 1; transform: translateY(0); }
}

#MyCalendar p.helvetica{ display: none; }

/* ── Legacy float spans (event popups) ── */
ul#fechas li span{padding: 5px; display: none; float: none; clear: both; position: absolute; z-index: 80;}
ul#fechas li span a.flotantes{position: absolute; z-index: 99; float: left; display: block; margin-right: 5px; top: -18px; width: 24px; height: 20px; background: #333; padding: 2px;}
ul#fechas li span a.flotantes:hover{color:#fff; background: #000;}
