/* Główna paleta i typografia */
:root {
    --cfmlp-primary: #2d3a8c;
    --cfmlp-primary-light: #3f51b5;
    --cfmlp-accent: #f2c100;
    --cfmlp-neutral: #f4f6fb;
    --cfmlp-neutral-strong: #d6d9e4;
    --cfmlp-text: #121527;
    --cfmlp-muted: #6b7280;
    --cfmlp-success-bg: #ecfdf3;
    --cfmlp-success-border: #bbf7d0;
}

.cfmlp-wrapper {
    font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
    background: linear-gradient(180deg, #ffffff 0%, var(--cfmlp-neutral) 100%);
    border-radius: 18px;
    padding: 24px;
    box-shadow: 0 20px 45px rgba(25, 32, 72, 0.08);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    margin: 0;
    display: block;
}

.cfmlp-row {
    display: grid;
    grid-template-columns: 84px 56px minmax(0, 0.9fr) minmax(0, 1fr) max-content;
    align-items: center;
    gap: 20px;
    padding: 16px 18px;
    border-radius: 16px;
    transition: transform .25s ease, box-shadow .25s ease, background-color .25s ease;
    background: rgba(255,255,255,0.72);
    border: 1px solid rgba(209, 214, 230, 0.6);
    margin-bottom: 12px;
}

.cfmlp-row:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 38px rgba(32, 44, 94, 0.16);
    background: #fff;
}

.cfmlp-head {
    font-weight: 700;
    color: var(--cfmlp-muted);
    text-transform: uppercase;
    letter-spacing: .04em;
}

.cfmlp-row img {
    width: 84px;
    height: 84px;
    object-fit: cover;
    border-radius: 18px;
    box-shadow: 0 10px 22px rgba(0,0,0,0.12);
}

.cfmlp-cover-placeholder {
    width: 84px;
    height: 84px;
    border-radius: 18px;
    background: linear-gradient(135deg, #e1e6f6 0%, #f5f7ff 100%);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.6);
}

.cfmlp-col.col-lp {
    font-weight: 900;
    font-size: 36px;
    line-height: 1;
    color: var(--cfmlp-accent);
    text-align: center;
    text-shadow: 0 4px 18px rgba(242,193,0,0.35);
}

.cfmlp-col.col-artist {
    font-weight: 800;
    color: var(--cfmlp-primary);
    letter-spacing: -.01em;
}

.cfmlp-col.col-title {
    color: var(--cfmlp-muted);
    font-weight: 500;
    margin-top: -6px;
}

.cfmlp-play {
    display: inline-flex;
    width: 46px;
    height: 46px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--cfmlp-primary);
    color: #fff !important;
    text-decoration: none;
    font-weight: 700;
    box-shadow: 0 10px 18px rgba(45,58,140,0.28);
    transition: transform .2s ease, box-shadow .2s ease;
    border: none;
    cursor: pointer;
}

.cfmlp-play:hover {
    transform: translateY(-1px) scale(1.04);
    box-shadow: 0 12px 24px rgba(45,58,140,0.35);
}

.cfmlp-play:focus-visible {
    outline: 2px solid rgba(63,81,181,0.6);
    outline-offset: 2px;
}

.cfmlp-play--playing {
    background: var(--cfmlp-primary-light);
    box-shadow: 0 14px 28px rgba(45,58,140,0.35);
}

.cfmlp-vote {
    width: 44px;
    height: 44px;
    border-radius: 18px;
    border: none;
    background: rgba(45,58,140,0.08);
    color: var(--cfmlp-primary);
    font-size: 22px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,.08);
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
    cursor: pointer;
    flex-shrink: 0;
    min-width: 44px;
}

.cfmlp-vote:hover {
    transform: translateY(-1px);
    background: rgba(45,58,140,0.12);
    box-shadow: 0 6px 16px rgba(32,44,94,0.18);
}

.cfmlp-vote:disabled {
    background: rgba(17, 24, 39, 0.08);
    color: rgba(17, 24, 39, 0.45);
    cursor: not-allowed;
    box-shadow: none;
}

.cfmlp-vote--selected {
    background: var(--cfmlp-primary);
    color: #fff;
    box-shadow: 0 12px 28px rgba(45,58,140,0.35);
}

