/* =====================================================================
   Zelpophai AI — Halloween seasonal theme  (v2: illustrated scene)
   Active only while <html> has the "halloween" class (js/halloween.js:
   auto Oct 15 – Nov 2, or forced on/off in Settings → Appearance).
   Everything is scoped to html.halloween, so the normal themes (dark,
   light, owner silver, admin gold) are untouched the rest of the year.
   Artwork lives in /static/img/halloween/*.svg (hand-built vector art).
   ===================================================================== */

html.halloween body {
    --bg: #0b070e;
    --sidebar: #110b15;
    --surface: #160e1b;
    --cards: #1c1222;
    --text: #f5ebe0;
    --muted: #bfaebf;
    --input-bg: #140d19;
    --border: #3a2531;
    --hover-bg: #23141f;
    --accent: linear-gradient(135deg, #ffb347, #ff7a1a 45%, #d4520b);
    --accent-solid: #ff7a1a;
    --accent-hover: #ff9a3c;
    --user-msg: linear-gradient(135deg, #ff8a2a, #c2410c);
    --ai-msg: rgba(16, 10, 20, .84);
    --code-bg: #120b16;
    --hw-orange: #ff7a1a;
    --hw-amber: #ffb347;
    --hw-line: rgba(255, 122, 26, .45);
    --hw-glass: rgba(14, 9, 18, .78);
    --hw-serif: 'Playfair Display', 'Cormorant Garamond', Georgia, serif;
    --hw-display: 'Cinzel Decorative', 'Cinzel', Georgia, serif;
    background:
        radial-gradient(55% 45% at 58% 0%, rgba(255, 110, 20, .30), transparent 70%),
        radial-gradient(50% 40% at 70% 100%, rgba(255, 90, 10, .16), transparent 70%),
        linear-gradient(180deg, #1a0b1c 0%, #120914 45%, #0b070e 100%) fixed,
        #0b070e;
}

/* ======================= illustrated scene ======================= */
/* z-index -1: painted above the page background but beneath every piece of
   real UI, so it can never cover text or take a click */
#hw-fx { position: fixed; inset: 0; pointer-events: none; z-index: -1; overflow: hidden; }
#hw-fx .hw-art { position: absolute; background-repeat: no-repeat; }
#hw-fx .hw-sky {
    top: 0;
    left: calc(280px + (100vw - 280px) / 2);
    transform: translateX(-50%);
    width: min(1100px, 78vw);
    aspect-ratio: 1200 / 420;
    background-image: url("/static/img/halloween/sky.svg");
    background-size: 100% 100%;
    opacity: .95;
    -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 62%, transparent 100%);
}
#hw-fx .hw-left {
    left: 280px;
    bottom: 0;
    height: min(46vh, 430px);
    aspect-ratio: 420 / 520;
    background-image: url("/static/img/halloween/left.svg");
    background-size: contain;
    background-position: left bottom;
    opacity: .92;
}
#hw-fx .hw-right {
    right: 0;
    bottom: 0;
    height: min(62vh, 600px);
    aspect-ratio: 520 / 640;
    background-image: url("/static/img/halloween/right.svg");
    background-size: contain;
    background-position: right bottom;
    opacity: .92;
}
#hw-fx .hw-web {
    position: absolute;
    top: 0;
    width: 150px;
    height: 150px;
    opacity: .22;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' fill='none' stroke='%23e9dcf5' stroke-width='.6'%3E%3Cpath d='M100 0L0 100M100 0L0 40M100 0L60 100M100 0L0 0M100 0L100 100M100 0L25 100M100 0L0 70'/%3E%3Cpath d='M88 0Q90 8 100 12M72 0Q76 16 100 26M54 0Q60 26 100 44M34 0Q44 40 100 64M14 0Q28 56 100 86'/%3E%3Cpath d='M92 9Q88 13 89 17Q82 19 82 25Q74 28 74 36Q64 40 64 49Q53 54 52 64'/%3E%3C/svg%3E") no-repeat right top / contain;
}
#hw-fx .hw-web.r { right: 0; }
#hw-fx .hw-web.l { left: 280px; transform: scaleX(-1); width: 110px; height: 110px; opacity: .16; }
#hw-fx .hw-spider {
    position: absolute;
    top: 0;
    right: 64px;
    width: 1px;
    height: 70px;
    background: rgba(233, 220, 245, .35);
    animation: hwDangle 9s ease-in-out infinite;
    transform-origin: top center;
}
#hw-fx .hw-spider::after {
    content: "";
    position: absolute;
    bottom: -10px;
    left: -7px;
    width: 15px;
    height: 13px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 26'%3E%3Cg stroke='%23140c1c' stroke-width='1.6' fill='none'%3E%3Cpath d='M10 12L2 6M10 14L1 14M10 16L3 23M20 12L28 6M20 14L29 14M20 16L27 23M12 10L7 2M18 10L23 2'/%3E%3C/g%3E%3Cellipse cx='15' cy='15' rx='6' ry='7' fill='%23140c1c'/%3E%3Ccircle cx='15' cy='8' r='3.5' fill='%23140c1c'/%3E%3Ccircle cx='13.6' cy='7.6' r='.8' fill='%23ff7a1a'/%3E%3Ccircle cx='16.4' cy='7.6' r='.8' fill='%23ff7a1a'/%3E%3C/svg%3E") no-repeat center / contain;
}
@keyframes hwDangle {
    0%, 100% { height: 70px; transform: rotate(0deg); }
    40% { height: 120px; transform: rotate(2deg); }
    60% { height: 112px; transform: rotate(-2deg); }
}
#hw-fx .hw-fog {
    position: absolute;
    left: -20%;
    right: -20%;
    bottom: -40px;
    height: 220px;
    background:
        radial-gradient(40% 60% at 20% 70%, rgba(170, 140, 200, .10), transparent 70%),
        radial-gradient(35% 55% at 60% 80%, rgba(170, 140, 200, .09), transparent 70%),
        radial-gradient(30% 50% at 90% 70%, rgba(255, 140, 60, .06), transparent 70%);
    animation: hwFog 26s ease-in-out infinite alternate;
}
@keyframes hwFog { from { transform: translateX(-4%); } to { transform: translateX(4%); } }
#hw-fx .hw-bat {
    position: absolute;
    width: 34px;
    height: 16px;
    opacity: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 30'%3E%3Cpath fill='%230a0610' d='M32 9c-2 0-3 2-3.5 3.5C27 10 24 6 18 5c2 3 2 6 0 8-3-3-7-4-12-3 3 2 4 5 3 8 4-2 9-1 12 3 3-2 7-2 11 1 4-3 8-3 11-1 3-4 8-5 12-3-1-3 0-6 3-8-5-1-9 0-12 3-2-2-2-5 0-8-6 1-9 5-10.5 7.5C35 11 34 9 32 9z'/%3E%3C/svg%3E") no-repeat center / contain;
    filter: drop-shadow(0 0 6px rgba(255, 122, 26, .3));
}
#hw-fx .hw-bat.fly { animation: hwBat 9s linear forwards, hwFlap .22s steps(2) infinite; }
@keyframes hwBat {
    0% { opacity: 0; transform: translate(0, 0) scale(.7); }
    8% { opacity: .85; }
    50% { transform: translate(var(--hw-dx-half), var(--hw-dy)) scale(1); }
    92% { opacity: .85; }
    100% { opacity: 0; transform: translate(var(--hw-dx), calc(var(--hw-dy) * .3)) scale(.8); }
}
@keyframes hwFlap { 0% { background-size: 100% 100%; } 100% { background-size: 100% 55%; } }

