/* The embeddable quote widget (/embed/quotes). Self-contained: the only stylesheet of the page.
   Selectgo's monochrome look: near-black text on a soft grey card, no shadows, site typography.
   The card fills the iframe (default 320px): short quotes sit centred, long quotes scroll inside
   the body while the author and the link back stay visible in the footer. */
:root {
    --qe-fg: #1d1d1f;
    --qe-muted: #6e6e73;
    --qe-line: #d2d2d7;
    --qe-bg: #f5f5f7;
    --qe-mark: #b0b0b5;
    /* Light only: the host page's own theme is unknown, and a dark card on a light page reads as broken. */
    color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; margin: 0; padding: 0; background: transparent; }
body {
    color: var(--qe-fg);
    font-family: "Segoe UI", "Segoe UI Midlevel", Inter, system-ui, -apple-system, sans-serif;
    font-size: 16px;
    line-height: 1.55;
    -webkit-text-size-adjust: 100%;
    overflow: hidden;
}
.qe {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 120px;
    margin: 0;
    border: 1px solid var(--qe-line);
    border-radius: 12px;
    background: var(--qe-bg);
    overflow: hidden;
}
.qe__body {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    padding: 20px 24px 12px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--qe-line) transparent;
    text-align: center;
}
.qe__body:focus-visible { outline: 2px solid var(--qe-fg); outline-offset: -4px; }
/* Centred while it fits, top-aligned and scrollable when it does not (margin auto never clips). */
.qe__body > :first-child { margin-top: auto; }
.qe__body > :last-child { margin-bottom: auto; }
.qe__mark { display: block; height: 30px; color: var(--qe-mark); font: 700 60px/1 Georgia, "Times New Roman", serif; }
.qe__text {
    margin: 10px 0 0;
    font-size: clamp(17px, 4.4vw, 22px);
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: -.01em;
    white-space: pre-line;
    overflow-wrap: anywhere;
}
.qe__foot {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 16px;
    border-top: 1px solid var(--qe-line);
    font-size: 14px;
}
.qe__by { min-width: 0; color: var(--qe-muted); }
.qe__author { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qe__author::before { content: "— "; }
.qe__source { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.qe__link {
    flex: 0 0 auto;
    color: var(--qe-fg);
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}
.qe__link:hover { text-decoration: underline; text-underline-offset: 3px; }
.qe__link:focus-visible { outline: 2px solid var(--qe-fg); outline-offset: 2px; border-radius: 2px; }
.qe--empty p { margin: 8px 0 0; color: var(--qe-muted); font-size: 15px; }
@media (max-width: 360px) {
    .qe__body { padding: 16px 16px 10px; }
    .qe__foot { padding: 8px 12px; }
}
/* First-party embed preview: compact editorial card, without changing installed widgets. */
.qe-preview .qe { border-color: #e5e7eb; border-radius: 10px; }
.qe-preview .qe__body { padding: 14px 16px 0; text-align: left; }
.qe-preview .qe__mark { display: none; }
.qe-preview .qe__text { margin: 0; font-family: Cambria, Georgia, serif; font-size: 18px; font-weight: 400; line-height: 1.4; }
.qe-preview .qe__foot { flex-wrap: wrap; gap: 8px; padding: 10px 16px 16px; border: 0; }
.qe-preview .qe__by { flex-basis: 100%; }
.qe-preview .qe__link { margin-left: auto; font-weight: 400; }
