html.iwg-merge body{background:var(--iwg-paper);color:var(--iwg-ink)}
.merge-entry{max-width:1184px;margin:auto;padding:26px 24px 36px;font-family:var(--iwg-font);color:var(--iwg-ink)}
.merge-crumbs{display:flex;flex-wrap:wrap;gap:10px;font-size:12px;color:var(--iwg-muted);margin-bottom:24px}.merge-heading{display:flex;align-items:center;gap:18px;margin-bottom:28px}.merge-mark{display:grid;place-items:center;width:66px;height:66px;flex-shrink:0;border:2px solid #f0c5d4;border-radius:17px;background:#fff0f4;color:#b52d60;font-size:37px;font-weight:800;transform:rotate(-6deg)}.merge-heading h1{display:flex;align-items:center;flex-wrap:wrap;gap:14px;font:850 38px/1.2 var(--iwg-font);letter-spacing:-1.3px}.merge-heading h1 span{font:750 9px var(--iwg-font);letter-spacing:1px;padding:6px 9px;border-radius:30px;background:#fff0f4;color:#9b2851}.merge-heading p{font-size:13px;color:var(--iwg-muted);margin-top:7px}
.merge-layout{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:24px;align-items:start}.merge-panel{overflow:hidden}.merge-mode-bar{display:flex;justify-content:space-between;gap:12px;padding:20px 24px;border-bottom:1px solid var(--iwg-border);font-size:12px}.merge-mode-bar strong{color:var(--iwg-blue)}.merge-mode-bar a{color:var(--iwg-muted)}.merge-setup{padding:30px 24px}.merge-intro{text-align:center;margin-bottom:26px}.merge-intro h2{font:800 22px/1.4 var(--iwg-font)}.merge-intro p{font-size:12px;color:var(--iwg-muted);margin-top:9px}
.merge-name{max-width:380px;margin:0 auto 24px}.merge-entry label{display:block;font-size:12px;font-weight:700;margin-bottom:9px}.merge-entry input{display:block;width:100%;min-width:0;min-height:48px;padding:12px 14px;border:2px solid var(--iwg-muted);border-radius:12px;background:var(--iwg-paper);color:var(--iwg-ink);font:500 14px var(--iwg-font)}.merge-entry input::placeholder{color:var(--iwg-muted)}.merge-entry :is(input,button,a):focus-visible{outline:3px solid var(--iwg-blue);outline-offset:3px}.merge-forms{display:grid;grid-template-columns:1fr 1fr;gap:16px}.merge-forms>:is(section,form){display:flex;flex-direction:column;min-width:0;padding:22px;border:1px solid var(--iwg-border);border-radius:18px;background:var(--iwg-soft)}.merge-forms h3{font:800 17px var(--iwg-font);margin-bottom:16px}.merge-forms p{font-size:12px;line-height:1.7;color:var(--iwg-muted);margin-bottom:20px}.merge-entry .iwg-button{width:100%;font-size:12px;min-height:48px;margin-top:auto}.merge-forms input{margin-bottom:18px}.merge-panel-bottom{border-top:1px solid var(--iwg-border);padding:18px 24px;text-align:center;color:var(--iwg-muted);font-size:11px}
.merge-guide{padding:24px}.merge-guide h2{font:800 22px/1.3 var(--iwg-font);letter-spacing:-.5px;margin-bottom:12px}.merge-guide p{font-size:12px;line-height:1.7;color:var(--iwg-muted)}.merge-rule{display:flex;gap:12px;align-items:start;margin-top:24px}.merge-rule>span{display:grid;place-items:center;flex-shrink:0;width:38px;height:38px;border-radius:9px;background:var(--iwg-soft);font-size:22px;color:var(--iwg-blue)}.merge-rule h3{font-size:12px;font-weight:750;margin-bottom:5px}.merge-rule p{font-size:11px}.merge-guide .merge-tip{margin-top:24px;padding-top:18px;border-top:1px solid var(--iwg-border);font-size:11px}
@media(max-width:900px){.merge-layout{grid-template-columns:1fr}}
@media(max-width:600px){.merge-entry{padding:20px 12px 30px}.merge-heading{gap:12px}.merge-mark{width:50px;height:50px;font-size:29px}.merge-heading h1{font-size:27px;gap:8px}.merge-heading h1 span{font-size:7px}.merge-heading p{font-size:11px;line-height:1.6}.merge-setup{padding:24px 14px}.merge-intro h2{font-size:20px}.merge-forms{grid-template-columns:1fr}.merge-forms>:is(section,form){padding:18px}.merge-mode-bar{padding:18px 14px}.merge-related{gap:8px}}

.merge-forms h2{font-size:17px;font-weight:800;margin-bottom:16px}.merge-entry #landing-error{margin-top:18px;color:var(--iwg-ink)}.merge-entry #input-room-code{text-transform:uppercase;letter-spacing:.15em}

.merge-entry-shell{background:var(--iwg-paper)!important;color:var(--iwg-ink)}.merge-entry-shell>div{min-height:0}.merge-entry select{width:100%;padding:12px;border:1px solid var(--iwg-border);border-radius:12px;background:var(--iwg-paper);color:var(--iwg-ink);margin-bottom:16px}.merge-feedback{font-size:12px;color:var(--iwg-muted);margin-top:18px}

.merge-preview{position:relative;max-width:400px;margin:auto;display:grid;place-items:center}.merge-preview svg{width:100%;opacity:.4}.merge-preview .iwg-button{position:absolute;width:auto;min-width:190px}.iwg-merge #pageIntro{padding-top:84px;min-height:0}
@media(max-width:650px){.iwg-merge #pageIntro{padding-top:76px}}.iwg-merge body{background:var(--iwg-paper);color:var(--iwg-ink)}

.merge-related { margin-top: 34px; }
.merge-related-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 15px;
}
.merge-related-heading h2 { font-size: 20px; font-weight: 800; }
.merge-related-heading > a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 44px;
  color: var(--iwg-blue);
  font-size: 13px;
  font-weight: 700;
}
.merge-related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.merge-related-grid > a { display: flex; align-items: center; gap: 12px; min-width: 0; padding: 16px; }
.merge-related-grid > a:hover { border-color: var(--iwg-blue); }
.merge-related-grid svg {
  width: 64px;
  height: 60px;
  flex-shrink: 0;
  border-radius: 12px;
  background: var(--iwg-soft);
}
.merge-related-grid h3 { font-size: 14px; font-weight: 800; }
.merge-related-grid p { margin-top: 5px; font-size: 12px; color: var(--iwg-muted); }
.merge-related-grid > a > span { margin-left: auto; color: var(--iwg-blue); }

#pageGame .controls-row { flex-wrap: wrap; }
#pageGame .controls-row > button { min-width: 44px; min-height: 44px; padding: 0 8px; }
#pageGame .controls-row .btn-fullscreen { flex: 0 0 44px; padding: 0; }
#pageGame .merge-quit {
  border-color: var(--iwg-border);
  background: var(--iwg-paper);
  color: var(--iwg-ink);
}
#pageGame .merge-quit:hover { background: var(--iwg-soft); color: var(--iwg-blue); }
#pageGame .merge-quit:focus-visible { outline: 3px solid var(--iwg-blue); outline-offset: 2px; }

@media (max-width: 900px) {
  .merge-related-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .merge-related-heading { flex-direction: column; align-items: flex-start; gap: 0; }
  .merge-related-heading h2 { font-size: 19px; }
}
