/* featured_materials.css - "Wyróżnione materiały" picker + public profile badges/nudge. */

.featured-nudge-banner {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: rgba(255, 193, 7, 0.12);
    border: 1px solid rgba(255, 193, 7, 0.35);
    border-radius: 12px;
    padding: 1rem 1.25rem;
    color: inherit;
}
.featured-nudge-banner > i { font-size: 1.6rem; color: #d4a017; flex-shrink: 0; }
.featured-nudge-banner p { font-size: 0.9rem; opacity: 0.85; }

.featured-ribbon {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    z-index: 2;
    background: rgba(255, 193, 7, 0.95);
    color: #4a3200;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.25rem 0.6rem;
    border-radius: 999px;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

@media (max-width: 480px) {
    .featured-nudge-banner { flex-wrap: wrap; }
}

/* --- Picker modal ---
   The modal has a fixed white background regardless of the teacher's profile theme,
   so it must not inherit the page's (possibly white/light) themed text color. */
#featured-materials-modal .dashboard-modal-content { color: #1e293b; }
#featured-materials-modal .dashboard-modal-header p { color: #1e293b; }

.fm-toolbar { display: flex; gap: 0.75rem; flex-wrap: wrap; padding: 1rem 1.5rem 0; }
.fm-input, .fm-select {
    width: 100%;
    padding: 0.55rem 0.75rem 0.55rem 2.25rem;
    border: 1px solid var(--border-color, #dcdfe4);
    border-radius: 8px;
    background: var(--card-bg-default, #fff);
    color: inherit;
    font-size: 0.9rem;
}
.fm-select { padding-left: 0.75rem; }

.fm-candidate-list { max-height: 360px; overflow-y: auto; border: 1px solid var(--border-color, #e5e7eb); border-radius: 8px; }
.fm-candidate-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 0.75rem;
    border-bottom: 1px solid var(--border-color, #eef0f2);
    cursor: pointer;
    font-size: 0.9rem;
}
.fm-candidate-item:last-child { border-bottom: none; }
.fm-candidate-item:hover { background: rgba(0,0,0,0.03); }
.fm-candidate-item.fm-candidate-selected { background: rgba(255, 193, 7, 0.1); }
.fm-candidate-type-tag {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    background: rgba(0,0,0,0.08);
    flex-shrink: 0;
}
.fm-candidate-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.fm-selected-list { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 0.75rem; }
.fm-selected-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 0.65rem;
    border: 1px solid rgba(255, 193, 7, 0.4);
    background: rgba(255, 193, 7, 0.08);
    border-radius: 8px;
    font-size: 0.88rem;
}
.fm-order-badge {
    flex-shrink: 0;
    width: 22px; height: 22px;
    border-radius: 50%;
    background: #d4a017;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex; align-items: center; justify-content: center;
}
.fm-selected-title { flex-grow: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fm-selected-actions { display: flex; gap: 0.25rem; flex-shrink: 0; }
.fm-icon-btn {
    background: none;
    border: 1px solid rgba(0,0,0,0.15);
    border-radius: 6px;
    width: 24px; height: 24px;
    line-height: 1;
    cursor: pointer;
    color: inherit;
    font-size: 0.85rem;
}
.fm-icon-btn:disabled { opacity: 0.3; cursor: not-allowed; }
.fm-remove-btn { color: #c0392b; }

.fm-btn-secondary, .fm-btn-primary {
    padding: 0.5rem 1.1rem;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
}
.fm-btn-secondary { background: none; border: 1px solid var(--border-color, #dcdfe4); color: inherit; }
.fm-btn-primary { background: #d4a017; border: none; color: #fff; }
.fm-btn-primary:disabled { opacity: 0.6; cursor: not-allowed; }

.fm-toast {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: #333;
    color: #fff;
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    font-size: 0.9rem;
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
    pointer-events: none;
    z-index: 10060;
}
.fm-toast.fm-toast-visible { opacity: 1; transform: translateX(-50%) translateY(0); }
