/* ============================================================
   CALENDAR — Availability calendar + expandable event cards
   ============================================================ */

.cal-container { max-width: 700px; margin: 0 auto; }
.cal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.cal-nav { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--border); background: var(--white); display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all 0.2s; }
.cal-nav:hover { border-color: var(--gold); color: var(--gold); }
.cal-nav svg { width: 16px; height: 16px; }
.cal-reload svg { transition: transform 0.6s ease; }
.cal-reload.spinning svg { transform: rotate(360deg); }
.cal-month { font-family: 'Cormorant Garamond', serif; font-size: 22px; font-weight: 500; color: var(--charcoal); }

/* ========== MONTH/YEAR PICKER ========== */
.cal-month-toggle { background: transparent; border: 1px solid transparent; cursor: pointer; padding: 6px 16px; border-radius: 999px; display: inline-flex; align-items: center; gap: 8px; font-family: 'Cormorant Garamond', serif; font-size: 22px; font-weight: 500; color: var(--charcoal); transition: background 0.18s, border-color 0.18s; }
.cal-month-toggle:hover { background: var(--gold-bg); }
.cal-month-toggle[aria-expanded="true"] { background: var(--gold-bg); border-color: var(--gold-pale); }
.cal-month-chevron { width: 14px; height: 14px; opacity: 0.7; transition: transform 0.18s; }
.cal-month-toggle[aria-expanded="true"] .cal-month-chevron { transform: rotate(180deg); }

.month-picker { position: absolute; top: 70px; left: 50%; transform: translateX(-50%); z-index: 20; background: var(--white); border: 1px solid var(--border-light); border-radius: 14px; box-shadow: 0 12px 32px rgba(0,0,0,0.12); padding: 16px 18px 12px; min-width: 300px; }
.month-picker[hidden] { display: none; }
.month-picker-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--border-light); }
.month-picker-year { font-family: 'Cormorant Garamond', serif; font-size: 18px; font-weight: 500; color: var(--charcoal); }
.month-picker-nav { background: transparent; border: none; cursor: pointer; width: 28px; height: 28px; border-radius: 8px; color: var(--muted); display: inline-flex; align-items: center; justify-content: center; transition: background 0.15s, color 0.15s; }
.month-picker-nav:hover { background: var(--cream); color: var(--charcoal); }
.month-picker-nav svg { width: 14px; height: 14px; }
.month-picker-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 8px; }
.month-picker-cell { background: transparent; border: 1px solid transparent; cursor: pointer; padding: 12px 0; border-radius: 10px; font-family: 'Outfit', sans-serif; font-size: 11px; font-weight: 600; letter-spacing: 0.06em; color: var(--charcoal); transition: background 0.15s, color 0.15s, border-color 0.15s; }
.month-picker-cell:hover { background: var(--gold); color: var(--white); }
.month-picker-cell.is-current { border-color: var(--gold); background: var(--white); color: var(--charcoal); }
.month-picker-cell.is-current:hover { background: var(--gold); color: var(--white); }
.month-picker-today { width: 100%; background: transparent; border: none; cursor: pointer; color: var(--gold); font-family: 'Outfit', sans-serif; font-weight: 500; font-size: 12px; padding: 10px 0 4px; border-top: 1px solid var(--border-light); margin-top: 4px; letter-spacing: 0.02em; transition: background 0.15s; }
.month-picker-today:hover { background: var(--gold-bg); border-radius: 0 0 8px 8px; }

.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-dow { text-align: center; font-size: 10px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); padding: 8px 0; }
.cal-cell { aspect-ratio: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; border-radius: 10px; font-size: 14px; font-weight: 400; color: var(--charcoal); cursor: pointer; transition: all 0.15s; position: relative; gap: 2px; }
.cal-cell:hover:not(.past):not(.empty) { background: var(--cream); }
.cal-cell.past { opacity: 0.25; cursor: default; }
.cal-cell.today { border: 2px solid var(--gold); font-weight: 600; }
.cal-cell.has-event { background: var(--red-bg); color: var(--red); font-weight: 600; }
.cal-cell.has-event:hover { background: #fbe3e1; }
.cal-cell.blocked { background: var(--cream-dark); color: var(--muted); }
.cal-cell.selected { background: var(--gold-bg); border: 2px solid var(--gold); }
.cal-dots { display: flex; gap: 3px; height: 5px; }
.cal-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--gold); }

