/* =============================================================================
   FYSH — Rich text editor (basic formatting for the description field)
   CR: fysh-description-richtext-2026-09-26
   Paragraphs, line breaks, bold, italic, bulleted and numbered lists.
============================================================================= */

.rt-editor {
    border: 1px solid var(--wb-border, #D5D9DF);
    border-radius: 4px;
    background: #fff;
    overflow: hidden;
}
.rt-editor.is-focused { border-color: var(--blue, #1E5BA8); }

.rt-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 2px;
    padding: 6px;
    border-bottom: 1px solid var(--wb-border, #D5D9DF);
    background: var(--surface-2, #EEF2F8);
}
.rt-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 28px;
    padding: 0;
    border: 1px solid transparent;
    border-radius: 4px;
    background: transparent;
    color: #0F2340;
    cursor: pointer;
    font-family: var(--font-body, sans-serif);
    transition: background-color 0.12s, border-color 0.12s;
}
.rt-btn:hover { background: #fff; border-color: var(--wb-border, #D5D9DF); }
.rt-btn:focus-visible { outline: 2px solid var(--blue, #1E5BA8); outline-offset: 1px; }
.rt-btn.is-active { background: var(--navy, #0F2340); color: #fff; }
.rt-btn svg { width: 16px; height: 16px; }
.rt-btn b, .rt-btn i { font-size: 14px; line-height: 1; }

.rt-surface {
    min-height: 160px;
    max-height: 420px;
    overflow-y: auto;
    padding: 12px 14px;
    font-family: var(--font-body, sans-serif);
    font-size: 14px;
    line-height: 1.6;
    color: var(--navy, #0F2340);
    outline: none;
}
.rt-surface p { margin: 0 0 0.7em; }
.rt-surface p:last-child { margin-bottom: 0; }
.rt-surface ul, .rt-surface ol { margin: 0 0 0.7em; padding-left: 1.6em; }
/* base.css applies a global `ul { list-style: none }` reset; override it. */
.rt-surface ul { list-style: disc outside !important; }
.rt-surface ol { list-style: decimal outside !important; }
.rt-surface li { margin: 0 0 0.2em; display: list-item; }
.rt-surface u { text-decoration: underline; }
.rt-surface mark { background: #FCE9B8; color: inherit; padding: 0 2px; border-radius: 2px; }
.rt-surface:empty::before {
    content: attr(data-placeholder);
    color: #9AA7B5;
    pointer-events: none;
}

/* Public listing render inherits the same list rhythm */
.listing-desc-body p { margin: 0 0 0.8em; }
.listing-desc-body p:last-child { margin-bottom: 0; }
.listing-desc-body ul, .listing-desc-body ol { margin: 0 0 0.8em; padding-left: 1.6em; }
.listing-desc-body ul { list-style: disc outside !important; }
.listing-desc-body ol { list-style: decimal outside !important; }
.listing-desc-body li { margin: 0 0 0.25em; display: list-item; }
.listing-desc-body u { text-decoration: underline; }
.listing-desc-body mark { background: #FCE9B8; color: inherit; padding: 0 2px; border-radius: 2px; }
