/* ====== REDAKTOR PANEL — GRID (bez zmian w PHP) ====== */
/* ====== GÓRNY PANEL PRZYCISKÓW — wyrównanie i proporcje ====== */
.rp-wrap-full .rp-actions {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)) !important;
    gap: 10px !important;
    margin-bottom: 20px !important;
    justify-content: center !important;
}

.rp-wrap-full .rp-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 10px 0 !important;
    border-radius: 10px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    background: #f9fafb !important;
    border: 1px solid #d1d5db !important;
    color: #111827 !important;
    text-decoration: none !important;
    transition: all 0.2s ease !important;
    min-height: 44px !important;
}

.rp-wrap-full .rp-btn:hover {
    background: #f3f4f6 !important;
    border-color: #cbd5e1 !important;
}

.rp-wrap-full .rp-btn-danger {
    background: #fef2f2 !important;
    color: #b91c1c !important;
    border-color: #fca5a5 !important;
}

.rp-wrap-full .rp-btn-danger:hover {
    background: #fee2e2 !important;
}

/* ====== Nagłówek "Panel redaktora" – dopasowany do motywu Newsio ====== */
.rp-wrap-full .rp-title {
    font-family: "Khand", "Inter", "Segoe UI", sans-serif !important;
    font-size: clamp(2.8rem, 5vw, 3.2rem) !important;
    font-weight: 700 !important;
    color: #222 !important;
    letter-spacing: 0.5px !important;
    text-transform: uppercase !important;
    border-bottom: 3px solid #d40004 !important;
    /* główny kolor motywu */
    padding-bottom: 8px !important;
    margin-bottom: 18px !important;
}

@media (max-width: 768px) {
    .rp-wrap-full .rp-title {
        text-align: center !important;
        font-size: 1.8rem !important;
        border-bottom-width: 2px !important;
        padding-bottom: 6px !important;
        margin-bottom: 14px !important;
    }
}
@media (max-width: 768px) {

    /* Karta = grid: [thumb | title] / [status] / [actions] */
    .rp-wrap-full .rp-table tbody tr {
        display: grid !important;
        grid-template-columns: 80px 1fr !important;
        grid-template-rows: auto auto auto !important;
        grid-template-areas:
            "thumb title"
            "status status"
            "actions actions" !important;
        gap: 10px 12px !important;

        background: #fff !important;
        border: 1px solid #e5e7eb !important;
        border-radius: 14px !important;
        padding: 14px !important;
        margin: 0 !important;
        box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05) !important;
    }

    /* wyłączenie nagłówka tabeli */
    .rp-wrap-full .rp-table thead {
        display: none !important;
    }

    /* zerowanie defaultowych styli komórek */
    .rp-wrap-full .rp-table td {
        border: 0 !important;
        padding: 0 !important;
        vertical-align: middle !important;
    }

    /* przypisanie komórek do obszarów siatki */
    .rp-wrap-full .rp-table td:first-child {
        grid-area: thumb !important;
    }

    .rp-wrap-full .rp-table td:nth-child(2) {
        grid-area: title !important;
    }

    .rp-wrap-full .rp-table td:nth-child(6) {
        grid-area: actions !important;
    }

    /* ukryj oryginalne kolumny Status / Wyświetlenia / Data */
    .rp-wrap-full .rp-table td:nth-child(3),
    .rp-wrap-full .rp-table td:nth-child(4),
    .rp-wrap-full .rp-table td:nth-child(5) {
        display: none !important;
    }

    /* MINIATURA */
    .rp-wrap-full .rp-table td:first-child img {
        width: 70px !important;
        height: 70px !important;
        border-radius: 10px !important;
        object-fit: cover !important;
        border: 1px solid #eee !important;
        display: block !important;
    }

    /* TYTUŁ obok miniatury */
    .rp-wrap-full .rp-table td:nth-child(2) {
        display: flex !important;
        align-items: center !important;
    }

    .rp-wrap-full .rp-table td:nth-child(2) strong {
        font-size: 0.9rem !important;
        font-weight: 600 !important;
        color: #111827 !important;
        line-height: 1.3 !important;
        font-family: "Inter", system-ui, sans-serif !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    /* STATUS: syntetyczny pasek między tytułem a przyciskami */
    .rp-wrap-full .rp-table tbody tr::after {
        grid-area: status !important;
        content: attr(data-status);
        display: block !important;
        padding: 6px 10px !important;
        border-radius: 8px !important;
        font-size: 13px !important;
        font-weight: 600 !important;
        background: #f9fafb !important;
        color: #374151 !important;
    }

    .rp-wrap-full .rp-table tbody tr[data-status="Opublikowany"]::after {
        background: #ecfdf5 !important;
        color: #065f46 !important;
        content: "🟢 Opublikowany" !important;
    }

    .rp-wrap-full .rp-table tbody tr[data-status="Wersja robocza"]::after,
    .rp-wrap-full .rp-table tbody tr[data-status="Kopia robocza"]::after {
        background: #f3f4f6 !important;
        color: #6b7280 !important;
        content: "⚙️ Wersja robocza" !important;
    }

    .rp-wrap-full .rp-table tbody tr[data-status="Zaplanowany"]::after {
        background: #eff6ff !important;
        color: #1e3a8a !important;
        content: "🕒 Zaplanowany" !important;
    }

    /* PRZYCISKI na dole */
    .rp-wrap-full .rp-actions-td {
        grid-area: actions !important;
        display: flex !important;
        gap: 8px !important;
        flex-wrap: wrap !important;
        padding-top: 10px !important;
        border-top: 1px solid #f1f1f1 !important;
    }

    .rp-wrap-full .rp-btn-sm {
        flex: 1 1 calc(33% - 6px) !important;
        text-align: center !important;
        font-size: 13px !important;
        padding: 8px 0 !important;
        border-radius: 8px !important;
        border: 1px solid #d1d5db !important;
        background: #f9fafb !important;
        color: #374151 !important;
        font-weight: 500 !important;
        text-decoration: none !important;
        transition: background .2s ease, border-color .2s ease !important;
    }

    .rp-wrap-full .rp-btn-sm:hover {
        background: #f3f4f6 !important;
        border-color: #cbd5e1 !important;
    }

    .rp-wrap-full .rp-btn-sm.rp-btn-danger {
        color: #b91c1c !important;
        background: #fef2f2 !important;
        border-color: #fca5a5 !important;
    }

    .rp-wrap-full .rp-btn-sm.rp-btn-publish {
        color: #065f46 !important;
        background: #ecfdf5 !important;
        border-color: #a7f3d0 !important;
    }

    /* odstępy między kartami */
    .rp-wrap-full .rp-table tbody {
        display: grid !important;
        gap: 20px !important;
    }
}
/* ====== Ukrycie przycisku "Edit" / "Edytuj" ====== */
a.post-edit-link,
.post-edit-link {
    display: none !important;
    visibility: hidden !important;
}