/* ═══════════════════════════════════════════════════════════════════════
   MATERRA CALENDAR  —  css/calendar.css
═══════════════════════════════════════════════════════════════════════ */


/* ── INDEX PAGE WIDGET ─────────────────────────────────────────────────── */

.calendar-widget {
  border: 1.5px solid var(--gold);
  background: rgba(255, 255, 255, 0.18);
  margin: 0 0 18px 0;
  overflow: hidden;
}

/* Navy header bar */
.cal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 14px;
  background: var(--navy-deep);
  color: #fff;
}

.cal-era {
  font-family: 'Cinzel', serif;
  font-size: 8.5px;
  letter-spacing: 3px;
  text-transform: uppercase;
  opacity: 0.7;
}

.cal-year {
  font-family: 'Cinzel Decorative', serif;
  font-size: 14px;
  color: var(--gold-light);
  letter-spacing: 1px;
}

/* Zodiac strip */
.cal-sign {
  text-align: center;
  padding: 5px 14px;
  font-family: 'IM Fell English', Georgia, serif;
  font-style: italic;
  font-size: 12.5px;
  color: var(--navy);
  background: rgba(184, 144, 44, 0.1);
  border-bottom: 1px solid rgba(184, 144, 44, 0.3);
}

/* Date block — ordered: season, month, week, weekday, day */
.cal-date-block {
  padding: 12px 14px 10px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cal-season {
  font-family: 'Cinzel', serif;
  font-size: 9px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--gold-deep);
  opacity: 0.9;
}

/* Month row: "Month 3 · Trelus" */
.cal-month-row {
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 7px;
}

.cal-month-num {
  font-family: 'Cinzel', serif;
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--navy);
  opacity: 0.7;
}

.cal-month-sep {
  color: var(--gold);
  opacity: 0.6;
}

.cal-month-of {
  font-family: 'Cinzel', serif;
  font-size: 16px;
  font-weight: 600;
  color: var(--navy);
}

.cal-week {
  font-family: 'Cinzel', serif;
  font-size: 8.5px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--navy);
  opacity: 0.45;
}

.cal-weekday {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--navy-deep);
  letter-spacing: 0.5px;
}

/* "❖ the 28th ❖" */
.cal-day-row {
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 10px;
  margin-top: 4px;
}

.cal-ornament {
  color: var(--gold);
  font-size: 12px;
  opacity: 0.65;
}

.cal-day-num {
  font-family: 'Cinzel Decorative', serif;
  font-size: 20px;
  color: var(--gold-deep);
  line-height: 1;
}

/* Controls: Prev | Save | Next */
.cal-controls {
  display: flex;
  border-top: 1px solid rgba(184, 144, 44, 0.4);
  margin-top: 10px;
}

.cal-btn {
  flex: 1;
  padding: 9px 10px;
  border: none;
  border-right: 1px solid rgba(184, 144, 44, 0.3);
  background: transparent;
  color: var(--navy);
  cursor: pointer;
  font-family: 'Cinzel', serif;
  font-size: 9.5px;
  letter-spacing: 1px;
  transition: background 0.15s, color 0.15s;
}

.cal-btn:last-child { border-right: none; }

.cal-btn:hover {
  background: rgba(184, 144, 44, 0.14);
  color: var(--navy-deep);
}

.cal-btn:active { background: rgba(184, 144, 44, 0.28); }

.cal-btn:disabled {
  cursor: default;
  opacity: 0.7;
}

/* Save button — slightly highlighted */
.cal-btn-save {
  font-weight: 700;
  color: var(--gold-deep);
  letter-spacing: 1.5px;
}

.cal-btn-save:hover {
  background: rgba(184, 144, 44, 0.22);
  color: var(--gold-deep);
}


/* ── CHARACTER SHEET BAR ───────────────────────────────────────────────── */

.calendar-sheet-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 7px 30px;
  margin-bottom: 18px;
  border: 1px solid rgba(184, 144, 44, 0.4);
  background: rgba(184, 144, 44, 0.06);
  font-family: 'IM Fell English', Georgia, serif;
  font-style: italic;
  font-size: 12.5px;
  color: var(--navy);
  line-height: 1.4;
}

.cal-sheet-lbl {
  font-family: 'Cinzel', serif;
  font-style: normal;
  font-size: 8.5px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--gold-deep);
  white-space: nowrap;
  flex-shrink: 0;
}

.cal-sheet-sep {
  color: var(--gold);
  font-style: normal;
  flex-shrink: 0;
}

.cal-sheet-date { color: var(--ink); flex: 1; min-width: 0; }


/* ── MOBILE ────────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
  .cal-month-of  { font-size: 14px; }
  .cal-weekday   { font-size: 12px; }
  .cal-day-num   { font-size: 17px; }
  .cal-btn       { font-size: 9px; padding: 8px 6px; }

  .calendar-sheet-bar { padding: 6px 10px; font-size: 11.5px; }
  .cal-sheet-lbl, .cal-sheet-sep { display: none; }
}


/* ── SHARED CAMPAIGN TRAVEL ─────────────────────────────────────────────── */

.cal-travel {
  border-top: 1px solid rgba(184, 144, 44, 0.38);
  background: rgba(184, 144, 44, 0.055);
  padding: 8px 10px 9px;
}

.cal-travel-heading {
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 6px;
}

.cal-travel-label {
  color: var(--navy);
  font-family: 'Cinzel', serif;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 1.7px;
  opacity: .78;
  text-transform: uppercase;
}

.cal-travel-count {
  color: var(--gold-deep);
  font-family: 'Cinzel Decorative', serif;
  font-size: 15px;
  font-weight: 700;
}

