/* ================================================================
   FriendsByChance — components/etb-viewer.css
   Editable Text Block — viewer component
   ================================================================ */

/* ── Outer wrap: content area + side column ─────────────────────── */
.etb-viewer-wrap {
    display:     flex;
    gap:         8px;
    align-items: flex-start;
}

/* ── Content area ───────────────────────────────────────────────── */
.etb-viewer-body {
    flex:       1;
    min-width:  0;
}

/* Clickable on small screens (class toggled by JS) */
.etb-viewer-wrap.etb-viewer--clickable .etb-viewer-body {
    cursor: pointer;
}
.etb-viewer-wrap.etb-viewer--clickable .etb-viewer-body:hover {
    opacity: 0.85;
}

/* ── Label / Title ──────────────────────────────────────────────── */
.etb-viewer-label {
    font-weight:   600;
    font-size:     0.92em;
    margin-bottom: 4px;
    color:         var(--color-text);
}

/* ── Rich-text content ──────────────────────────────────────────── */
.etb-viewer-content {
    font-size:   0.92em;
    line-height: 1.6;
    color:       var(--color-text);
    word-break:  break-word;
}
/* Reset Quill-generated markup inside the viewer */
.etb-viewer-content p  { margin: 0 0 0.4em; }
.etb-viewer-content p:last-child { margin-bottom: 0; }
.etb-viewer-content ul,
.etb-viewer-content ol { padding-left: 1.4em; margin: 0.3em 0; }

/* ── Side column (hidden when empty) ───────────────────────────── */
.etb-viewer-side-col {
    display:        flex;
    flex-direction: column;
    gap:            6px;
    flex-shrink:    0;
    padding-top:    2px;
}
.etb-viewer-side-col:empty { display: none; }

/* ── Fullscreen overlay ─────────────────────────────────────────── */
.etb-fs-overlay {
    position:        fixed;
    inset:           0;
    z-index:         600;
    background:      rgba(0, 0, 0, 0.55);
    display:         flex;
    align-items:     stretch;
    justify-content: center;
}

.etb-fs-modal {
    background:     var(--color-bg);
    width:          100%;
    max-width:      100vw;
    max-height:     100vh;
    display:        flex;
    flex-direction: column;
    overflow:       hidden;
}

/* ── Fullscreen header (pinned, shows label + close button) ─────── */
.etb-fs-header {
    display:         flex;
    align-items:     center;
    justify-content: space-between;
    gap:             10px;
    padding:         12px 16px 10px;
    border-bottom:   1px solid var(--color-divider);
    flex-shrink:     0;
}

.etb-fs-title {
    font-weight:   600;
    font-size:     1em;
    color:         var(--color-text);
    min-width:     0;
    overflow:      hidden;
    text-overflow: ellipsis;
    white-space:   nowrap;
    flex:          1;
}

/* ── Fullscreen body (scrollable content) ───────────────────────── */
.etb-fs-body {
    flex:       1;
    overflow-y: auto;
    padding:    16px;
}
