/* =========================================================
   DRAWER
========================================================= */

.drawer-overlay {
    position: fixed;
    inset: 0;
    background: var(--overlay);
    backdrop-filter: blur(2px);
    z-index: 200;
    display: none;
}

.drawer-overlay.show {
    display: block;
}

.drawer {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: min(520px, 92vw);
    background: white;
    box-shadow: -12px 0 35px rgba(15,23,42,.12);
    display: flex;
    flex-direction: column;
    animation: drawerIn .18s ease;
}

@keyframes drawerIn {
    from { transform: translateX(20px); opacity: .7; }
    to { transform: translateX(0); opacity: 1; }
}

.drawer-header {
    padding: 17px 18px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    gap: 15px;
}

.drawer-title {
    font-size: 14px;
    font-weight: 800;
}

.drawer-subtitle {
    color: var(--text-3);
    font-size: 10px;
    margin-top: 3px;
}

.drawer-body {
    padding: 18px;
    overflow-y: auto;
    flex: 1;
}

.drawer-footer {
    padding: 12px 18px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
    gap: 7px;
}

/* ---------- reuse a published post (cross-post / repost) ---------- */

.reuse-modes {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    font-size: 12px;
    color: var(--text-2);
}

.reuse-modes label,
.reuse-channels label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
}

.reuse-channels {
    display: grid;
    gap: 6px;
    margin-top: 10px;
    font-size: 12px;
}

/* A channel this post can't reach in the chosen mode: still listed, with why. */
.reuse-channels label.is-blocked {
    color: var(--text-3);
    cursor: not-allowed;
}

.reuse-hint {
    color: var(--text-3);
    font-size: 10px;
}

.reuse-when {
    margin-top: 10px;
}

.reuse-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin: 10px 0;
}

/* Delete sits apart from the actions people reach for without looking. */
.drawer-delete {
    margin-right: auto;
    color: var(--danger);
}

.drawer-delete:hover {
    background: var(--danger-soft);
}