.cal-legend { display: flex; gap: 20px; margin-top: 20px; justify-content: center; flex-wrap: wrap; }
.cal-legend-item { display: flex; align-items: center; gap: 6px; font-size: 11px; color: var(--muted); font-weight: 300; }
.cal-legend-dot { width: 10px; height: 10px; border-radius: 4px; }

.cal-detail { background: var(--white); border: 1px solid var(--border-light); border-radius: 16px; padding: 24px; margin-top: 20px; min-height: 120px; }
.cal-detail-title { font-family: 'Cormorant Garamond', serif; font-size: 18px; font-weight: 500; color: var(--charcoal); margin-bottom: 16px; }
.cal-detail-empty { font-size: 13px; color: var(--muted); font-weight: 300; text-align: center; padding: 20px 0; }
.cal-detail-section { margin-bottom: 16px; }
.cal-detail-section:last-child { margin-bottom: 0; }
.cal-detail-label { font-size: 10px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.cal-detail-event { background: var(--red-bg); border-radius: 8px; padding: 10px 14px; font-size: 13px; color: var(--red); font-weight: 500; }

.evt-card { background: var(--gold-bg); border-radius: 10px; margin-bottom: 8px; overflow: hidden; cursor: pointer; transition: background 0.15s; border: 1px solid rgba(184, 134, 11, 0.15); }
.evt-card:hover { background: #fbf3e0; }
.evt-card:last-child { margin-bottom: 0; }
.evt-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; gap: 12px; }
.evt-head-main { font-size: 13px; color: var(--charcoal); font-weight: 600; flex: 1; min-width: 0; }
.evt-head-main strong { color: var(--gold); }
.evt-head-meta { font-weight: 400; opacity: 0.7; color: var(--charcoal); }
.evt-head-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.evt-hora { font-size: 13px; color: var(--gold); font-weight: 700; }
.evt-chevron { font-size: 12px; color: var(--gold); opacity: 0.7; transition: transform 0.2s; display: inline-block; }
.evt-card.open .evt-chevron { transform: rotate(180deg); }
.evt-body { display: none; padding: 12px 14px 14px; border-top: 1px solid rgba(184, 134, 11, 0.18); }
.evt-card.open .evt-body { display: block; }
.evt-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 4px 0; font-size: 12px; color: var(--charcoal); }
.evt-k { font-size: 10px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); flex-shrink: 0; }
.evt-v { text-align: right; font-weight: 500; word-break: break-word; }
.evt-v a { color: var(--gold); text-decoration: none; }
.evt-v a:hover { text-decoration: underline; }
.evt-total { color: var(--gold); font-weight: 700; font-size: 14px; }
.evt-pkg { margin: 10px 0 4px; background: var(--white); border-radius: 8px; padding: 12px 14px; border: 1px solid rgba(184, 134, 11, 0.12); }
.evt-pkg-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.evt-pkg-name { font-family: 'Cormorant Garamond', serif; font-size: 16px; font-weight: 600; color: var(--charcoal); }
.evt-pkg-list { list-style: none; padding: 0; margin: 6px 0 0; display: flex; flex-direction: column; gap: 3px; }
.evt-pkg-list li { font-size: 12px; color: var(--charcoal); opacity: 0.85; padding-left: 16px; position: relative; }
.evt-pkg-list li::before { content: '✓'; position: absolute; left: 0; color: var(--gold); font-weight: 600; }

.evt-adic-wrap { margin-top: 12px; }
.evt-adic-label { font-size: 10px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.evt-adic-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 8px; }
.evt-adic-card { background: var(--white); border: 1px solid rgba(184, 134, 11, 0.18); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 4px; }
.evt-adic-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.evt-adic-name { font-size: 12px; font-weight: 600; color: var(--charcoal); }
.evt-adic-price { font-size: 12px; font-weight: 700; color: var(--gold); }
.evt-adic-detalle { font-size: 11px; color: var(--muted); font-weight: 400; }
.cal-detail-visit { background: var(--gold-bg); border-radius: 8px; padding: 8px 14px; font-size: 13px; color: var(--charcoal); font-weight: 400; margin-bottom: 6px; display: flex; align-items: center; gap: 8px; }
.cal-detail-visit-time { font-weight: 600; color: var(--gold); min-width: 50px; }
.cal-detail-blocked { background: var(--cream-dark); border-radius: 8px; padding: 10px 14px; font-size: 13px; color: var(--muted); }

/* Calendar loading overlay (extracted from inline styles when the
   refactor switched to the `hidden` attribute) */
#cal-loading { position: absolute; inset: 0; background: rgba(255,255,255,0.8); display: flex; align-items: center; justify-content: center; border-radius: 16px; }
