/* Base look */
.cmcis-weekly-calendar,
.cmcis-vertical-list {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  border: 1px solid #e6e6e6;
  border-radius: 12px;
  padding: 12px;
  background: #fff;
  line-height: 1.3;
  color: #111;
}

/* -------- Horizontal (grid) -------- */
.cmcis-week {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}
.cmcis-weekly-calendar.is-sunsat .cmcis-week {
  grid-template-columns: repeat(7, 1fr);
}

/* Day boxes (BACK ON) */
.cmcis-day {
  border: 1px solid #eee;
  border-radius: 12px;
  padding: 12px;
  background: #fafafa;
}
.cmcis-day.is-today {
  border-color: #2a6df4;
  box-shadow: 0 0 0 2px rgba(42,109,244,.15) inset;
}
.cmcis-dayname {
  font-weight: 800;
  margin-bottom: 10px;
  font-size: 1.1rem;
  text-align: center;   /* centered date header */
}

/* Events inside a day */
.cmcis-events {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Event rows (NO BOXES) */
.cmcis-event {
  display: flex;
  align-items: center;       /* vertical centering */
  gap: 12px;
  padding: 6px 2px;          /* light spacing, no borders/background */
}

/* Centered time, bold red */
.cmcis-time {
  font-weight: 700;
  font-size: 1rem;
  color: #d40000;
  white-space: nowrap;
  min-width: 5.2ch;          /* give time its lane */
  text-align: center;        /* horizontal centering */
  margin: 0;
}

/* Title flexes to fill */
.cmcis-title {
  flex: 1;
  font-size: 1.05rem;
}

/* -------- Vertical (stacked list) -------- */

/* Day boxes (BACK ON) */
.cmcis-v-day {
  border: 1px solid #eee;
  border-radius: 12px;
  padding: 12px;
  background: #fafafa;
  margin-bottom: 12px;
}
.cmcis-v-day.is-today {
  border-color: #2a6df4;
  box-shadow: 0 0 0 2px rgba(42,109,244,.15) inset;
}
.cmcis-v-dayname {
  margin: 0 0 10px 0;
  font-size: 1.15rem;
  font-weight: 800;
  text-align: center;   /* centered date header */
}

.cmcis-v-items {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 6px;
}

/* Event rows (NO BOXES) */
.cmcis-v-item {
  display: flex;
  align-items: center;       /* vertical centering */
  gap: 12px;
  padding: 6px 2px;          /* light spacing, no borders/background */
}

/* Centered time, bold red */
.cmcis-v-time {
  font-weight: 700;
  font-size: 1rem;
  color: #d40000;
  white-space: nowrap;
  min-width: 5.2ch;
  text-align: center;
  margin: 0;
}

.cmcis-v-title {
  flex: 1;
  font-size: 1.05rem;
}

/* Small screens */
@media (max-width: 640px) {
  .cmcis-week { grid-template-columns: 1fr !important; }
}