.cal-travel-controls {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 5px;
}

.cal-travel-btn {
  padding: 5px 7px;
  border: 1px solid rgba(184, 144, 44, 0.54);
  border-radius: 2px;
  background: rgba(255, 253, 245, 0.16);
  color: var(--navy);
  cursor: pointer;
  font-family: 'Cinzel', serif;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .45px;
  transition:
    background .15s ease,
    border-color .15s ease,
    color .15s ease;
}

.cal-travel-btn:hover,
.cal-travel-btn:focus-visible {
  background: rgba(184, 144, 44, 0.16);
  border-color: var(--gold-deep);
  color: var(--navy-deep);
  outline: none;
}

.cal-travel-btn:disabled {
  cursor: default;
  opacity: .72;
}

@media (max-width: 768px) {
  .cal-travel {
    padding: 7px 7px 8px;
  }

  .cal-travel-controls {
    gap: 4px;
  }

  .cal-travel-btn {
    flex: 1 1 calc(50% - 4px);
    padding: 6px 5px;
    font-size: 7.5px;
  }
}


/* ── ADJUSTABLE DAYS TRAVELED ───────────────────────────────────────────── */

.cal-travel-count-input {
  width: 58px;
  height: 26px;
  padding: 0 4px;
  border: none;
  border-bottom: 1px dotted rgba(184, 144, 44, 0.66);
  border-radius: 0;
  background: transparent;
  color: var(--gold-deep);
  font-family: 'Cinzel Decorative', serif;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
  outline: none;
  appearance: textfield;
  -moz-appearance: textfield;
}

.cal-travel-count-input:focus {
  border-bottom-color: var(--gold-deep);
  background: rgba(255, 253, 245, 0.22);
}

.cal-travel-count-input::-webkit-inner-spin-button,
.cal-travel-count-input::-webkit-outer-spin-button {
  margin: 0;
  -webkit-appearance: none;
}

.cal-sheet-travel {
  color: var(--gold-deep);
  font-family: 'Cinzel', serif;
  font-size: 8.5px;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  white-space: nowrap;
}

.cal-sheet-travel strong {
  color: var(--navy-deep);
  font-family: 'Cinzel Decorative', serif;
  font-size: 11px;
}

@media (max-width: 768px) {
  .cal-travel-count-input {
    width: 52px;
    height: 24px;
    font-size: 14px;
  }

  .cal-sheet-travel {
    width: 100%;
    font-size: 8px;
    text-align: right;
  }

  .cal-sheet-travel strong {
    font-size: 10px;
  }
}


/* ── SUBTLE CALENDAR CORRECTION CONTROLS ─────────────────────────────────
   Replaces the chunky travel buttons with thin inline − / + controls. */

.cal-travel-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 11px;
}

.cal-travel-step {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.cal-travel-step-label {
  min-width: 36px;
  color: var(--navy);
  font-family: 'Cinzel', serif;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .8px;
  opacity: .72;
  text-align: center;
  text-transform: uppercase;
}

.cal-travel-step-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 15px;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--gold-deep);
  cursor: pointer;
  font-family: 'Cinzel', serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  opacity: .52;
  transition:
    color .15s ease,
    opacity .15s ease,
    transform .15s ease;
}

.cal-travel-step-btn:hover,
.cal-travel-step-btn:focus-visible {
  color: var(--navy-deep);
  opacity: 1;
  outline: none;
  transform: scale(1.08);
}

.cal-travel-step-btn:disabled {
  cursor: default;
  opacity: .72;
  transform: none;
}

@media (max-width: 768px) {
  .cal-travel-controls {
    gap: 8px;
  }

  .cal-travel-step {
    gap: 3px;
  }

  .cal-travel-step-label {
    min-width: 31px;
    font-size: 7.5px;
  }

  .cal-travel-step-btn {
    width: 14px;
    height: 14px;
    font-size: 13px;
  }
}


/* ── INLINE CALENDAR DATE CORRECTION CONTROLS ────────────────────────────
   Thin gold − / + controls live directly beside Month, Week, and Day. */

.cal-inline-adjust-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}

.cal-week-row {
  gap: 6px;
}

.cal-day-row {
  gap: 9px;
}

.cal-inline-adjust {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 auto !important;
  width: 16px !important;
  min-width: 16px !important;
  max-width: 16px !important;
  height: 16px !important;
  padding: 0 !important;
  margin: 0 !important;
  border: none !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--gold-deep) !important;
  cursor: pointer;
  font-family: 'Cinzel', serif;
  font-size: 14px !important;
  font-weight: 700;
  line-height: 1 !important;
  opacity: .52;
  transition:
    color .15s ease,
    opacity .15s ease,
    transform .15s ease;
}

.cal-inline-adjust:hover,
.cal-inline-adjust:focus-visible {
  background: transparent !important;
  color: var(--navy-deep) !important;
  opacity: 1;
  outline: none !important;
  transform: scale(1.08);
}

.cal-inline-adjust:disabled {
  cursor: default;
  opacity: .72;
  transform: none;
}

.cal-travel {
  padding-bottom: 6px;
}

.cal-travel-heading {
  margin-bottom: 0;
}

@media (max-width: 768px) {
  .cal-inline-adjust-row {
    gap: 5px;
  }

  .cal-day-row {
    gap: 7px;
  }

  .cal-inline-adjust {
    width: 15px !important;
    min-width: 15px !important;
    max-width: 15px !important;
    height: 15px !important;
    font-size: 13px !important;
  }

  .cal-travel {
    padding-bottom: 5px;
  }
}