.cfmlp-col.col-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: flex-end;
    flex-wrap: nowrap;
    white-space: nowrap;
}

.cfmlp-action {
    flex-shrink: 0;
}

.cfmlp-col.col-actions .cfmlp-count {
    margin: 0 0 0 2px;
}

.cfmlp-col.col-actions .cfmlp-vote.cfmlp-vote-down:not(.cfmlp-vote--selected) {
    background: rgba(0,0,0,0.06);
    color: #3d404b;
}

.cfmlp-play.cfmlp-play--disabled {
    background: rgba(45,58,140,0.12);
    color: rgba(45,58,140,0.55);
    box-shadow: none;
    cursor: default;
    pointer-events: none;
}

.cfmlp-count {
    font-size: 13px;
    color: var(--cfmlp-muted);
    vertical-align: middle;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(17, 24, 39, 0.06);
    display: inline-block;
}

.cfmlp-thanks,
.cfmlp-suggest-thanks {
    margin-top: 12px;
    background: var(--cfmlp-success-bg);
    border: 1px solid var(--cfmlp-success-border);
    padding: 10px 14px;
    border-radius: 10px;
    color: #14532d;
    font-weight: 600;
}

.cfmlp-suggest {
    margin-top: 26px;
    padding: 18px 20px;
    border-radius: 16px;
    background: rgba(255,255,255,0.82);
    border: 1px solid rgba(209, 214, 230, 0.65);
    box-shadow: 0 14px 30px rgba(17, 24, 39, 0.08);
}

.cfmlp-suggest h3 {
    margin-bottom: 14px;
    font-weight: 700;
    color: var(--cfmlp-primary);
}

.cfmlp-suggest-message {
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 16px;
    font-weight: 600;
    background: #fef3c7;
    border: 1px solid #fcd34d;
    color: #92400e;
}

.cfmlp-suggest-message--error {
    background: #fee2e2;
    border-color: #ffc9c9;
    color: #991b1b;
}

.cfmlp-suggest input[type="text"] {
    width: 100%;
    max-width: 520px;
    padding: 12px 14px;
    margin-right: 10px;
    border-radius: 12px;
    border: 1px solid rgba(45,58,140,0.15);
    background: #fff;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.cfmlp-suggest input[type="text"]:focus {
    border-color: var(--cfmlp-primary-light);
    box-shadow: 0 0 0 4px rgba(63,81,181,0.15);
    outline: none;
}

.cfmlp-suggest button,
.cfmlp-modal .cfmlp-btn {
    padding: 11px 18px;
    border-radius: 12px;
    font-weight: 600;
    border: none;
    background: linear-gradient(135deg, var(--cfmlp-primary) 0%, var(--cfmlp-primary-light) 100%);
    color: #fff;
    box-shadow: 0 12px 24px rgba(45,58,140,0.28);
    cursor: pointer;
    transition: transform .2s ease, box-shadow .2s ease;
}

.cfmlp-suggest button:hover,
.cfmlp-modal .cfmlp-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 28px rgba(45,58,140,0.34);
}

.cfmlp-modal-wrap {
    position: fixed;
    inset: 0;
    background: rgba(13, 20, 40, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    backdrop-filter: blur(6px);
    animation: cfmlp-modal-fade-in .25s ease forwards;
}

.cfmlp-modal-wrap--hide {
    animation: cfmlp-modal-fade-out .22s ease forwards;
}

.cfmlp-modal {
    position: relative;
    background: radial-gradient(circle at top, #fff 0%, #f4f5ff 60%, #e5e7fb 100%);
    padding: 32px 34px 30px;
    border-radius: 24px;
    max-width: 460px;
    width: min(90vw, 460px);
    box-shadow: 0 35px 70px rgba(7, 12, 32, 0.45);
    text-align: center;
    color: #0b1224;
    overflow: hidden;
}

.cfmlp-modal__badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: #083344;
    background: rgba(8, 51, 68, 0.08);
    margin-bottom: 12px;
}

.cfmlp-modal__title {
    font-size: 26px;
    margin: 8px 0;
    color: #0f172a;
}

.cfmlp-modal__text {
    color: #475569;
    margin-bottom: 22px;
    font-size: 16px;
}

.cfmlp-modal__close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: rgba(15, 23, 42, 0.08);
    color: #111827;
    font-size: 20px;
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

.cfmlp-modal__close:hover {
    background: rgba(15, 23, 42, 0.18);
    transform: scale(1.05);
}

.cfmlp-modal-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.cfmlp-btn-secondary {
    background: rgba(15, 23, 42, 0.08);
    color: #0f172a;
    box-shadow: none;
}

.cfmlp-btn-secondary:hover {
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.18);
}

