:root {
    --ink: #17233a;
    --muted: #68738a;
    --navy: #173b66;
    --blue: #2869a8;
    --gold: #b78b38;
    --cream: #f7f4ed;
    --white: #ffffff;
    --line: #dfe4ec;
    --success: #177245;
    --danger: #a52a2a;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--ink);
    background: var(--cream);
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: linear-gradient(160deg, #f8f5ee 0%, #edf2f8 100%); }
.shell { width: min(1120px, calc(100% - 32px)); margin: 0 auto; padding: 44px 0 64px; }
.shell-narrow { width: min(520px, calc(100% - 32px)); padding-top: 12vh; }
.hero { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(2rem, 5vw, 3.6rem); letter-spacing: -0.04em; margin-bottom: 8px; }
h2 { font-size: 1.28rem; margin-bottom: 10px; }
h3 { font-size: 1.05rem; line-height: 1.45; }
.eyebrow, .section-label { color: var(--gold); font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 8px; }
.subtitle, .action-card p, .result-card p, .status-copy p { color: var(--muted); line-height: 1.6; }
.panel { background: rgba(255,255,255,.96); border: 1px solid rgba(23,59,102,.1); border-radius: 18px; box-shadow: 0 12px 36px rgba(23,35,58,.08); }
.login-panel { padding: 34px; }
.login-form { display: grid; gap: 12px; margin-top: 26px; }
.login-form label { font-weight: 700; }
.login-form input { width: 100%; padding: 13px 14px; border: 1px solid var(--line); border-radius: 10px; font-size: 1rem; }
.status-pill { display: inline-flex; padding: 8px 13px; border-radius: 999px; background: #e9edf3; color: var(--navy); font-weight: 800; text-transform: capitalize; }
.status-pill.running, .status-pill.queued { background: #fff2cf; color: #805b0e; }
.status-pill.complete { background: #dff5e9; color: var(--success); }
.status-pill.error { background: #fde3e3; color: var(--danger); }
.notice { padding: 13px 16px; margin-bottom: 18px; border-radius: 12px; background: #edf3fa; color: var(--navy); font-weight: 650; }
.notice.success { background: #dff5e9; color: var(--success); }
.notice.error { background: #fde3e3; color: var(--danger); }
.status-panel { padding: 24px; margin-bottom: 22px; }
.status-copy h2 { margin-bottom: 4px; }
.status-copy p { margin-bottom: 0; }
.progress-track { height: 10px; margin-top: 20px; overflow: hidden; background: #e9edf3; border-radius: 999px; }
.progress-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--gold), var(--blue)); transition: width .35s ease; }
.action-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.action-card { position: relative; display: flex; flex-direction: column; min-height: 315px; padding: 26px; }
.action-card p { flex: 1; }
.step-number { display: grid; place-items: center; width: 38px; height: 38px; margin-bottom: 22px; border-radius: 12px; background: var(--navy); color: var(--white); font-weight: 900; }
.future-card { opacity: .72; }
.button { display: inline-flex; justify-content: center; width: 100%; border: 0; border-radius: 11px; padding: 13px 16px; font: inherit; font-weight: 800; cursor: pointer; }
.button { align-items: center; text-decoration: none; }
.button.primary { color: white; background: var(--navy); }
.button.secondary { color: white; background: var(--blue); }
.button.disabled, .button:disabled { color: #7f8794; background: #e4e7eb; cursor: not-allowed; }
.button:not(:disabled):hover { filter: brightness(1.08); transform: translateY(-1px); }
.requirement { flex: 0 !important; margin: 10px 0 0; font-size: .82rem; text-align: center; }
.results-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 22px; }
.result-card { padding: 24px; }
dl { display: grid; gap: 10px; margin-bottom: 0; }
dl div { display: flex; justify-content: space-between; gap: 18px; padding-top: 10px; border-top: 1px solid var(--line); }
dt { color: var(--muted); }
dd { margin: 0; font-weight: 700; text-align: right; }
.result-actions { margin-top: 20px; }
.transcript-shell { width: min(900px, calc(100% - 32px)); }
.transcript-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 20px; }
.transcript-toolbar .button { width: auto; }
.transcript-panel { padding: clamp(22px, 5vw, 46px); }
.transcript-panel h1 { font-size: clamp(1.8rem, 5vw, 3rem); }
.transcript-meta { color: var(--muted); margin-bottom: 28px; }
.transcript-body { white-space: pre-wrap; overflow-wrap: anywhere; font-family: Georgia, "Times New Roman", serif; font-size: 1.08rem; line-height: 1.8; color: #202a3a; }

.simple-shell { width: min(720px, calc(100% - 28px)); }
.simple-hero { display: grid; grid-template-columns: 72px 1fr auto; align-items: center; gap: 18px; margin-bottom: 24px; }
.simple-hero h1 { margin: 0; font-size: clamp(2rem, 7vw, 3.25rem); }
.simple-hero .eyebrow { margin-bottom: 4px; }
.app-mark { width: 72px; height: 72px; border-radius: 17px; box-shadow: 0 8px 22px rgba(7,28,59,.18); }
.simple-status { margin-bottom: 18px; padding: 14px 18px; border-radius: 12px; background: rgba(255,255,255,.72); color: var(--navy); text-align: center; }
.simple-status .progress-track { margin-top: 12px; }
.simple-actions { display: grid; gap: 14px; }
.simple-actions form { margin: 0; }
.download-options { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 5px 12px; margin-top: 9px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.72); }
.download-options label { font-weight: 800; }
.download-options label span, .download-options small { color: var(--muted); font-weight: 500; }
.download-options input { padding: 8px 10px; border: 1px solid #cfd6e0; border-radius: 8px; background: white; color: var(--ink); font: inherit; }
.download-options small { grid-column: 1 / -1; }
.download-choice-list { display: grid; gap: 14px; margin-top: 22px; }
.download-choice-panel { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 18px; }
.download-choice-panel > div { display: grid; gap: 4px; }
.download-choice-panel small { color: var(--muted); }
.download-choice-panel .button { width: auto; min-width: 120px; }
.date-choice-panel { grid-template-columns: minmax(0, 1fr) auto auto; }
.date-choice-panel input { padding: 10px 11px; border: 1px solid #cfd6e0; border-radius: 8px; background: white; color: var(--ink); font: inherit; }
.recent-audio { margin-top: 28px; }
.recent-audio > h2 { margin-bottom: 10px; font-size: .88rem; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }
.audio-reference-row > small { color: var(--muted); white-space: nowrap; }
.big-action { display: flex; align-items: center; gap: 16px; width: 100%; min-height: 72px; padding: 14px 20px; border: 0; border-radius: 15px; color: white; font: inherit; font-size: 1.18rem; font-weight: 850; text-align: left; cursor: pointer; box-shadow: 0 9px 24px rgba(23,35,58,.13); transition: transform .15s ease, filter .15s ease; }
.big-action { text-decoration: none; }
.big-action span { display: grid; place-items: center; flex: 0 0 40px; width: 40px; height: 40px; border-radius: 50%; background: rgba(255,255,255,.18); font-weight: 900; }
.big-action.download { background: var(--navy); }
.big-action.transcribe { background: var(--blue); }
.big-action.transcripts { background: #247a64; }
.big-action.guide { background: var(--gold); }
.big-action.library { background: #5b477d; }
.big-action:not(:disabled):hover { filter: brightness(1.08); transform: translateY(-1px); }
.big-action:disabled { background: #cfd4dc; color: #737b88; box-shadow: none; cursor: not-allowed; }
.simple-results { margin-top: 28px; }
.simple-results h2 { margin-bottom: 10px; font-size: .88rem; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }
.file-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 18px; border-top: 1px solid var(--line); background: rgba(255,255,255,.7); }
.file-row:first-of-type { border-radius: 13px 13px 0 0; border-top: 0; }
.file-row:last-child { border-radius: 0 0 13px 13px; }
.file-row > div { display: grid; gap: 3px; }
.file-label { color: var(--muted); font-size: .8rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.view-link { flex: 0 0 auto; padding: 10px 14px; border-radius: 10px; background: var(--blue); color: white; font-weight: 800; text-decoration: none; }
.guide-link { background: var(--gold); }
.guide-library { margin-top: 28px; }
.guide-library > h2 { margin-bottom: 10px; font-size: .88rem; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }
.library-list { display: grid; gap: 10px; }
.library-row, .library-empty { padding: 16px 18px; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,.75); }
.library-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.library-row > div { display: grid; gap: 3px; }
.library-row span, .library-row small, .library-empty { color: var(--muted); }
.library-row span { font-size: .82rem; font-weight: 800; }
.library-actions { display: flex !important; align-items: center; gap: 8px !important; }
.transcript-library-row > div:first-child { min-width: 0; }
.transcript-library-row strong { overflow-wrap: anywhere; }
.sermon-picker { margin-top: 22px; }
.sermon-picker-list { display: grid; gap: 12px; }
.sermon-choice { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 18px; }
.sermon-choice-copy { display: grid; gap: 4px; }
.sermon-choice-copy span, .sermon-choice-copy small { color: var(--muted); }
.sermon-choice-copy span { font-size: .82rem; font-weight: 800; }
.guide-library-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 3px; }
.sermon-choice-copy .guide-final-status { display: inline-flex; align-items: center; width: fit-content; padding: 4px 8px; border-radius: 999px; font-size: .75rem; font-weight: 850; }
.sermon-choice-copy .guide-final-status.is-finalized { background: #e7f5ee; color: #2f7d5c; }
.sermon-choice-copy .guide-final-status.is-website-current { background: #e8effa; color: var(--navy); }
.sermon-choice-copy .guide-final-status.not-finalized { background: #fff4d6; color: #805e12; }
.sermon-choice-actions { display: flex; align-items: center; gap: 8px; }
.sermon-choice-actions .view-link { text-align: center; }
.sermon-choice-actions.single-action { display: block; }
.guide-library-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 20px 0; }
.button.archive-button { background: #edf1f7; color: var(--navy); border: 1px solid #c6d0df; }
.guide-archive-actions { display: grid; grid-template-columns: 1fr; flex: 0 0 135px; }
.guide-archive-actions form { margin: 0; }
.guide-archive-actions .button, .guide-archive-actions .view-link { width: 100%; min-height: 44px; padding: 10px 12px; font-size: .9rem; }
.sermon-choice-copy { min-width: 0; overflow-wrap: anywhere; }
.editor-shell { width: min(1480px, calc(100% - 28px)); }
.editor-panel { padding: clamp(22px, 5vw, 42px); }
.editor-login-panel { width: min(520px, 100%); margin: 8vh auto 0; padding: clamp(24px, 5vw, 38px); }
.generation-empty-state { display: grid; gap: 12px; padding: 8px; text-align: center; }
.generation-empty-state p { color: var(--muted); }
.generation-empty-state .button { width: min(260px, 100%); margin: 0 auto; }
.guide-editor-form { display: grid; gap: 12px; }
.guide-editor-form label { font-weight: 850; }
.editor-heading { margin-bottom: 18px; }
.editor-heading h1 { margin-bottom: 0; }
.editor-sermon-date { margin: 6px 0 0; color: var(--muted); font-weight: 700; }
.editor-workspace, .editor-workspace > *, .guide-editor-form, .format-toolbar, .editor-save-top, .editor-view-frame { min-width: 0; max-width: 100%; }
.view-switch { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 10px; background: rgba(255,255,255,.85); }
.view-switch button { padding: 8px 10px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); font: inherit; font-size: .85rem; font-weight: 800; cursor: pointer; }
.view-switch button.active { background: var(--navy); color: white; }
.editor-workspace { display: grid; grid-template-columns: minmax(0, 1fr); align-items: start; gap: 12px; }
.draft-panel { display: grid; gap: 10px; padding: 14px 18px; }
.draft-panel-heading { display: flex; align-items: baseline; gap: 8px; }
.draft-panel-heading h2 { margin-bottom: 0; }
.draft-panel-heading span { color: var(--muted); font-size: .78rem; font-weight: 750; }
.draft-panel > p { color: var(--muted); }
.draft-toolbar-row { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 8px; }
.draft-chooser-form { display: flex; align-items: flex-end; gap: 8px; flex: 1 1 340px; margin: 0; }
.draft-chooser-form label { display: grid; gap: 4px; flex: 1 1 180px; color: var(--muted); font-size: .78rem; font-weight: 800; }
.draft-chooser-form select { width: 100%; min-height: 40px; padding: 7px 10px; border: 1px solid #cfd6e0; border-radius: 7px; background: white; color: var(--ink); font: inherit; font-weight: 750; }
.draft-chooser-form .button { width: auto; min-height: 40px; padding: 8px 12px; }
.draft-meta { align-self: center; color: var(--muted); font-size: .82rem; font-weight: 700; }
.draft-status-label { align-self: center; padding: 5px 8px; border-radius: 999px; background: #e7f5ee; font-size: .78rem; }
.draft-list { display: grid; gap: 8px; }
.draft-item { display: grid; gap: 5px; }
.draft-link { display: grid; gap: 2px; padding: 10px 11px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); text-decoration: none; }
.draft-link span { color: var(--muted); font-size: .72rem; }
.draft-link.current { border-color: var(--blue); background: #edf4fb; }
.draft-delete-form { margin: 0; }
.draft-delete-form button { width: 100%; padding: 6px 8px; border: 1px solid #e2bcbc; border-radius: 7px; background: #fff5f5; color: var(--danger); font: inherit; font-size: .78rem; font-weight: 800; cursor: pointer; }
.current-draft-delete-form, .delete-all-drafts-form { align-self: center; }
.delete-all-drafts-form { margin: 0; padding: 0; border-top: 0; }
.delete-all-drafts-form button { width: 100%; padding: 9px 8px; border: 1px solid var(--danger); border-radius: 7px; background: var(--danger); color: white; font: inherit; font-size: .82rem; font-weight: 850; cursor: pointer; }
.format-toolbar { position: sticky; top: 0; z-index: 2; display: flex; flex-wrap: wrap; gap: 6px; padding: 9px; border: 1px solid var(--line); border-bottom: 0; border-radius: 12px 12px 0 0; background: #f4f6f9; }
.guide-editor-form.view-mode-desktop .format-toolbar { flex-wrap: nowrap; overflow-x: auto; }
.guide-editor-form.view-mode-desktop .format-toolbar > * { flex: 0 0 auto; }
.format-toolbar button, .format-toolbar select { min-height: 38px; padding: 7px 10px; border: 1px solid #cfd6e0; border-radius: 7px; background: white; color: var(--ink); font: inherit; font-weight: 750; cursor: pointer; }
.format-toolbar button:hover, .format-toolbar select:hover { border-color: var(--blue); }
.more-format-panel { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding: 10px; border: 1px solid var(--line); border-top: 0; background: #f4f6f9; }
.more-format-panel[hidden] { display: none; }
.more-format-panel label { display: grid; gap: 5px; color: var(--muted); font-size: .82rem; font-weight: 800; }
.more-format-panel select { width: 100%; min-height: 40px; padding: 7px 10px; border: 1px solid #cfd6e0; border-radius: 7px; background: white; color: var(--ink); font: inherit; }
.more-panel-actions { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr; gap: 8px; }
.more-panel-actions .button { width: 100%; padding: 9px 10px; }
.link-panel { display: grid; gap: 10px; padding: 12px; border: 1px solid var(--line); border-top: 0; background: #f4f6f9; }
.link-panel[hidden] { display: none; }
.link-panel label { display: grid; gap: 5px; color: var(--muted); font-size: .82rem; font-weight: 800; }
.link-panel input { width: 100%; min-height: 42px; padding: 8px 10px; border: 1px solid #cfd6e0; border-radius: 7px; background: white; color: var(--ink); font: inherit; }
.link-panel-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.link-panel-actions .button { width: 100%; padding: 9px 10px; }
.link-error { margin: 0; color: var(--danger); font-size: .86rem; font-weight: 750; }
.more-format-panel, .link-panel { position: fixed; z-index: 60; max-height: calc(100vh - 16px); overflow-y: auto; border-top: 1px solid var(--line); border-radius: 10px; box-shadow: 0 10px 30px rgba(23,35,58,.24); }
.quick-color-panel { position: fixed; z-index: 70; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; width: min(420px, calc(100vw - 16px)); padding: 8px; border: 1px solid #c9d1dc; border-radius: 10px; background: #fff; box-shadow: 0 10px 30px rgba(23,35,58,.24); }
.quick-color-panel[hidden] { display: none; }
.quick-color-panel button { min-height: 38px; padding: 7px 8px; border: 1px solid #cfd6e0; border-radius: 7px; background: #fff; color: var(--ink); font: inherit; font-size: .82rem; font-weight: 800; cursor: pointer; }
.quick-color-panel button:hover { border-color: var(--blue); }
.rich-guide-editor a { color: #175fa5; text-decoration: underline; text-underline-offset: 2px; }
.rich-guide-editor .link-selection-marker { border-radius: 3px; background: #dbeafe; }
.editor-save-top { display: flex; justify-content: flex-end; gap: 8px; padding: 10px 0; }
.editor-save-top .button { width: auto; min-width: 180px; }
.finalize-button { border-color: #2f7d5c; background: #2f7d5c; color: white; }
.finalize-choice-backdrop { position: fixed; z-index: 120; inset: 0; display: grid; place-items: center; padding: 18px; background: rgba(7,28,59,.55); }
.finalize-choice-backdrop[hidden] { display: none; }
.finalize-choice-panel { width: min(520px, 100%); padding: 24px; border-radius: 16px; background: white; box-shadow: 0 20px 60px rgba(7,28,59,.3); }
.finalize-choice-panel h2 { margin-bottom: 8px; }
.finalize-choice-panel p { color: var(--muted); line-height: 1.55; }
.finalize-choice-actions { display: grid; gap: 9px; }
.guide-helper-button { border-color: #5e4d84; background: #5e4d84; color: white; }
.guide-helper-layout { display: grid; grid-template-columns: minmax(0, 1fr); align-items: start; gap: 16px; min-width: 0; }
.guide-helper-layout.helper-open { grid-template-columns: minmax(0, 1fr) minmax(340px, 410px); }
.guide-helper-layout.helper-open .editor-view-frame.view-desktop .rich-guide-editor { width: 100%; }
.guide-helper-panel { position: sticky; top: 12px; display: grid; gap: 12px; max-height: calc(100vh - 24px); padding: 18px; overflow-y: auto; border: 1px solid #cfd8e6; border-radius: 14px; background: #f8fafc; box-shadow: 0 12px 32px rgba(23,35,58,.13); }
.guide-helper-panel[hidden] { display: none; }
.guide-helper-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.guide-helper-heading h2, .guide-helper-heading p { margin: 0; }
.guide-helper-heading p { color: var(--muted); font-size: .88rem; }
.guide-helper-heading > button { width: 34px; height: 34px; padding: 0; border: 1px solid #cfd6e0; border-radius: 8px; background: white; color: var(--ink); font: inherit; font-size: 1.45rem; line-height: 1; cursor: pointer; }
.guide-helper-panel > label { color: var(--ink); font-size: .85rem; font-weight: 850; }
.guide-helper-panel select, .guide-helper-panel textarea { width: 100%; padding: 10px 11px; border: 1px solid #c7d0dc; border-radius: 9px; background: white; color: var(--ink); font: inherit; }
.guide-helper-panel textarea { min-height: 105px; resize: vertical; }
.guide-helper-messages { display: grid; gap: 8px; max-height: 190px; padding: 10px; overflow-y: auto; border: 1px solid #dde3eb; border-radius: 10px; background: white; }
.guide-helper-message, .guide-helper-note { margin: 0; font-size: .85rem; line-height: 1.45; }
.guide-helper-message.user { color: var(--navy); }
.guide-helper-message.assistant, .guide-helper-note { color: var(--muted); }
.guide-helper-preview { display: grid; gap: 9px; padding: 12px; border: 2px solid #90b5dc; border-radius: 11px; background: white; }
.guide-helper-preview[hidden] { display: none; }
.guide-helper-preview > p { margin: 0; color: var(--muted); font-size: .88rem; }
.guide-helper-preview-content { max-height: 310px; padding: 12px; overflow: auto; border: 1px solid #d7dee8; border-radius: 8px; background: #fff; color: var(--ink); font: .9rem/1.5 Georgia, "Times New Roman", serif; }
.guide-helper-preview-content h1 { font-size: 1.35rem; }
.guide-helper-preview-content h2 { font-size: 1.15rem; }
.guide-helper-preview-content h3 { font-size: 1rem; }
.guide-helper-preview-content img { max-width: 100%; height: auto; }
.guide-helper-preview-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.guide-helper-preview-actions .button { min-width: 0; padding: 9px; font-size: .82rem; }
.guide-helper-preview-actions #guideHelperApply { grid-column: 1 / -1; }
.guide-helper-submit { background: var(--navy); color: white; }
.guide-helper-status { min-height: 1.4em; margin: 0; color: var(--muted); font-size: .84rem; font-weight: 750; }
.finalized-link-panel { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; padding: 16px 18px; }
.finalized-link-panel > div:first-child { display: grid; gap: 3px; }
.finalized-link-panel span { color: var(--muted); font-size: .85rem; }
.finalized-link-actions { display: flex; gap: 8px; }
.finalized-link-actions .button { width: auto; }
.finalized-draft-label { color: #2f7d5c !important; font-weight: 850; }
.color-control { display: inline-flex; align-items: center; gap: 4px; min-height: 38px; padding: 5px 8px; border: 1px solid #cfd6e0; border-radius: 7px; background: white; font-weight: 850; }
.color-control input { width: 30px; height: 26px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.editor-view-frame { width: 100%; overflow-x: auto; padding: 0 0 4px; }
.rich-guide-editor { min-height: 62vh; padding: 24px; overflow-wrap: anywhere; border: 1px solid var(--line); border-radius: 0 0 12px 12px; background: #fff; color: var(--ink); font: 1rem/1.65 Georgia, "Times New Roman", serif; }
.editor-view-frame.view-mobile .rich-guide-editor { width: min(390px, 100%); margin: 0 auto; }
.editor-view-frame.view-desktop .rich-guide-editor { width: 1100px; max-width: none; margin: 0 auto; }
.rich-guide-editor:focus { outline: 3px solid rgba(40,105,168,.2); border-color: var(--blue); }
.rich-guide-editor h1 { font-size: 2rem; }
.rich-guide-editor h2 { font-size: 1.45rem; }
.rich-guide-editor h3 { font-size: 1.15rem; }
.rich-guide-editor ol { margin-left: 0; padding-left: 0; list-style: none; }
.rich-guide-editor ol > li { position: relative; padding-left: 2em; }
.rich-guide-editor ol > li::before { content: attr(data-list-number) "."; position: absolute; left: 0; width: 1.7em; text-align: left; font-weight: inherit; }
.rich-guide-editor ul { margin-left: 2em; margin-bottom: 1.35em; padding-left: 1.5em; list-style-type: disc; list-style-position: outside; }
.rich-guide-editor ul > li::marker { color: #000; }
.rich-guide-editor .leader-helper { color: #e51f1f; }
.rich-guide-editor .sermon-overview-leader { color: #e51f1f; }
.rich-guide-editor .leader-help-key { color: #e51f1f; font-size: 14pt; font-weight: 700; }
.rich-guide-editor li { padding-left: .2em; }
.rich-guide-editor .number-follow-text { margin-left: 2em; }
.rich-guide-editor::after { display: block; clear: both; content: ""; }
.rich-guide-editor .guide-inserted-image { display: block; width: auto; max-width: 100%; height: auto; margin-top: 1em; margin-bottom: 1em; border-radius: 8px; cursor: pointer; }
.rich-guide-editor .guide-image-align-left { margin-left: 0; margin-right: auto; }
.rich-guide-editor .guide-image-align-center { margin-left: auto; margin-right: auto; }
.rich-guide-editor .guide-image-align-right { margin-left: auto; margin-right: 0; }
.rich-guide-editor .guide-image-wrap-left { float: left; margin: .35em 1.1em .8em 0; }
.rich-guide-editor .guide-image-wrap-right { float: right; margin: .35em 0 .8em 1.1em; }
.final-guide-body .guide-inserted-image { cursor: default; }
.image-upload-status { margin: 0; padding: 9px 12px; border: 1px solid #b9ddcb; border-radius: 8px; background: #eef9f3; color: #246348; font-size: .88rem; font-weight: 800; }
.image-upload-status.is-error { border-color: #e2bcbc; background: #fff5f5; color: var(--danger); }
.image-toolbar { position: fixed; z-index: 80; display: flex; align-items: center; flex-wrap: wrap; gap: 7px; max-width: calc(100vw - 16px); max-height: calc(100vh - 16px); padding: 9px; overflow-y: auto; border: 1px solid #b7c5d8; border-radius: 10px; background: #fff; box-shadow: 0 10px 30px rgba(23,35,58,.26); }
.image-toolbar[hidden], .image-resize-box[hidden] { display: none; }
.image-toolbar-group { display: flex; align-items: center; flex-wrap: wrap; gap: 4px; padding-right: 6px; border-right: 1px solid var(--line); }
.image-toolbar-group > span { color: var(--muted); font-size: .74rem; font-weight: 850; text-transform: uppercase; }
.image-toolbar button { min-height: 34px; padding: 6px 8px; border: 1px solid #cfd6e0; border-radius: 6px; background: #fff; color: var(--ink); font: inherit; font-size: .78rem; font-weight: 800; cursor: pointer; }
.image-toolbar button.active { border-color: var(--blue); background: #e8f1fb; color: var(--navy); }
.image-toolbar .image-remove-button { border-color: #e2bcbc; color: var(--danger); }
.image-resize-box { position: fixed; z-index: 70; border: 2px solid var(--blue); pointer-events: none; }
.image-resize-handle { position: absolute; width: 15px; height: 15px; padding: 0; border: 2px solid var(--blue); border-radius: 50%; background: #fff; pointer-events: auto; touch-action: none; cursor: nwse-resize; }
.image-resize-handle.top-left { top: -9px; left: -9px; }
.image-resize-handle.top-right { top: -9px; right: -9px; }
.image-resize-handle.bottom-left { bottom: -9px; left: -9px; }
.image-resize-handle.bottom-right { right: -9px; bottom: -9px; }
.image-resize-handle.top-right, .image-resize-handle.bottom-left { cursor: nesw-resize; }
.selection-toolbar { position: fixed; z-index: 50; display: flex; align-items: center; gap: 4px; max-width: calc(100vw - 16px); padding: 7px; overflow-x: auto; border: 1px solid #c9d1dc; border-radius: 10px; background: #fff; box-shadow: 0 10px 30px rgba(23,35,58,.24); }
.selection-toolbar[hidden] { display: none; }
.selection-toolbar button, .selection-toolbar select { flex: 0 0 auto; min-height: 36px; padding: 6px 8px; border: 1px solid #cfd6e0; border-radius: 6px; background: #fff; color: var(--ink); font: inherit; font-weight: 750; }
.selection-color { display: inline-flex; align-items: center; gap: 3px; min-height: 36px; padding: 4px 6px; border: 1px solid #cfd6e0; border-radius: 6px; background: #fff; font-weight: 850; }
.selection-color input { width: 28px; height: 24px; padding: 0; border: 0; background: transparent; }
.editor-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.final-guide-shell { width: min(940px, calc(100% - 28px)); padding-bottom: 50px; }
.final-guide-heading { display: grid; grid-template-columns: 78px 1fr; align-items: center; gap: 18px; margin-bottom: 22px; }
.final-guide-heading .app-mark { width: 78px; height: 78px; }
.final-guide-heading h1 { font-size: clamp(2rem, 6vw, 3.4rem); }
.final-guide-heading p:last-child { margin-bottom: 0; color: var(--muted); }
.final-guide-card { padding: clamp(22px, 5vw, 48px); }
.final-guide-body { min-height: 0; padding: 0; border: 0; border-radius: 0; }

@media (max-width: 820px) {
    .action-grid { grid-template-columns: 1fr; }
    .action-card { min-height: 0; }
    .guide-helper-layout.helper-open { grid-template-columns: minmax(0, 1fr); }
    .guide-helper-panel { position: fixed; z-index: 100; right: 0; bottom: 0; left: 0; top: auto; max-height: 82vh; padding: 16px; border-radius: 18px 18px 0 0; box-shadow: 0 -12px 36px rgba(23,35,58,.24); }
}
@media (max-width: 620px) {
    .shell { width: min(100% - 22px, 1120px); padding-top: 26px; }
    .hero { align-items: flex-start; }
    .results-grid { grid-template-columns: 1fr; }
    .panel { border-radius: 14px; }
    .transcript-toolbar { align-items: stretch; flex-direction: column; }
    .transcript-toolbar .button { width: 100%; }
    .simple-hero { grid-template-columns: 58px 1fr; gap: 12px; }
    .simple-hero .status-pill { grid-column: 1 / -1; justify-self: start; }
    .app-mark { width: 58px; height: 58px; border-radius: 14px; }
    .big-action { min-height: 66px; }
    .file-row { align-items: flex-start; }
    .editor-workspace { grid-template-columns: 1fr; }
    .draft-list { display: flex; overflow-x: auto; }
    .draft-item { min-width: 125px; }
    .guide-editor-form.view-mode-mobile .format-toolbar { flex-wrap: wrap; overflow-x: visible; }
    .guide-editor-form.view-mode-mobile .format-toolbar > * { flex: 0 0 auto; }
    .guide-editor-form.view-mode-mobile .selection-toolbar { flex-wrap: wrap; overflow-x: visible; }
    .link-panel-actions { grid-template-columns: 1fr; }
    .image-toolbar { align-items: stretch; flex-direction: column; flex-wrap: nowrap; }
    .image-toolbar-group { border-right: 0; }
    .image-toolbar-group > span { width: 100%; }
    .image-resize-box { display: none !important; }
    .editor-save-top { display: grid; grid-template-columns: 1fr; }
    .editor-save-top .button { width: 100%; min-width: 0; }
    .editor-actions { grid-template-columns: 1fr; }
    .finalized-link-panel { align-items: stretch; flex-direction: column; }
    .finalized-link-actions { display: grid; grid-template-columns: 1fr 1fr; }
    .finalized-link-actions .button { width: 100%; }
    .final-guide-heading { grid-template-columns: 58px 1fr; gap: 12px; }
    .final-guide-heading .app-mark { width: 58px; height: 58px; }
    .view-switch { width: 100%; }
    .view-switch button { flex: 1; }
    .sermon-choice { align-items: stretch; flex-direction: column; }
    .sermon-choice-actions { display: grid; grid-template-columns: 1fr 1fr; }
    .guide-archive-actions { flex-basis: auto; }
    .transcript-library-row { align-items: stretch; flex-direction: column; }
    .library-actions { display: grid !important; grid-template-columns: 1fr 1fr; }
    .library-actions .view-link { text-align: center; }
    .download-choice-panel, .date-choice-panel { grid-template-columns: 1fr; }
    .download-choice-panel .button { width: 100%; }
    .date-choice-panel input { width: 100%; }
}
