/* =========================================================
   Schedule: remove the visible calendar container only
   Keeps the existing calendar structure, spacing and position intact.
   ========================================================= */

#scheduleTab .schedule-page-panel,
#scheduleTab .schedule-calendar-layout {
  background: transparent !important;
}

#scheduleTab .schedule-calendar-card {
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
  outline: 0 !important;
}

#scheduleTab .schedule-calendar-card::before,
#scheduleTab .schedule-calendar-card::after {
  content: none !important;
  display: none !important;
}

body.dark-theme #scheduleTab .schedule-calendar-card {
  background: transparent !important;
}

/* =========================================================
   Schedule: smooth borderless calendar cells
   Removes the visible outlines while keeping each date as its
   own softly separated tile.
   ========================================================= */

#scheduleTab .full-page-panel,
#scheduleTab .schedule-page-panel,
#scheduleTab .schedule-calendar-layout,
#scheduleTab .schedule-calendar-card {
  border: 0 !important;
  outline: 0 !important;
}

#scheduleTab .schedule-page-panel {
  background:
    radial-gradient(circle at 18% 0%, rgba(123, 92, 255, 0.08), transparent 34%),
    radial-gradient(circle at 86% 12%, rgba(255, 255, 255, 0.42), transparent 34%),
    linear-gradient(180deg, rgba(250, 248, 255, 0.26), rgba(255, 255, 255, 0.04)) !important;
}

#scheduleTab .big-calendar-weekdays span {
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
}

#scheduleTab .big-calendar-day {
  border: 0 !important;
  outline: 0 !important;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(248, 248, 255, 0.74)),
    rgba(255, 255, 255, 0.64) !important;
  box-shadow: none !important;
  background-clip: padding-box !important;
}

#scheduleTab .big-calendar-day:hover {
  border: 0 !important;
  outline: 0 !important;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(250, 249, 255, 0.9)),
    rgba(255, 255, 255, 0.82) !important;
  box-shadow: none !important;
}

#scheduleTab .big-calendar-day.muted {
  border: 0 !important;
  outline: 0 !important;
  background:
    linear-gradient(180deg, rgba(247, 248, 253, 0.66), rgba(240, 243, 250, 0.54)),
    rgba(246, 247, 252, 0.54) !important;
  box-shadow: none !important;
}

#scheduleTab .big-calendar-day.today,
#scheduleTab .big-calendar-day.selected {
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

#scheduleTab .big-calendar-day.selected {
  background:
    radial-gradient(circle at top right, rgba(123, 92, 255, 0.16), transparent 42%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 246, 255, 0.9)),
    rgba(255, 255, 255, 0.86) !important;
}

#scheduleTab .schedule-calendar-actions button,
#scheduleTab .schedule-calendar-view-tabs,
#scheduleTab .schedule-calendar-view-tab {
  border: 0 !important;
  outline: 0 !important;
}

#scheduleTab .schedule-calendar-view-tabs {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.82), rgba(246, 243, 255, 0.72)) !important;
  box-shadow: none !important;
}

#scheduleTab .schedule-calendar-view-tabs::after {
  content: none !important;
  display: none !important;
}

#scheduleTab .schedule-calendar-view-tab.active {
  box-shadow: none !important;
}

body.dark-theme #scheduleTab .full-page-panel,
body.dark-theme #scheduleTab .schedule-page-panel,
body.dark-theme #scheduleTab .schedule-calendar-layout,
body.dark-theme #scheduleTab .schedule-calendar-card,
body.dark-theme #scheduleTab .big-calendar-day,
body.dark-theme #scheduleTab .schedule-calendar-actions button,
body.dark-theme #scheduleTab .schedule-calendar-view-tabs,
body.dark-theme #scheduleTab .schedule-calendar-view-tab {
  border: 0 !important;
  outline: 0 !important;
}

body.dark-theme #scheduleTab .big-calendar-day {
  background: rgba(29, 34, 58, 0.74) !important;
  box-shadow: none !important;
}

body.dark-theme #scheduleTab .big-calendar-day.muted {
  background: rgba(24, 28, 48, 0.64) !important;
}

body.dark-theme #scheduleTab .big-calendar-day.selected {
  background:
    radial-gradient(circle at top right, rgba(123, 92, 255, 0.24), transparent 42%),
    rgba(33, 38, 66, 0.82) !important;
}

/* =========================================================
   Schedule: transparent month controls and calendar switcher
   Removes the visible pill backgrounds from the month nav and
   My Calendar / Family Calendar controls while keeping their
   positions, sizing and click targets intact.
   ========================================================= */

