/* DJ Manager — Availability Calendar (mini) */
.djm-avail-wrap {
    font-family: -apple-system, 'Segoe UI', sans-serif;
    max-width: 220px;
    margin: 0 auto;
}

/* ── Calendar container ── */
.djm-cal {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,.10);
    overflow: hidden;
    border: 1px solid #e5e7eb;
}

/* ── Header bar ── */
.djm-cal-header {
    background: linear-gradient(135deg, #1a1209, #2d2318);
    padding: 6px 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
}
.djm-cal-month-label {
    font-size: 11px;
    font-weight: 800;
    color: #c9a96e;
    flex: 1;
    text-align: center;
}
.djm-cal-nav {
    background: rgba(201,169,110,.15);
    border: 1px solid rgba(201,169,110,.3);
    color: #c9a96e;
    border-radius: 4px;
    width: 20px;
    height: 20px;
    cursor: pointer;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s;
    flex-shrink: 0;
    line-height: 1;
    padding: 0;
}
.djm-cal-nav:hover { background: rgba(201,169,110,.3); }

/* ── Weekday row ── */
.djm-cal-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
}
.djm-cal-wd {
    text-align: center;
    padding: 3px 0;
    font-size: 8px;
    font-weight: 700;
    text-transform: uppercase;
    color: #9ca3af;
}

/* ── Grid ── */
.djm-cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1px;
    background: #e5e7eb;
    padding: 1px;
}
.djm-cal-day {
    background: #fff;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    font-weight: 600;
    cursor: pointer;
    transition: background .12s;
    position: relative;
    min-height: 22px;
    user-select: none;
}
.djm-cal-day.empty  { background: #f9fafb; cursor: default; }
.djm-cal-day.past   { color: #d1d5db; cursor: not-allowed; background: #fafafa; }
.djm-cal-day.today  { font-weight: 900; }
.djm-cal-day.today::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px; height: 3px;
    border-radius: 50%;
    background: #c9a96e;
}
.djm-cal-day.available:hover { background: #f0fdf4; color: #15803d; }
.djm-cal-day.booked {
    background: #fff1f2;
    cursor: not-allowed;
}
.djm-cal-day.booked::before {
    content: '';
    position: absolute;
    inset: 3px;
    border-radius: 50%;
    background: #fee2e2;
}
.djm-cal-day.booked span { position: relative; z-index: 1; color: #f87171; }
.djm-cal-day.selected { background: #c9a96e; color: #fff !important; }
.djm-cal-day.selected span { color: #fff !important; }

/* ── Loading overlay ── */
.djm-cal-loading {
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    border-radius: 8px;
}

/* ── Legend ── */
.djm-cal-legend {
    display: flex;
    gap: 8px;
    padding: 5px 8px;
    border-top: 1px solid #e5e7eb;
    justify-content: center;
    flex-wrap: wrap;
}
.djm-cal-legend-item {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 8px;
    color: #6b7280;
    font-weight: 600;
}
.djm-cal-legend-dot {
    width: 7px; height: 7px;
    border-radius: 2px;
    flex-shrink: 0;
}

/* ── Result message ── */
.djm-avail-result {
    margin-top: 8px;
    border-radius: 6px;
    padding: 8px 10px;
    font-size: 11px;
    font-weight: 700;
    text-align: center;
    display: none;
    animation: djm-fadein .2s ease;
}
.djm-avail-result.available  { background:#f0fdf4; border:1px solid #86efac; color:#15803d; }
.djm-avail-result.unavailable{ background:#fff1f2; border:1px solid #fca5a5; color:#dc2626; }
.djm-avail-result p { margin:0 0 6px; font-size:11px; }
.djm-avail-result .djm-avail-date { font-size:10px; font-weight:600; opacity:.7; margin-bottom:6px; }
.djm-avail-btn {
    display:inline-block; padding:5px 12px;
    border-radius:5px; font-size:11px; font-weight:700;
    text-decoration:none; cursor:pointer; border:none;
    font-family:inherit; transition:all .15s;
}
.djm-avail-btn.green { background:#16a34a; color:#fff; }
.djm-avail-btn.green:hover { background:#15803d; color:#fff; }
.djm-avail-btn.red   { background:#dc2626; color:#fff; }
.djm-avail-btn.red:hover   { background:#b91c1c; color:#fff; }

/* ── Spinner ── */
.djm-avail-checking { text-align:center; padding:6px; color:#9ca3af; font-size:10px; display:none; }
@keyframes djm-fadein { from{opacity:0;transform:translateY(3px)} to{opacity:1;transform:none} }
.djm-avail-spin {
    width:12px; height:12px;
    border:2px solid #e5e7eb; border-top-color:#c9a96e;
    border-radius:50%; animation:djm-spin .7s linear infinite;
    display:inline-block; vertical-align:middle; margin-right:4px;
}
@keyframes djm-spin { to{transform:rotate(360deg)} }
