/* /Features/Mail/MailCampaign.razor.rz.scp.css */
/* Page-scoped styles for the campaign editor.

   The prototype (docs/prototype/mailing-compose.html) defines these in a local <style>
   block because they belong to exactly one screen. Scoped CSS is the Blazor equivalent —
   they stay out of the shared design system, where a "placeholder chip" would be a
   component nobody else needs. */

.kp-ph[b-j62a2assey] {
    display: inline-block;
    padding: 0.0625rem 0.3125rem;
    border-radius: var(--radius-sm);
    font-size: var(--kp-text-section);
    font-family: var(--font-mono);
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--muted);
    cursor: pointer;
}

.kp-ph:hover[b-j62a2assey] {
    border-color: var(--border-strong);
    color: var(--fg);
}

.kp-mailframe[b-j62a2assey] {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.kp-mailframe-head[b-j62a2assey] {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--border);
    background: var(--surface-2);
}

.kp-mailframe-body[b-j62a2assey] {
    padding: 1rem;
    /* KP-433: Das ist die Textfassung; ihre Zeilenumbrüche gehören dazu. */
    white-space: pre-wrap;
}

/* KP-433: die HTML-Fassung in einem abgeschotteten Rahmen, hell wie die Mail selbst. */
.kp-mailframe-html[b-j62a2assey] {
    display: block;
    width: 100%;
    height: 34rem;
    border: 0;
    background: #F4F4F5;
}

/* KP-431: Treffer der Zielsuche als Liste, linksbündig über die volle Breite. */
.kp-target-option[b-j62a2assey] {
    justify-content: flex-start;
    width: 100%;
    text-align: left;
}
/* /Features/Mail/MailTemplates.razor.rz.scp.css */
/* KP-432: Aktionen rechtsbündig in einer Zeile. */
.kp-template-actions[b-4d2899roi9] { width: 1%; white-space: nowrap; }
.kp-template-actions .kp-row-actions[b-4d2899roi9] { justify-content: flex-end; gap: 0.125rem; flex-wrap: nowrap; }

/* KP-432: Am Handy fällt der Betreff weg; Name, Ablage und Aktionen passen dann in die Breite. */
.kp-template-scope-inline[b-4d2899roi9] { display: none; }

@media (max-width: 639.98px) {
    .kp-template-subject[b-4d2899roi9], .kp-template-scope[b-4d2899roi9] { display: none; }
    .kp-template-scope-inline[b-4d2899roi9] { display: block; margin: 0.125rem 0 0; }
}
/* /Features/Mail/RichTextEditor.razor.rz.scp.css */
/* KP-433: Editor wie ein Textfeld (Rahmen, Fokusring), mit Leiste oben. Der Inhalt entsteht im Skript
   und trägt kein Scope-Attribut, darum ::deep für alles darin. */
.kp-rte[b-30hodv7n6c] {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
}

.kp-rte:focus-within[b-30hodv7n6c] {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--ring);
}

.kp-rte-bar[b-30hodv7n6c] {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.125rem;
    padding: 0.25rem;
    border-bottom: 1px solid var(--border);
    background: var(--surface-2);
    border-radius: var(--radius) var(--radius) 0 0;
}

.kp-rte-btn[b-30hodv7n6c] {
    min-width: 2rem;
    height: 2rem;
    padding: 0 0.5rem;
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--fg);
    font: inherit;
    font-size: var(--kp-text-section);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.kp-rte-btn:hover[b-30hodv7n6c] { background: var(--surface); border-color: var(--border); }
.kp-rte-btn:focus-visible[b-30hodv7n6c] { outline: 2px solid var(--ring); outline-offset: 1px; }
.kp-rte-btn[aria-pressed="true"][b-30hodv7n6c], .kp-rte-btn[aria-expanded="true"][b-30hodv7n6c] { background: var(--surface); border-color: var(--border-strong); }

.kp-rte-sep[b-30hodv7n6c] { width: 1px; height: 1.25rem; background: var(--border); margin: 0 0.25rem; }

.kp-rte-form[b-30hodv7n6c] {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.75rem;
    border-bottom: 1px solid var(--border);
}

.kp-rte-area[b-30hodv7n6c] {
    min-height: 12rem;
    padding: 0.75rem;
    font-size: 0.875rem;
    line-height: 1.6;
    outline: none;
    overflow-wrap: anywhere;
}

.kp-rte.is-disabled .kp-rte-area[b-30hodv7n6c] { background: var(--bg-body); color: var(--muted); }

.kp-rte-area[b-30hodv7n6c]  p { margin: 0 0 0.75rem; }
.kp-rte-area[b-30hodv7n6c]  h2 { margin: 0.75rem 0 0.5rem; font-size: 1.125rem; font-weight: 600; }
.kp-rte-area[b-30hodv7n6c]  h3 { margin: 0.75rem 0 0.5rem; font-size: 1rem; font-weight: 600; }
.kp-rte-area[b-30hodv7n6c]  ul, .kp-rte-area[b-30hodv7n6c]  ol { margin: 0 0 0.75rem; padding-left: 1.5rem; }
.kp-rte-area[b-30hodv7n6c]  a { color: var(--kp-accent); text-decoration: underline; }

/* Der Aktionsknopf sieht im Editor schon aus wie in der Mail. */
.kp-rte-area[b-30hodv7n6c]  a[data-kp-button] {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    background: var(--kp-accent);
    color: var(--kp-accent-fg);
    text-decoration: none;
    font-weight: 600;
}

.kp-rte-area[b-30hodv7n6c]  .kp-ph-chip {
    display: inline-block;
    padding: 0 0.3125rem;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--muted);
    user-select: all;
}

/* KP-438: ein verlinktes Dokument, nicht bearbeitbar wie ein Platzhalter. */
.kp-rte-area[b-30hodv7n6c]  .kp-doc-chip {
    display: inline-block;
    padding: 0 0.375rem;
    border-radius: var(--radius-sm);
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--kp-accent);
    text-decoration: none;
    user-select: all;
}

.kp-rte-doclist[b-30hodv7n6c] {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    max-height: 14rem;
    overflow-y: auto;
}

.kp-rte-doclist .kp-btn[b-30hodv7n6c] {
    justify-content: flex-start;
    width: 100%;
    text-align: left;
}