#scheduleTab .schedule-calendar-actions,
#scheduleTab .schedule-calendar-card-header,
#scheduleTab .schedule-calendar-tabs-below,
#scheduleTab .schedule-calendar-view-tabs {
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

#scheduleTab .schedule-calendar-actions button,
#scheduleTab #calendarPrevButton,
#scheduleTab #calendarTodayButton,
#scheduleTab #calendarNextButton {
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  color: #5f6a82 !important;
}

#scheduleTab .schedule-calendar-actions button:hover,
#scheduleTab #calendarPrevButton:hover,
#scheduleTab #calendarTodayButton:hover,
#scheduleTab #calendarNextButton:hover {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  color: #6d4df6 !important;
}

#scheduleTab #calendarTodayButton {
  min-width: 108px !important;
  padding-left: 8px !important;
  padding-right: 8px !important;
  font-size: 16px !important;
  font-weight: 850 !important;
  letter-spacing: -0.02em !important;
}

#scheduleTab .schedule-calendar-view-tabs::before,
#scheduleTab .schedule-calendar-view-tabs::after,
#scheduleTab .schedule-calendar-tabs-below::before,
#scheduleTab .schedule-calendar-tabs-below::after {
  content: none !important;
  display: none !important;
}

#scheduleTab .schedule-calendar-view-tab,
#scheduleTab .schedule-calendar-view-tab.active,
#scheduleTab .schedule-calendar-view-tab:not(.active),
#scheduleTab .schedule-calendar-view-tab:hover,
#scheduleTab .schedule-calendar-view-tab.active:hover {
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

#scheduleTab .schedule-calendar-view-tab {
  color: #66708f !important;
}

#scheduleTab .schedule-calendar-view-tab.active {
  color: #5b35f5 !important;
}

#scheduleTab .schedule-calendar-view-tab:hover {
  color: #5b35f5 !important;
}

body.dark-theme #scheduleTab .schedule-calendar-actions,
body.dark-theme #scheduleTab .schedule-calendar-card-header,
body.dark-theme #scheduleTab .schedule-calendar-tabs-below,
body.dark-theme #scheduleTab .schedule-calendar-view-tabs,
body.dark-theme #scheduleTab .schedule-calendar-actions button,
body.dark-theme #scheduleTab .schedule-calendar-view-tab,
body.dark-theme #scheduleTab .schedule-calendar-view-tab.active {
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

/* =========================================================
   Schedule: month controls below the calendar grid
   Moves the existing Previous / Month / Next row under the day
   boxes while keeping it centred and transparent.
   ========================================================= */

#scheduleTab .schedule-calendar-toolbar-below,
#scheduleTab .schedule-calendar-card-header.schedule-calendar-toolbar-below {
  width: 100% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 14px auto 0 !important;
  padding: 0 !important;
  gap: 0 !important;
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

#scheduleTab .schedule-calendar-toolbar-below .schedule-calendar-actions {
  width: auto !important;
  min-width: 0 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 0 auto !important;
  gap: 12px !important;
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

#scheduleTab .schedule-calendar-toolbar-below + .schedule-calendar-tabs-below {
  margin-top: 12px !important;
}

@media (max-width: 820px) {
  #scheduleTab .schedule-calendar-toolbar-below,
  #scheduleTab .schedule-calendar-card-header.schedule-calendar-toolbar-below {
    width: 100% !important;
    margin-top: 10px !important;
    margin-bottom: 0 !important;
    align-items: center !important;
    justify-content: center !important;
  }

  #scheduleTab .schedule-calendar-toolbar-below .schedule-calendar-actions {
    width: auto !important;
    margin: 0 auto !important;
  }

  #scheduleTab .schedule-calendar-toolbar-below + .schedule-calendar-tabs-below {
    margin-top: 8px !important;
  }
}


/* =========================================================
   Schedule: calendar switcher back to the top + tighter month nav
   Keeps all changes scoped to the schedule tab.
   ========================================================= */

#scheduleTab .schedule-calendar-card {
  display: grid !important;
  grid-template-rows: auto auto auto auto !important;
  align-content: start !important;
  row-gap: 0 !important;
}

#scheduleTab .schedule-calendar-tabs-top,
#scheduleTab .schedule-calendar-view-tabs.schedule-calendar-tabs-top {
  order: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  margin: 0 0 18px !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

#scheduleTab .schedule-calendar-tabs-top .schedule-calendar-view-tab {
  width: 100% !important;
  justify-content: center !important;
  min-height: 36px !important;
  height: 36px !important;
  padding: 0 8px !important;
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  font-weight: 850 !important;
}

