/* ==========================================================================
   CDSWerx Text Editor Widget
   ========================================================================== */

/* Base Component */
.cdswerx-text-editor {
    word-wrap: break-word;
}

/* Links — transition for hover color */
.cdswerx-text-editor a {
    transition: color 0.2s ease;
}

/* ==========================================================================
   Drop Cap
   ========================================================================== */

.cdswerx-drop-cap-yes .cdswerx-text-editor > p:first-child {
    /* Ensure first paragraph accommodates the drop cap floated element */
}

.cdswerx-drop-cap {
    float: left;
    text-align: center;
    line-height: 1;
    font-size: 50px;
}

.cdswerx-drop-cap-letter {
    display: inline-block;
}

/* View: Stacked */
.cdswerx-drop-cap-view-stacked .cdswerx-drop-cap {
    background-color: var(--e-global-color-primary, #6ec1e4);
    color: #fff;
}

/* View: Framed */
.cdswerx-drop-cap-view-framed .cdswerx-drop-cap {
    border-style: solid;
    border-width: 3px;
}

/* ==========================================================================
   Columns — prevent orphaned headings / widows
   ========================================================================== */

.cdswerx-text-editor[style*="columns"] h1,
.cdswerx-text-editor[style*="columns"] h2,
.cdswerx-text-editor[style*="columns"] h3,
.cdswerx-text-editor[style*="columns"] h4,
.cdswerx-text-editor[style*="columns"] h5,
.cdswerx-text-editor[style*="columns"] h6 {
    break-after: avoid;
}

.cdswerx-text-editor[style*="columns"] p,
.cdswerx-text-editor[style*="columns"] li {
    orphans: 2;
    widows: 2;
}

/* List / marker base styles for this widget's WYSIWYG content live in the shared
   stylesheet assets/css/wysiwyg-content.css (handle cdswerx-wysiwyg-content,
   loaded as a dependency of this file). Rendered markup carries the generic
   `cds-wysiwyg*` hooks next to the BEM classes (WYSIWYG_List_Styles_Trait).
   The per-widget copies that used to live here were removed after #87 —
   do not re-add them. */