/* ============================ sidebar ============================ */
html.halloween body .sidebar {
    background:
        linear-gradient(180deg, rgba(17, 11, 21, .94) 0%, rgba(13, 8, 16, .9) 45%, rgba(13, 8, 16, .93) 100%),
        url("/static/img/halloween/right.svg") no-repeat right -60px bottom 150px / 330px auto,
        #0d0810;
    border-right: 1px solid rgba(255, 122, 26, .22);
    box-shadow: 1px 0 30px rgba(255, 122, 26, .08);
}
html.halloween body .brand { padding: 18px 15px 14px; gap: 12px; }
html.halloween body .z-logo {
    width: 54px !important;
    height: 54px !important;
    min-width: 54px !important;
    background: url("/static/img/halloween/pumpkin.svg") no-repeat center / contain !important;
    border: none !important;
    box-shadow: none !important;
    color: transparent !important;
    font-size: 0 !important;
    animation: none !important;
    filter: drop-shadow(0 0 12px rgba(255, 122, 26, .55));
}
html.halloween body .brand h2 {
    font-family: var(--hw-serif);
    font-weight: 700;
    font-size: 21px;
    letter-spacing: .5px;
    line-height: 1.05;
    color: #fbf3ea !important;
    text-shadow: 0 2px 12px rgba(0, 0, 0, .6) !important;
}
html.halloween body .brand h2 .hw-ai { color: var(--hw-orange); text-shadow: 0 0 14px rgba(255, 122, 26, .6); }
html.halloween body .brand h2::after {
    content: "THINK \00B7 CREATE \00B7 EXPLORE";
    display: block;
    margin-top: 5px;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 8.5px;
    font-weight: 600;
    letter-spacing: 2.6px;
    color: #cdbcc9;
}

/* New Chat: glowing pumpkin bar with a little castle on the right */
html.halloween body #new-chat-btn,
html.halloween body .btn.primary {
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 90 40'%3E%3Cpath fill='%237a2a05' fill-opacity='.55' d='M0 40V30h8v-8l4-6 4 6v8h6V16l-3 0 6-12 6 12h-3v14h6V20l5-8 5 8v10h6V24l4-6 4 6v6h8V18l-3 0 5-10 5 10h-3v12h6v10z'/%3E%3C/svg%3E") no-repeat right 8px bottom / 74px auto,
        linear-gradient(135deg, #ffad4a 0%, #ff7a1a 50%, #e0560f 100%) !important;
    color: #fff8f0 !important;
    text-shadow: 0 1px 2px rgba(90, 25, 0, .6);
    border: 1px solid rgba(255, 200, 130, .55) !important;
    box-shadow: 0 0 22px rgba(255, 122, 26, .45), inset 0 1px 0 rgba(255, 255, 255, .25) !important;
    animation: none !important;
    font-weight: 700;
    font-size: 15px;
    border-radius: 12px;
}
html.halloween body #new-chat-btn:hover,
html.halloween body .btn.primary:hover { box-shadow: 0 0 32px rgba(255, 122, 26, .65), inset 0 1px 0 rgba(255, 255, 255, .25) !important; filter: brightness(1.05); }
html.halloween body #request-btn { color: #f5ebe0; }

/* chat list */
html.halloween body .chat-group-tag { color: #a99aa6 !important; }
html.halloween body .chat-item {
    color: #e9ddd8;
    border: 1px solid transparent;
    border-radius: 10px;
    gap: 10px;
}
html.halloween body .chat-item::before {
    content: "";
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    background: currentColor;
    opacity: .75;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z'/%3E%3C/svg%3E") no-repeat center / contain;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z'/%3E%3C/svg%3E") no-repeat center / contain;
}
html.halloween body .chat-item:hover { background: rgba(255, 122, 26, .07); color: #fff; }
html.halloween body .chat-item.active {
    background: rgba(255, 122, 26, .10);
    border-color: rgba(255, 122, 26, .75);
    color: #fff;
    box-shadow: 0 0 16px rgba(255, 122, 26, .22), inset 0 0 12px rgba(255, 122, 26, .08);
}
html.halloween body .chat-item.active::after {
    content: "";
    flex: 0 0 22px;
    width: 22px;
    height: 22px;
    background: url("/static/img/halloween/pumpkin.svg") no-repeat center / contain;
    filter: drop-shadow(0 0 6px rgba(255, 122, 26, .6));
}

/* Upgrade: dark plate, amber outline, crown + chevron */
html.halloween body #upgrade-btn {
    background: linear-gradient(135deg, rgba(60, 30, 8, .85), rgba(30, 14, 6, .9)) !important;
    color: #ffc163 !important;
    border: 1px solid rgba(255, 179, 71, .8) !important;
    box-shadow: 0 0 18px rgba(255, 150, 40, .25), inset 0 0 12px rgba(255, 150, 40, .1) !important;
    justify-content: flex-start !important;
    gap: 12px;
    padding-left: 14px !important;
    font-size: 15px;
    position: relative;
}
html.halloween body #upgrade-btn svg { display: none; }
html.halloween body #upgrade-btn::before {
    content: "";
    width: 22px;
    height: 18px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 20'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23ffe08a'/%3E%3Cstop offset='1' stop-color='%23f29a1f'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath fill='url(%23g)' d='M2 6l5 4 5-8 5 8 5-4-2 11H4z'/%3E%3Crect x='4' y='17.5' width='16' height='2.5' rx='1' fill='url(%23g)'/%3E%3C/svg%3E") no-repeat center / contain;
}
html.halloween body #upgrade-btn::after {
    content: "\203A";
    margin-left: auto;
    margin-right: 6px;
    font-size: 22px;
    line-height: 1;
    color: #ffc163;
}
html.halloween body #upgrade-btn:hover { box-shadow: 0 0 26px rgba(255, 150, 40, .4), inset 0 0 12px rgba(255, 150, 40, .14) !important; }

