/* EW Style Selector — Font size & dark mode controls */

/* ── Inline toolbar (inside nav container) ── */

.ewfp-nav-container {
    display: flex !important;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.ew-ss-toolbar {
    display: flex;
    gap: 6px;
    align-items: center;
    margin-left: auto;
    flex-shrink: 0;
}

/* ── Fallback: floating toolbar if nav not found ── */

.ew-ss-toolbar-float {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 9990;
    opacity: 0.6;
    transition: opacity 0.2s ease;
}

.ew-ss-toolbar-float:hover {
    opacity: 1;
}

/* ── Buttons ── */

.ew-ss-btn {
    width: 36px;
    height: 36px;
    border: 1px solid #c8c8c8;
    border-radius: 4px;
    background: #ffffff;
    color: #333333;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s ease;
    user-select: none;
    -webkit-user-select: none;
}

.ew-ss-btn:hover {
    border-color: #449ae3;
    background: #ffffff;
}

.ew-ss-btn:active {
    background: #f5f5f5;
}

.ew-ss-btn-decrease {
    font-size: 13px;
}

.ew-ss-btn-increase {
    font-size: 17px;
}

.ew-ss-btn-dark svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
}

.ew-ss-btn-dark.ew-ss-active {
    background: #1a1a1a;
    color: #e0e0e0;
    border-color: rgba(255, 255, 255, 0.15);
}

/* ── Dark mode: toolbar ── */

body.ew-dark-mode .ew-ss-btn {
    background: rgba(40, 40, 40, 0.95) !important;
    color: #e0e0e0 !important;
    border-color: rgba(255, 255, 255, 0.12) !important;
}

body.ew-dark-mode .ew-ss-btn:hover {
    background: rgba(55, 55, 55, 0.98) !important;
    border-color: #449ae3 !important;
}

/* ── Dark mode: commentary content ── */

body.ew-dark-mode .entry-content-wrap,
body.ew-dark-mode .entry.content-bg,
body.ew-dark-mode .content-bg {
    background-color: #1a1a1a !important;
    color: #e0e0e0 !important;
}

body.ew-dark-mode .entry-content-wrap *,
body.ew-dark-mode .entry-content *,
body.ew-dark-mode .single-content * {
    color: #e0e0e0 !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

body.ew-dark-mode .entry-content a,
body.ew-dark-mode .single-content a {
    color: #6db3f2 !important;
}

body.ew-dark-mode .entry-content a:hover,
body.ew-dark-mode .single-content a:hover {
    color: #90c9ff !important;
}

body.ew-dark-mode .entry-content h1,
body.ew-dark-mode .entry-content h2,
body.ew-dark-mode .entry-content h3,
body.ew-dark-mode .entry-content h4 {
    color: #f0f0f0 !important;
}

body.ew-dark-mode .ew-bible-text,
body.ew-dark-mode .ew-bible-text * {
    color: #c8d8e8 !important;
}

body.ew-dark-mode .ew-bvs-attribution {
    color: #6db3f2 !important;
}

/* ── Font size override ── */

.ew-ss-font-size .entry-content,
.ew-ss-font-size .single-content,
.ew-ss-font-size .entry-content p,
.ew-ss-font-size .single-content p,
.ew-ss-font-size .entry-content li,
.ew-ss-font-size .single-content li {
    font-size: var(--ew-ss-font-size) !important;
    line-height: 1.7 !important;
}

/* ── Mobile ── */

@media (max-width: 768px) {
    .ew-ss-toolbar {
        margin-top: 8px;
    }

    .ew-ss-toolbar-float {
        bottom: 16px;
        left: 16px;
    }

    .ew-ss-btn {
        width: 32px;
        height: 32px;
    }
}
