/* Decembrsko veselje: whole-site treatment. Message/name palettes retain the
   existing opaque light/dark surfaces; illustration never sits under text. */
html[data-festive="true"] { --blue:#793149; --link:#793149; --focus:#a44000; }
html[data-festive="true"][data-theme="dark"] { --blue:#efd094; --link:#efd094; --focus:#ffbc78; }
@media(prefers-color-scheme:dark) { html[data-festive="true"][data-theme="system"] { --blue:#efd094; --link:#efd094; --focus:#ffbc78; } }
html[data-festive="true"] body { background:linear-gradient(#071e35aa,#071e35e8),url('/assets/winter/village.png') center top/cover fixed; }
html[data-festive="true"] .topbar { position:relative; background:#0c293c; border-bottom:2px solid #bc995d; color:#fff3dc; box-shadow:0 8px 35px #05142160; }
html[data-festive="true"] .topbar :is(a,small,button) { color:#fff3dc; }
html[data-festive="true"] .topbar .brand-number { color:#f1ce86; }
html[data-festive="true"] .topbar::after { content:""; position:absolute; inset:auto 0 -4px; height:8px; pointer-events:none; background:radial-gradient(circle,#ffdc94 0 2px,transparent 3px) 0 0/40px 8px; filter:drop-shadow(0 0 4px #e1b364); }
.winter-panorama { display:none; }
html[data-festive="true"] .winter-panorama { display:block; height:clamp(90px,13vw,200px); background:url('/assets/winter/village.png') center 57%/cover; border-bottom:1px solid #cda870; position:relative; overflow:hidden; }
.winter-panorama::after { content:""; position:absolute; inset:0; background:linear-gradient(transparent 55%,#071e3560); pointer-events:none; }
html[data-festive="true"] .shell { gap:24px; }
html[data-festive="true"] .sidebar { background:#102f3c; color:#f8eed9; border:1px solid #8e7956; border-radius:20px; box-shadow:0 14px 40px #03132455; }
html[data-festive="true"] .sidebar :is(a,p,button) { color:#f8eed9; }
html[data-festive="true"] .sidebar::after { content:""; display:block; height:110px; background:url('/assets/winter/bough.svg') center/contain no-repeat; pointer-events:none; }
html[data-festive="true"] .sidebar a:is(:hover,[aria-current="page"]) { background:#f3dbaa; color:#253044; border-radius:10px; }
html[data-festive="true"] main { background:var(--page); color:var(--text); padding:clamp(12px,2.5vw,30px); border-radius:24px; border:1px solid #af966b; box-shadow:0 15px 50px #03132255; min-width:0; }
html[data-festive="true"] :is(.card,.post,.feed-card,.profile-card,dialog) { border-radius:18px; border-color:#ac916861; box-shadow:0 6px 20px #061a3210; }
html[data-festive="true"] :is(h1,h2) { letter-spacing:.01em; font-family:Georgia,'Times New Roman',serif; }
html[data-festive="true"] .page-heading { border-bottom:1px solid #ac916880; padding-bottom:18px; }
html[data-festive="true"] :is(button,.button) { border-radius:12px; }
html[data-festive="true"] :is(button,.button):not(.quiet):not(.secondary):not(.danger):not(.chip):not(.mention-option) { background:#793149; color:#fff; }
html[data-festive="true"] :is(button,.button):not(.quiet):not(.secondary):not(.danger):not(.chip):not(.mention-option):hover { background:#63243b; }
html[data-festive="true"] :is(input,textarea,select) { border-radius:10px; }
html[data-festive="true"] #chat-log .message { background:var(--surface); border:1px solid #ac916866; border-radius:16px; }
html[data-festive="true"] #chat-log .message-own { border-inline-start:4px solid #997038; }
html[data-festive="true"] #chat-log .message-quoted-me { background:var(--quote-recipient-bg); border-inline-start:5px solid var(--quote-recipient-accent); }
html[data-festive="true"] .site-footer { background:#0c293c; color:#f8eed9; border-top:2px solid #bc995d; }
html[data-festive="true"] .site-footer :is(a,button) { color:#f8eed9; }
.winter-offer { border:1px solid #ad8752; border-radius:18px; overflow:hidden; margin:16px 0; background:var(--surface); color:var(--text); }
.winter-offer-art { height:130px; background:url('/assets/winter/village.png') center 60%/cover; }
.winter-offer-content { padding:20px; }
.winter-offer :is(h2,h3) { margin-top:0; }
.special-theme-catalog { display:grid; gap:20px; }
.special-theme-card { border:1px solid var(--line); border-radius:18px; overflow:hidden; background:var(--surface); color:var(--text); }
.special-theme-card .winter-offer-art { height:150px; }
.special-theme-content { padding:clamp(16px,3vw,24px); }
.special-theme-content h3 { margin:0 0 12px; font-size:1.3rem; }
.special-theme-status { border-inline-start:4px solid var(--muted); padding:8px 12px; background:var(--page); border-radius:4px; }
.special-theme-status[data-state="available"] { border-inline-start-color:var(--link); }
.special-theme-editor { margin-top:16px; border-top:1px solid var(--line); padding-top:8px; }
.special-theme-editor summary { min-height:48px; }
.special-theme-editor summary:focus-visible { outline:3px solid var(--focus); outline-offset:3px; border-radius:4px; }
.special-theme-dates { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.special-theme-dates input { width:100%; min-width:0; }
.special-theme-editor form { margin-top:8px; }
.winter-actions { display:flex; gap:12px; flex-wrap:wrap; }
.winter-actions button { min-height:48px; }
.winter-status:empty { display:none; }
.winter-snow { position:absolute; inset:0; width:100%; height:100%; pointer-events:none; }
.winter-preview-exit { position:fixed; bottom:16px; right:16px; z-index:100; background:#fff3dc; color:#272e3b; border:2px solid #793149; padding:12px 18px; }
@media(max-width:650px) {
  html[data-festive="true"] body { background:#0c293c; }
  html[data-festive="true"] .shell { gap:12px; }
  html[data-festive="true"] main { border-radius:16px; }
  html[data-festive="true"] .winter-panorama { height:78px; background-size:auto 200%; }
  html[data-festive="true"] .sidebar::after { display:none; }
  .winter-actions { flex-direction:column; }
  .special-theme-dates { grid-template-columns:1fr; }
  .special-theme-content > button { width:100%; }
}
@media(forced-colors:active) {
  .winter-panorama,.winter-offer-art,.winter-snow { display:none!important; }
  html[data-festive="true"] :is(body,.topbar,.sidebar,main,.site-footer) { background:Canvas; color:CanvasText; border-color:CanvasText; box-shadow:none; }
  html[data-festive="true"] :is(.topbar,.sidebar,.site-footer) :is(a,button,small,p) { color:LinkText; }
  html[data-festive="true"] .topbar::after { display:none; }
  html[data-festive="true"] .sidebar::after { display:none; }
}