#scheduleTab .big-calendar-grid {
  height: auto !important;
  min-height: 0 !important;
  grid-template-rows: repeat(6, minmax(0, auto)) !important;
}

#scheduleTab .schedule-calendar-toolbar-below,
#scheduleTab .schedule-calendar-card-header.schedule-calendar-toolbar-below {
  margin: 18px auto 0 !important;
  padding: 0 !important;
  min-height: 28px !important;
}

#scheduleTab .schedule-calendar-toolbar-below .schedule-calendar-actions {
  gap: 22px !important;
}

#scheduleTab .schedule-calendar-toolbar-below + .schedule-calendar-tabs-below {
  margin-top: 0 !important;
}

@media (max-width: 820px) {
  #scheduleTab .schedule-calendar-card {
    grid-template-rows: auto auto auto auto !important;
    align-content: start !important;
  }

  #scheduleTab .schedule-calendar-tabs-top,
  #scheduleTab .schedule-calendar-view-tabs.schedule-calendar-tabs-top {
    margin: 0 0 12px !important;
    gap: 8px !important;
  }

  #scheduleTab .schedule-calendar-tabs-top .schedule-calendar-view-tab {
    height: 34px !important;
    min-height: 34px !important;
    font-size: 13px !important;
    gap: 7px !important;
  }

  #scheduleTab .big-calendar-weekdays {
    margin-bottom: 8px !important;
  }

  #scheduleTab .schedule-calendar-toolbar-below,
  #scheduleTab .schedule-calendar-card-header.schedule-calendar-toolbar-below {
    margin-top: 16px !important;
    margin-bottom: 0 !important;
  }

  #scheduleTab .schedule-calendar-toolbar-below .schedule-calendar-actions {
    gap: 20px !important;
  }
}

/* =========================================================
   Schedule: full mobile canvas + month row above bottom nav
   Stretches the schedule screen to the device width/height and
   parks the month navigator just above the mobile nav.
   ========================================================= */

