/* Body-level floating surface; no inline slot, mounting section or expansion mode. */
.illum-launcher,.illum-panel { position:fixed; right:max(16px,env(safe-area-inset-right)); bottom:max(16px,env(safe-area-inset-bottom)); z-index:60; color:var(--charcoal); background:var(--alabaster); border:1px solid rgba(64,59,55,.24); border-radius:8px; box-shadow:0 10px 32px rgba(64,59,55,.18),inset 0 1px 0 rgba(255,255,255,.6); }
.illum-launcher { display:flex; gap:10px; align-items:center; min-height:52px; padding:9px 16px 9px 10px; font-size:13px; font-weight:600; cursor:pointer; transition:background-color 220ms ease,transform 220ms ease,box-shadow 220ms ease; }
.illum-launcher:hover { background:var(--mushroom); transform:translateY(-1px); box-shadow:0 12px 35px rgba(64,59,55,.23); }
/* Exact existing raster mark, isolated by viewport; no new/generated logo geometry. */
.illum-mark { display:block; flex:0 0 34px; width:34px; height:34px; background-image:url('/assets/cfr-mandala-icon.svg'); background-repeat:no-repeat; background-size:contain; background-position:center; }
.illum-panel { width:min(430px,calc(100vw - 32px)); max-height:calc(100dvh - 32px); overflow:auto; }
.illum-header { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:13px 15px; border-bottom:1px solid var(--mushroom); }
.illum-heading { display:flex; align-items:center; gap:9px; }
.illum-heading h2 { margin:0; font:600 15px/1.3 Montserrat,Arial,sans-serif; letter-spacing:0; }
.illum-close { padding:10px 4px; min-height:44px; border:0; background:none; color:inherit; cursor:pointer; font-size:12px; }
.illum-close:hover { text-decoration:underline; }
.illum-body { padding:20px; font-size:14px; }
.illum-preview { font-size:11px; line-height:1.6; color:var(--charcoal); }
.illum-body nav { display:grid; gap:9px; margin:20px 0; }
.illum-body nav a,.illum-demo { display:block; padding:10px 13px; border:1px solid var(--mushroom); border-radius:4px; font-size:13px; background:rgba(216,206,194,.23); color:inherit; text-decoration:none; text-align:left; min-height:44px; }
.illum-body nav a:hover,.illum-demo:hover { background:var(--mushroom); }
.illum-demo { cursor:pointer; width:100%; }
.illum-result { margin-top:18px; font-size:12px; }
.illum-result:empty { display:none; }
.illum-launcher[hidden],.illum-panel[hidden] { display:none; }
body:has(.illum-launcher) footer { padding-bottom:94px; }
@media(max-width:760px) { .illum-launcher,.illum-panel { right:max(12px,env(safe-area-inset-right)); bottom:max(12px,env(safe-area-inset-bottom)); }.illum-panel { width:calc(100vw - 24px); max-height:calc(100dvh - 24px); } }
@media(prefers-reduced-motion:reduce) { .illum-launcher { transition:none; }.illum-launcher:hover { transform:none; } }
@media print { .illum-launcher,.illum-panel { display:none; } }
/* Glass preset adapted to the Home headline: steady material while the page scrolls. */
.illum-launcher,.illum-panel {
  border-radius:4px;
  border:1px solid rgba(244,237,230,.65);
  box-shadow:inset 0 1px 0 rgba(244,237,230,.8),0 18px 48px rgba(64,59,55,.16);
}
@supports ((backdrop-filter:blur(18px)) or (-webkit-backdrop-filter:blur(18px))) {
  .illum-launcher,.illum-panel {
    background:rgba(244,237,230,.78);
    backdrop-filter:blur(18px); -webkit-backdrop-filter:blur(18px);
  }
  .illum-launcher:hover { background:rgba(244,237,230,.88); }
}
.illum-header { background:transparent; border-bottom-color:rgba(64,59,55,.15); }
.illum-body nav a,.illum-demo { background:rgba(244,237,230,.3); border-color:rgba(64,59,55,.2); transition:background-color 220ms ease; }
.illum-body nav a:hover,.illum-demo:hover { background:rgba(244,237,230,.65); }
@media(prefers-reduced-motion:reduce) { .illum-body nav a,.illum-demo { transition:none; } }
.illum-panel { height:min(600px,75dvh); display:flex; flex-direction:column; overflow:hidden; }
.illum-header { flex:0 0 auto; }
.illum-messages { flex:1 1 auto; min-height:0; overflow:auto; padding:18px; overscroll-behavior:contain; }
.illum-message { padding:12px 14px; margin-bottom:14px; border:1px solid rgba(64,59,55,.16); border-radius:4px; background:rgba(244,237,230,.45); font-size:13px; line-height:1.65; overflow-wrap:anywhere; }
.illum-message.user { margin-left:24px; background:rgba(216,206,194,.6); }
.illum-message p { margin:0 0 10px; }.illum-message p:last-child { margin:0; }
.illum-message h3 { font-size:15px; margin:0 0 10px; }.illum-message ul,.illum-message ol { padding-left:20px; }
.illum-status { flex:0 0 auto; margin:0; padding:0 18px; font-size:12px; }
.illum-status:empty { display:none; }
.illum-terms { flex:0 0 auto; font-size:10px; line-height:1.5; padding:8px 14px; border-top:1px solid rgba(64,59,55,.12); }
.illum-form { flex:0 0 auto; display:flex; gap:8px; padding:10px; border-top:1px solid rgba(64,59,55,.15); }
.illum-form textarea { flex:1; min-width:0; min-height:44px; max-height:120px; resize:none; padding:11px; font:13px/1.5 Montserrat,Arial,sans-serif; color:var(--charcoal); background:rgba(244,237,230,.6); border:1px solid rgba(64,59,55,.3); border-radius:4px; }
.illum-form button { min-height:44px; align-self:flex-end; padding:10px 15px; border:1px solid rgba(64,59,55,.25); border-radius:4px; color:var(--charcoal); background:rgba(216,206,194,.8); cursor:pointer; font-size:12px; }
.illum-form button:disabled { opacity:.6; cursor:wait; }
.illum-sr { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
@media(max-width:760px){.illum-panel { height:min(600px,78dvh); }}

.illum-panel { transform-origin:bottom right; }

/* Template external-window icon and compact close control, with full touch targets. */
.illum-header-actions { display:flex; align-items:center; gap:2px; flex-shrink:0; }
.illum-header-actions a,.illum-header-actions button {
 display:inline-flex; align-items:center; justify-content:center; width:44px; height:44px;
 padding:0; border:1px solid transparent; border-radius:4px; background:transparent;
 color:inherit; cursor:pointer; text-decoration:none; transition:background-color 220ms ease,border-color 220ms ease;
}
.illum-header-actions svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.illum-header-actions a:hover,.illum-header-actions button:hover { background:rgba(244,237,230,.55); border-color:rgba(64,59,55,.2); text-decoration:none; }
.illum-header-actions a:focus-visible,.illum-header-actions button:focus-visible { outline:2px solid var(--charcoal); outline-offset:2px; }
.illum-heading { min-width:0; }
@media(prefers-reduced-motion:reduce) { .illum-header-actions a,.illum-header-actions button { transition:none; } }

.illum-launcher.illum-pointer-focus:focus,.illum-header-actions .illum-close.illum-pointer-focus:focus { outline:none; }

/* Immediate, in-panel tooltip: stays inside the clipped floating surface. */
.illum-header { position:relative; z-index:2; }
.illum-window .illum-tooltip {
 position:absolute; top:calc(100% - 5px); right:14px; max-width:calc(100% - 28px);
 width:max-content; padding:9px 12px; border-radius:4px;
 background:var(--charcoal); color:var(--alabaster); box-shadow:0 4px 14px rgba(0,0,0,.16);
 font:500 11px/1.5 Montserrat,Arial,sans-serif; text-align:center;
 opacity:0; visibility:hidden; pointer-events:none;
}
.illum-window:focus-visible .illum-tooltip { opacity:1; visibility:visible; pointer-events:auto; }
@media(hover:hover) { .illum-window:hover .illum-tooltip { opacity:1; visibility:visible; pointer-events:auto; } }
/* Avoid iOS focus zoom while preserving browser pinch-to-zoom. */
@media(max-width:760px){.illum-form textarea{font-size:16px}}
/* Tuck the closed launcher closer to the mobile edge; retain the device safe area. */
@media(max-width:760px){.illum-launcher{bottom:max(6px,env(safe-area-inset-bottom))}}

.illum-scripted-word{display:inline-block;white-space:nowrap}.illum-scripted-character{display:inline-block}
.illum-message.illum-wait-notice{color:#425b4e;background:rgba(137,144,122,.12);border:1px solid rgba(137,144,122,.3);padding:12px;border-radius:5px}
[data-theme="dark"] .illum-message.illum-wait-notice{color:#c6d4bd;background:rgba(137,144,122,.15)}

/* Builder themes must not override the floating widget typography. */
.illum-panel :is(h1,h2,h3,h4,h5,h6) { color:inherit !important; }

.illum-terms a { text-decoration:underline !important; text-underline-offset:2px; }
