/* calendar.css — Calendar grid, day cells, detail panels, and calendar badges */

.cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 3px
}

.cal-h {
    font-size: 10px;
    font-weight: 700;
    color: var(--text3);
    text-align: center;
    padding: 8px 0;
    text-transform: uppercase
}

.cal-d {
    aspect-ratio: 1;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: var(--text2);
    cursor: pointer;
    transition: all .12s;
    border: 1px solid transparent;
    gap: 3px;
    font-weight: 500;
    position: relative
}

.cal-d:hover {
    border-color: var(--border);
    background: var(--bg3)
}

.cal-d.hp {
    background: var(--accent-bg);
    border-color: var(--accent);
    color: var(--accent);
    font-weight: 700
}

.cal-dots {
    display: flex;
    gap: 3px
}

.cd {
    width: 5px;
    height: 5px;
    border-radius: 50%
}

.cd-x {
    background: #0f1419
}

.cd-tg {
    background: #0088cc
}

.cd-li {
    background: #0a66c2
}

.cal-d.cal-today {
    border: 2px solid var(--accent) !important;
    box-shadow: 0 0 0 2px rgba(108, 92, 231, 0.15);
    position: relative
}

.cal-d.cal-today::after {
    content: 'Today';
    position: absolute;
    top: 2px;
    right: 3px;
    font-size: 6px;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.3px
}

.cal-d.cal-selected {
    background: var(--accent) !important;
    color: #fff !important;
    border-color: var(--accent) !important
}

.cal-d.cal-selected .cd-x { background: #fff }
.cal-d.cal-selected .cd-tg { background: rgba(255,255,255,0.7) }
.cal-d.cal-selected .cd-li { background: rgba(255,255,255,0.5) }
.cal-d.cal-selected .cal-badge { background: #fff; color: var(--accent) }

.cal-badge {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-size: 8px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1
}

.cal-detail {
    background: var(--bg3);
    border-radius: 10px;
    padding: 14px 16px;
    margin-top: 12px;
    display: none
}

.cal-detail.show {
    display: block
}

.cal-detail-title {
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 8px
}

.cal-detail-posts {
    display: flex;
    flex-direction: column;
    gap: 8px
}

.cal-detail-post {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg2);
    border-radius: 8px;
    padding: 10px 12px;
    border: 1px solid var(--border)
}

.cal-detail-post .ch {
    flex-shrink: 0
}

.cal-detail-post-text {
    flex: 1;
    font-size: 12px;
    color: var(--text);
    line-height: 1.4
}

.cal-detail-post-time {
    font-size: 11px;
    color: var(--text3);
    white-space: nowrap
}

.cal-detail-post-status {
    font-size: 10px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 6px;
    white-space: nowrap
}

.cal-detail-post-status.approved {
    color: var(--green);
    background: var(--green-bg)
}

.cal-detail-post-status.pending {
    color: var(--orange);
    background: var(--orange-bg)
}

.cal-detail-add {
    margin-top: 10px;
    display: flex;
    justify-content: flex-end
}

.cal-detail-add button {
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 7px 16px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: opacity .15s
}

.cal-detail-add button:hover {
    opacity: 0.85
}