.cfmlp-modal__cta {
    min-width: 180px;
}

@keyframes cfmlp-modal-fade-in {
    from {
        opacity: 0;
        transform: scale(0.98);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes cfmlp-modal-fade-out {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(0.96);
    }
}

/* Tabele i sekcje w panelu administratora */
.cfmlp-admin-wrap {
    font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
    color: var(--cfmlp-text);
}

.cfmlp-admin-wrap h1 {
    font-size: 28px;
    margin-bottom: 18px;
    color: var(--cfmlp-primary);
}

.cfmlp-admin-wrap .cfmlp-section {
    background: #fff;
    border-radius: 16px;
    padding: 22px 26px;
    margin-bottom: 24px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
    border: 1px solid rgba(209, 214, 230, 0.6);
}

.cfmlp-admin-wrap .cfmlp-section h2 {
    margin-top: 0;
    color: var(--cfmlp-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.cfmlp-admin-wrap .cfmlp-section h2::before {
    content: "";
    width: 6px;
    height: 22px;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--cfmlp-primary-light) 0%, var(--cfmlp-primary) 100%);
}

.cfmlp-admin-wrap table.widefat {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(209, 214, 230, 0.6);
}

.cfmlp-admin-wrap table.widefat thead {
    background: rgba(45, 58, 140, 0.08);
}

.cfmlp-admin-wrap table.widefat th,
.cfmlp-admin-wrap table.widefat td {
    padding: 14px 16px;
}

.cfmlp-admin-wrap .cfmlp-table tbody tr:hover {
    background: rgba(45,58,140,0.05);
}

.cfmlp-admin-wrap .cfmlp-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px 24px;
}

.cfmlp-admin-wrap .cfmlp-form-grid label {
    font-weight: 600;
    color: var(--cfmlp-muted);
}

.cfmlp-admin-wrap input[type="text"],
.cfmlp-admin-wrap input[type="number"],
.cfmlp-admin-wrap input[type="url"],
.cfmlp-admin-wrap textarea {
    width: 100%;
    border-radius: 12px;
    border: 1px solid rgba(45,58,140,0.18);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.45);
    padding: 10px 12px;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.cfmlp-admin-wrap input:focus,
.cfmlp-admin-wrap textarea:focus {
    border-color: var(--cfmlp-primary-light);
    box-shadow: 0 0 0 4px rgba(63,81,181,0.15);
    outline: none;
}

.cfmlp-admin-wrap .cfmlp-button-primary {
    background: linear-gradient(135deg, var(--cfmlp-primary) 0%, var(--cfmlp-primary-light) 100%);
    color: #fff;
    border: none;
    border-radius: 12px;
    padding: 11px 24px;
    font-weight: 600;
    box-shadow: 0 12px 22px rgba(45,58,140,0.28);
    cursor: pointer;
}

.cfmlp-admin-wrap .cfmlp-button-secondary {
    background: linear-gradient(135deg, #f5f5f5 0%, #e2e8f0 100%);
    border: none;
    border-radius: 12px;
    padding: 11px 20px;
    font-weight: 600;
    cursor: pointer;
    color: #16223e;
}

.cfmlp-admin-wrap .cfmlp-notice {
    border-radius: 12px;
    padding: 12px 18px;
    margin-bottom: 16px;
}

.cfmlp-admin-wrap .cfmlp-dashboard-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 18px;
}

.cfmlp-admin-wrap .cfmlp-summary-card {
    background: linear-gradient(135deg, rgba(45,58,140,0.08) 0%, rgba(45,58,140,0.16) 100%);
    border-radius: 14px;
    padding: 14px 16px;
    color: var(--cfmlp-primary);
    font-weight: 600;
}

.cfmlp-reset-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 18px;
    align-items: stretch;
}