html.halloween body .bottom-bar .btn { color: #efe4dc; }
html.halloween body .bottom-bar .btn svg { color: #ffb878; }
html.halloween body .bottom-bar .btn:hover,
html.halloween body .sidebar-tools-toggle:hover { background: rgba(255, 122, 26, .08); }
html.halloween body .btn.info { color: #efe4dc; text-shadow: none !important; }
html.halloween body #clear-all-btn { color: #ff5a4a; }
html.halloween body #clear-all-btn svg { color: #ff5a4a; }

/* badges */
html.halloween body #request-badge,
html.halloween body #feedback-badge,
html.halloween body #live-chat-badge {
    background: linear-gradient(180deg, #ff5a4a, #d62c1e) !important;
    color: #fff !important;
    box-shadow: 0 0 10px rgba(255, 60, 40, .5);
}

/* profile */
html.halloween body .user-profile-bar { border-top: 1px solid rgba(255, 122, 26, .14); }
html.halloween body .user-profile-bar .user-avatar {
    background: linear-gradient(135deg, #e6dcf0, #9d8bb3) !important;
    color: #2a1d38 !important;
    animation: none !important;
}
html.halloween body #user-role-badge > * { border-color: rgba(255, 179, 71, .7) !important; color: #ffb347 !important; }
html.halloween body .logout-btn { color: #ff6a4a; }

/* ============================ chat header ============================ */
html.halloween body #chat-header {
    background: transparent !important;
    border-bottom: none !important;
    backdrop-filter: none !important;
    padding: 14px 18px 8px !important;
    gap: 12px !important;
}
html.halloween body #chat-header-title {
    flex: 0 1 auto !important;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 16px 9px 12px;
    background: var(--hw-glass);
    border: 1px solid rgba(255, 122, 26, .35);
    border-radius: 14px;
    font-family: var(--hw-serif);
    font-size: 15px !important;
    color: #fbf3ea !important;
    box-shadow: 0 6px 24px rgba(0, 0, 0, .35);
    max-width: 46%;
}
html.halloween body #chat-header-title::before {
    content: "";
    flex: 0 0 24px;
    width: 24px;
    height: 24px;
    background: url("/static/img/halloween/pumpkin.svg") no-repeat center / contain;
}
html.halloween body #chat-header::after { content: ""; flex: 1; order: 1; }
html.halloween body #chat-model-select { order: 2; }
html.halloween body #chat-pin-btn { order: 3; }
html.halloween body #chat-share-btn { order: 4; }
html.halloween body #chat-model-select,
html.halloween body #chat-pin-btn {
    background: var(--hw-glass) !important;
    border: 1px solid rgba(255, 122, 26, .3) !important;
    color: #f5ebe0 !important;
    border-radius: 12px !important;
    padding: 9px 12px !important;
    box-shadow: 0 6px 24px rgba(0, 0, 0, .35);
}
html.halloween body #chat-share-btn {
    background: rgba(40, 16, 6, .75) !important;
    border: 1px solid #ff7a1a !important;
    color: #ffb347 !important;
    border-radius: 12px !important;
    padding: 9px 18px !important;
    font-weight: 700 !important;
    box-shadow: 0 0 18px rgba(255, 122, 26, .35) !important;
}