@media (max-width: 820px) {
  :root {
    --schedule-mobile-side-pad: 12px;
    --schedule-mobile-top-pad: max(10px, env(safe-area-inset-top));
    --schedule-mobile-nav-clearance: var(--fc-mobile-nav-height, calc(86px + env(safe-area-inset-bottom)));
    --schedule-month-nav-height: 34px;
    --schedule-month-nav-gap: 12px;
  }

  #scheduleTab,
  #scheduleTab.app-tab-panel,
  #scheduleTab.app-tab-panel.active {
    width: 100vw !important;
    height: 100dvh !important;
    min-height: 100dvh !important;
    max-height: 100dvh !important;
    inset: 0 !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
  }

  #scheduleTab .schedule-page-panel,
  #scheduleTab .full-page-panel.schedule-page-panel {
    width: 100vw !important;
    max-width: none !important;
    height: 100dvh !important;
    min-height: 100dvh !important;
    max-height: 100dvh !important;
    margin: 0 !important;
    padding: var(--schedule-mobile-top-pad) var(--schedule-mobile-side-pad) 0 !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
    display: block !important;
  }

  #scheduleTab .schedule-calendar-layout {
    width: 100% !important;
    max-width: none !important;
    height: 100% !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    display: block !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
  }

  #scheduleTab .schedule-calendar-side {
    display: none !important;
  }

  #scheduleTab .schedule-calendar-card {
    position: relative !important;
    width: 100% !important;
    max-width: none !important;
    height: 100% !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 0 0 calc(var(--schedule-mobile-nav-clearance) + var(--schedule-month-nav-height) + var(--schedule-month-nav-gap) + 10px) !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
    display: grid !important;
    grid-template-rows: auto auto minmax(0, 1fr) !important;
    align-content: stretch !important;
    row-gap: 8px !important;
  }

  #scheduleTab .schedule-calendar-tabs-top,
  #scheduleTab .schedule-calendar-view-tabs.schedule-calendar-tabs-top {
    width: 100% !important;
    height: 34px !important;
    min-height: 34px !important;
    max-height: 34px !important;
    margin: 0 !important;
    padding: 0 !important;
    flex: 0 0 auto !important;
    gap: 8px !important;
  }

  #scheduleTab .schedule-calendar-tabs-top .schedule-calendar-view-tab {
    height: 34px !important;
    min-height: 34px !important;
    padding: 0 4px !important;
    font-size: clamp(11px, 3.4vw, 13px) !important;
    white-space: nowrap !important;
  }

  #scheduleTab .big-calendar-weekdays {
    width: 100% !important;
    margin: 0 !important;
    gap: 6px !important;
    min-height: 18px !important;
    align-items: center !important;
  }

  #scheduleTab .big-calendar-weekdays span {
    padding: 0 !important;
    font-size: clamp(9px, 2.7vw, 11px) !important;
    line-height: 1 !important;
  }

  #scheduleTab .big-calendar-grid {
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    display: grid !important;
    grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
    grid-template-rows: repeat(6, minmax(0, 1fr)) !important;
    gap: clamp(5px, 1.7vw, 8px) !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
  }

  #scheduleTab .big-calendar-day {
    min-width: 0 !important;
    min-height: 0 !important;
    height: auto !important;
    padding: clamp(4px, 1.5vw, 7px) !important;
    border-radius: clamp(12px, 3.4vw, 17px) !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
  }

  #scheduleTab .big-calendar-day-header {
    min-width: 0 !important;
    min-height: 0 !important;
  }

  #scheduleTab .big-calendar-date-number {
    width: clamp(20px, 6.7vw, 29px) !important;
    height: clamp(15px, 6.7vw, 29px) !important;
    font-size: clamp(9px, 3.2vw, 13px) !important;
  }

  #scheduleTab .big-calendar-events,
  #scheduleTab .big-calendar-event,
  #scheduleTab .big-calendar-more {
    max-width: 100% !important;
    overflow: hidden !important;
  }

  #scheduleTab .schedule-calendar-toolbar-below,
  #scheduleTab .schedule-calendar-card-header.schedule-calendar-toolbar-below {
    position: fixed !important;
    left: var(--schedule-mobile-side-pad) !important;
    right: var(--schedule-mobile-side-pad) !important;
    bottom: calc(var(--schedule-mobile-nav-clearance) + var(--schedule-month-nav-gap)) !important;
    z-index: 1190 !important;
    width: auto !important;
    height: var(--schedule-month-nav-height) !important;
    min-height: var(--schedule-month-nav-height) !important;
    max-height: var(--schedule-month-nav-height) !important;
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: transparent !important;
    border: 0 !important;
    outline: 0 !important;
    box-shadow: none !important;
    pointer-events: none !important;
  }

  #scheduleTab .schedule-calendar-toolbar-below .schedule-calendar-actions {
    pointer-events: auto !important;
    width: min(100%, 260px) !important;
    max-width: 260px !important;
    height: 100% !important;
    margin: 0 auto !important;
    padding: 0 !important;
    display: grid !important;
    grid-template-columns: 44px minmax(96px, 1fr) 44px !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 14px !important;
    background: transparent !important;
  }

  #scheduleTab #calendarPrevButton,
  #scheduleTab #calendarNextButton,
  #scheduleTab #calendarTodayButton {
    height: var(--schedule-month-nav-height) !important;
    min-height: var(--schedule-month-nav-height) !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }

  #scheduleTab #calendarPrevButton,
  #scheduleTab #calendarNextButton {
    width: 44px !important;
    min-width: 44px !important;
  }

  #scheduleTab #calendarTodayButton {
    width: auto !important;
    min-width: 96px !important;
    font-size: clamp(11px, 4vw, 17px) !important;
  }
}

@media (max-width: 380px) {
  :root {
    --schedule-mobile-side-pad: 8px;
    --schedule-month-nav-gap: 2px;
  }

  #scheduleTab .schedule-calendar-card {
    row-gap: 6px !important;
  }

  #scheduleTab .schedule-calendar-toolbar-below .schedule-calendar-actions {
    width: min(100%, 238px) !important;
    grid-template-columns: 40px minmax(88px, 1fr) 40px !important;
    gap: 10px !important;
  }
}

/* =========================================================
   Schedule: mobile side breathing room
   Adds left/right padding while preserving full-height layout and
   keeping the month navigator aligned above the bottom nav.
   ========================================================= */

@media (max-width: 820px) {
  :root {
    --schedule-mobile-side-pad: clamp(18px, 5.4vw, 24px);
  }

  #scheduleTab .schedule-page-panel,
  #scheduleTab .full-page-panel.schedule-page-panel {
    padding-left: var(--schedule-mobile-side-pad) !important;
    padding-right: var(--schedule-mobile-side-pad) !important;
  }

  #scheduleTab .schedule-calendar-toolbar-below,
  #scheduleTab .schedule-calendar-card-header.schedule-calendar-toolbar-below {
    left: var(--schedule-mobile-side-pad) !important;
    right: var(--schedule-mobile-side-pad) !important;
  }
}

@media (max-width: 380px) {
  :root {
    --schedule-mobile-side-pad: 26px;
  }
}
