/* ===== Clan-HQ-Karte (js/clan-hq.js) ===== */
.chq { position: absolute; inset: 0; z-index: 250; background: #8fd07a; overflow: hidden; touch-action: none; color: #e9eef5; }
.chq-canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; cursor: grab; }
.chq-canvas:active { cursor: grabbing; }
.chq-loading { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 10px; background: #8fd07a; color: #0f2a17; font-weight: 800; }

.chq-top { position: absolute; top: calc(8px + var(--sat)); left: calc(8px + var(--sal)); right: calc(8px + var(--sar));
  display: flex; align-items: center; gap: 8px; pointer-events: none; }
.chq-top > * { pointer-events: auto; }
.chq-back { flex: 0 0 auto; width: 42px; height: 42px; border: 2px solid rgba(255,255,255,.25); border-radius: 12px;
  background: linear-gradient(180deg, #2c3a4d, #1b2430); color: #fff; font: 900 26px/1 system-ui, sans-serif; cursor: pointer; box-shadow: 0 3px 8px rgba(0,0,0,.4); }
.chq-title { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; padding: 5px 12px 6px 6px; border-radius: 14px;
  background: rgba(10,16,28,.86); border: 1px solid rgba(96,165,250,.35); box-shadow: 0 4px 12px rgba(0,0,0,.35); }
.chq-title > div { min-width: 0; flex: 1; }
.chq-title b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.chq-title small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #8fb4d9; font-size: 9px; font-weight: 900; letter-spacing: 1.2px; }
.chq-lvl { display: block; height: 4px; margin-top: 3px; border-radius: 2px; background: #1c2838; overflow: hidden; }
.chq-lvl i { display: block; height: 100%; background: linear-gradient(90deg, #f6c453, #ffe39a); }
.chq-bits { flex: 0 0 auto; display: flex; align-items: center; gap: 3px; padding: 4px 10px 4px 4px; border-radius: 99px;
  background: rgba(10,16,28,.86); border: 1px solid rgba(56,214,255,.45); color: #38d6ff; font-weight: 900; font-size: 15px; }
.chq-bits img { width: 28px; height: 28px; }

.chq-side { position: absolute; right: calc(8px + var(--sar)); top: calc(66px + var(--sat)); display: flex; flex-direction: column; gap: 8px; }
.chq-side button { position: relative; width: 48px; height: 48px; padding: 0; border: 2px solid rgba(255,255,255,.25); border-radius: 12px;
  background: linear-gradient(180deg, #2c3a4d, #1b2430); cursor: pointer; box-shadow: 0 3px 8px rgba(0,0,0,.4); }
.chq-side img { width: 36px; height: 36px; object-fit: contain; }
.chq-side .chq-garden-btn { height: 58px; border-color: rgba(208,183,255,.8); background: linear-gradient(155deg, #7a38d8, #34205f 62%, #152333); }
.chq-side .chq-garden-btn img { width: 32px; height: 32px; margin-top: 2px; }
.chq-side small { display: block; margin-top: -3px; color: #fff; font-size: 7.5px; font-weight: 900; letter-spacing: .8px; }

.chq-vote { position: absolute; left: calc(8px + var(--sal)); right: calc(8px + var(--sar)); bottom: calc(10px + var(--sab));
  display: flex; justify-content: center; pointer-events: none; }
.chq-card { pointer-events: auto; width: 100%; max-width: 430px; display: flex; flex-direction: column; gap: 6px; padding: 12px 14px;
  border-radius: 16px; background: rgba(10,16,28,.93); border: 1px solid rgba(96,165,250,.35); box-shadow: 0 10px 28px rgba(0,0,0,.45); }
.chq-card b { color: #fff; font-size: 15px; line-height: 1.25; }
.chq-card small { color: #9fb0c5; font-size: 11.5px; line-height: 1.4; }
.chq-card.is-vote { border-color: rgba(246,196,83,.6); box-shadow: 0 0 0 3px rgba(246,196,83,.12), 0 10px 28px rgba(0,0,0,.45); }
.chq-card.is-rejected { border-color: rgba(239,68,68,.5); }
.chq-card.is-done { border-color: rgba(246,196,83,.7); text-align: center; align-items: center; }
.chq-card.is-visit { border-color: rgba(110,231,255,.55); }
.chq-card .btn { width: 100%; margin-top: 4px; }
.chq-kicker { color: #46c8ff; font-size: 9.5px; font-weight: 900; letter-spacing: 1.6px; }
.chq-kicker.gold { color: #f6c453; }
.chq-kicker.red { color: #f87171; }
.chq-vote-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.chq-timer { color: #ffe39a; font-size: 12px; font-weight: 800; white-space: nowrap; }
.chq-timer b { font-size: 14px; color: #fff; font-variant-numeric: tabular-nums; }
.chq-cost { display: flex; align-items: center; gap: 4px; }
.chq-cost img { width: 18px; height: 18px; }
.chq-tally { display: flex; justify-content: space-between; height: 10px; margin-top: 2px; border-radius: 99px; background: #1c2838; overflow: hidden; }
.chq-tally i { display: block; height: 100%; transition: width .4s ease; }
.chq-tally .yes { background: linear-gradient(90deg, #16a34a, #4ade80); }
.chq-tally .no { background: linear-gradient(90deg, #f87171, #dc2626); }
.chq-tally-legend { display: flex; justify-content: space-between; font-size: 10.5px; font-weight: 800; color: #8594a8; }
.chq-tally-legend .yes { color: #4ade80; }
.chq-tally-legend .no { color: #f87171; }
.chq-vote-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 2px; }
.chq-vote-btns button { height: 46px; border: 2px solid transparent; border-radius: 12px; font: inherit; font-size: 15px; font-weight: 900; color: #fff; cursor: pointer; transition: transform .1s; }
.chq-vote-btns button:active { transform: scale(.97); }
.chq-vote-btns button:disabled { opacity: .6; }
.chq-yes { background: linear-gradient(180deg, #22c55e, #15803d); box-shadow: 0 3px 0 #0f5f2d; }
.chq-no { background: linear-gradient(180deg, #ef4444, #b91c1c); box-shadow: 0 3px 0 #7f1414; }
.chq-vote-btns .is-on { border-color: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,.25), 0 3px 0 rgba(0,0,0,.4); }
.chq-weight { color: #8594a8 !important; font-size: 10.5px !important; }
.chq-progress { position: relative; height: 24px; border-radius: 12px; background: #1c2838; overflow: hidden; }
.chq-progress i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, #38d6ff, #7c5cff); }
.chq-progress em { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 4px; color: #fff; font-size: 12px; font-style: normal; font-weight: 900; }
.chq-progress em img { width: 18px; height: 18px; }

.chq-banner { position: absolute; left: 50%; top: 28%; transform: translate(-50%, -50%) scale(.6); opacity: 0; pointer-events: none;
  padding: 10px 20px 12px; border-radius: 16px; text-align: center; white-space: nowrap;
  background: linear-gradient(180deg, #ffe39a, #f6b83d); color: #3a2a00; box-shadow: 0 10px 30px rgba(0,0,0,.35), 0 0 0 3px rgba(255,255,255,.6); }
.chq-banner small { display: block; font-size: 10px; font-weight: 900; letter-spacing: 1.8px; }
.chq-banner b { display: block; font-size: 19px; font-weight: 900; }
.chq-banner.is-on { animation: chq-banner 2.6s cubic-bezier(.2,.9,.3,1.2) forwards; }
@keyframes chq-banner {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.6); }
  12% { opacity: 1; transform: translate(-50%, -50%) scale(1.06); }
  20%, 80% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -80%) scale(.96); }
}

/* Garten-Auswahl */
.chq-sheet { position: absolute; inset: 0; z-index: 5; display: flex; align-items: flex-end; justify-content: center; background: rgba(4,8,16,.55); }
.chq-sheet-card { width: 100%; max-width: 520px; max-height: 82%; overflow-y: auto; padding: 14px 14px calc(14px + var(--sab));
  border-radius: 18px 18px 0 0; background: #0f1724; border: 1px solid rgba(96,165,250,.3); display: flex; flex-direction: column; gap: 8px; }
.chq-sheet-card header { position: sticky; top: -14px; z-index: 1; display: flex; justify-content: space-between; align-items: center; margin: -14px -14px 0; padding: 12px 14px 8px; background: #0f1724; }
.chq-sheet-card header b { font-size: 17px; }
.chq-sheet-x { width: 32px; height: 32px; border: 0; border-radius: 9px; background: rgba(255,255,255,.1); color: #fff; font-weight: 900; cursor: pointer; }
.chq-sheet-card p { margin: 0; color: #9fb0c5; font-size: 12.5px; line-height: 1.45; }
.chq-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: 8px; }
.chq-opt { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 4px 4px 6px; border: 2px solid transparent; border-radius: 12px;
  background: #111925; color: #e9eef5; font: inherit; cursor: pointer; }
.chq-opt canvas { display: block; width: 100%; height: 92px; border-radius: 8px; }
.chq-opt small { font-size: 10.5px; font-weight: 800; text-align: center; line-height: 1.2; }
.chq-opt.is-on { border-color: #f6c453; box-shadow: 0 0 0 3px rgba(246,196,83,.2); }
.chq-opt-none { display: grid; place-items: center; width: 100%; height: 92px; border-radius: 8px; background: #0b111b; font-size: 30px; }
.chq-empty { padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,.05); }

/* HQ-Karte in der Clan-Uebersicht */
.clan-hq-card { position: relative; display: grid; grid-template-columns: 112px 1fr; gap: 10px; align-items: center; width: 100%; padding: 8px; text-align: left;
  border: 1px solid rgba(246,196,83,.45); border-radius: 15px; cursor: pointer; font: inherit; color: #e9eef5;
  background: radial-gradient(90% 140% at 0% 50%, rgba(246,196,83,.18), transparent 60%), linear-gradient(135deg, #1b1a14, #111823 70%); }
.clan-hq-card img { width: 112px; height: 84px; object-fit: cover; border-radius: 10px; }
.clan-hq-card b { display: block; margin: 2px 0; font-size: 14.5px; color: #fff; }
.clan-hq-card small { display: block; color: #b8c4d4; font-size: 11.5px; }
.clan-hq-bar { display: block; height: 5px; margin-top: 6px; border-radius: 3px; background: #1c2838; overflow: hidden; }
.clan-hq-bar i { display: block; height: 100%; background: linear-gradient(90deg, #f6c453, #ffe39a); }
.clan-hq-card.has-vote { border-color: #f6c453; box-shadow: 0 0 0 3px rgba(246,196,83,.15); }
.clan-hq-badge { position: absolute; top: -7px; right: 10px; padding: 2px 8px; border-radius: 99px; background: #ef4444; color: #fff; font-size: 9.5px; font-weight: 900; letter-spacing: 1px; animation: pulse 1.4s ease-in-out infinite; }
.clan-hq-lv { margin-left: 6px; padding: 1px 6px; border-radius: 99px; background: rgba(246,196,83,.16); color: #ffe39a; font-size: 9.5px; font-weight: 900; }
.clans-side-btn .badge.is-vote { min-width: 18px; background: #ef4444; font-size: 11px; animation: pulse 1.4s ease-in-out infinite; }

/* Erklaerbild 4: das HQ waechst, der Clan stimmt ab */
.ci-hq { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; }
.ci-hq.h1 { opacity: 1; }
.is-playing .ci-hq.h2 { animation: ci-hq-in .5s 1.3s ease-out forwards; }
.is-playing .ci-hq.h3 { animation: ci-hq-in .5s 2.6s ease-out forwards; }
@keyframes ci-hq-in { from { opacity: 0; transform: scale(1.04); } to { opacity: 1; transform: none; } }
.ci-hqlevel { position: absolute; right: 4%; top: 4%; display: grid; justify-items: end; padding: 5px 10px 6px; border-radius: 12px;
  background: rgba(8,14,26,.82); border: 1px solid rgba(246,196,83,.5); color: #ffe39a; }
.ci-hqlevel b { font-size: 20px; font-weight: 900; line-height: 1; }
.ci-hqlevel small { color: #8fa3bb; font-size: 8.5px; font-weight: 900; letter-spacing: 1px; }
.ci-votes { position: absolute; left: 3%; right: 3%; bottom: 6%; display: flex; justify-content: center; flex-wrap: wrap; gap: 5px; }
.ci-votes span { display: inline-flex; align-items: center; gap: 3px; padding: 3px 8px 3px 3px; border-radius: 99px; background: rgba(8,14,26,.88);
  border: 1px solid rgba(255,255,255,.18); color: #fff; font-size: 10px; font-weight: 900; opacity: 0; transform: translateY(8px) scale(.8); }
.ci-votes img { width: 20px; height: 20px; object-fit: contain; }
.ci-votes em { color: #4ade80; font-style: normal; }
.is-playing .ci-votes span { animation: ci-vote-in .35s calc(.3s + var(--i) * .25s) cubic-bezier(.34,1.56,.64,1) forwards; }
@keyframes ci-vote-in { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .chq-banner.is-on { animation: none; opacity: 1; transform: translate(-50%, -50%); }
  .ci-hq.h3, .ci-votes span { opacity: 1 !important; transform: none !important; }
}

/* ===== Seit 2026-10-03: Hilfe, Plan, beschriftete Seitenknoepfe, Umzug, Haus-Info ===== */
button.chq-title { font: inherit; color: inherit; text-align: left; cursor: pointer; }
.chq-plan-go { flex: 0 0 auto; color: #f6c453; font-style: normal; font-size: 8.5px; font-weight: 900; letter-spacing: 1px; line-height: 1.1; text-align: center; }
.chq-help { flex: 0 0 auto; width: 38px; height: 38px; border: 2px solid rgba(255,255,255,.25); border-radius: 50%;
  background: linear-gradient(180deg, #2c3a4d, #1b2430); color: #fff; font: 900 18px/1 system-ui, sans-serif; cursor: pointer; box-shadow: 0 3px 8px rgba(0,0,0,.4); }
.chq-side button { height: 56px; display: grid; justify-items: center; align-content: center; gap: 1px; color: #fff; }
.chq-side img { width: 30px; height: 30px; }
.chq-side small { margin-top: 0; }
.chq-side .chq-move-btn { border-color: rgba(125,211,252,.8); background: linear-gradient(155deg, #0e7bc4, #123a63 62%, #152333); }
.chq-side .chq-move-btn svg { width: 26px; height: 26px; color: #e0f2fe; }
.chq.is-moving .chq-side, .chq.is-moving .chq-bits, .chq.is-moving .chq-help { display: none; }
.chq.is-moving .chq-canvas { cursor: move; }

.chq-card { position: relative; }
.chq-min { position: absolute; top: 6px; right: 8px; width: 28px; height: 22px; border: 0; border-radius: 7px; background: rgba(255,255,255,.08);
  color: #9fb0c5; font-size: 13px; cursor: pointer; }
.chq-card.is-vote .chq-vote-head { padding-right: 32px; }
.chq-card:not(.is-vote) > .chq-kicker:first-of-type { padding-right: 32px; }
.chq-pill { pointer-events: auto; display: inline-flex; align-items: center; gap: 6px; padding: 9px 14px; border-radius: 99px; border: 1px solid rgba(96,165,250,.45);
  background: rgba(10,16,28,.93); color: #fff; font: inherit; font-size: 13px; font-weight: 800; cursor: pointer; box-shadow: 0 8px 20px rgba(0,0,0,.4); }
.chq-pill.is-vote { border-color: #f6c453; box-shadow: 0 0 0 3px rgba(246,196,83,.18), 0 8px 20px rgba(0,0,0,.4); }
.chq-pill img { width: 16px; height: 16px; vertical-align: -3px; }
.chq-pill > i { color: #9fb0c5; font-style: normal; }
.chq-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 4px; }
.chq-btn { height: 44px; border: 0; border-radius: 12px; color: #fff; font: inherit; font-size: 14px; font-weight: 900; cursor: pointer; }
.chq-btn:disabled { opacity: .5; cursor: default; }
.chq-btn:active:not(:disabled) { transform: translateY(1px); }
.chq-btn.green { background: linear-gradient(180deg, #22c55e, #15803d); box-shadow: 0 3px 0 #0f5f2d; }
.chq-btn.red { background: linear-gradient(180deg, #ef4444, #b91c1c); box-shadow: 0 3px 0 #7f1414; }
.chq-btn.blue { background: linear-gradient(180deg, #38bdf8, #0369a1); box-shadow: 0 3px 0 #0c4a6e; }
.chq-btn.purple { background: linear-gradient(180deg, #a855f7, #6d28d9); box-shadow: 0 3px 0 #4c1d95; }
.chq-card.is-move { border-color: rgba(125,211,252,.7); }
.chq-move-hint { color: #86efac !important; font-weight: 800; }
.chq-move-hint.is-bad { color: #fca5a5 !important; }
.chq-card.is-info { border-color: var(--role, rgba(96,165,250,.35)); }
.chq-info-head { display: grid; grid-template-columns: 44px 1fr 32px; gap: 10px; align-items: center; }
.chq-info-head img { width: 44px; height: 44px; object-fit: contain; }
.chq-info-head b { display: block; font-size: 16px; }
.chq-info-facts { display: flex; flex-wrap: wrap; gap: 6px; }
.chq-info-facts span { display: inline-flex; align-items: center; gap: 4px; padding: 4px 9px; border-radius: 99px; background: rgba(255,255,255,.06);
  color: #c7d2e0; font-size: 11px; font-weight: 800; }
.chq-info-facts span.is-on { background: rgba(56,214,255,.14); color: #7dd3fc; }
.chq-info-facts img { width: 14px; height: 14px; }
.chq-info-tip { color: #8594a8 !important; }
.chq-plan { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 4px; }
.chq-plan li { display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 10px; background: #111925;
  color: #8594a8; font-size: 12.5px; font-weight: 700; }
.chq-plan li i { font-style: normal; font-weight: 900; color: #5b6b80; text-align: center; }
.chq-plan li.is-built { color: #d6e2f0; background: rgba(34,197,94,.08); }
.chq-plan li.is-built i { color: #4ade80; }
.chq-plan li.is-next { color: #fff; background: rgba(246,196,83,.14); box-shadow: inset 0 0 0 1px rgba(246,196,83,.6); }
.chq-plan li em { font-style: normal; font-size: 9.5px; font-weight: 900; letter-spacing: 1px; color: #4ade80; }
.chq-plan li.is-next em { color: #f6c453; }

/* ===== Erklaerbilder Clan-HQ (js/clan-hq-intro.js) ===== */
.hq-intro .ci-card { border-color: rgba(246,196,83,.4); background: linear-gradient(180deg, #14213a, #0a0f17); }
.hq-intro .ci-stage::after { background: linear-gradient(180deg, transparent 74%, #14213a); }
.hq-intro .ci-kicker { background: linear-gradient(180deg, #f6c453, #d99a26); color: #2b1d00; }
.hq-intro .ci-copy p b { color: #ffe39a; }
.hq-intro .ci-dots i.on { background: #f6c453; }
.hq-intro .ci-next { background: linear-gradient(180deg, #ffe08a, #f2b536); color: #2b1d00; box-shadow: 0 4px 14px rgba(242,181,54,.35); }
@keyframes hqi-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes hqi-pop { from { opacity: 0; transform: translate(-50%, 0) scale(.6); } to { opacity: 1; transform: translate(-50%, 0) scale(1); } }

/* Bild 2: Wahlurne, Karten fallen hinein, Zaehler */
.hqi-rays { position: absolute; left: 50%; top: 46%; width: 120%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; opacity: 0;
  background: repeating-conic-gradient(from 0deg, rgba(255,214,107,.16) 0 9deg, transparent 9deg 22deg);
  -webkit-mask: radial-gradient(circle, #000 18%, transparent 62%); mask: radial-gradient(circle, #000 18%, transparent 62%); }
.hqi-ballot { position: absolute; left: 50%; top: 20%; width: 42%; transform: translate(-50%, 0); opacity: 0; filter: drop-shadow(0 14px 18px rgba(0,0,0,.45)); }
.hqi-card { position: absolute; left: 50%; top: -24%; width: 9%; margin-left: -4.5%; opacity: 0; filter: drop-shadow(0 6px 8px rgba(0,0,0,.4)); }
.hqi-tally { position: absolute; left: 50%; top: 5%; width: 56%; transform: translateX(-50%); height: 26px; border-radius: 99px;
  background: rgba(8,14,26,.85); border: 1px solid rgba(255,255,255,.18); opacity: 0; --yes: 0%; --no: 0%; }
.hqi-tally i { position: absolute; top: 0; bottom: 0; transition: width .35s ease; }
.hqi-tally .yes { left: 0; width: var(--yes); border-radius: 99px 0 0 99px; background: linear-gradient(90deg, #16a34a, #4ade80); }
.hqi-tally .no { right: 0; width: var(--no); border-radius: 0 99px 99px 0; background: linear-gradient(90deg, #f87171, #dc2626); }
.hqi-tally span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 6px; color: #fff; font-size: 11px; font-weight: 900; letter-spacing: .5px; text-shadow: 0 1px 2px rgba(0,0,0,.6); }
.hqi-tally b { font-size: 14px; }
.hqi-tally b.bump { animation: ci-bump .25s ease-out; }
.hqi-tally.is-done { box-shadow: 0 0 0 3px rgba(74,222,128,.55); }
.hq-intro .ci-votes span em { color: #ffe39a; }
.is-playing .hqi-rays { animation: hqi-in .6s .1s ease-out forwards; }
.is-playing .hqi-ballot { animation: hqi-pop .6s .15s cubic-bezier(.34,1.56,.64,1) forwards; }
.is-playing .hqi-tally { animation: hqi-in .4s .5s ease-out forwards; }
.is-playing .hqi-card { animation: hqi-drop .65s calc(.55s + var(--i) * .6s) cubic-bezier(.5,0,.75,0) forwards; }
@keyframes hqi-drop {
  0% { opacity: 0; transform: translateY(0) rotate(-14deg); }
  20% { opacity: 1; }
  80% { opacity: 1; transform: translateY(260%) rotate(0deg); }
  100% { opacity: 0; transform: translateY(300%) rotate(0deg) scale(.9); }
}

/* Bild 3: Haus ueber das Raster ziehen */
.hqi-grid { position: absolute; left: 50%; top: 60%; width: 150%; aspect-ratio: 2 / 1; transform: translate(-50%, -50%); opacity: 0;
  background:
    repeating-linear-gradient(26.57deg, rgba(255,255,255,.28) 0 1px, transparent 1px 22px),
    repeating-linear-gradient(-26.57deg, rgba(255,255,255,.28) 0 1px, transparent 1px 22px);
  -webkit-mask: radial-gradient(closest-side, #000 55%, transparent); mask: radial-gradient(closest-side, #000 55%, transparent); }
.hqi-spot { position: absolute; left: 68%; top: 64%; width: 42%; aspect-ratio: 2 / 1; transform: translate(-50%, -50%); opacity: 0;
  background: rgba(74,222,128,.4); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.hqi-house { position: absolute; left: 30%; top: 26%; width: 52%; transform: translateX(-50%); opacity: 0; filter: drop-shadow(0 10px 12px rgba(0,0,0,.4)); }
.hqi-hand { position: absolute; left: 32%; top: 56%; font-size: 34px; opacity: 0; filter: drop-shadow(0 3px 4px rgba(0,0,0,.5)); }
.hqi-chip { position: absolute; left: 4%; top: 6%; display: inline-flex; align-items: center; gap: 5px; padding: 6px 11px 6px 8px; border-radius: 12px;
  background: linear-gradient(155deg, #0e7bc4, #123a63); border: 2px solid rgba(125,211,252,.8); color: #fff; font-size: 12px; font-weight: 900; letter-spacing: 1px; opacity: 0; }
.hqi-chip svg { width: 18px; height: 18px; }
.hqi-ok { position: absolute; right: 5%; top: 8%; padding: 5px 10px; border-radius: 99px; background: #16a34a; color: #fff; font-size: 11px; font-weight: 900; opacity: 0; }
.is-playing .hqi-grid { animation: hqi-in .5s .1s ease-out forwards; }
.is-playing .hqi-chip { animation: hqi-in .4s .3s ease-out forwards; }
.is-playing .hqi-house { animation: hqi-in .4s .3s ease-out forwards, hqi-slide 2.4s 1s cubic-bezier(.45,0,.3,1) forwards; }
.is-playing .hqi-hand { animation: hqi-hand 2.4s 1s cubic-bezier(.45,0,.3,1) forwards; }
.is-playing .hqi-spot { animation: hqi-in .3s 1.1s ease-out forwards, hqi-pulse 1s 1.4s ease-in-out infinite; }
.is-playing .hqi-ok { animation: hqi-in .3s 3.3s ease-out forwards; }
@keyframes hqi-slide { 0% { left: 30%; top: 26%; } 25% { top: 20%; } 85% { left: 68%; top: 20%; } 100% { left: 68%; top: 27%; } }
@keyframes hqi-hand { 0% { opacity: 1; left: 32%; top: 56%; } 85% { opacity: 1; left: 70%; top: 50%; } 100% { left: 72%; top: 62%; opacity: 0; } }
@keyframes hqi-pulse { 50% { background: rgba(74,222,128,.6); } }

/* Bild 4: Garten, Max macht nach 3x Tippen einen Salto */
.hqi-garden { position: absolute; left: 50%; top: 12%; width: 74%; transform: translateX(-50%); opacity: 0; filter: drop-shadow(0 12px 14px rgba(0,0,0,.4)); }
.hqi-max { position: absolute; left: 31%; top: 46%; width: 15%; opacity: 0; transform-origin: 50% 60%; filter: drop-shadow(0 4px 4px rgba(0,0,0,.35)); }
.hqi-tap { position: absolute; left: 38.5%; top: 60%; width: 0; height: 0; }
.hqi-tap i { position: absolute; left: -20px; top: -20px; width: 40px; height: 40px; border-radius: 50%; border: 3px solid #fff; opacity: 0; }
.hqi-taps { position: absolute; left: 47%; top: 40%; padding: 4px 9px; border-radius: 99px; background: #fff; color: #14213a; font-size: 11px; font-weight: 900; opacity: 0; }
.hqi-spark { position: absolute; left: 38.5%; top: 54%; width: 9px; height: 9px; border-radius: 2px; opacity: 0; background: hsl(calc(var(--i) * 45deg) 90% 65%); }
.is-playing .hqi-garden { animation: hqi-in .5s .1s ease-out forwards; }
.is-playing .hqi-max { animation: hqi-in .3s .5s ease-out forwards, hqi-flip .9s 2.4s cubic-bezier(.3,.7,.4,1) forwards; }
.is-playing .hqi-tap i:nth-child(1) { animation: hqi-ring .5s 1.1s ease-out; }
.is-playing .hqi-tap i:nth-child(2) { animation: hqi-ring .5s 1.5s ease-out; }
.is-playing .hqi-tap i:nth-child(3) { animation: hqi-ring .5s 1.9s ease-out; }
.is-playing .hqi-taps { animation: hqi-in .2s 1.1s ease-out forwards, hqi-out .3s 2.3s ease-in forwards; }
.is-playing .hqi-spark { animation: hqi-burst 1s 2.6s ease-out forwards; }
@keyframes hqi-ring { from { opacity: 1; transform: scale(.4); } to { opacity: 0; transform: scale(1.4); } }
@keyframes hqi-out { to { opacity: 0; } }
@keyframes hqi-flip { 0% { transform: none; } 40% { transform: translateY(-55%) rotate(-180deg); } 75% { transform: translateY(-20%) rotate(-340deg); } 100% { transform: rotate(-360deg); } }
@keyframes hqi-burst {
  0% { opacity: 1; transform: rotate(calc(var(--i) * 45deg)) translateX(0); }
  100% { opacity: 0; transform: rotate(calc(var(--i) * 45deg)) translateX(70px) rotate(200deg); }
}

/* Bild 5: Start-Bedingung, 4 Clans mit 5+ Mitgliedern */
.hqi-gate { position: absolute; left: 3%; right: 3%; top: 21%; display: grid; grid-template-columns: repeat(4, 1fr); gap: 2%; }
.hqi-clan { position: relative; display: grid; justify-items: center; gap: 3px; padding: 6px 2px 8px; border-radius: 14px; background: rgba(8,14,26,.8);
  border: 1px solid rgba(255,255,255,.12); opacity: 0; filter: grayscale(.85) brightness(.75); }
.hqi-clan img { width: 70%; }
.hqi-clan b { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 3px; color: #fff; font-size: 10.5px; }
.hqi-clan small { color: #8fa3bb; font-size: 10px; font-weight: 900; }
.hqi-clan em { position: absolute; top: -8px; right: -6px; width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; background: #16a34a;
  color: #fff; font-style: normal; font-weight: 900; font-size: 13px; box-shadow: 0 0 0 2px #0a0f17; transform: scale(0); }
.hqi-pips { display: grid; grid-template-columns: repeat(5, 7px); gap: 3px; }
.hqi-pips i { width: 7px; height: 7px; border-radius: 2px; background: #2a3a52; }
.hqi-pips i.on { background: #46c8ff; }
.hqi-clan.is-ready { border-color: rgba(74,222,128,.7); }
.hqi-clan.is-ready small { color: #86efac; }
.hqi-count { position: absolute; left: 50%; top: 4%; transform: translateX(-50%); display: flex; align-items: baseline; gap: 5px; padding: 5px 12px; border-radius: 12px;
  background: rgba(8,14,26,.85); border: 1px solid rgba(246,196,83,.5); color: #ffe39a; white-space: nowrap; }
.hqi-count b { font-size: 22px; font-weight: 900; line-height: 1; }
.hqi-count b.bump { animation: ci-bump .25s ease-out; }
.hqi-count small { color: #c7d2e0; font-size: 10px; font-weight: 900; letter-spacing: 1px; }
.hqi-mine { position: absolute; left: 50%; bottom: 9%; transform: translateX(-50%); padding: 4px 10px; border-radius: 99px; background: rgba(37,99,235,.88); color: #fff;
  font-size: 11px; font-weight: 900; white-space: nowrap; }
.is-playing .hqi-clan { animation: hqi-clan .5s calc(.2s + var(--i) * .12s) ease-out forwards; }
.is-playing .hqi-clan.is-ready { animation: hqi-clan .5s calc(.2s + var(--i) * .12s) ease-out forwards, hqi-lit .5s calc(1.1s + var(--i) * .45s) ease-out forwards; }
.is-playing .hqi-clan.is-ready em { animation: hqi-check .35s calc(1.2s + var(--i) * .45s) cubic-bezier(.34,1.56,.64,1) forwards; }
@keyframes hqi-clan { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes hqi-lit { to { opacity: 1; filter: none; box-shadow: 0 0 18px rgba(74,222,128,.35); } }
@keyframes hqi-check { to { transform: scale(1); } }

/* HQ-Karte in der Clan-Uebersicht vor dem Start: Vorschau mit Zaehler */
.clan-hq-card.is-gate { border-style: dashed; }
.clan-hq-card .clan-hq-tag { position: absolute; left: 14px; top: 14px; padding: 2px 7px; border-radius: 99px; background: rgba(8,14,26,.85); color: #ffe39a;
  font-size: 9px; font-weight: 900; letter-spacing: 1px; }
.clan-hq-gate { display: flex; gap: 4px; margin-top: 6px; }
.clan-hq-gate i { flex: 1; height: 6px; border-radius: 3px; background: #2a3a52; }
.clan-hq-gate i.on { background: linear-gradient(90deg, #4ade80, #16a34a); }
.clan-hq-lv.is-ready { background: rgba(74,222,128,.16); color: #86efac; }
.poll-news-count { display: flex; align-items: center; gap: 6px; margin: 4px 0 2px; }
.poll-news-count i { width: 22px; height: 8px; border-radius: 4px; background: rgba(0,0,0,.18); }
.poll-news-count i.on { background: #16a34a; }

@media (prefers-reduced-motion: reduce) {
  .hq-intro .is-playing * { animation: none !important; }
  .hqi-rays, .hqi-ballot, .hqi-tally, .hqi-grid, .hqi-chip, .hqi-house, .hqi-spot, .hqi-ok, .hqi-garden, .hqi-max, .hqi-clan { opacity: 1 !important; }
  .hqi-house { left: 68%; }
  .hqi-clan.is-ready { filter: none; }
  .hqi-clan em { transform: none; }
}

/* Villa (Kauf) */
.chq-btn.gold { width: 100%; margin-top: 2px; background: linear-gradient(180deg, #ffe08a, #f2b536); color: #2b1d00; box-shadow: 0 3px 0 #a8730f; }
.chq-link { border: 0; background: none; color: #ffe39a; font: inherit; font-size: 12px; font-weight: 800; cursor: pointer; padding: 4px 0; text-align: left; }
.chq-info-facts span.is-villa { background: rgba(246,196,83,.16); color: #ffe39a; }
.chq-villa { border-color: rgba(246,196,83,.5); }
.chq-villa-art { position: relative; border-radius: 14px; background: radial-gradient(70% 80% at 50% 45%, #2d4a6b, #0f1724 75%); display: grid; place-items: center; padding: 6px 0; }
.chq-villa-art img { width: 86%; max-width: 380px; filter: drop-shadow(0 14px 16px rgba(0,0,0,.5)); }
.chq-villa-art span { position: absolute; left: 10px; top: 10px; padding: 3px 9px; border-radius: 99px; background: linear-gradient(180deg, #f6c453, #d99a26); color: #2b1d00; font-size: 9.5px; font-weight: 900; letter-spacing: 1.2px; }
.chq-villa ul { margin: 2px 0 0; padding-left: 18px; color: #c7d2e0; font-size: 12.5px; line-height: 1.55; }
.chq-villa ul b { color: #ffe39a; }
.chq-villa .chq-btn.gold { height: 50px; font-size: 16px; }
.chq-villa .chq-link { text-align: center; color: #9fb0c5; }
.chq-villa-err { color: #fca5a5 !important; font-weight: 700; }

/* 3D-Icons statt Emojis (js/clan-hq.js ICON, blender/render_chq_icons.py) */
.chq-ico { width: 18px; height: 18px; object-fit: contain; flex: 0 0 auto; vertical-align: -4px; filter: drop-shadow(0 1px 1px rgba(0,0,0,.35)); }
.chq-ico.is-wide { width: auto; height: 16px; }
.chq-info-facts .chq-ico { width: 16px; height: 16px; margin-right: 1px; }
.chq-info-facts .chq-ico.is-wide { width: auto; height: 14px; }
.chq-btn, .chq-vote-btns button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; }
.chq-link .chq-ico { margin-right: 5px; }
.chq-btn .chq-ico, .chq-vote-btns .chq-ico { width: 22px; height: 22px; }
.chq-btn .chq-ico.is-wide { width: auto; height: 20px; }
.chq-vote-btns .chq-ico { width: 20px; height: 22px; }
.chq-timer { display: inline-flex; align-items: center; gap: 4px; }
.chq-timer .chq-ico { width: 16px; height: 16px; vertical-align: 0; }
.chq-opt-none .chq-ico.is-none { width: 46px; height: 46px; opacity: .45; filter: grayscale(1); }
img.hqi-hand { width: 46px; height: 46px; object-fit: contain; }