/* ============================ messages ============================ */
html.halloween body #chat-container { scrollbar-color: #4a2a32 transparent; }
html.halloween body .assistant .msg-bubble {
    position: relative;
    background: linear-gradient(180deg, rgba(20, 12, 22, .88), rgba(14, 9, 17, .9));
    border: 1px solid var(--hw-line);
    border-radius: 18px;
    padding: 20px 26px;
    box-shadow: 0 0 0 1px rgba(255, 122, 26, .06), 0 0 28px rgba(255, 122, 26, .14), 0 18px 40px rgba(0, 0, 0, .45);
    backdrop-filter: blur(3px);
    color: #f3e9df;
}
/* cobweb tucked into the card's top-left corner */
html.halloween body .assistant .msg-bubble::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 56px;
    height: 56px;
    pointer-events: none;
    opacity: .35;
    border-top-left-radius: 18px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40' fill='none' stroke='%23e9dcf5' stroke-width='.6'%3E%3Cpath d='M0 0L40 40M0 0L40 14M0 0L14 40M0 0L40 0M0 0L0 40'/%3E%3Cpath d='M10 0Q8 5 9 9Q4 8 0 10M22 0Q17 9 19 19Q9 17 0 22M34 0Q26 14 29 29Q14 26 0 34'/%3E%3C/svg%3E") no-repeat;
}
html.halloween body .assistant .msg-bubble h1,
html.halloween body .assistant .msg-bubble h2,
html.halloween body .assistant .msg-bubble h3 {
    font-family: var(--hw-serif);
    font-weight: 700;
    letter-spacing: .3px;
    line-height: 1.2;
}
html.halloween body .assistant .msg-bubble h1 {
    font-size: 30px;
    text-align: center;
    margin: 4px 0 18px;
    background: linear-gradient(90deg, #fff7ee 0%, #ffe6cc 45%, #ffb347 75%, #ff7a1a 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 10px rgba(255, 122, 26, .35));
}
/* ornament under the main heading: line, pumpkin, line */
html.halloween body .assistant .msg-bubble h1::after {
    content: "";
    display: block;
    height: 18px;
    margin: 10px auto 0;
    max-width: 380px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 380 18'%3E%3Cg stroke='%23ff7a1a' stroke-width='1.2'%3E%3Cpath d='M10 9H165M215 9H370'/%3E%3C/g%3E%3Cg fill='%23ff7a1a'%3E%3Cpath d='M160 9l5-4 5 4-5 4zM210 9l5-4 5 4-5 4z'/%3E%3Ccircle cx='10' cy='9' r='2'/%3E%3Ccircle cx='370' cy='9' r='2'/%3E%3C/g%3E%3Cellipse cx='190' cy='10' rx='9' ry='7' fill='%23ff8a1a'/%3E%3Cpath d='M189 3q1-3 3-3' stroke='%234b5d1c' stroke-width='2' fill='none'/%3E%3Cg fill='%23ffe08a'%3E%3Cpath d='M185 9l2-3 2 3zM191 9l2-3 2 3zM185 12q5 3 10 0l-2 1-1-1-2 1-2-1-1 1z'/%3E%3C/g%3E%3C/svg%3E") no-repeat center / contain;
    -webkit-text-fill-color: initial;
}
html.halloween body .assistant .msg-bubble h2 { font-size: 22px; color: #ffd2a6; margin: 18px 0 8px; }
html.halloween body .assistant .msg-bubble h3 { font-size: 18px; color: #ffbe7a; margin: 14px 0 6px; }
html.halloween body .assistant .msg-bubble strong { color: #ffb066; }
html.halloween body .assistant .msg-bubble a { color: #ff9a3c; }
html.halloween body .assistant .msg-bubble blockquote { border-left-color: #ff7a1a; }
html.halloween body .user .msg-bubble {
    color: #fff8f0;
    border: 1px solid rgba(255, 200, 140, .35);
    box-shadow: 0 0 18px rgba(255, 122, 26, .25);
}

/* action pills under each answer */
html.halloween body .msg-actions { gap: 8px; margin-top: 10px; flex-wrap: wrap; }
html.halloween body .msg-actions button {
    background: var(--hw-glass);
    border: 1px solid rgba(255, 122, 26, .4);
    color: #f1e5da;
    border-radius: 10px;
    padding: 6px 12px;
    font-size: 12.5px;
    gap: 6px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .3);
}
html.halloween body .msg-actions button svg { width: 14px; height: 14px; color: #ff9a3c; }
html.halloween body .msg-actions button:hover {
    color: #fff !important;
    border-color: #ff7a1a !important;
    box-shadow: 0 0 14px rgba(255, 122, 26, .35) !important;
    text-shadow: none !important;
}

/* ============================ welcome ============================ */
html.halloween body .welcome-z-logo {
    width: 116px !important;
    height: 116px !important;
    background: url("/static/img/halloween/pumpkin.svg") no-repeat center / contain !important;
    border: none !important;
    box-shadow: none !important;
    color: transparent !important;
    font-size: 0 !important;
    animation: hwFlicker 3.4s infinite !important;
    filter: drop-shadow(0 0 28px rgba(255, 122, 26, .6));
    margin-bottom: 14px !important;
}
@keyframes hwFlicker {
    0%, 100% { filter: drop-shadow(0 0 28px rgba(255, 122, 26, .6)) brightness(1); }
    8% { filter: drop-shadow(0 0 34px rgba(255, 140, 30, .75)) brightness(1.12); }
    10% { filter: drop-shadow(0 0 20px rgba(255, 122, 26, .5)) brightness(.9); }
    12% { filter: drop-shadow(0 0 30px rgba(255, 122, 26, .7)) brightness(1.06); }
    57% { filter: drop-shadow(0 0 22px rgba(255, 122, 26, .5)) brightness(.94); }
    60% { filter: drop-shadow(0 0 32px rgba(255, 122, 26, .7)) brightness(1.08); }
}
html.halloween body .welcome-message h2 {
    font-family: var(--hw-serif);
    font-weight: 700;
    font-size: 42px;
    letter-spacing: .5px;
    line-height: 1.15;
    color: #fbf3ea;
    text-shadow: 0 3px 18px rgba(0, 0, 0, .7);
}
html.halloween body .welcome-message h2 span {
    font-family: inherit !important;
    background: linear-gradient(90deg, #ffd27a, #ff7a1a 50%, #ffb347) !important;
    background-size: 200% 100% !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    animation: hwShimmer 6s ease-in-out infinite !important;
    filter: drop-shadow(0 0 12px rgba(255, 122, 26, .5));
}
@keyframes hwShimmer { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
html.halloween body .welcome-message .welcome-sub { color: #d5c3cf; font-size: 16px; }
html.halloween body .welcome-message .welcome-sub::after {
    content: "";
    display: block;
    height: 16px;
    width: 300px;
    max-width: 80vw;
    margin: 14px auto 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 16'%3E%3Cg stroke='%23ff7a1a' stroke-width='1.2'%3E%3Cpath d='M6 8H130M170 8H294'/%3E%3C/g%3E%3Cg fill='%23ff7a1a'%3E%3Cpath d='M126 8l4-3 4 3-4 3zM166 8l4-3 4 3-4 3z'/%3E%3C/g%3E%3Cellipse cx='150' cy='9' rx='8' ry='6' fill='%23ff8a1a'/%3E%3Cpath d='M149 3q1-3 3-3' stroke='%234b5d1c' stroke-width='2' fill='none'/%3E%3C/svg%3E") no-repeat center / contain;
}
html.halloween body .template-card {
    background: var(--hw-glass);
    border: 1px solid rgba(255, 122, 26, .3);
    box-shadow: 0 8px 22px rgba(0, 0, 0, .35);
    backdrop-filter: blur(3px);
}
html.halloween body .template-card:hover {
    border-color: rgba(255, 122, 26, .75);
    box-shadow: 0 0 20px rgba(255, 122, 26, .25), 0 8px 22px rgba(0, 0, 0, .35);
}

/* ============================ composer ============================ */
html.halloween body .input-wrapper { padding: 10px 18px 16px; }
html.halloween body .composer-box {
    position: relative;
    background: linear-gradient(180deg, rgba(20, 12, 22, .92), rgba(13, 8, 16, .94));
    border: 1px solid rgba(255, 122, 26, .55);
    border-radius: 26px;
    padding: 10px 10px 10px 18px;
    box-shadow: 0 0 26px rgba(255, 122, 26, .18), 0 14px 36px rgba(0, 0, 0, .45);
}
html.halloween body .composer-box:focus-within {
    border-color: #ff8a2a !important;
    box-shadow: 0 0 0 1px rgba(255, 122, 26, .3), 0 0 32px rgba(255, 122, 26, .32), 0 14px 36px rgba(0, 0, 0, .45) !important;
}
html.halloween body .composer-box::before {
    content: "";
    position: absolute;
    top: -1px;
    left: -1px;
    width: 34px;
    height: 34px;
    pointer-events: none;
    opacity: .45;
    border-top-left-radius: 26px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40' fill='none' stroke='%23d8c9e6' stroke-width='.8'%3E%3Cpath d='M0 0L40 40M0 0L40 14M0 0L14 40M0 0L40 0M0 0L0 40'/%3E%3Cpath d='M10 0Q8 5 9 9Q4 8 0 10M22 0Q17 9 19 19Q9 17 0 22M34 0Q26 14 29 29Q14 26 0 34'/%3E%3C/svg%3E") no-repeat;
}
html.halloween body #user-input { font-size: 16px; color: #f7ede4; }
html.halloween body #user-input::placeholder { color: #a8949f; }
html.halloween body .composer-icon { color: #d9cbc6; }
html.halloween body .composer-icon:hover { color: var(--hw-amber); text-shadow: none !important; }
html.halloween body .composer-icon.active {
    color: #ffd8b0 !important;
    background: rgba(255, 122, 26, .16) !important;
    box-shadow: 0 0 12px rgba(255, 122, 26, .3) !important;
}
html.halloween body #send-btn {
    width: 46px !important;
    height: 46px !important;
    background: radial-gradient(circle at 40% 35%, #ffc46a 0%, #ff8a1a 45%, #d4520b 100%) !important;
    color: #2a0f02 !important;
    box-shadow: 0 0 22px rgba(255, 122, 26, .6), inset 0 1px 0 rgba(255, 255, 255, .35) !important;
    animation: none !important;
}
html.halloween body #send-btn svg { width: 20px; height: 20px; }

/* thinking / streaming accents */
html.halloween body .thinking-text { color: var(--hw-amber) !important; text-shadow: 0 0 10px rgba(255, 122, 26, .5) !important; }
html.halloween body .streaming-cursor::after { background: var(--hw-orange) !important; box-shadow: 0 0 10px rgba(255, 122, 26, .8) !important; }

/* scrollbars */
html.halloween body *::-webkit-scrollbar-thumb { background: #4a2a32; }
html.halloween body * { scrollbar-color: #4a2a32 transparent; }

/* ============================ small screens ============================ */
@media (max-width: 768px) {
    #hw-fx .hw-sky { left: 50%; width: 150vw; opacity: .7; }
    #hw-fx .hw-left { left: 0; height: 26vh; opacity: .55; }
    #hw-fx .hw-right { height: 32vh; opacity: .55; }
    #hw-fx .hw-web.l { display: none; }
    #hw-fx .hw-web.r { width: 96px; height: 96px; }
    #hw-fx .hw-spider { right: 34px; }
    html.halloween body .welcome-message h2 { font-size: 28px; white-space: normal !important; padding: 0 12px; }
    html.halloween body .welcome-z-logo { width: 88px !important; height: 88px !important; }
    html.halloween body .assistant .msg-bubble { padding: 16px 16px; }
    html.halloween body .assistant .msg-bubble h1 { font-size: 23px; }
    html.halloween body .chat-item::before,
    html.halloween body .chat-item.active::after { display: none; }
    html.halloween body #chat-header-title { max-width: 100%; }
    html.halloween body .brand h2::after { display: none; }
}

/* =====================================================================
   Landing (welcome) page + login / register  (static/index.html)
   The scene is painted straight onto the full-screen sheets as background
   layers, so it stays put while the page scrolls and never covers text.
   ===================================================================== */
html.halloween body.auth-page { background: #0b070e; }
/* webs, spider, fog and bats float above the sheets here; no clicks, edges only */
html.halloween body.auth-page #hw-fx { z-index: 2100; }
html.halloween body.auth-page #hw-fx .hw-art { display: none; }
html.halloween body.auth-page #hw-fx .hw-web.l { left: 0; }

html.halloween body .landing-page,
html.halloween body .login-screen {
    background:
        url("/static/img/halloween/sky.svg") no-repeat center top / min(1150px, 135vw) auto,
        url("/static/img/halloween/left.svg") no-repeat left bottom / auto min(44vh, 420px),
        url("/static/img/halloween/right.svg") no-repeat right bottom / auto min(58vh, 560px),
        radial-gradient(55% 45% at 50% 0%, rgba(255, 110, 20, .32), transparent 70%),
        linear-gradient(180deg, #1c0b1e 0%, #130914 50%, #0b070e 100%) !important;
    animation: none !important;
}
html.halloween body .landing-title {
    font-family: var(--hw-display);
    font-weight: 900;
    letter-spacing: 3px;
    color: #fff6ec;
    text-shadow: 0 0 22px rgba(255, 122, 26, .7), 0 4px 30px rgba(0, 0, 0, .8);
    margin-top: 16vh;
}
html.halloween body .landing-subtitle { color: #ead8e2; text-shadow: 0 2px 12px rgba(0, 0, 0, .8); }
html.halloween body .landing-subtitle .hw-tag {
    display: block;
    margin-top: 10px;
    font-style: normal;
    font-family: var(--hw-serif);
    font-size: .62em;
    letter-spacing: 6px;
    color: #ffb347;
    text-transform: uppercase;
}
html.halloween body .start-btn {
    border: 1px solid #ff8a2a;
    color: #fff3e6;
    font-family: var(--hw-serif);
    background: linear-gradient(135deg, rgba(255, 140, 40, .9), rgba(214, 82, 11, .9));
    box-shadow: 0 0 26px rgba(255, 122, 26, .55);
    border-radius: 12px;
    text-shadow: 0 1px 2px rgba(90, 25, 0, .6);
}
html.halloween body .start-btn:hover { box-shadow: 0 0 42px rgba(255, 122, 26, .8); background: linear-gradient(135deg, #ffa04a, #e0600f); }
html.halloween body .seo-section h2 { font-family: var(--hw-serif); color: #ffe6cc; }
html.halloween body .seo-feature { background: rgba(16, 10, 20, .82); border-color: rgba(255, 122, 26, .3); backdrop-filter: blur(3px); }
html.halloween body .seo-feature h3 { color: #ffb347; font-family: var(--hw-serif); }
html.halloween body .seo-faq details { background: rgba(16, 10, 20, .8); border-color: rgba(255, 122, 26, .25); backdrop-filter: blur(3px); }
html.halloween body .seo-footer a { color: #ffb347; }

/* login card */
html.halloween body .login-container {
    background: linear-gradient(180deg, rgba(20, 12, 22, .93), rgba(13, 8, 16, .95));
    border: 1px solid rgba(255, 122, 26, .5);
    box-shadow: 0 20px 60px rgba(0, 0, 0, .65), 0 0 40px rgba(255, 122, 26, .2);
    position: relative;
}
html.halloween body .login-container::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 70px;
    height: 70px;
    pointer-events: none;
    opacity: .35;
    border-top-left-radius: 20px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40' fill='none' stroke='%23e9dcf5' stroke-width='.6'%3E%3Cpath d='M0 0L40 40M0 0L40 14M0 0L14 40M0 0L40 0M0 0L0 40'/%3E%3Cpath d='M10 0Q8 5 9 9Q4 8 0 10M22 0Q17 9 19 19Q9 17 0 22M34 0Q26 14 29 29Q14 26 0 34'/%3E%3C/svg%3E") no-repeat;
}
html.halloween body .login-header::before {
    content: "";
    display: block;
    width: 64px;
    height: 64px;
    margin: 0 auto 8px;
    background: url("/static/img/halloween/pumpkin.svg") no-repeat center / contain;
    filter: drop-shadow(0 0 16px rgba(255, 122, 26, .55));
}
html.halloween body .login-header h1, html.halloween body .login-header h2 {
    font-family: var(--hw-display);
    font-weight: 900;
    letter-spacing: 2px;
    background: linear-gradient(90deg, #fff3e6, #ffb347 55%, #ff7a1a);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 10px rgba(255, 122, 26, .4));
}
html.halloween body .login-header p { color: #cdbac6; }
html.halloween body .auth-tab { border-color: rgba(255, 122, 26, .3); background: rgba(0, 0, 0, .3); }
html.halloween body .auth-tab.active { background: rgba(255, 122, 26, .16); border-color: #ff7a1a; color: #ffb347; }
html.halloween body .login-label { color: #ffb347; }
html.halloween body .login-form input { border-color: rgba(255, 122, 26, .3); background: rgba(0, 0, 0, .45); }
html.halloween body .login-form input:focus { border-color: #ff7a1a; box-shadow: 0 0 20px rgba(255, 122, 26, .3); }
html.halloween body .login-btn {
    background: linear-gradient(135deg, #ffad4a, #ff7a1a 55%, #e0560f);
    color: #fff8f0;
    text-shadow: 0 1px 2px rgba(90, 25, 0, .6);
    box-shadow: 0 0 26px rgba(255, 122, 26, .4);
}
html.halloween body .login-btn:hover:not(:disabled) { box-shadow: 0 0 40px rgba(255, 122, 26, .6); }
html.halloween body .pw-toggle { color: rgba(255, 179, 71, .65) !important; }
/* these carry inline cyan styles, hence !important */
html.halloween body #guest-btn { border-color: rgba(255, 179, 71, .45) !important; color: #f1e2d6 !important; }
html.halloween body #guest-btn:hover { background: rgba(255, 122, 26, .1) !important; }
html.halloween body #forgot-link { color: rgba(255, 179, 71, .85) !important; }
html.halloween body #forgot-modal h3 { color: #ffb347 !important; }
html.halloween body #forgot-modal input { border-color: rgba(255, 122, 26, .3) !important; }
html.halloween body #forgot-submit { background: linear-gradient(135deg, #ffad4a, #ff7a1a 55%, #e0560f) !important; color: #fff8f0 !important; }

@media (max-width: 768px) {
    html.halloween body .landing-page,
    html.halloween body .login-screen {
        background:
            url("/static/img/halloween/sky.svg") no-repeat center top / 170vw auto,
            url("/static/img/halloween/left.svg") no-repeat left bottom / auto 22vh,
            url("/static/img/halloween/right.svg") no-repeat right bottom / auto 28vh,
            radial-gradient(70% 40% at 50% 0%, rgba(255, 110, 20, .3), transparent 70%),
            linear-gradient(180deg, #1c0b1e 0%, #130914 50%, #0b070e 100%) !important;
    }
    html.halloween body .landing-title { margin-top: 10vh; letter-spacing: 1px; }
}

/* respect people who turn motion off */
@media (prefers-reduced-motion: reduce) {
    html.halloween body .welcome-z-logo,
    html.halloween body .welcome-message h2 span,
    #hw-fx .hw-spider,
    #hw-fx .hw-fog { animation: none !important; }
    #hw-fx .hw-bat { display: none; }
}

/* =====================================================================
   Fun & games: catchable bats, candy, pumpkin pokes, AI greeting popup
   ===================================================================== */
#hw-play { position: fixed; inset: 0; pointer-events: none; z-index: 9000; overflow: hidden; }
#hw-play .hw-bat {
    position: absolute;
    width: 40px;
    height: 20px;
    padding: 0;
    border: none;
    opacity: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 30'%3E%3Cpath fill='%230a0610' d='M32 9c-2 0-3 2-3.5 3.5C27 10 24 6 18 5c2 3 2 6 0 8-3-3-7-4-12-3 3 2 4 5 3 8 4-2 9-1 12 3 3-2 7-2 11 1 4-3 8-3 11-1 3-4 8-5 12-3-1-3 0-6 3-8-5-1-9 0-12 3-2-2-2-5 0-8-6 1-9 5-10.5 7.5C35 11 34 9 32 9z'/%3E%3C/svg%3E") no-repeat center / contain;
    filter: drop-shadow(0 0 6px rgba(255, 122, 26, .45));
}
#hw-play .hw-bat.hw-catch { pointer-events: auto; cursor: crosshair; }
/* invisible padding so a moving bat is easy to tap */
#hw-play .hw-bat.hw-catch::before { content: ""; position: absolute; inset: -14px -10px; }
#hw-play .hw-bat.fly { animation: hwBat 9s linear forwards, hwFlap .22s steps(2) infinite; }
#hw-play .hw-bat.swarm.fly { animation: hwBat 3.4s ease-in forwards, hwFlap .16s steps(2) infinite; }
#hw-play .hw-bat.caught { animation: hwPoof .26s ease-out forwards !important; }
@keyframes hwPoof { to { opacity: 0; transform: scale(2.2) rotate(25deg); filter: blur(2px); } }

.hw-candy { position: absolute; pointer-events: none; font-size: 22px; line-height: 1; will-change: transform, opacity; }
.hw-candy.burst { animation: hwBurst 1.1s cubic-bezier(.15, .7, .35, 1) forwards; }
@keyframes hwBurst {
    0% { transform: translate(-50%, -50%) scale(.4); opacity: 1; }
    70% { opacity: 1; }
    100% { transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy) + 60px)) rotate(var(--rot)) scale(1); opacity: 0; }
}
.hw-candy.rain { top: -40px; animation-name: hwRain; animation-timing-function: cubic-bezier(.4, 0, .9, .6); animation-fill-mode: both; }
@keyframes hwRain {
    0% { transform: translateY(0) rotate(0); opacity: 0; }
    10% { opacity: 1; }
    100% { transform: translateY(calc(100vh + 80px)) rotate(400deg); opacity: .9; }
}

html.halloween body .z-logo,
html.halloween body .welcome-z-logo { cursor: pointer; }
.hw-wobble { animation: hwWobble .6s cubic-bezier(.3, 1.6, .5, 1) !important; }
@keyframes hwWobble {
    0% { transform: scale(1) rotate(0); }
    25% { transform: scale(1.18, .86) rotate(-8deg); }
    50% { transform: scale(.92, 1.1) rotate(7deg); }
    75% { transform: scale(1.05, .97) rotate(-3deg); }
    100% { transform: scale(1) rotate(0); }
}
.hw-shake { animation: hwShake .5s ease !important; }
@keyframes hwShake { 0%, 100% { transform: none; } 20% { transform: translateX(-9px) rotate(-1deg); } 40% { transform: translateX(8px) rotate(1deg); } 60% { transform: translateX(-6px); } 80% { transform: translateX(4px); } }

/* ---------- greeting popup ---------- */
.hwg-overlay {
    position: fixed;
    inset: 0;
    z-index: 10040;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: radial-gradient(60% 60% at 50% 40%, rgba(60, 20, 8, .55), rgba(5, 3, 8, .82));
    backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity .3s ease;
}
.hwg-overlay.in { opacity: 1; }
.hwg-overlay.out { opacity: 0; }
.hwg-card {
    position: relative;
    width: min(460px, 100%);
    max-height: calc(100vh - 36px);
    overflow-y: auto;
    padding: 26px 24px 20px;
    border-radius: 22px;
    text-align: center;
    color: #f7ede4;
    background:
        linear-gradient(180deg, rgba(20, 8, 16, .55) 0%, rgba(20, 8, 16, 0) 30%),
        url("/static/img/halloween/sky.svg") no-repeat center 46px / 150% auto,
        linear-gradient(180deg, rgba(36, 14, 26, .97) 0%, rgba(16, 9, 18, .98) 55%);
    border: 1px solid rgba(255, 122, 26, .6);
    box-shadow: 0 30px 80px rgba(0, 0, 0, .65), 0 0 50px rgba(255, 122, 26, .25);
    transform: translateY(24px) scale(.94);
    transition: transform .45s cubic-bezier(.2, 1.3, .4, 1);
    font-family: Inter, system-ui, sans-serif;
}
.hwg-overlay.in .hwg-card { transform: none; }
.hwg-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 74px;
    height: 74px;
    pointer-events: none;
    opacity: .4;
    border-top-left-radius: 22px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40' fill='none' stroke='%23e9dcf5' stroke-width='.6'%3E%3Cpath d='M0 0L40 40M0 0L40 14M0 0L14 40M0 0L40 0M0 0L0 40'/%3E%3Cpath d='M10 0Q8 5 9 9Q4 8 0 10M22 0Q17 9 19 19Q9 17 0 22M34 0Q26 14 29 29Q14 26 0 34'/%3E%3C/svg%3E") no-repeat;
}
.hwg-x {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .15);
    background: rgba(0, 0, 0, .35);
    color: #f7ede4;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}
.hwg-x:hover { border-color: #ff7a1a; }
.hwg-title {
    font-family: 'Cinzel Decorative', 'Playfair Display', Georgia, serif;
    font-weight: 900;
    font-size: 30px;
    letter-spacing: 1px;
    margin: 6px 0 4px;
    background: linear-gradient(90deg, #fff3e6, #ffb347 55%, #ff7a1a);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .9)) drop-shadow(0 0 12px rgba(255, 122, 26, .5));
    position: relative;
    z-index: 1;
}
.hwg-pumpkin {
    --glow: .35;
    position: relative;
    display: block;
    width: 120px;
    height: 120px;
    margin: 4px auto 6px;
    border: none;
    cursor: pointer;
    background: url("/static/img/halloween/pumpkin.svg") no-repeat center / contain;
    filter: drop-shadow(0 0 calc(14px + 30px * var(--glow)) rgba(255, 140, 30, calc(.35 + .5 * var(--glow)))) brightness(calc(.9 + .35 * var(--glow)));
    transition: filter .3s ease;
}
.hwg-pumpkin:focus-visible { outline: 2px solid #ffb347; outline-offset: 4px; border-radius: 50%; }
.hwg-say {
    position: absolute;
    left: 50%;
    top: -6px;
    transform: translate(-50%, -100%) scale(.6);
    white-space: nowrap;
    padding: 6px 12px;
    border-radius: 12px;
    background: #fff3e6;
    color: #3a1604;
    font: 700 13px/1 Inter, system-ui, sans-serif;
    opacity: 0;
    pointer-events: none;
}
.hwg-say::after { content: ""; position: absolute; left: 50%; bottom: -6px; transform: translateX(-50%); border: 6px solid transparent; border-bottom: none; border-top-color: #fff3e6; }
.hwg-say.show { animation: hwSay 1.6s ease forwards; }
@keyframes hwSay { 0% { opacity: 0; transform: translate(-50%, -80%) scale(.6); } 15% { opacity: 1; transform: translate(-50%, -100%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -120%) scale(1); } }
.hwg-ai { display: flex; gap: 10px; align-items: flex-start; text-align: left; margin: 6px 0 14px; }
.hwg-av {
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: url("/static/img/halloween/pumpkin.svg") no-repeat center / 80%, radial-gradient(circle, #3a1a10, #160b10);
    border: 1px solid rgba(255, 122, 26, .5);
}
.hwg-bubble {
    flex: 1;
    padding: 11px 14px;
    border-radius: 4px 16px 16px 16px;
    background: rgba(14, 9, 18, .85);
    border: 1px solid rgba(255, 122, 26, .4);
}
.hwg-bubble b { display: block; font-size: 12px; letter-spacing: .5px; color: #ffb347; margin-bottom: 4px; }
.hwg-text { margin: 0; font-size: 14.5px; line-height: 1.55; min-height: 44px; }
.hwg-dots { display: inline-flex; gap: 4px; padding: 6px 0; }
.hwg-dots i { width: 7px; height: 7px; border-radius: 50%; background: #ffb347; animation: hwDot 1s infinite ease-in-out; }
.hwg-dots i:nth-child(2) { animation-delay: .15s; }
.hwg-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes hwDot { 0%, 100% { opacity: .3; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-4px); } }
.hwg-result { display: none; margin: 0 0 14px; padding: 12px 14px; border-radius: 14px; font-size: 14px; line-height: 1.5; }
.hwg-result.show { display: block; animation: hwPop .4s cubic-bezier(.2, 1.4, .4, 1); }
.hwg-result b { display: block; font-family: 'Cinzel Decorative', Georgia, serif; font-size: 18px; margin-bottom: 4px; }
.hwg-result.treat { background: rgba(255, 140, 30, .14); border: 1px solid rgba(255, 179, 71, .55); }
.hwg-result.treat b { color: #ffc163; }
.hwg-result.trick { background: rgba(140, 60, 220, .16); border: 1px solid rgba(178, 107, 255, .55); }
.hwg-result.trick b { color: #c9a2ff; }
@keyframes hwPop { from { transform: scale(.85); opacity: 0; } to { transform: none; opacity: 1; } }
.hwg-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.hwg-actions button {
    flex: 1 1 160px;
    padding: 12px 16px;
    border-radius: 12px;
    font: 700 14px/1 Inter, system-ui, sans-serif;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .2s ease;
}
.hwg-actions button:hover { transform: translateY(-2px); }
.hwg-tot { background: rgba(40, 16, 6, .8); color: #ffc163; border: 1px solid #ff8a2a; box-shadow: 0 0 16px rgba(255, 122, 26, .3); }
.hwg-go { background: linear-gradient(135deg, #ffad4a, #ff7a1a 55%, #e0560f); color: #fff8f0; border: 1px solid rgba(255, 200, 130, .6); text-shadow: 0 1px 2px rgba(90, 25, 0, .6); box-shadow: 0 0 22px rgba(255, 122, 26, .45); }
.hwg-tip { margin-top: 14px; font-size: 12px; color: #bfa9b8; }
@media (max-width: 480px) {
    .hwg-card { padding: 22px 16px 16px; }
    .hwg-title { font-size: 24px; }
    .hwg-pumpkin { width: 96px; height: 96px; }
}
@media (prefers-reduced-motion: reduce) {
    .hwg-card, .hwg-overlay { transition: none; }
    .hw-wobble, .hw-shake, .hwg-say.show, .hwg-result.show { animation: none !important; }
    .hwg-say.show { opacity: 1; transform: translate(-50%, -100%); }
}

/* new (Nov 2026) welcome page: keep the seasonal look tidy on its layout */
html.halloween body .wl-hero .landing-title { margin-top: 0; font-size: clamp(30px, 3.6vw, 48px); letter-spacing: 1px; line-height: 1.12; }
html.halloween body .wl-shine { background: linear-gradient(90deg, #ffd27a, #ff7a1a 50%, #ffb347); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
html.halloween body .wl-btn,
html.halloween body .landing-page .wl-btn.start-btn { background: linear-gradient(135deg, #ffad4a, #ff7a1a 55%, #e0560f); box-shadow: 0 0 26px rgba(255, 122, 26, .45); }
html.halloween body .wl-z,
html.halloween body .wl-ask { background: linear-gradient(135deg, #ff9a3c, #c2410c); }
html.halloween body .wl-chips button.on { border-color: #ff7a1a; background: rgba(255, 122, 26, .16); }
html.halloween body .wl-bg .wl-orb.o1, html.halloween body .wl-bg .wl-orb.o4 { background: rgba(255, 110, 20, .22); }