.cfmlp-reset-card {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(209, 214, 230, 0.7);
    border-radius: 16px;
    padding: 20px 22px;
    box-shadow: 0 14px 30px rgba(17, 24, 39, 0.08);
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.cfmlp-reset-card h3 {
    margin: 0;
    font-size: 18px;
    color: var(--cfmlp-primary);
}

.cfmlp-reset-card__info,
.cfmlp-reset-card__description {
    margin: 0;
    color: var(--cfmlp-muted);
}

.cfmlp-reset-card__status {
    margin: 0;
    color: var(--cfmlp-primary);
}

.cfmlp-reset-card form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cfmlp-reset-card__label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-weight: 600;
    color: var(--cfmlp-muted);
}

.cfmlp-reset-card__label span {
    font-size: 12px;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.cfmlp-reset-card__label input,
.cfmlp-reset-card__label select {
    border-radius: 12px;
    border: 1px solid rgba(45,58,140,0.18);
    padding: 10px 12px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.45);
    width: 100%;
}

.cfmlp-reset-card__label input:focus,
.cfmlp-reset-card__label select:focus {
    border-color: var(--cfmlp-primary-light);
    box-shadow: 0 0 0 4px rgba(63,81,181,0.15);
    outline: none;
}

.cfmlp-reset-card__checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-weight: 600;
    color: var(--cfmlp-primary);
}

.cfmlp-reset-card__checkbox input {
    margin-top: 4px;
}

.cfmlp-reset-card__fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
}

.cfmlp-reset-card .description {
    font-size: 13px;
    line-height: 1.4;
}

.cfmlp-schedule-form--cancel {
    margin-top: -4px;
}

.cfmlp-schedule-form--cancel button {
    width: 100%;
}

/* Responsywność */
@media (max-width: 960px) {
    .cfmlp-row {
        grid-template-columns: 72px 48px minmax(0, 0.9fr) minmax(0, 1fr) max-content;
    }
}

@media (max-width: 760px) {
    .cfmlp-wrapper {
        padding: 18px;
    }
    .cfmlp-reset-grid {
        grid-template-columns: 1fr;
    }
    .cfmlp-row {
        grid-template-columns: 68px minmax(0, 1fr);
        grid-template-areas:
            "cover lp"
            "cover artist"
            "cover title"
            "actions actions";
        gap: 12px 14px;
        padding: 14px;
    }
    .cfmlp-row img,
    .cfmlp-cover-placeholder {
        width: 60px;
        height: 60px;
    }
    .cfmlp-col.col-cover {
        grid-area: cover;
        display: flex;
        justify-content: center;
    }
    .cfmlp-col.col-lp {
        grid-area: lp;
        justify-self: start;
        margin-top: -6px;
    }
    .cfmlp-col.col-artist {
        grid-area: artist;
    }
    .cfmlp-col.col-title {
        grid-area: title;
        margin-top: 2px;
    }
    .cfmlp-col.col-actions {
        grid-area: actions;
        justify-content: flex-start;
        width: 100%;
        gap: 10px;
    }
}

@media (max-width: 520px) {
    .cfmlp-row {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas:
            "cover"
            "lp"
            "artist"
            "title"
            "actions";
        align-items: flex-start;
        gap: 12px;
    }
    .cfmlp-col.col-cover {
        grid-area: cover;
        display: flex;
        align-items: center;
        gap: 14px;
        justify-content: flex-start;
    }
    .cfmlp-col.col-lp {
        grid-area: lp;
        justify-self: start;
        font-size: 30px;
        margin-top: -6px;
    }
    .cfmlp-col.col-artist {
        grid-area: artist;
    }
    .cfmlp-col.col-title {
        grid-area: title;
        margin-top: 0;
        opacity: .9;
    }
    .cfmlp-col.col-actions {
        grid-area: actions;
        justify-content: flex-start;
        margin-top: 6px;
        gap: 10px;
        flex-wrap: wrap;
        width: 100%;
    }
    .cfmlp-play {
        width: 42px;
        height: 42px;
    }
    .cfmlp-vote {
        width: 40px;
        height: 40px;
        min-width: 40px;
        border-radius: 14px;
    }
}
.cfmlp-col.col-like,
.cfmlp-col.col-dislike {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: nowrap;
    justify-content: flex-start;
    white-space: nowrap;
}
