/* Authentic 1999 Internet Gaming Zone Client & Portal Stylesheet.
 * Modeled directly from real 1999 Zone screenshots and extracted PE/ZRS assets:
 *   - Portal: toplevelcommon.css (#000000 bg, #669999 side/nav, #FFFFCC links, #CCFFFF text)
 *   - ZoneFriends: #2B5A5A teal curved swirl header + #FFCC66 golden-amber buddy tree
 *   - ZoneMessage / Log On As: 2-tone curved #2E5E5E teal + #FFCC66 gold dialog
 *   - Classic Lobby (Genre 0): #330000 burgundy floor with wooden 162x144 tables + black roster
 *   - Matchmaking Lobby (Genre 2/3/4): #000000 black + idb_lobby.png arc + curved boomerang tiles + gold Host orbs
 *   - Launchpad: #000000 black + idb_launchpad.png curve + teal pill buttons + black HOST/PLAYERS sidebar
 *   - Chat / Theater: 60px black banner + white chat pane + black TOTAL PEOPLE sidebar
 * ASCII only, LF line endings. */

:root {
  --igz-bg: #000000;
  --igz-side: #669999;
  --igz-link: #FFFFCC;
  --igz-text: #CCFFFF;
  --igz-muted: #99CCCC;
  --igz-white: #FFFFFF;
  --zf-teal: #336666;
  --zf-gold: #FFCC66;
  --clob-burgundy: #330000;
  --clob-maroon: #5C0000;
  --w98-face: #D4D0C8;
  --w98-light: #FFFFFF;
  --w98-dark: #808080;
  --w98-darker: #404040;
  --w98-title-a: #0A246A;
  --w98-title-b: #A6CAF0;
  --w98-cur-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='22' viewBox='0 0 20 22' shape-rendering='crispEdges'%3E%3Cpolygon points='1,1 1,17 5,13 8,20 10.5,19 7.5,12 13,12' fill='%23ffffff' stroke='%23000000' stroke-width='1.35' stroke-linejoin='miter'/%3E%3C/svg%3E") 1 1, default;
  --w98-cur-hand: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='24' viewBox='0 0 22 24' shape-rendering='crispEdges'%3E%3Cpath d='M7,1 H9 V9 H11 V7 H13 V10 H15 V8 H17 V11 H19 V17 L17,22 H8 L5,17 L2,12 L4,10 L7,13 Z' fill='%23ffffff' stroke='%23000000' stroke-width='1.3' stroke-linejoin='miter'/%3E%3C/svg%3E") 6 1, pointer;
  --w98-cur-ibeam: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='13' height='20' viewBox='0 0 13 20' shape-rendering='crispEdges'%3E%3Cpath d='M2,2 H11 M6.5,2 V18 M2,18 H11' fill='none' stroke='%23ffffff' stroke-width='3'/%3E%3Cpath d='M3,2 H10 M6.5,2 V18 M3,18 H10' fill='none' stroke='%23000000' stroke-width='1.4'/%3E%3C/svg%3E") 6 10, text;
  --w98-cur-ew: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='14' viewBox='0 0 22 14' shape-rendering='crispEdges'%3E%3Cpolygon points='1,7 6,2 6,5 16,5 16,2 21,7 16,12 16,9 6,9 6,12' fill='%23ffffff' stroke='%23000000' stroke-width='1.2' stroke-linejoin='miter'/%3E%3C/svg%3E") 11 7, ew-resize;
  --w98-cur-ns: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='22' viewBox='0 0 14 22' shape-rendering='crispEdges'%3E%3Cpolygon points='7,1 12,6 9,6 9,16 12,16 7,21 2,16 5,16 5,6 2,6' fill='%23ffffff' stroke='%23000000' stroke-width='1.2' stroke-linejoin='miter'/%3E%3C/svg%3E") 7 11, ns-resize;
  --w98-cur-nwse: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 20 20' shape-rendering='crispEdges'%3E%3Cpolygon points='2,2 9,2 6.8,4.2 15.8,13.2 18,11 18,18 11,18 13.2,15.8 4.2,6.8 2,9' fill='%23ffffff' stroke='%23000000' stroke-width='1.2' stroke-linejoin='miter'/%3E%3C/svg%3E") 10 10, nwse-resize;
  --w98-cur-nesw: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 20 20' shape-rendering='crispEdges'%3E%3Cpolygon points='18,2 11,2 13.2,4.2 4.2,13.2 2,11 2,18 9,18 6.8,15.8 15.8,6.8 18,9' fill='%23ffffff' stroke='%23000000' stroke-width='1.2' stroke-linejoin='miter'/%3E%3C/svg%3E") 10 10, nesw-resize;
  --w98-cur-wait: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='24' viewBox='0 0 18 24' shape-rendering='crispEdges'%3E%3Crect x='2' y='2' width='14' height='2.5' fill='%23808080' stroke='%23000000' stroke-width='1'/%3E%3Crect x='2' y='19.5' width='14' height='2.5' fill='%23808080' stroke='%23000000' stroke-width='1'/%3E%3Cpolygon points='4,4.5 14,4.5 10,12 14,19.5 4,19.5 8,12' fill='%23ffffff' stroke='%23000000' stroke-width='1'/%3E%3Cpolygon points='6,6 12,6 9,10.5' fill='%23008080'/%3E%3Cpolygon points='6,18.5 12,18.5 9,15' fill='%23008080'/%3E%3C/svg%3E") 9 12, wait;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
  background: #000000;
  color: #CCFFFF;
  font-family: Arial, "MS Sans Serif", Tahoma, sans-serif;
  font-size: 12px;
}

/* ---- Main App Shell ---- */
#app-shell {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  background: #000000;
}

/* 1999 MSN Gaming Zone Portal Masthead (matches netscape-portal.png & toplevelcommon.css) */
.igz-masthead {
  background: #000000;
  border-bottom: 1px solid #335555;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 10px;
  gap: 10px;
  height: 64px;
  flex-shrink: 0;
}

.igz-brand {
  display: flex;
  align-items: center;
}

.igz-brand img {
  height: 56px;
  width: auto;
  image-rendering: pixelated;
  display: block;
}

.igz-banner-wrap {
  display: flex;
  align-items: center;
}

.igz-banner-wrap img.igz-ad-banner {
  width: 468px;
  height: 60px;
  display: block;
}

.igz-promo-wrap {
  display: flex;
  align-items: center;
}

.igz-promo-wrap img {
  height: 28px;
  width: auto;
  image-rendering: pixelated;
  display: block;
}

/* Horizontal #669999 nav strip matching toplevelcommon.css TD.nav */
.igz-navbar {
  background: #669999;
  color: #000000;
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 6px;
  height: 22px;
  font-size: 12px;
  font-weight: bold;
  flex-shrink: 0;
  border-bottom: 1px solid #335555;
}

.igz-nav-div {
  width: 1px;
  height: 13px;
  background: #2E5E5E;
  margin: 0 2px;
  flex-shrink: 0;
}

.igz-nav-btn {
  background: transparent;
  border: 0;
  color: #000000;
  font-family: Arial, sans-serif;
  font-size: 12px;
  font-weight: bold;
  padding: 2px 9px;
  height: 21px;
  cursor: pointer;
  white-space: nowrap;
}

.igz-nav-btn:hover { color: #FFFFFF; }
.igz-nav-btn.active { background: #000000; color: #FFFFCC; }

/* Workspace: 1999 Portal layer + floating Zone client windows */
#desktop-area {
  position: relative;
  flex: 1;
  overflow: hidden;
  background: #000000;
}

/* Real 1999 MSN Gaming Zone Portal iframe + exact webvm_portal_ui.py offline fallback */
.zportal-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: #336666;
  display: block;
  touch-action: pan-x pan-y;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.zportal-fallback {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  background: #336666;
  color: #CCFFFF;
  touch-action: pan-x pan-y;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.wp99-root {
  min-height: 100%;
  background: #336666;
  color: #CCFFFF;
  font-family: Arial, sans-serif;
  font-size: 10pt;
}
.wp99-root table { border-collapse: collapse; }
.wp99-root img { border: 0; display: block; }
.wp99-head { width: 608px; max-width: 100%; }
.wp99-head td { padding: 0; vertical-align: top; }
.wp99-msn { width: 140px; }
.wp99-ban { width: 468px; }
.wp99-zone { width: 260px; }
.wp99-sp { width: 198px; }
.wp99-fa { width: 150px; vertical-align: middle !important; }
.wp99-navband { width: 100%; background: #FFCC66; }
.wp99-navtbl { width: 608px; max-width: 100%; height: 18px; }
.wp99-navtbl td { text-align: center; white-space: nowrap; padding: 0 6px; height: 18px; font-weight: bold; }
.wp99-navtbl td.wp99-sep { width: 1px; padding: 0; }
.wp99-navtbl td.wp99-nav a { color: #000000; text-decoration: none; }
.wp99-navtbl td.wp99-nav a:hover { color: #FFFFFF; }
.wp99-navtbl td.wp99-navdown { background: #669999; }
.wp99-navtbl td.wp99-navdown a { color: #FFFFCC; text-decoration: none; }
.wp99-body { width: 608px; max-width: 100%; margin-top: 8px; table-layout: fixed; }
.wp99-sidecol { width: 100px; vertical-align: top; padding: 0; }
.wp99-sidebar { width: 100%; }
.wp99-sidebar td { padding: 2px 8px; font-weight: bold; }
.wp99-sidebar td.side { background: #669999; }
.wp99-sidebar td.side a { color: #000000; text-decoration: none; }
.wp99-sidebar td.side a:hover { color: #CCFFFF; }
.wp99-sidebar td.sidedown { background: #99CCCC; }
.wp99-sidebar td.sidedown a { color: #FFFFCC; text-decoration: none; }
.wp99-content { vertical-align: top; padding: 0 10px 24px 12px; }
.wp99-content h1 { font-size: 18pt; font-weight: normal; color: #FFFFFF; margin: 0 0 8px; }
.wp99-intro { margin: 0 0 12px; line-height: 1.35; color: #CCFFFF; }
.wp99-find { margin: 10px 0 8px; }
.wp99-find input { font: 10pt Arial; color: #000; background: #FFFFEE; border: 1px solid #99CCCC; padding: 2px; width: 180px; }
.wp99-find #wp99-cnt { display: block; color: #99CCCC; margin: 4px 0 8px; }
.wp99-games { width: 100%; table-layout: fixed; }
.wp99-games th { text-align: left; color: #FFFFFF; font-size: 11pt; border-bottom: 1px solid #669999; padding: 4px 0; }
.wp99-games td { padding: 4px 0; border-bottom: 1px solid #477C7C; vertical-align: top; }
.wp99-games .gname { width: 75%; padding-right: 10px; }
.wp99-games .ggenre { width: 25%; color: #99CCCC; }
.wp99-games a { color: #FFFFCC; font-weight: bold; }
.wp99-games a:hover { color: #FFFFFF; }
.wp99-ed { display: block; color: #FFCC66; font-size: 9pt; margin-top: 2px; }
.wp99-ed a { color: #FFCC66; font-weight: normal; }

/* ---- Authentic 1999 IGZ Portal Table Layout (toplevelcommon.css) ---- */
.portal-page {
  display: grid;
  grid-template-columns: 162px 1fr;
  min-height: 100%;
  background: #000000;
}

.portal-sidebar {
  background: #669999;
  color: #000000;
  padding: 8px 7px;
  border-right: 2px solid #335555;
  font-size: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.portal-side-head {
  background: #2E5E5E;
  color: #FFFFCC;
  font-weight: bold;
  font-size: 11px;
  padding: 3px 6px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.portal-side-links {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 2px 4px;
}

.portal-side-link {
  background: transparent;
  border: 0;
  text-align: left;
  padding: 2px 4px;
  font-family: Arial, sans-serif;
  font-size: 12px;
  font-weight: bold;
  color: #000000;
  cursor: pointer;
}

.portal-side-link:hover { color: #CCFFFF; }
.portal-side-link.active { color: #FFFFCC; background: #2E5E5E; }

.portal-main {
  padding: 10px 14px 42px;
  background: #000000;
  color: #CCFFFF;
}

.portal-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid #669999;
}

.portal-search {
  background: #FFFFFF;
  color: #000000;
  border: 1px solid #669999;
  padding: 3px 6px;
  font-size: 12px;
  min-width: 240px;
}

.portal-section-title {
  background: #003333;
  border-top: 1px solid #669999;
  border-bottom: 1px solid #669999;
  color: #FFFFFF;
  font-weight: bold;
  font-size: 13px;
  padding: 4px 8px;
  margin: 12px 0 4px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Authentic 1999 Zone HTML Room Directory Table */
.portal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin-bottom: 8px;
}

.portal-table th {
  text-align: left;
  color: #99CCCC;
  font-size: 11px;
  border-bottom: 1px solid #335555;
  padding: 3px 6px;
  font-weight: bold;
}

.portal-table td {
  padding: 4px 6px;
  border-bottom: 1px solid #162626;
  vertical-align: middle;
}

.portal-table tr:hover td {
  background: #0d1f1f;
}

.portal-room-link {
  color: #FFFFCC;
  font-weight: bold;
  text-decoration: underline;
  background: none;
  border: 0;
  padding: 0;
  font-family: Arial, sans-serif;
  font-size: 12px;
  cursor: pointer;
}

.portal-room-link:hover { color: #FFFFFF; }

.portal-room-link.alt {
  color: #CCFFFF;
  font-weight: normal;
  margin-left: 8px;
}

.portal-tag {
  display: inline-block;
  font-size: 10px;
  padding: 1px 5px;
  border: 1px solid #669999;
  color: #CCFFFF;
  background: #002222;
}
.portal-tag.webgl { border-color: #66cc66; color: #ccffcc; background: #102a10; }
.portal-tag.dplay { border-color: #ccaa44; color: #ffeeaa; background: #2a2008; }

/* ---- Authentic Windows 98 / Zone Window Frame ---- */
.zbtn {
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  padding: 2px 8px;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #404040;
  border-bottom: 1px solid #404040;
  box-shadow: inset -1px -1px 0 #808080;
  cursor: default;
}

.zbtn:active:not(:disabled),
.zbtn.zbtn-kbd-active:not(:disabled) {
  border-top: 1px solid #404040;
  border-left: 1px solid #404040;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: none;
  padding: 3px 7px 1px 9px;
}

.zbtn:disabled {
  color: #808080;
  text-shadow: 1px 1px 0 #FFFFFF;
  cursor: default;
}
.zbtn:focus,
.zbtn:focus-visible {
  outline: 1px dotted #000000;
  outline-offset: -4px;
}
.zbtn-primary { font-weight: bold; }
.zbtn-sm { padding: 1px 6px; font-size: 11px; }
.zbtn-sm:active:not(:disabled),
.zbtn-sm.zbtn-kbd-active:not(:disabled) { padding: 2px 5px 0 7px; }

/* Authentic Zone Teal Flat Dialog Button (Send ZoneMessage / Log On As, signin_dialog.png) */
.zbtn-teal {
  background: #2E5E5E;
  color: #FFFFFF;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: bold;
  min-width: 68px;
  height: 22px;
  padding: 2px 10px;
  border: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #5C9494, inset -1px -1px 0 #1B3B3B;
  cursor: default;
}
.zbtn-teal:hover { background: #3B7676; }
.zbtn-teal:active:not(:disabled),
.zbtn-teal.zbtn-kbd-active:not(:disabled) {
  box-shadow: inset 1px 1px 0 #1B3B3B, inset -1px -1px 0 #5C9494;
  padding: 3px 9px 1px 11px;
}
.zbtn-teal:disabled { background: #778866; color: #FFFFCC; cursor: default; box-shadow: none; }

/* Authentic Launchpad Rounded Teal Pill Button (ch_lp.png) */
/* Authentic Launchpad Real Extracted 80x16 Teal Pill Sprites (lobbyres/2515..2518.png) */
.zbtn-lp-sprite {
  width: 80px;
  height: 16px;
  padding: 0;
  border: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  background-position: 0 0;
  color: transparent;
  font-size: 0;
  cursor: pointer;
  image-rendering: pixelated;
  flex-shrink: 0;
}
.zbtn-lp-sprite.launch { background-image: url("../assets/dll/lobbyres/2515.png"); }
.zbtn-lp-sprite.join { background-image: url("../assets/dll/lobbyres/2516.png"); }
.zbtn-lp-sprite.leave { background-image: url("../assets/dll/lobbyres/2517.png"); }
.zbtn-lp-sprite.settings { background-image: url("../assets/dll/lobbyres/2518.png"); }
.zbtn-lp-sprite:hover { background-position: -80px 0; }
.zbtn-lp-sprite:active { background-position: -160px 0; }
/* disabled = the 4th cell as drawn, with no extra fade */
.zbtn-lp-sprite:disabled { background-position: -240px 0; cursor: default; }

.zbtn-lp-pill {
  background: linear-gradient(180deg, #3f7878 0%, #2b5959 60%, #1e4242 100%);
  color: #FFFFCC;
  font-family: Arial, Tahoma, sans-serif;
  font-size: 12px;
  font-weight: bold;
  min-width: 82px;
  height: 22px;
  padding: 0 14px;
  border: 1px solid #6fa6a6;
  border-radius: 11px;
  cursor: pointer;
}
.zbtn-lp-pill:hover { background: linear-gradient(180deg, #5c9999 0%, #3d7575 100%); color: #FFFFFF; }
.zbtn-lp-pill:disabled { opacity: 0.45; cursor: default; }

/* Authentic Chat Pill Send Button (commonres/1102.png 48x16 4-state sprite) */
.zbtn-send-pill {
  width: 48px;
  height: 16px;
  padding: 0;
  border: 0;
  background: transparent url("../assets/dll/commonres/1102.png") no-repeat 0 0;
  color: transparent;
  font-size: 0;
  cursor: pointer;
  flex-shrink: 0;
}
.zbtn-send-pill:hover { background-position: -48px 0; }
.zbtn-send-pill:active { background-position: -96px 0; }
.zbtn-send-pill:disabled { background-position: -144px 0; cursor: default; }

.zwin {
  position: absolute;
  display: flex;
  flex-direction: column;
  background: var(--w98-face);
  color: #000000;
  padding: 2px;
  border-top: 1px solid #DFDFDF;
  border-left: 1px solid #DFDFDF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080;
  min-width: 220px;
  min-height: 120px;
  overflow: hidden;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
}

/* Classic Win98 16px 3D gray scrollbars with strictly ONE arrow button per end */
.zwin *::-webkit-scrollbar {
  width: 16px;
  height: 16px;
}
.zwin *::-webkit-scrollbar-track {
  background: repeating-conic-gradient(#FFFFFF 0% 25%, #D4D0C8 0% 50%) 0 0 / 2px 2px;
}
.zwin *::-webkit-scrollbar-thumb {
  background: #D4D0C8;
  border-top: 1px solid #DFDFDF;
  border-left: 1px solid #DFDFDF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080;
  min-height: 18px;
}
.zwin *::-webkit-scrollbar-button {
  display: none;
  width: 0;
  height: 0;
}
.zwin *::-webkit-scrollbar-button:vertical:start:decrement,
.zwin *::-webkit-scrollbar-button:vertical:end:increment,
.zwin *::-webkit-scrollbar-button:horizontal:start:decrement,
.zwin *::-webkit-scrollbar-button:horizontal:end:increment {
  display: block;
  background-color: #D4D0C8;
  background-repeat: no-repeat;
  background-position: center;
  height: 16px;
  width: 16px;
  border-top: 1px solid #DFDFDF;
  border-left: 1px solid #DFDFDF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080;
}
.zwin *::-webkit-scrollbar-button:vertical:start:decrement {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='4' shape-rendering='crispEdges'%3E%3Cpath d='M3 0h1v1H2v1H1v1H0v1h7V3H6V2H5V1H4z' fill='%23000'/%3E%3C/svg%3E");
}
.zwin *::-webkit-scrollbar-button:vertical:end:increment {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='4' shape-rendering='crispEdges'%3E%3Cpath d='M0 0h7v1H6v1H5v1H4v1H3V3H2V2H1V1H0z' fill='%23000'/%3E%3C/svg%3E");
}
.zwin *::-webkit-scrollbar-button:horizontal:start:decrement {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='7' shape-rendering='crispEdges'%3E%3Cpath d='M0 3h1V2h1V1h1V0h1v7H3V6H2V5H1V4H0z' fill='%23000'/%3E%3C/svg%3E");
}
.zwin *::-webkit-scrollbar-button:horizontal:end:increment {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='7' shape-rendering='crispEdges'%3E%3Cpath d='M0 0h1v1h1v1h1v1h1v1H3v1H2v1H1v1H0z' fill='%23000'/%3E%3C/svg%3E");
}
.zwin *::-webkit-scrollbar-corner {
  background: #D4D0C8;
}

/* Remove modern browser focus halos inside Win98 Zone windows */
.zwin input:focus,
.zwin textarea:focus,
.zwin select:focus {
  outline: none;
}

.zwin select {
  background: #FFFFFF;
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  border-radius: 0;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  padding: 1px 4px;
  height: 20px;
}

.zwin-titlebar {
  background: linear-gradient(90deg, #808080, #B5B5B5);
  color: #D4D0C8;
  padding: 1px 2px 1px 2px;
  height: 18px;
  margin-bottom: 1px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
  cursor: default;
  flex-shrink: 0;
}

.zwin.active .zwin-titlebar {
  background: linear-gradient(90deg, #000080, #1084D0);
  color: #FFFFFF;
}

/* Authentic Win98 FlashWindow animation when clicking a parent window locked by a modal */
.zwin.zwin-flash-dim .zwin-titlebar,
.zwin.active.zwin-flash-dim .zwin-titlebar {
  background: linear-gradient(90deg, #808080, #B5B5B5);
  color: #D4D0C8;
}

.zwin.zwin-frameless.zwin-flash-dim {
  outline: 2px solid #000080;
  outline-offset: -2px;
  box-shadow: inset 2px 2px 0 #1084D0, inset -2px -2px 0 #000080;
}

.zwin-modal-shield {
  position: absolute;
  inset: 0;
  z-index: 90;
  background: transparent;
  cursor: default;
}

/* Authentic Windows 98 DrawAnimatedRects (IDANI_CAPTION) minimize / restore caption bar animation */
.zwin-anim-caption {
  position: fixed;
  z-index: 99992;
  pointer-events: none;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 1px 4px;
  overflow: hidden;
  white-space: nowrap;
  background: linear-gradient(90deg, #000080, #1084D0);
  color: #FFFFFF;
  font-family: Tahoma, "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  font-weight: bold;
  border: 1px solid #DFDFDF;
  box-shadow: 1px 1px 0 rgba(0, 0, 0, 0.35);
}
.zwin-anim-caption.zwin-anim-go {
  transition: left 170ms linear, top 170ms linear, width 170ms linear, height 170ms linear;
}
.zwin-anim-caption-txt {
  overflow: hidden;
  text-overflow: ellipsis;
}
body.ztheme-dark .zwin-anim-caption {
  background: linear-gradient(90deg, #163664, #2B5E9E);
  color: #F2F5FA;
  border-color: #464B57;
}
@keyframes ztbAlertPulse {
  0%, 100% { background: var(--w98-face); color: #000000; }
  50% { background: #000080; color: #FFFFFF; }
}
.ztb-item.ztb-alert {
  animation: ztbAlertPulse 0.9s steps(2, start) infinite;
}
body.ztheme-dark .ztb-item.ztb-alert {
  animation: none;
  background: #2B5E9E;
  color: #FFFFFF;
}

.zwin-title-left {
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: bold;
  font-size: 11px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* Real extracted 16x16 Win32 Zone icons (CommonRes.dll & zone.exe) */
.zwin-ico-img {
  display: block;
  width: 16px;
  height: 16px;
  object-fit: contain;
  image-rendering: pixelated;
  flex-shrink: 0;
}

.zwin-title-btns {
  display: flex;
  align-items: center;
  gap: 0;
}

.zwin-btn {
  width: 16px;
  height: 14px;
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--w98-face);
  color: #000000;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #DFDFDF, inset -1px -1px 0 #808080;
  cursor: default;
}
.zwin-btn-cls {
  margin-left: 2px;
}
.zwin-btn:active {
  border-top: 1px solid #000000;
  border-left: 1px solid #000000;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #808080;
  padding: 1px 0 0 1px;
}
.zico-svg {
  display: block;
  width: 12px;
  height: 10px;
  pointer-events: none;
}

.zwin-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 0;
  background: #FFFFFF;
}

.zwin-inset {
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #DFDFDF;
  border-bottom: 1px solid #DFDFDF;
}

/* Authentic Win32 Menu Bar inside Zone windows (Room  Options  Zone  Help) */
.zwin-menubar {
  background: var(--w98-face);
  color: #000000;
  border-bottom: 1px solid #808080;
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 1px 4px;
  height: 20px;
  flex-shrink: 0;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
}

.zmenu-item {
  background: transparent;
  border: 1px solid transparent;
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  padding: 0 5px;
  height: 18px;
  line-height: 16px;
  cursor: default;
}
.zmenu-item:hover:not(.open):not(.armed) {
  background: transparent;
  color: #000000;
  border-top-color: #FFFFFF;
  border-left-color: #FFFFFF;
  border-right-color: #808080;
  border-bottom-color: #808080;
}
.zmenu-item.open {
  background: transparent;
  color: #000000;
  border-top-color: #808080;
  border-left-color: #808080;
  border-right-color: #FFFFFF;
  border-bottom-color: #FFFFFF;
  padding: 1px 4px 0 6px;
}
.zmenu-item.armed {
  background: #000080;
  color: #FFFFFF;
  border-color: transparent;
}

/* Authentic Win98 3D-Beveled Dropdown Popup Menu */
.zmenu-popup {
  position: fixed;
  z-index: 99999;
  min-width: 156px;
  background: var(--w98-face);
  color: #000000;
  padding: 2px;
  border-top: 2px solid #FFFFFF;
  border-left: 2px solid #FFFFFF;
  border-right: 2px solid #404040;
  border-bottom: 2px solid #404040;
  box-shadow: 1px 1px 0 #000000;
  display: flex;
  flex-direction: column;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  cursor: default;
  user-select: none;
}

.zmenu-row {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  background: transparent;
  border: 0;
  color: #000000;
  text-align: left;
  padding: 3px 12px 3px 6px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  white-space: nowrap;
  cursor: default;
  outline: none;
}
.zmenu-row.bold {
  font-weight: bold;
}
.zmenu-txt {
  flex: 1;
}
.zmenu-acc {
  margin-left: 18px;
  text-align: right;
  flex-shrink: 0;
}
.zmenu-row:hover:not(:disabled),
.zmenu-row:focus:not(:disabled) {
  /* Windows 98 selection colour */
  background: #000080;
  color: #FFFFFF;
  outline: none;
}
.zmenu-row.disabled, .zmenu-row:disabled {
  color: #808080;
  text-shadow: 1px 1px 0 #FFFFFF;
  cursor: default;
}

.zmenu-chk {
  width: 12px;
  height: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.zmenu-chk svg {
  display: block;
}

.zmenu-sep {
  height: 1px;
  background: #808080;
  border-bottom: 1px solid #FFFFFF;
  margin: 3px 2px;
}

.zwin-toolbar {
  background: var(--w98-face);
  color: #000000;
  border-top: 1px solid #FFFFFF;
  border-bottom: 1px solid #808080;
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 2px 4px;
  height: 24px;
  flex-shrink: 0;
  font-size: 11px;
}

.ztool-sep {
  width: 2px;
  height: 16px;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  margin: 0 3px;
  flex-shrink: 0;
}

.ztool-btn {
  background: transparent;
  border: 1px solid transparent;
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  padding: 1px 6px;
  height: 20px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.ztool-btn:hover {
  border-top-color: #FFFFFF;
  border-left-color: #FFFFFF;
  border-right-color: #808080;
  border-bottom-color: #808080;
}
.ztool-btn.active {
  border-top-color: #808080;
  border-left-color: #808080;
  border-right-color: #FFFFFF;
  border-bottom-color: #FFFFFF;
  background: repeating-conic-gradient(#FFFFFF 0% 25%, #D4D0C8 0% 50%) 0 0 / 2px 2px;
  font-weight: normal;
}

/* Lobby toolbar (ZoneClient FUN_600c28d4, LobbyRes toolbar 1165): buttons are the 16px image
 * plus 7 = 23px tall, drawn in the dialog font, and sink while the mouse button is down. */
.zwin-toolbar.zlobby-toolbar {
  height: 27px;
  padding: 1px 4px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
}
.zlobby-toolbar .ztool-btn {
  height: 23px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
}
.zlobby-toolbar .ztool-btn:active {
  border-top-color: #808080;
  border-left-color: #808080;
  border-right-color: #FFFFFF;
  border-bottom-color: #FFFFFF;
  padding: 2px 5px 0 7px;
}
body.ztheme-dark .zlobby-toolbar .ztool-btn:active {
  border-top-color: var(--dm-dk);
  border-left-color: var(--dm-dk);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
}

/* Genuine 1999 LobbyRes.dll BMP 1165 (64x16 = 4x 16x16 icons: Quick Host, Quick Join, Table View, List View) */
.ztool-ico {
  display: inline-block;
  width: 16px;
  height: 16px;
  background-image: url("../assets/dll/lobbyres/1165.png");
  background-repeat: no-repeat;
  background-size: 64px 16px;
  image-rendering: pixelated;
  flex-shrink: 0;
}
.ztool-ico.host  { background-position: 0 0; }
.ztool-ico.join  { background-position: -16px 0; }
.ztool-ico.table { background-position: -32px 0; }
.ztool-ico.list  { background-position: -48px 0; }

.zwin-statusbar {
  background: var(--w98-face);
  color: #000000;
  border-top: 1px solid #808080;
  box-shadow: inset 0 1px 0 #FFFFFF;
  padding: 2px 6px;
  height: 20px;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  position: relative;
}
.zwin-statusbar.zf-statusbar {
  padding: 1px 16px 1px 2px;
  height: 20px;
  border-top: none;
  box-shadow: none;
}
.zwin-sb-well {
  flex: 1;
  min-width: 0;
  height: 100%;
  display: flex;
  align-items: center;
  padding: 0 4px;
  background: var(--w98-face);
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: none;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.zwin-statusbar.has-grip {
  padding-right: 16px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' shape-rendering='crispEdges'%3E%3Cpath d='M11 3L3 11M11 7L7 11M11 10L10 11' stroke='%23808080'/%3E%3Cpath d='M11 4L4 11M11 8L8 11' stroke='%23fff'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 2px bottom 2px;
}

/* Iconic 60px Black Top Banner inside Classic Lobby, Matchmaking Lobby, and Chat */
.zroom-banner {
  background: #000000;
  height: 60px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #000000;
  flex-shrink: 0;
  overflow: hidden;
}

.zroom-banner-logo {
  height: 60px;
  width: 120px;
  flex-shrink: 0;
  image-rendering: pixelated;
  display: block;
}
.zroom-banner-logo.classic {
  width: 84px;
}

.zroom-banner-ad {
  height: 60px;
  width: 468px;
  max-width: calc(100% - 120px);
  object-fit: cover;
  object-position: right center;
  image-rendering: pixelated;
  display: block;
  flex-shrink: 1;
  min-width: 0;
}

/* Authentic Windows 98 Taskbar + System Tray */
#taskbar {
  height: 28px;
  background: var(--w98-face);
  border-top: 2px solid #FFFFFF;
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 2px 3px;
  flex-shrink: 0;
  overflow: hidden;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
}

.ztb-windows {
  flex: 1 1 0;
  display: flex;
  align-items: center;
  gap: 3px;
  overflow: hidden;
  min-width: 0;
}

.ztb-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  height: 22px;
  padding: 0 6px 0 4px;
  flex: 0 1 168px;
  min-width: 56px;
  max-width: 168px;
  overflow: hidden;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #404040;
  border-bottom: 1px solid #404040;
  box-shadow: inset -1px -1px 0 #808080;
  cursor: pointer;
}

.ztb-lbl {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

.ztb-item.active {
  font-weight: bold;
  background: repeating-conic-gradient(#FFFFFF 0% 25%, #D4D0C8 0% 50%) 0 0 / 2px 2px;
  border-top: 1px solid #404040;
  border-left: 1px solid #404040;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #808080;
}

.ztb-tray {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 22px;
  padding: 0 5px;
  background: var(--w98-face);
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  color: #000000;
  flex-shrink: 0;
}

.ztb-tray-ico {
  background: transparent;
  border: 0;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  cursor: pointer;
}

.zwin.zwin-frameless {
  min-height: 0;
  border-top: 1px solid #DFDFDF;
  border-left: 1px solid #DFDFDF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080;
}

/* ============================================================================
 * AUTHENTIC 1999 ZPASSPC "Sign In" DIALOG (ZPASSPC.DLL DLG 500 + LOGO 414x208)
 * Exact 1:1 layout from ror-public-fresh-signin-20261106.png & DLG 500 coords
 * ============================================================================ */
.zzpa-dlg {
  position: relative;
  width: 414px;
  height: 208px;
  flex-shrink: 0;
  background: #2E5E5E url("../assets/dll/zpasspc/logo.png") no-repeat 0 0;
  background-size: 414px 208px;
  image-rendering: pixelated;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  color: #FFFFFF;
  overflow: hidden;
  user-select: none;
}

.zzpa-lbl {
  position: absolute;
  left: 175px;
  width: 68px;
  height: 18px;
  line-height: 18px;
  color: #FFFFFF;
  font-size: 11px;
  font-weight: normal;
  white-space: nowrap;
}

.zzpa-lbl-user { top: 94px; }
.zzpa-lbl-pass { top: 120px; }

.zzpa-in {
  position: absolute;
  left: 246px;
  width: 155px;
  height: 21px;
  padding: 1px 4px;
  background: #FFFFFF;
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  border-radius: 0;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}

.zzpa-in-user { top: 92px; }
.zzpa-in-pass { top: 118px; }

.zzpa-chk {
  position: absolute;
  left: 246px;
  top: 145px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #FFFFFF;
  cursor: pointer;
  white-space: nowrap;
}

.zzpa-chk input[type="checkbox"] {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
  width: 13px;
  height: 13px;
  background: #FFFFFF;
  border-radius: 0;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}

.zzpa-chk input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 2px;
  top: 1px;
  width: 7px;
  height: 7px;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='7' shape-rendering='crispEdges'%3E%3Cpath d='M0 3h1v1h1v1h1V4h1V3h1V2h1V1h1v2H6v1H5v1H4v1H3v1H2V6H1V5H0z' fill='%23000'/%3E%3C/svg%3E") no-repeat center;
}

.zzpa-btn {
  position: absolute;
  top: 175px;
  width: 75px;
  height: 22px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
}

.zzpa-ok {
  left: 84px;
  box-shadow: inset -1px -1px 0 #808080, 0 0 0 1px #000000;
}
.zzpa-signup { left: 165px; }
.zzpa-cancel { left: 246px; }
.zzpa-help { left: 327px; }

/* ============================================================================
 * AUTHENTIC 1999 "Connecting to the server ..." SPLASH (CommonRes.dll DLG 1148)
 * Borderless Win98 dialog matching rg-ban-fresh-login-win95.png
 * ============================================================================ */
.zsplash-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 11px 11px 9px 11px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}

.zsplash-img-frame {
  position: relative;
  width: 320px;
  height: 200px;
  background: #000000;
  line-height: 0;
  align-self: center;
  flex-shrink: 0;
}

.zsplash-img {
  display: block;
  width: 320px;
  height: 200px;
  image-rendering: pixelated;
}

.zsplash-copy {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 5px;
  text-align: center;
  color: #C4C4C4;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 10px;
  line-height: 12px;
  letter-spacing: 0.1px;
  pointer-events: none;
}

.zsplash-status {
  color: #000000;
  font-size: 11px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 0 1px;
}

.zsplash-btns {
  display: flex;
  justify-content: flex-end;
}

.zsplash-cancel {
  width: 75px;
  height: 23px;
}

/* ============================================================================
 * AUTHENTIC 1999 WIN98 DIALOGS (zone.exe DLG 273 Add Person / Zone Profile)
 * ============================================================================ */
/* Sysop prompt (ZoneClient FUN_600ec3fd / FUN_600ec8c4): one control filling the client area, Tahoma 10 */
.zsp-dlg {
  flex: 1;
  display: flex;
  background: var(--w98-face);
  padding: 0;
  margin: 0;
}
.zsp-in {
  flex: 1;
  width: 100%;
  box-sizing: border-box;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 13px;
  resize: none;
}
/* the reason drop-down keeps a combo box's own height at the top of the window; only the message edit fills it */
input.zsp-in {
  align-self: flex-start;
  height: 23px;
}

.zadd-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 10px 10px 0 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
}

.zadd-hdr {
  font-size: 12px;
  font-weight: bold;
  color: #000000;
}

.zadd-row {
  display: flex;
  align-items: center;
  gap: 6px;
}
.zadd-row label { flex-shrink: 0; }
.zadd-row input {
  flex: 1;
  height: 20px;
  padding: 1px 4px;
  background: #FFFFFF;
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}

.zadd-btns {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  padding-bottom: 8px;
}
.zadd-btn { min-width: 70px; height: 22px; }
.zadd-status { margin: auto -10px 0 -10px; }

/* ============================================================================
 * AUTHENTIC ZONEFRIENDS (matches zonefriends.png pixel-for-pixel)
 * ============================================================================ */
.zf-shell {
  display: flex;
  flex-direction: column;
  flex: 1;
  background: var(--zf-gold);
  overflow: hidden;
}

.zf-header {
  position: relative;
  height: 46px;
  background: var(--zf-teal);
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  padding: 4px 6px 0 82px;
  flex-shrink: 0;
  user-select: none;
}

.zf-swirl {
  position: absolute;
  left: 0;
  top: 0;
  width: 80px;
  height: 32px;
  background: transparent url("../assets/dll/zoneexe/270.png") no-repeat left top;
  image-rendering: pixelated;
}

.zf-status-img {
  display: block;
  width: 88px;
  height: 14px;
  margin-top: 1px;
  image-rendering: pixelated;
}

.zf-tab-row {
  position: absolute;
  left: 6px;
  bottom: 0;
  display: flex;
  align-items: flex-end;
  line-height: 0;
}

.zf-people-tab-img {
  display: block;
  width: 52px;
  height: 14px;
  image-rendering: pixelated;
}

.zf-tree-area {
  flex: 1;
  background: var(--zf-gold);
  color: #000000;
  overflow-y: auto;
  padding: 2px 4px;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
}

.zf-group-row {
  display: flex;
  align-items: center;
  gap: 3px;
  margin-bottom: 1px;
  cursor: pointer;
}

/* Real zone.exe 267.png (70x11 = 7x 10x11 buddy tree icons, matching zonefriends.png) */
.zf-ico267 {
  display: inline-block;
  width: 10px;
  height: 11px;
  background: transparent url("../assets/dll/zoneexe/267.png") no-repeat 0 0;
  image-rendering: pixelated;
  flex-shrink: 0;
}
.zf-ico267.grp { background-position: 0 0; }
/* Tree-view image indices from zone.exe FUN_0100f0c8. */
.zf-ico267.p2 { background-position: -10px 0; } /* Online */
.zf-ico267.p3 { background-position: -40px 0; } /* Offline */
.zf-ico267.p4 { background-position: -30px 0; } /* DND */
.zf-ico267.p5 { background-position: -20px 0; } /* Away */
.zf-ico267.p0,
.zf-ico267.ignored { background-position: -60px 0; }

.zf-group-hdr {
  display: inline-block;
  font-weight: bold;
  color: #000000;
  padding: 1px 3px;
}

.zf-group-hdr.sel {
  background: #0A246A;
  color: #FFFFFF;
  outline: 1px dotted #FFFF00;
}

.zf-buddy-row {
  display: flex;
  align-items: center;
  padding: 1px 4px 1px 18px;
  gap: 5px;
  line-height: 15px;
  cursor: pointer;
  user-select: none;
}

.zf-buddy-row:hover {
  background: rgba(10, 36, 106, 0.10);
}

.zf-buddy-row.sel .zf-buddy-txt {
  background: #0A246A;
  color: #FFFFFF;
  padding: 0 3px;
  outline: 1px dotted #FFFF00;
}

.zf-buddy-row.online .zf-buddy-txt {
  font-weight: bold;
  color: #000000;
}

.zf-buddy-row.offline .zf-buddy-txt {
  font-weight: normal;
  color: #000000;
}

.zf-buddy-row.sel.online .zf-buddy-txt,
.zf-buddy-row.sel.offline .zf-buddy-txt {
  color: #FFFFFF;
}

/* Real 64x16 / 74x16 zone.exe bitmap buttons for Send ZoneMessage, ZoneMessage & Chat Invitation */
.zbtn-zm {
  width: 64px;
  height: 16px;
  padding: 0;
  border: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  background-position: 0 0;
  color: transparent;
  font-size: 0;
  /* zone.exe CRolloverButton registers no cursor of its own: the arrow stays */
  cursor: default;
  image-rendering: pixelated;
  flex-shrink: 0;
}
/* a focused rollover button is framed in black (FUN_0100a462: FrameRect while it has the focus) */
.zbtn-zm:focus {
  outline: 1px solid #000000;
  outline-offset: -1px;
}
.zbtn-zm.chat { background-image: url("../assets/dll/zoneexe/248.png"); }
.zbtn-zm.chat:hover:not(:disabled) { background-image: url("../assets/dll/zoneexe/247.png"); }
.zbtn-zm.chat:active:not(:disabled) { background-image: url("../assets/dll/zoneexe/245.png"); }
.zbtn-zm.chat:disabled { background-image: url("../assets/dll/zoneexe/246.png"); cursor: default; }
.zbtn-zm.send { background-image: url("../assets/dll/zoneexe/235.png"); }
.zbtn-zm.send:hover:not(:disabled) { background-image: url("../assets/dll/zoneexe/236.png"); }
.zbtn-zm.send:active:not(:disabled) { background-image: url("../assets/dll/zoneexe/237.png"); }
.zbtn-zm.send:disabled { background-image: url("../assets/dll/zoneexe/234.png"); cursor: default; }
.zbtn-zm.close { background-image: url("../assets/dll/zoneexe/224.png"); }
.zbtn-zm.close:hover:not(:disabled) { background-image: url("../assets/dll/zoneexe/218.png"); }
.zbtn-zm.close:active:not(:disabled) { background-image: url("../assets/dll/zoneexe/219.png"); }
.zbtn-zm.close:disabled { background-image: url("../assets/dll/zoneexe/250.png"); cursor: default; }
.zbtn-zm.accept { background-image: url("../assets/dll/zoneexe/244.png"); }
.zbtn-zm.accept:hover:not(:disabled) { background-image: url("../assets/dll/zoneexe/243.png"); }
.zbtn-zm.accept:active:not(:disabled) { background-image: url("../assets/dll/zoneexe/260.png"); }
.zbtn-zm.accept:disabled { background-image: url("../assets/dll/zoneexe/241.png"); cursor: default; }
.zbtn-zm.decline { background-image: url("../assets/dll/zoneexe/255.png"); }
.zbtn-zm.decline:hover:not(:disabled) { background-image: url("../assets/dll/zoneexe/254.png"); }
.zbtn-zm.decline:active:not(:disabled) { background-image: url("../assets/dll/zoneexe/265.png"); }
.zbtn-zm.decline:disabled { background-image: url("../assets/dll/zoneexe/253.png"); cursor: default; }
.zbtn-zm.reply { background-image: url("../assets/dll/zoneexe/221.png"); }
.zbtn-zm.reply:hover:not(:disabled) { background-image: url("../assets/dll/zoneexe/222.png"); }
.zbtn-zm.reply:active:not(:disabled) { background-image: url("../assets/dll/zoneexe/223.png"); }
.zbtn-zm.reply:disabled { background-image: url("../assets/dll/zoneexe/220.png"); cursor: default; }
.zbtn-zm.addfriend {
  width: 74px;
  background-image: url("../assets/dll/zoneexe/293.png");
}
.zbtn-zm.addfriend:hover:not(:disabled) { background-image: url("../assets/dll/zoneexe/294.png"); }
.zbtn-zm.addfriend:active:not(:disabled) { background-image: url("../assets/dll/zoneexe/295.png"); }
.zbtn-zm.addfriend:disabled { opacity: 0.55; cursor: default; }

.zf-controls-strip {
  background: #F0C05A;
  border-top: 1px solid #C89630;
  padding: 4px 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.zf-add-bar {
  display: flex;
  gap: 4px;
}

.zf-add-bar input {
  flex: 1;
  padding: 2px 4px;
  font-size: 11px;
  border: 1px solid #333;
  background: #FFFFFF;
}

/* ============================================================================
 * AUTHENTIC 2-TONE CURVED ZONE DIALOG (Send ZoneMessage, ZoneMessage, Chat Invite)
 * Exact 352x176 pixel bitmap zoneexe/217.png with absolute coords from zone.exe
 * ============================================================================ */
.zcurve-dlg {
  position: relative;
  flex: 1;
  width: 352px;
  height: 176px;
  background:
    url("../assets/dll/zoneexe/217.png") no-repeat left top,
    var(--zf-gold);
  color: #000000;
  border: 0;
  padding: 0;
  overflow: hidden;
  image-rendering: pixelated;
  /* zone.exe creates two fonts for these windows: Arial -11 regular (labels, message text, message and
   * reply boxes) and Verdana -11 regular, Arial when Verdana is missing (the sender's name, the Member ID box) */
  font-family: Arial, sans-serif;
  font-size: 11px;
}

.zcurve-lbl {
  position: absolute;
  height: 13px;
  line-height: 13px;
  font-size: 11px;
  color: #000000;
  font-weight: normal;
  white-space: nowrap;
  user-select: none;
}

.zcurve-teal-lbl {
  position: absolute;
  height: 13px;
  line-height: 13px;
  font-size: 11px;
  color: #FFFFFF;
  font-weight: normal;
  white-space: nowrap;
  user-select: none;
}

.zcurve-teal-who {
  position: absolute;
  height: 14px;
  line-height: 13px;
  font-family: Verdana, Arial, sans-serif;
  font-size: 11px;
  color: #FFFFFF;
  font-weight: normal;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* the original's name control is plain text with a right-click menu: no hover styling */
.zcurve-teal-who:hover {
  text-decoration: none;
  color: #FFFFFF;
}

.zcurve-in,
.zcurve-ta {
  position: absolute;
  box-sizing: border-box;
  background: #FFFFFF;
  color: #000000;
  /* zone.exe creates these EDITs with no border and paints a 1px black FrameRect in the ring just outside
   * each one (WM_PAINT of the three windows), so the whole box stays white */
  border: 0;
  border-radius: 0;
  box-shadow: 0 0 0 1px #000000;
  padding: 1px 3px;
  font-family: Arial, sans-serif;
  font-size: 11px;
  outline: none;
}
.zcurve-in {
  font-family: Verdana, Arial, sans-serif;
}
.zcurve-ta {
  resize: none;
  line-height: 1.25;
  overflow-y: auto;
}

.zcurve-msg-gold {
  position: absolute;
  box-sizing: border-box;
  background: transparent;
  color: #000000;
  border: 0;
  padding: 0;
  font-family: Arial, sans-serif;
  font-size: 11px;
  line-height: 1.25;
  overflow-y: auto;
  white-space: pre-wrap;
  word-break: break-word;
  user-select: text;
}

.zcurve-btn {
  position: absolute;
}

/* ============================================================================
 * AUTHENTIC WINDOWS 2000 "LOCAL AREA CONNECTION STATUS" DIALOG (netshell.dll)
 * ============================================================================ */
.zw2k-net-dlg {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  padding: 8px 8px 8px;
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
}
.zw2k-tabs {
  display: flex;
  align-items: flex-end;
  padding-left: 2px;
  margin-bottom: -1px;
  z-index: 3;
  flex-shrink: 0;
}
.zw2k-tab {
  position: relative;
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  margin-top: 2px;
  padding: 2px 10px 3px;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #404040;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset -1px 0 0 #808080;
  border-radius: 2px 2px 0 0;
  cursor: pointer;
}
.zw2k-tab.active {
  margin-top: 0;
  padding: 3px 11px 5px;
  border-bottom-color: var(--w98-face);
  z-index: 4;
  cursor: default;
}
.zw2k-tab:focus-visible {
  outline: 1px dotted #000000;
  outline-offset: -3px;
}
.zw2k-tab-pane {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-height: 0;
}
.zw2k-tab-pane[hidden] {
  display: none;
}
.zw2k-tab-body {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 9px 10px 8px;
  background: var(--w98-face);
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #404040;
  border-bottom: 1px solid #404040;
  box-shadow: inset -1px -1px 0 #808080;
}
.zprefs-tab-body {
  gap: 5px;
  padding: 7px 9px 7px;
}
.zprefs-tab-body .zwin-grp {
  padding: 6px 9px 7px;
  gap: 4px;
}
.zw2k-grp {
  margin: 0;
  padding: 6px 10px 8px;
}
.zw2k-kv {
  display: flex;
  justify-content: space-between;
  padding: 2px 0;
  line-height: 15px;
}
.zw2k-act-grid {
  display: grid;
  grid-template-columns: 1fr 56px 1fr;
  row-gap: 4px;
  align-items: center;
}
.zw2k-act-hdr {
  font-weight: normal;
  color: #000000;
}
.zw2k-act-hdr.right,
.zw2k-act-val.right {
  text-align: right;
}
.zw2k-act-lbl {
  text-align: center;
  color: #000000;
}
.zw2k-act-ico-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 28px;
}
.zw2k-act-ico {
  display: block;
  width: 32px;
  height: 32px;
  background: transparent url("../assets/win98/net_off.png") no-repeat center / 32px 32px;
  image-rendering: pixelated;
}
.zw2k-act-ico.idle { background-image: url("../assets/win98/net_idle.png"); }
.zw2k-act-ico.tx { background-image: url("../assets/win98/net_tx.png"); }
.zw2k-act-ico.rx { background-image: url("../assets/win98/net_rx.png"); }
.zw2k-act-ico.both { background-image: url("../assets/win98/net_both.png"); }
.zw2k-act-ico.off { background-image: url("../assets/win98/net_off.png"); }
.zw2k-sub-meta {
  margin-top: 6px;
  padding-top: 4px;
  border-top: 1px solid #808080;
  font-size: 10px;
  color: #333333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zw2k-mid-btns {
  display: flex;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 2px;
}
.zw2k-foot-btns {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  margin-top: 8px;
}
.zw2k-btn {
  min-width: 75px;
  height: 23px;
}
.zw2k-props-dlg {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 10px 12px 10px;
  gap: 4px;
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
}
.zw2k-props-list {
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  padding: 4px 6px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-height: 92px;
}
.zw2k-props-row {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zw2k-props-desc {
  margin-top: 4px;
  color: #202020;
  line-height: 1.35;
}

/* ============================================================================
 * AUTHENTIC WINDOWS 98 / 2000 TRAY VOLUME POPUP & VOLUME CONTROL (sndvol32.exe)
 * ============================================================================ */
.zwvol-tray-pop {
  position: fixed;
  z-index: 9998;
  width: 82px;
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  padding: 6px 8px 8px;
  border-top: 1px solid #DFDFDF;
  border-left: 1px solid #DFDFDF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080, 1px 1px 0 rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  user-select: none;
}
.zwvol-tray-hdr {
  font-size: 11px;
  color: #000000;
  text-align: center;
}
.zwvol-tray-track,
.zwvol-fader-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  height: 76px;
}
.zwvol-ramp,
.zwvol-ticks {
  flex-shrink: 0;
  display: block;
}
.zwvol-vslider-wrap {
  width: 24px;
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.zwvol-vslider {
  -webkit-appearance: none;
  appearance: none;
  writing-mode: vertical-lr;
  direction: rtl;
  width: 22px;
  height: 72px;
  margin: 0;
  padding: 0;
  background: transparent;
  cursor: default;
}
.zwvol-vslider::-webkit-slider-runnable-track {
  width: 4px;
  height: 72px;
  background: var(--w98-face);
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}
.zwvol-vslider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 10px;
  margin-left: -9px;
  background: var(--w98-face);
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #DFDFDF, inset -1px -1px 0 #808080;
}
.zwvol-tray-mute {
  width: 100%;
  justify-content: center;
  margin-top: 2px;
}

.zwvol-mixer-dlg {
  display: flex;
  flex-direction: column;
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zwvol-strips {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  flex: 1;
  padding: 6px 4px 6px;
}
.zwvol-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 4px 8px 6px;
  border-right: 1px solid #808080;
  box-shadow: inset -1px 0 0 #FFFFFF;
  gap: 5px;
}
.zwvol-col:last-child {
  border-right: none;
  box-shadow: none;
}
.zwvol-col-title {
  font-size: 11px;
  font-weight: bold;
  text-align: center;
  white-space: nowrap;
  margin-bottom: 2px;
}
.zwvol-bal-lbl,
.zwvol-vol-lbl {
  font-size: 11px;
  text-align: center;
}
.zwvol-bal-row {
  display: flex;
  align-items: center;
  gap: 3px;
  width: 100%;
  justify-content: center;
}
.zwvol-bal-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 58px;
  height: 16px;
  margin: 0;
  background: transparent;
}
.zwvol-bal-slider::-webkit-slider-runnable-track {
  height: 4px;
  background: var(--w98-face);
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}
.zwvol-bal-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 9px;
  height: 15px;
  margin-top: -6px;
  background: var(--w98-face);
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #DFDFDF, inset -1px -1px 0 #808080;
}
.zwvol-col-mute {
  margin-top: auto;
  padding-top: 4px;
  white-space: nowrap;
}
.zwvol-adv-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px;
  border-top: 1px solid #808080;
  box-shadow: inset 0 1px 0 #FFFFFF;
  font-size: 11px;
}
.zwvol-sb {
  padding: 1px 2px;
  height: 20px;
  gap: 3px;
  border-top: none;
  box-shadow: none;
}
.zwvol-sb-pct {
  flex: 0 0 92px;
  justify-content: center;
}

.zsignin-err {
  color: #990000;
  font-weight: bold;
  font-size: 11px;
  min-height: 14px;
}

/* ============================================================================
 * AUTHENTIC GENRE-0 CLASSIC LOBBY (backgammon_lobby.png / checkers_classic_room.png)
 * Burgundy #330000 floor + 162x144 graphical wooden tables + Black right roster + White chat
 * ============================================================================ */
.clob-shell {
  display: flex;
  flex-direction: column;
  flex: 1;
  background: #000000;
  overflow: hidden;
}

.clob-middle {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 4px 148px;
  overflow: hidden;
  background: var(--w98-face);
}

.clob-floor {
  background: var(--clob-burgundy);
  overflow-y: scroll;
  overflow-x: hidden;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 162px);
  justify-content: start;
  gap: 0;
  align-content: start;
}

/* Real 162x144 wooden table cell from zroom2.zrs / zroom4.zrs */
.clob-tbl-sprite {
  position: relative;
  width: 162px;
  height: 144px;
  background-color: var(--clob-burgundy);
  background-repeat: no-repeat;
  background-position: 0 0;
  user-select: none;
  flex-shrink: 0;
}

.clob-tbl-num {
  position: absolute;
  color: #FFCC66;
  font-family: Arial, sans-serif;
  font-size: 12px;
  font-weight: bold;
  text-align: center;
  line-height: 14px;
  pointer-events: none;
}

.clob-tbl-board {
  position: absolute;
  image-rendering: pixelated;
  pointer-events: none;
}

.clob-chair-hit {
  position: absolute;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
}
.clob-chair-hit:hover {
  filter: brightness(1.22) drop-shadow(0 0 2px #FFFF66);
}
.clob-chair-hit img {
  display: block;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}

.clob-chair-label {
  position: absolute;
  color: #FFFFFF;
  font-family: Arial, sans-serif;
  font-size: 11px;
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 1px 1px 0 #000000;
  pointer-events: none;
}
.clob-chair-label.me { color: #FFFF66; }
.clob-chair-label.bot { color: #99EEFF; font-style: italic; }

.clob-start-hit {
  position: absolute;
  left: 56px;
  top: 76px;
  width: 50px;
  height: 32px;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
}

.clob-kibitz-tag {
  position: absolute;
  right: 4px;
  top: 2px;
  background: #660000;
  color: #FFFF99;
  border: 1px solid #CC9933;
  font-size: 9px;
  padding: 0 3px;
  cursor: default;
}
.clob-kibitz-tag.has-watchers {
  background: #802200;
  color: #FFFFFF;
  border-color: #FFCC44;
  font-weight: bold;
}

.clob-rated-row {
  color: #99EEEE;
  font-size: 10px;
  font-weight: bold;
}
.clob-bots-row {
  color: #AADDFF;
  font-size: 10px;
  font-weight: bold;
}

/* Classic Lobby right sidebar: maroon stats header + black roster */
.clob-sidebar {
  display: flex;
  flex-direction: column;
  background: #000000;
  border-left: 2px solid #808080;
  overflow: hidden;
}

.clob-stats-box {
  background: var(--clob-maroon);
  color: #FFCC66;
  font-size: 11px;
  font-weight: bold;
  padding: 3px 6px;
  line-height: 1.35;
  border-bottom: 1px solid #000000;
}

.clob-net-row {
  display: flex;
  align-items: center;
  gap: 5px;
}

.clob-net-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #00EE00;
  border: 1px solid #004400;
}
.clob-net-dot.off {
  background: #888888;
  border-color: #333333;
}

.clob-roster-head {
  background: #000000;
  color: #FFCC66;
  font-size: 11px;
  font-weight: bold;
  padding: 2px 4px 2px;
  display: flex;
  justify-content: space-between;
}

.clob-roster-list {
  flex: 1;
  background: #000000;
  color: #FFFFFF;
  overflow-y: auto;
  padding: 2px 3px;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
}

.clob-sidebar:not(.zc-sidebar):not(.zchat-sidebar) .clob-roster-list {
  overflow-y: scroll;
}

.clob-roster-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1px 2px;
  gap: 0;
  line-height: 15px;
}

.clob-sidebar:not(.zc-sidebar) .clob-roster-row {
  padding: 1px 2px 1px 10px;
}

.clob-roster-row a {
  color: #FFFFFF;
  font-weight: bold;
  text-decoration: none;
}
.clob-roster-row a:hover { color: #FFFF66; text-decoration: underline; }
.clob-roster-row a.me { color: #FFFFFF; }
.clob-roster-row a.bot { color: #99EEFF; font-style: italic; }
.clob-bot-tag {
  color: #002233;
  background: #88DDFF;
  border: 1px solid #3388AA;
  font-size: 9px;
  font-weight: bold;
  line-height: 11px;
  padding: 0 2px;
  letter-spacing: 0.3px;
}

/* Authentic 1999 Chat & Theater sidebar: normal weight ZoneNames + self spacing (chat_multiuser.png / theater.png) */
.zchat-main-left {
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
  overflow: hidden;
}
.zchat-sidebar .clob-roster-row {
  padding: 1px 2px 1px 4px;
}
.zchat-sidebar .clob-roster-row a {
  font-weight: normal;
}
.zchat-roster-row.zchat-roster-me {
  margin-top: 10px;
  margin-bottom: 14px;
}

/* Bottom pure white chat pane matching ch_lobby.png / backgammon_lobby.png / chat_multiuser.png */
.zroom-chat-pane {
  height: 118px;
  background: #FFFFFF;
  color: #000000;
  border-top: 2px solid #808080;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.zchat-log {
  flex: 1;
  background: #FFFFFF;
  color: #000000;
  overflow-y: auto;
  padding: 3px 6px;
  font-family: Arial, Tahoma, sans-serif;
  font-size: 12px;
  line-height: 1.35;
  border: 0;
}

.zchat-line-sys { color: #000000; font-weight: bold; }
.zchat-line-who { font-weight: bold; color: #000000; }
.zchat-line-sysop { font-weight: bold; }
.zchat-ts {
  display: none;
  color: #555555;
  font-size: 10px;
  font-weight: normal;
  font-family: "Courier New", monospace;
}
.zchat-log.zchat-show-ts .zchat-ts {
  display: inline;
}
.zchat-link {
  color: #0000CC;
  text-decoration: underline;
  cursor: pointer;
}
.zchat-link:hover {
  color: #CC0000;
}
.zcurve-msg-gold .zchat-link {
  color: #000080;
}
.zchat-form {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 2px 4px;
  background: #FFFFFF;
  border-top: 1px solid #808080;
}

.zchat-form input {
  flex: 1;
  border: 0;
  outline: none;
  padding: 2px 3px;
  font-family: Arial, Tahoma, sans-serif;
  font-size: 12px;
  color: #000000;
  background: #FFFFFF;
}
.zchat-form.classic input::placeholder {
  color: #000000;
  font-weight: bold;
}
/* Lobby client chat control (ZoneClient FUN_600d8b43 / FUN_600d99d2): a 1px black line under the
 * history, then a 30px row holding the multi-line send box and the Send pill, which sits right
 * after the box, centred in the row, 2px from the right edge. Arial 10 pt = 13px. */
.zchat-form.zchat-form-lobby {
  height: 31px;
  box-sizing: border-box;
  flex-shrink: 0;
  gap: 0;
  padding: 0 2px 0 0;
  border-top: 1px solid #000000;
}
.zchat-form-lobby .zchat-input {
  flex: 1;
  min-width: 0;
  height: 30px;
  box-sizing: border-box;
  margin: 0;
  border: 0;
  outline: none;
  resize: none;
  overflow: hidden;
  padding: 1px 3px 0 3px;
  font-family: Arial, Tahoma, sans-serif;
  font-size: 13px;
  line-height: 1.15;
  color: #000000;
  background: #FFFFFF;
}

/* ============================================================================
 * AUTHENTIC ZONECLIENT MATCHMAKING LOBBY (ch_lobby.png + LobbyRes.dll CONFIG 1091)
 * Left = [150x150 boomerang grid | 4px Win98 h-splitter | white chat]
 * 4px Win98 v-splitter | Right = 134px full-height black Latency/Name sidebar
 * ============================================================================ */
.zclient-body {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 4px 138px;
  overflow: hidden;
  background: var(--w98-face);
}

.zclient-left {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
  background: var(--w98-face);
}

.zwin-vsplit {
  width: 4px;
  background: var(--w98-face);
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #808080;
  cursor: ew-resize;
  user-select: none;
  flex-shrink: 0;
}
.zwin-vsplit:hover,
.zwin-vsplit.dragging {
  background: #C0BCB0;
}

.zwin-hsplit {
  height: 4px;
  background: var(--w98-face);
  border-top: 1px solid #FFFFFF;
  border-bottom: 1px solid #808080;
  cursor: ns-resize;
  user-select: none;
  flex-shrink: 0;
}
.zwin-hsplit:hover,
.zwin-hsplit.dragging {
  background: #C0BCB0;
}

.zclient-left .zroom-chat-pane {
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}

.clob-sidebar.zc-sidebar {
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}

.zclient-floor {
  flex: 1;
  background: #000000 url("../assets/dll/lobbyres/idb_lobby.png") no-repeat left top;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  overflow-y: scroll;
  overflow-x: hidden;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, 150px);
  justify-content: start;
  gap: 0;
  align-content: start;
}

/* Exact CONFIG 1091 Table_Width=150 x Table_Height=150 cell wrapping 140x133 boomerang sprite */
.zc-slot-cell {
  position: relative;
  width: 150px;
  height: 150px;
  flex-shrink: 0;
}

/* Authentic 1999 ZoneClient List View (listview.png: pure white + #FFFFCC alternating zebra rows) */
.zclient-list-floor {
  flex: 1;
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  overflow-y: scroll;
  padding: 0;
}

.zc-list-tbl {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 12px;
  color: #000000;
  background: #FFFFFF;
}
.zc-list-tbl thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  text-align: left;
  font-size: 11px;
  font-weight: normal;
  background: var(--w98-face);
  color: #000000;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #808080;
  border-bottom: 1px solid #808080;
  /* heading text starts 2px in and carries its own leading space (" Info") */
  padding: 1px 0 1px 2px;
  height: 18px;
  white-space: pre;
  overflow: hidden;
  user-select: none;
}
/* drag handle on the right edge of the Game Name and Status headings */
.zc-lv-grip {
  position: absolute;
  top: 0;
  right: 0;
  width: 5px;
  height: 100%;
  cursor: col-resize;
}
.zc-list-tbl tbody tr {
  height: 17px;
  background: #FFFFFF;
}
.zc-list-tbl tbody tr:nth-child(even) {
  background: #FFFFCC;
}
.zc-list-tbl td {
  padding: 1px 4px;
  /* List_Item_Line_Color (255,204,102) along the top of every row (FUN_600de5f1) */
  border-top: 1px solid #FFCC66;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}
/* "(cur/max)" right behind the status in List_Item_Nums_Color (150,150,150) */
.zc-lv-cnt { color: #969696; }
.zc-list-tbl td.zc-lv-num {
  text-align: center;
  padding: 1px 0;
  color: #000000;
}
.zc-list-tbl td.zc-lv-c {
  text-align: center;
  padding: 1px 2px;
}

.zc-slot {
  position: relative;
  width: 140px;
  height: 133px;
  background: url("../assets/dll/lobbyres/2117.png") no-repeat 0 0;
  user-select: none;
  flex-shrink: 0;
}

.zc-slot.hosted {
  background-position: -140px 0;
}

/* CONFIG 1091: Table_Game_Num_Rect {3,0,150,32} in TableViewCtl/10PtBold (Tahoma 10pt = 13px),
 * Table_Game_Name_Rect {3,15,100,32} and Table_Player_Num_Rect {100,15,150,32} in 9PtNorm
 * (Tahoma 9pt = 12px), all in Table_Item_Color white, no shadow (FUN_600de74e/dea1b/dec1c). */
.zc-slot-hdr {
  position: absolute;
  left: 3px;
  top: 0;
  width: 147px;
  height: 32px;
  color: #FFFFFF;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 13px;
  font-weight: bold;
  line-height: 16px;
  white-space: nowrap;
  overflow: hidden;
  pointer-events: none;
}

.zc-slot-sub {
  position: absolute;
  left: 0;
  top: 15px;
  width: 147px;
  height: 17px;
  font-weight: normal;
  font-size: 12px;
  line-height: 14px;
  color: #FFFFFF;
}
.zc-slot-name {
  position: absolute;
  left: 0;
  top: 0;
  width: 97px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.zc-slot-cnt {
  position: absolute;
  left: 97px;
  top: 0;
  white-space: nowrap;
}
/* Host latency bars at Table_Latency_Rect {100,4} */
.zc-slot-lat {
  position: absolute;
  left: 100px;
  top: 4px;
  margin: 0;
  z-index: 4;
  pointer-events: none;
}

/* Real 26x13 4-state blue Info button sprite from LobbyRes.dll (2106.png: 104x13)
 * Exact CONFIG 1091 Table_Info_Rect = {0, 34, 16, 50} flush left */
.zc-info-tag {
  position: absolute;
  left: 0;
  top: 34px;
  z-index: 4;
  width: 26px;
  height: 13px;
  padding: 0;
  border: 0;
  background: transparent url("../assets/dll/lobbyres/2106.png") no-repeat 0 0;
  color: transparent;
  font-size: 0;
  line-height: 0;
  pointer-events: auto;
  cursor: pointer;
  image-rendering: pixelated;
}
.zc-info-tag:hover { background-position: -26px 0; }
.zc-info-tag:active { background-position: -52px 0; }
.zc-info-tag:disabled { background-position: -78px 0; cursor: default; }

/* Inline 26x13 Info, 34x13 Host (2111.png), and 34x13 Join (2113.png) sprites for List View */
.zc-lv-btn {
  display: inline-block;
  height: 13px;
  padding: 0;
  border: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  background-position: 0 0;
  color: transparent;
  font-size: 0;
  line-height: 0;
  vertical-align: middle;
  cursor: pointer;
  image-rendering: pixelated;
}
.zc-lv-btn.info {
  width: 26px;
  background-image: url("../assets/dll/lobbyres/2106.png");
  margin-right: 4px;
}
.zc-lv-btn.info:hover:not(:disabled) { background-position: -26px 0; }
.zc-lv-btn.info:active:not(:disabled) { background-position: -52px 0; }
.zc-lv-btn.info:disabled { background-position: -78px 0; cursor: default; }
.zc-lv-btn.host {
  width: 34px;
  background-image: url("../assets/dll/lobbyres/2111.png");
}
.zc-lv-btn.host:hover:not(:disabled) { background-position: -34px 0; }
.zc-lv-btn.host:active:not(:disabled) { background-position: -68px 0; }
.zc-lv-btn.host:disabled { background-position: -102px 0; cursor: default; }
.zc-lv-btn.join {
  width: 34px;
  background-image: url("../assets/dll/lobbyres/2113.png");
}
.zc-lv-btn.join:hover:not(:disabled) { background-position: -34px 0; }
.zc-lv-btn.join:active:not(:disabled) { background-position: -68px 0; }
.zc-lv-btn.join:disabled { background-position: -102px 0; cursor: default; }

/* Real 8x7 sort arrow sprite from LobbyRes.dll (2104.png: 16x7 = down, up) */
.zc-list-tbl .zc-sort-arrow { margin-left: 0; }
.zc-sort-arrow {
  display: inline-block;
  width: 8px;
  height: 7px;
  margin-left: 3px;
  vertical-align: middle;
  background: transparent url("../assets/dll/lobbyres/2104.png") no-repeat 0 0;
  image-rendering: pixelated;
}
/* cell 0 ascending, cell 1 descending (the client indexes the image by its descending flag) */
.zc-sort-arrow.desc { background-position: -8px 0; }

/* Real 54x54 Golden 3D Host Orb (2119.png) & Blue 3D Join Orb (2121.png)
 * Exact CONFIG 1091 Table_Host_Join_Rect = {39, 79, 93, 133} */
.zc-orb-btn {
  position: absolute;
  left: 39px;
  top: 79px;
  width: 54px;
  height: 54px;
  border: 0;
  padding: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  background-position: 0 0;
  cursor: pointer;
  color: transparent;
  font-size: 0;
}

.zc-orb-btn.host {
  background-image: url("../assets/dll/lobbyres/2119.png");
}
.zc-orb-btn.host:hover { background-position: -54px 0; }
.zc-orb-btn.host:active { background-position: -108px 0; }

.zc-orb-btn.join {
  background-image: url("../assets/dll/lobbyres/2121.png");
}
.zc-orb-btn.join:hover { background-position: -54px 0; }
.zc-orb-btn.join:active { background-position: -108px 0; }
/* 4th cell: the table cannot be joined (FUN_600de87e draws cell 3) */
.zc-orb-btn.join:disabled,
.zc-orb-btn.join:disabled:hover,
.zc-orb-btn.join:disabled:active { background-position: -162px 0; cursor: default; }

/* Occupancy marks around the orb (ZoneClient FUN_600def24, CONFIG 1091 [TableViewCtl]).
 * Up to Max_Player_Dots = 16: 5x5 dots from LobbyRes 2118 (cell 0 taken, cell 1 open).
 * Above 16: Ring_Empty (150,150,150) / Ring_Full (255,255,204) pen 5, Ring_Line (51,102,102) pen 2. */
.zc-pdots,
.zc-pring {
  position: absolute;
  left: 0;
  top: 0;
  width: 150px;
  height: 150px;
  overflow: visible;
  pointer-events: none;
}
.zc-pdot {
  position: absolute;
  width: 5px;
  height: 5px;
  background: url("../assets/dll/lobbyres/2118.png") no-repeat 0 0;
}
.zc-pdot.open { background-position: -5px 0; }
.zc-pring path,
.zc-pring circle {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  shape-rendering: crispEdges;
}
.zc-pring-empty { stroke: #969696; stroke-width: 5; }
.zc-pring-full { stroke: #FFFFCC; stroke-width: 5; }
.zc-pring-line { stroke: #336666; stroke-width: 2; }

/* Exact CONFIG 1091 Table_Status_Rect = {5, 54, 145, 74} */
.zc-slot-players {
  position: absolute;
  left: 5px;
  top: 54px;
  width: 140px;
  color: #FFFFFF;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: bold;
  line-height: 13px;
  text-align: center;
  text-shadow: 1px 1px 0 #000000;
  overflow: hidden;
  white-space: nowrap;
  pointer-events: none;
}
/* Table_Lock_Rect {120,3} */
.zc-slot-lock {
  position: absolute;
  left: 120px;
  top: 3px;
  z-index: 4;
  pointer-events: none;
}

/* Authentic 1999 Win98 raised 3D "Latency / Name" sort header button (ch_lobby.png) */
.zc-roster-colhdr {
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  height: 20px;
  padding: 0 4px;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #404040;
  border-bottom: 1px solid #404040;
  box-shadow: inset -1px -1px 0 #808080;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1px;
  flex-shrink: 0;
  user-select: none;
  cursor: pointer;
}
.zc-roster-colhdr:active {
  border-top-color: #404040;
  border-left-color: #404040;
  border-right-color: #FFFFFF;
  border-bottom-color: #FFFFFF;
  box-shadow: inset 1px 1px 0 #808080;
}
.zc-colhdr-btn {
  background: transparent;
  color: #000000;
  border: 0;
  padding: 0 2px;
  height: 17px;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}
.zc-colhdr-btn:hover { text-decoration: none; }
.zc-colhdr-btn.active { font-weight: bold; }
.zc-colhdr-sep {
  color: #000000;
  font-size: 11px;
}

.zc-sidebar .clob-roster-list {
  padding: 2px 3px 4px;
  background: #000000;
  color: #FFFFFF;
  overflow-y: auto;
}

.zc-roster-section {
  color: #FFFFFF;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  /* the list's heading line: (102,153,153), 3 px below the text (FUN_600e1be4) */
  border-bottom: 1px solid #669999;
  margin: 1px 1px 4px;
  padding: 1px 2px 3px;
  display: flex;
  justify-content: space-between;
}
.zc-roster-section.friends,
.zc-roster-section.zteam,
.zc-roster-section.players {
  margin: 10px 1px 3px;
}
.zc-roster-section.theater-total {
  margin: 1px 1px 12px;
}
.zc-roster-section.theater-grp {
  margin: 10px 1px 2px;
}

.zc-roster-row {
  justify-content: flex-start;
  align-items: center;
  padding: 1px 2px 1px 4px;
  color: #FFFFFF;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  line-height: 15px;
  cursor: pointer;
}
/* the name shrinks with an ellipsis (DT_END_ELLIPSIS); a rating, when shown, keeps its width at the right */
.zc-roster-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.zc-roster-rating {
  flex: 0 0 auto;
  margin-left: 4px;
  white-space: nowrap;
}
.zc-roster-row.zc-roster-me {
  margin-top: 10px;
  margin-bottom: 14px;
}
.zc-roster-row:hover {
  background: #000080;
}

/* ============================================================================
 * AUTHENTIC CURVED LAUNCHPAD WINDOW (ch_lp.png / launchpad_desc.png / retail-two-seated-launchpad.png)
 * ============================================================================ */
.lpad-shell {
  display: grid;
  /* LobbyRes CONFIG [LaunchPad]: user list 102 wide (VerticalSplitterSizeIdeal), splitter 8 (SplitterWidth) */
  grid-template-columns: 1fr 8px 102px;
  flex: 1;
  background: #000000;
  color: #FFFFFF;
  overflow: hidden;
}

/* the splitter is filled with the 8x8 pattern bitmap 2514 (CreatePatternBrush + PatBlt) */
.lpad-vsplit {
  width: 8px;
  background: #000000 url("../assets/dll/lobbyres/2514.png") repeat 0 0;
  border: 0;
  cursor: ew-resize;
  user-select: none;
  flex-shrink: 0;
  image-rendering: pixelated;
}

.lpad-left {
  position: relative;
  display: flex;
  flex-direction: column;
  background: #000000 url("../assets/dll/lobbyres/idb_launchpad.png") no-repeat left top;
  padding: 0 10px 8px 0;
  overflow: hidden;
  image-rendering: pixelated;
}

.lpad-top-badge {
  position: relative;
  width: 148px;
  background: #336666;
  color: #FFFFCC;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  padding: 2px 6px 3px 6px;
  line-height: 1.3;
  flex-shrink: 0;
}

.lpad-status-bar {
  width: 148px;
  background: #FFFFCC;
  color: #336666;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  padding: 2px 6px;
  flex-shrink: 0;
}

/* Authentic host Game Description displayed directly over curved launchpad art (launchpad_desc.png) */
.lpad-desc-box {
  height: 60px;
  margin: 6px 10px 4px 46px;
  color: #FFFFFF;
  /* LaunchPad/Description: Tahoma 10 pt bold, 16px lines; DrawText keeps the host's own line
   * breaks (ZoneClient launchpad paint, DT_WORDBREAK | DT_EDITCONTROL) */
  font-family: Tahoma, Arial, sans-serif;
  font-size: 13px;
  font-weight: bold;
  line-height: 16px;
  white-space: pre-wrap;
  text-shadow: 1px 1px 0 #000000;
  overflow: hidden;
  word-break: break-word;
  pointer-events: none;
  flex-shrink: 0;
}

.lpad-chat-box {
  margin: 4px 8px 8px 46px;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
  /* no border: the client's chat host is a plain child window (style 0x52000000) */
  border: 0;
  overflow: hidden;
}

.lpad-btn-row {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding-left: 42px;
  flex-shrink: 0;
}
.lpad-badge-sub {
  display: flex;
  justify-content: space-between;
  gap: 4px;
}
.lpad-badge-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Desktop layout by the launchpad's own coordinates (ZoneClient FUN_600e5623 layout, WM_PAINT above it).
 * The phone layouts further down keep the flow layout above.
 *   info tab (0,0) 144x32: "Game N" at (8,2), name in (8,15)-(106,32), count from x=109
 *   status line (0,32) 144x16, text at (8,33)
 *   description (48,56) 260x92
 *   chat (48,148) to 16 px from the pane edge and 32 px above the bottom
 *   buttons 80x16, 8 px above the bottom, Leave ending 16 px from the pane edge, 85 px apart */
@media (min-width: 721px) and (min-height: 461px) {
  .lpad-left {
    display: block;
    padding: 0;
  }
  .lpad-top-badge {
    position: absolute;
    left: 0;
    top: 0;
    width: 144px;
    height: 32px;
    box-sizing: border-box;
    padding: 0;
    line-height: 13px;
    overflow: hidden;
  }
  .lpad-badge-num {
    position: absolute;
    left: 8px;
    top: 2px;
    white-space: nowrap;
  }
  .lpad-badge-sub {
    position: absolute;
    left: 8px;
    top: 15px;
    width: 136px;
    height: 17px;
    display: block;
  }
  .lpad-badge-name {
    position: absolute;
    left: 0;
    top: 0;
    width: 98px;
  }
  .lpad-badge-cnt {
    position: absolute;
    left: 101px;
    top: 0;
    white-space: nowrap;
  }
  .lpad-status-bar {
    position: absolute;
    left: 0;
    top: 32px;
    width: 144px;
    height: 16px;
    box-sizing: border-box;
    padding: 1px 0 0 8px;
    line-height: 13px;
    overflow: hidden;
    white-space: nowrap;
  }
  .lpad-desc-box {
    position: absolute;
    left: 48px;
    top: 56px;
    width: 260px;
    height: 92px;
    margin: 0;
    font-family: Tahoma, Arial, sans-serif;
  }
  .lpad-chat-box {
    position: absolute;
    left: 48px;
    top: 148px;
    right: 16px;
    bottom: 32px;
    margin: 0;
  }
  .lpad-btn-row {
    position: absolute;
    right: 16px;
    bottom: 8px;
    height: 16px;
    padding: 0;
    justify-content: flex-end;
    gap: 5px;
  }
}

.lpad-right {
  background: #000000;
  border-left: 0;
  padding: 4px 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow-y: auto;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
}

.lpad-sec-lbl {
  color: #FFFFFF;
  font-size: 11px;
  /* the user list draws a 1px line in (102,153,153) 3 px below the heading text (FUN_600e1be4) */
  border-bottom: 1px solid #669999;
  padding-bottom: 3px;
  margin-top: 8px;
  margin-bottom: 4px;
}
.lpad-sec-lbl:first-child { margin-top: 0; margin-bottom: 8px; }

.lpad-player-item {
  display: flex;
  align-items: center;
  color: #FFFFFF;
  padding: 1px 0 1px 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lpad-player-item.self {
  padding-left: 24px;
}
/* names are cut with an ellipsis (DT_END_ELLIPSIS); the row is a flex box, so the name needs its own box */
.lpad-player-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.zc-lat-spacer {
  display: inline-block;
  width: 22px;
  flex-shrink: 0;
}

/* ============================================================================
 * AUTHENTIC CLASSIC GAME WINDOW SHELL (botgame_hearts.png / checkers_board_full.png)
 * Menu bar -> Full-bleed game canvas -> Full-width pure white chat log + input
 * ============================================================================ */
.zgame-wrap {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
  background: #000000;
}

.zgame-stage {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000000;
  overflow: hidden;
  position: relative;
}

.zgame-stage.felt {
  background:
    repeating-linear-gradient(
      135deg,
      rgba(0, 0, 0, 0.08) 0px,
      rgba(0, 0, 0, 0.08) 1px,
      transparent 1px,
      transparent 3px
    ),
    #006800;
}

.zgame-canvas {
  display: block;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
  cursor: pointer;
  touch-action: none;
}

.zgame-controls {
  display: flex;
  gap: 4px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  padding: 3px 6px;
  background: var(--w98-face);
  border-top: 1px solid #FFFFFF;
  border-bottom: 1px solid #808080;
  box-shadow: inset 0 -1px 0 #404040;
  flex-shrink: 0;
}

/* Classics-v2 in-window Rematch strip (RematchWire 0x111/0x112) */
.zgame-rematch-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 26px;
  padding: 2px 8px;
  background: #23201B;
  color: #F5EED8;
  border-top: 1px solid #8C7348;
  border-bottom: 1px solid #0E0C0A;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  flex-shrink: 0;
}
.zgame-rematch-bar.offered {
  background: #1B3328;
  border-top-color: #E6C56E;
  color: #FFF9DF;
}
.zgame-rematch-text {
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zgame-rematch-actions {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}
.zgame-rematch-btn {
  min-width: 72px;
}

.zgame-chat-bar {
  height: 84px;
  display: flex;
  flex-direction: column;
  background: var(--w98-face);
  flex-shrink: 0;
}

/* Native recreated parlor classic game chat strip (exact WM_CTLCOLOR* palette: dark wood / slate / felt + cream ink) */
.zgame-chat-bar.zgame-parlor {
  height: 82px;
  background: var(--parlor-hist, #412310);
  border-top: 1px solid var(--parlor-border, #261206);
}
.zgame-chat-bar.zgame-parlor .zchat-log {
  background: var(--parlor-hist, #412310);
  color: var(--parlor-ink, #F5EAD2);
  border: 1px solid var(--parlor-border, #261206);
  border-bottom: 0;
  font-family: Verdana, Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: bold;
  padding: 2px 5px;
}
.zgame-chat-bar.zgame-parlor .zchat-line-who {
  color: #FFE499;
}
.zgame-chat-bar.zgame-parlor .zchat-line-sys {
  color: #D9C398;
}
.zgame-chat-bar.zgame-parlor .zchat-form {
  background: var(--parlor-edit, #563018);
  border: 1px solid var(--parlor-border, #261206);
  height: 25px;
}
.zgame-chat-bar.zgame-parlor .zchat-form input {
  background: var(--parlor-edit, #563018);
  color: var(--parlor-ink, #F5EAD2);
  font-family: Verdana, Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: bold;
}
.zgame-chat-bar.zgame-parlor .zchat-form input::placeholder {
  color: rgba(245, 234, 210, 0.52);
}

/* Genuine 1999 Win98 SE RNAAPP.EXE dual-monitor animated taskbar network activity icon */
.ztb-net-ico {
  width: 18px;
  height: 18px;
  padding: 0;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 16px 16px;
  image-rendering: pixelated;
  background-image: url("../assets/win98/net_off.png");
}
.ztb-net-ico.off  { background-image: url("../assets/win98/net_off.png"); }
.ztb-net-ico.idle { background-image: url("../assets/win98/net_idle.png"); }
.ztb-net-ico.tx   { background-image: url("../assets/win98/net_tx.png"); }
.ztb-net-ico.rx   { background-image: url("../assets/win98/net_rx.png"); }
.ztb-net-ico.both { background-image: url("../assets/win98/net_both.png"); }

/* Real 16x16 Microsoft Windows taskbar tray speaker icon (SndVol.exe ID 110 / 111) */
.ztb-snd-ico {
  width: 18px;
  height: 18px;
  padding: 0;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 16px 16px;
  image-rendering: pixelated;
  background-image: url("../assets/win98/speaker.png");
}
.ztb-snd-ico.muted {
  background-image: url("../assets/win98/speaker_muted.png");
}

/* Real 15x7 5-tier Zone latency bar sprite from CommonRes.dll (1000.png: 75x7)
 * Frame 0 (0px): unknown, Frame 1 (-15px): 1 red, Frame 2 (-30px): 2 yellow,
 * Frame 3 (-45px): 3 green, Frame 4 (-60px): 4 green. */
.zc-lat-bars {
  display: inline-block;
  width: 15px;
  height: 7px;
  margin-right: 7px;
  vertical-align: middle;
  flex-shrink: 0;
  background: transparent url("../assets/dll/commonres/1000.png") no-repeat -60px 0;
  image-rendering: pixelated;
}
.zc-lat-bars.lat-0 { background-position: 0 0; }
.zc-lat-bars.lat-1 { background-position: -15px 0; }
.zc-lat-bars.lat-2 { background-position: -30px 0; }
.zc-lat-bars.lat-3 { background-position: -45px 0; }
.zc-lat-bars.lat-4 { background-position: -60px 0; }

/* Real 7x8 golden padlock sprite (2114.png) for private games & black padlock (2105.png) for List View header */
.zc-lock-ico,
.zc-lock-hdr-ico {
  display: inline-block;
  width: 7px;
  height: 8px;
  flex-shrink: 0;
  vertical-align: middle;
  background: transparent url("../assets/dll/lobbyres/2114.png") no-repeat 0 0;
  image-rendering: pixelated;
}
.zc-lock-hdr-ico {
  background-image: url("../assets/dll/lobbyres/2105.png");
}

/* ============================================================================
 * AUTHENTIC 1999 ZONECLIENT TableInfoCtl POPUP (LobbyRes CONFIG 1091 + FUN_600afc5f)
 * 148px popup (Default_Width 150 - 2, FUN_600c8670): #006699 description bar over the black HOST/PLAYERS list
 * ============================================================================ */
.zc-table-info {
  position: fixed;
  z-index: 99990;
  width: 148px;
  box-sizing: border-box;
  background: #000000;
  color: #FFFFFF;
  border: 1px solid #669999;
  box-shadow: 2px 2px 0 #000000;
  font-family: Tahoma, "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zc-ti-desc {
  background: #006699;
  color: #FFFFFF;
  min-height: 20px;
  padding: 3px 5px;
  font-size: 11px;
  line-height: 1.3;
  word-break: break-word;
  border-bottom: 1px solid #000000;
}
.zc-ti-body {
  background: #000000;
  padding: 3px 6px 6px;
  color: #FFFFFF;
  overflow-y: auto;
}
.zc-ti-players {
  display: flex;
  flex-direction: column;
}
.zc-ti-sec {
  /* the user list's shared heading: white text at the list size, a (102,153,153) line 3 px below (FUN_600e1be4) */
  color: #FFFFFF;
  font-size: 11px;
  line-height: 1.3;
  border-bottom: 1px solid #669999;
  padding-bottom: 3px;
  margin-top: 4px;
  margin-bottom: 2px;
}
.zc-ti-sec:first-child {
  margin-top: 1px;
}
.zc-ti-row {
  display: flex;
  align-items: center;
  color: #FFFFFF;
  font-size: 11px;
  line-height: 1.35;
  padding: 1px 0 1px 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* the name gets its own box so the ellipsis works inside the flex row */
.zc-ti-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Shared Win98 sunken edit box, checkbox, and default push-button ring */
.zwin-edit {
  background: #FFFFFF;
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  padding: 2px 4px;
  border-radius: 0;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}
.zwin-edit:disabled {
  background: #D4D0C8;
  color: #808080;
}
.zwin-edit[readonly] {
  background: #D4D0C8;
  color: #000000;
}
.zwin-chk {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #000000;
  font-size: 11px;
  cursor: pointer;
  white-space: nowrap;
}
.zwin-chk input[type="checkbox"] {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
  width: 13px;
  height: 13px;
  background: #FFFFFF;
  border-radius: 0;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}
.zwin-chk input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 2px;
  top: 1px;
  width: 7px;
  height: 7px;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='7' shape-rendering='crispEdges'%3E%3Cpath d='M0 3h1v1h1v1h1V4h1V3h1V2h1V1h1v2H6v1H5v1H4v1H3v1H2V6H1V5H0z' fill='%23000'/%3E%3C/svg%3E") no-repeat center;
}
.zwin-rad input[type="radio"] {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #FFFFFF;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040, inset -1px -1px 0 #DFDFDF;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}
.zwin-rad input[type="radio"]:disabled {
  background: #D4D0C8;
  cursor: default;
}
.zwin-rad input[type="radio"]:checked::after {
  content: "";
  position: absolute;
  left: 3px;
  top: 3px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #000000;
}
.zwin-rad input[type="radio"]:disabled:checked::after {
  background: #808080;
}
.zlp-pwd-dlg {
  /* LobbyRes DIALOG 2303 "Private Game", 191x47 DLU in MS Sans Serif 8: controls at the template's
   * positions (x * 1.5, y * 1.625) */
  position: relative;
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 0;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zlp-pwd-dlg > label,
.zlp-pwd-dlg > input,
.zlp-pwd-dlg > button {
  position: absolute;
  margin: 0;
  box-sizing: border-box;
}
.zlp-pwd-lbl {
  line-height: 13px;
  color: #000000;
}
.zlp-pwd-dlg > button {
  width: 75px;
  height: 23px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.zdyn-inv-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zdyn-inv-ta {
  flex: 1;
  width: 100%;
  resize: none;
  line-height: 1.3;
}
.zdyn-inv-btns {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  margin-top: 6px;
}
.zbtn-default {
  box-shadow: inset -1px -1px 0 #808080, 0 0 0 1px #000000;
}
.zbtn-default:active:not(:disabled),
.zbtn-default.zbtn-kbd-active:not(:disabled) {
  box-shadow: 0 0 0 1px #000000;
}

/* ============================================================================
 * AUTHENTIC 1999 LAUNCHPAD SETTINGS DIALOG (LobbyRes.dll DLG 2308, 270x129 dlu)
 * ============================================================================ */
.zlp-set-dlg {
  /* LobbyRes DIALOG 2308, 270x129 DLU in MS Sans Serif 8: every control at its template position
   * (x * 1.5, y * 1.625). Labels are in the regular dialog font. */
  position: relative;
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 0;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  user-select: none;
}
.zlp-set-dlg > label,
.zlp-set-dlg > input,
.zlp-set-dlg > textarea,
.zlp-set-dlg > button {
  position: absolute;
  margin: 0;
  box-sizing: border-box;
  font-weight: normal;
}
.zlp-set-dlg > label {
  line-height: 13px;
  white-space: nowrap;
}
.zlp-set-dlg > label.disabled {
  color: #808080;
}
.zlp-set-dlg > input[type="text"],
.zlp-set-dlg > input[type="number"] {
  height: 20px;
}
.zlp-set-dlg .zwin-chk span {
  font-weight: normal;
}
.zlp-set-desc {
  resize: none;
  line-height: 1.3;
}
.zlp-set-dlg > button {
  width: 75px;
  height: 23px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ============================================================================
 * AUTHENTIC 1999 ABOUT DIALOGS (zone.exe DLG 279 & CommonRes.dll DLG 1140)
 * ============================================================================ */
.zabout-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zabout-dlg.zf {
  padding: 12px 12px 10px 12px;
  display: grid;
  grid-template-columns: 98px 1fr 76px;
  gap: 12px;
  align-items: start;
}
.zabout-dlg.room {
  padding: 12px 2px 10px 12px;
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 6px;
  align-items: start;
}
.zabout-logo-box {
  background: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}
.zabout-logo-box.zf {
  width: 98px;
  height: 54px;
}
.zabout-logo-box.room {
  width: 112px;
  height: 58px;
}
.zabout-logo-box img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  image-rendering: pixelated;
}
.zabout-right {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-width: 0;
}
.zabout-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 1px;
}
.zabout-line {
  color: #000000;
  font-size: 11px;
  line-height: 1.3;
  white-space: nowrap;
}
.zabout-dlg.room .zabout-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
  margin-right: 12px;
}
.zabout-ok {
  width: 75px;
  height: 23px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Win98 embedded Zone Help browser frame */
.zhelp-frame {
  border: 0;
  width: 100%;
  height: 100%;
  flex: 1;
  min-height: 0;
  background: #FFFFFF;
}

/* Authentic 1999 Win98 3D-beveled trackbar sliders & selects inside classic game windows (zero modern blue controls) */
.zgame-controls label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
}
.zgame-controls input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 16px;
  background: transparent;
  margin: 0 2px;
  cursor: pointer;
}
.zgame-controls input[type="range"]::-webkit-slider-runnable-track {
  height: 4px;
  background: #FFFFFF;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}
.zgame-controls input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 9px;
  height: 16px;
  margin-top: -7px;
  background: #D4D0C8;
  border-top: 2px solid #FFFFFF;
  border-left: 2px solid #FFFFFF;
  border-right: 2px solid #404040;
  border-bottom: 2px solid #404040;
  border-radius: 0;
}
.zgame-controls input[type="range"]::-moz-range-track {
  height: 4px;
  background: #FFFFFF;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}
.zgame-controls input[type="range"]::-moz-range-thumb {
  width: 9px;
  height: 16px;
  background: #D4D0C8;
  border-top: 2px solid #FFFFFF;
  border-left: 2px solid #FFFFFF;
  border-right: 2px solid #404040;
  border-bottom: 2px solid #404040;
  border-radius: 0;
}
.zgame-controls select {
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  height: 20px;
  padding: 0 3px;
  background: #FFFFFF;
  color: #000000;
  border-top: 2px solid #808080;
  border-left: 2px solid #808080;
  border-right: 2px solid #FFFFFF;
  border-bottom: 2px solid #FFFFFF;
  border-radius: 0;
}

/* Kibitzer / Spectator status strip in Classic GameWindowBase */
.zkibitz-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 8px;
  height: 24px;
  background: #002828;
  border-bottom: 1px solid #669999;
  color: #FFFFCC;
  font-size: 11px;
  font-weight: bold;
  flex-shrink: 0;
}

/* ============================================================================
 * AUTHENTIC 1999 WINDOWS 98 16px 3D SCROLLBARS (ch_lobby.png / listview.png)
 * ============================================================================ */
.zclient-floor::-webkit-scrollbar,
.zclient-list-floor::-webkit-scrollbar,
.zchat-log::-webkit-scrollbar,
.clob-floor::-webkit-scrollbar,
.clob-roster-list::-webkit-scrollbar,
.lpad-right::-webkit-scrollbar,
.zlan-listbox::-webkit-scrollbar {
  width: 16px;
  height: 16px;
}

.zclient-floor::-webkit-scrollbar-track,
.zclient-list-floor::-webkit-scrollbar-track,
.zchat-log::-webkit-scrollbar-track,
.clob-floor::-webkit-scrollbar-track,
.clob-roster-list::-webkit-scrollbar-track,
.lpad-right::-webkit-scrollbar-track,
.zlan-listbox::-webkit-scrollbar-track {
  background: repeating-conic-gradient(#FFFFFF 0% 25%, #D4D0C8 0% 50%) 0 0 / 2px 2px;
}

.zclient-floor::-webkit-scrollbar-thumb,
.zclient-list-floor::-webkit-scrollbar-thumb,
.zchat-log::-webkit-scrollbar-thumb,
.clob-floor::-webkit-scrollbar-thumb,
.clob-roster-list::-webkit-scrollbar-thumb,
.lpad-right::-webkit-scrollbar-thumb,
.zlan-listbox::-webkit-scrollbar-thumb {
  background: #D4D0C8;
  border-top: 1px solid #DFDFDF;
  border-left: 1px solid #DFDFDF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080;
  min-height: 18px;
}

.zclient-floor::-webkit-scrollbar-button,
.zclient-list-floor::-webkit-scrollbar-button,
.zchat-log::-webkit-scrollbar-button,
.clob-floor::-webkit-scrollbar-button,
.clob-roster-list::-webkit-scrollbar-button,
.lpad-right::-webkit-scrollbar-button,
.zlan-listbox::-webkit-scrollbar-button {
  display: none;
  width: 0;
  height: 0;
}

.zclient-floor::-webkit-scrollbar-button:vertical:start:decrement,
.zclient-list-floor::-webkit-scrollbar-button:vertical:start:decrement,
.zchat-log::-webkit-scrollbar-button:vertical:start:decrement,
.clob-floor::-webkit-scrollbar-button:vertical:start:decrement,
.clob-roster-list::-webkit-scrollbar-button:vertical:start:decrement,
.lpad-right::-webkit-scrollbar-button:vertical:start:decrement,
.zlan-listbox::-webkit-scrollbar-button:vertical:start:decrement,
.zclient-floor::-webkit-scrollbar-button:vertical:end:increment,
.zclient-list-floor::-webkit-scrollbar-button:vertical:end:increment,
.zchat-log::-webkit-scrollbar-button:vertical:end:increment,
.clob-floor::-webkit-scrollbar-button:vertical:end:increment,
.clob-roster-list::-webkit-scrollbar-button:vertical:end:increment,
.lpad-right::-webkit-scrollbar-button:vertical:end:increment,
.zlan-listbox::-webkit-scrollbar-button:vertical:end:increment {
  width: 16px;
  height: 16px;
  display: block;
  background-color: #D4D0C8;
  background-repeat: no-repeat;
  background-position: center;
  border-top: 1px solid #DFDFDF;
  border-left: 1px solid #DFDFDF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080;
}

.zclient-floor::-webkit-scrollbar-button:vertical:start:decrement,
.zclient-list-floor::-webkit-scrollbar-button:vertical:start:decrement,
.zchat-log::-webkit-scrollbar-button:vertical:start:decrement,
.clob-floor::-webkit-scrollbar-button:vertical:start:decrement,
.clob-roster-list::-webkit-scrollbar-button:vertical:start:decrement,
.lpad-right::-webkit-scrollbar-button:vertical:start:decrement,
.zlan-listbox::-webkit-scrollbar-button:vertical:start:decrement {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='4' shape-rendering='crispEdges'%3E%3Cpath d='M3 0h1v1H2v1H1v1H0v1h7V3H6V2H5V1H4z' fill='%23000'/%3E%3C/svg%3E");
}

.zclient-floor::-webkit-scrollbar-button:vertical:end:increment,
.zclient-list-floor::-webkit-scrollbar-button:vertical:end:increment,
.zchat-log::-webkit-scrollbar-button:vertical:end:increment,
.clob-floor::-webkit-scrollbar-button:vertical:end:increment,
.clob-roster-list::-webkit-scrollbar-button:vertical:end:increment,
.lpad-right::-webkit-scrollbar-button:vertical:end:increment,
.zlan-listbox::-webkit-scrollbar-button:vertical:end:increment {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='4' shape-rendering='crispEdges'%3E%3Cpath d='M0 0h7v1H6v1H5v1H4v1H3V3H2V2H1V1H0z' fill='%23000'/%3E%3C/svg%3E");
}

/* Authentic 1999 LobbyRes.dll DLG 2304 / DLG 2307 Launchpad Launching dialog */
.zlpad-wait-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 13px 12px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  text-align: center;
}
.zlpad-wait-msg {
  color: #000000;
  /* three 13 px lines fit the template's 216x44 text area above the buttons at y=62 */
  line-height: 13px;
  white-space: pre-line;
  margin-top: 0;
}
.zlpad-wait-btns {
  display: flex;
  justify-content: center;
}
/* 48x14 DLU buttons */
.zlpad-wait-cancel {
  min-width: 72px;
  height: 23px;
}

.zclient-floor::-webkit-scrollbar-corner,
.zclient-list-floor::-webkit-scrollbar-corner,
.zchat-log::-webkit-scrollbar-corner,
.clob-floor::-webkit-scrollbar-corner,
.clob-roster-list::-webkit-scrollbar-corner,
.lpad-right::-webkit-scrollbar-corner,
.zlan-listbox::-webkit-scrollbar-corner {
  background: #D4D0C8;
}

/* ============================================================================
 * AUTHENTIC 1999 WIN98 ALERT DIALOG (CommonRes.dll DLG 1177 style)
 * ============================================================================ */
.zalert-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 12px 14px 10px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}

.zalert-body {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.zalert-ico-wrap {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.zalert-ico-svg {
  display: block;
  width: 32px;
  height: 32px;
}

.zalert-text {
  flex: 1;
  color: #000000;
  line-height: 1.4;
  word-break: break-word;
  padding-top: 2px;
  white-space: pre-line;
}
.zalert-body.plain {
  justify-content: center;
  align-items: center;
}
.zalert-text.plain {
  font-weight: bold;
  text-align: center;
  padding: 2px 6px;
}

.zalert-btns {
  display: flex;
  justify-content: center;
}

.zalert-ok {
  width: 75px;
  height: 23px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ============================================================================
 * AUTHENTIC 1999 ZONELAN - IPX / CHOOSE A GAME PICKER (LobbyRes.dll DLG 2660)
 * Matches winxpzone-zl2_xp_s4_picker.png (240x203 dlu -> 374x332px)
 * ============================================================================ */
.zlan-dlg {
  flex: 1 1 0;
  min-height: 0;
  overflow: hidden;
  background: var(--w98-face);
  color: #000000;
  padding: 10px 12px 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}

.zlan-lead {
  flex-shrink: 0;
  color: #000000;
  line-height: 1.35;
}

.zlan-listbox {
  flex: 1 1 0;
  min-height: 80px;
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  overflow-y: scroll;
  padding: 1px;
}

.zlan-list-item {
  padding: 2px 4px;
  color: #000000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
}

.zlan-list-item.selected {
  background: #000080;
  color: #FFFFFF;
}

.zlan-field {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2px;
}

.zlan-field label {
  color: #000000;
  white-space: nowrap;
}

.zlan-field input {
  width: 100%;
  height: 21px;
}

.zlan-btns {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 4px;
}

.zlan-btns-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

.zlan-btn {
  width: 75px;
  height: 23px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ============================================================================
 * AUTHENTIC 1999 GAME INSTALLATION GATE DIALOG (LobbyRes.dll STR 0xa5a / 0xa5b)
 * ============================================================================ */
.zinst-dlg {
  flex: 1 1 0;
  min-height: 0;
  overflow: hidden;
  background: var(--w98-face);
  color: #000000;
  padding: 12px 14px 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}

.zinst-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex-shrink: 0;
}

.zinst-ico {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.zinst-msg {
  color: #000000;
  line-height: 1.4;
  flex: 1;
}

.zinst-box {
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  padding: 7px 9px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1 1 0;
  min-height: 52px;
}

.zinst-box.dragover {
  outline: 2px dashed #000080;
  outline-offset: -3px;
  background: #E8F2FF;
}

.zinst-req {
  font-weight: bold;
  color: #000080;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.zinst-status {
  color: #222222;
  line-height: 1.35;
}

.zinst-status.err {
  color: #990000;
  font-weight: bold;
}

.zinst-status.ok {
  color: #006600;
  font-weight: bold;
}

.zinst-cache-bar {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 5px 7px;
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}

.zinst-cache-txt {
  font-size: 11px;
  color: #222222;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.zinst-saves-btns {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.zinst-saves-panel {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.zinst-saves-list {
  max-height: 86px;
  overflow-y: auto;
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}

.zinst-saves-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 3px 6px;
  border-bottom: 1px solid #ECECEC;
  font-size: 11px;
}

.zinst-saves-row:last-child {
  border-bottom: 0;
}

.zinst-saves-row-info {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.zinst-mini-btn {
  min-width: 44px;
  height: 19px;
  padding: 0 6px;
  font-size: 10px;
}

.zinst-roam-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 2px 2px 0;
  font-size: 11px;
}

.zinst-roam-chk {
  font-size: 11px;
  color: #000000;
}

.zinst-roam-stat {
  font-size: 10px;
  color: #444444;
  white-space: nowrap;
}

.zinst-btns {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.zinst-btns-left {
  display: flex;
  align-items: center;
  gap: 6px;
}

.zinst-ok {
  width: 75px;
  height: 23px;
}

.zinst-mgr-lead {
  color: #000000;
  line-height: 1.35;
  flex-shrink: 0;
}

.zinst-mgr-list {
  flex: 1 1 0;
  min-height: 120px;
  overflow-y: auto;
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  padding: 2px;
}

.zinst-mgr-row {
  padding: 4px 6px;
  cursor: default;
  border-bottom: 1px solid #ECECEC;
}

.zinst-mgr-row.sel {
  background: #000080;
  color: #FFFFFF;
}

.zinst-mgr-row-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.zinst-mgr-title {
  font-weight: bold;
}

.zinst-mgr-badge {
  font-size: 10px;
  padding: 0 4px;
  border: 1px solid #808080;
  background: var(--w98-face);
  color: #000000;
  flex-shrink: 0;
}

.zinst-mgr-row.sel .zinst-mgr-badge {
  background: #2040A0;
  border-color: #88AAFF;
  color: #FFFFFF;
}

.zinst-mgr-meta {
  font-size: 10px;
  color: #444444;
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.zinst-mgr-row.sel .zinst-mgr-meta {
  color: #D8E8FF;
}

.zinst-mgr-empty {
  padding: 24px 12px;
  text-align: center;
  color: #666666;
}

/* ============================================================================
 * WIN98 WINDOW RESIZE HANDLES (edges + corners on resizable windows)
 * ============================================================================ */
.zwin-resize {
  position: absolute;
  z-index: 6;
}
.zwin-resize-n { top: -3px; left: 6px; right: 6px; height: 6px; cursor: ns-resize; }
.zwin-resize-s { bottom: -3px; left: 6px; right: 6px; height: 6px; cursor: ns-resize; }
.zwin-resize-w { left: -3px; top: 6px; bottom: 6px; width: 6px; cursor: ew-resize; }
.zwin-resize-e { right: -3px; top: 6px; bottom: 6px; width: 6px; cursor: ew-resize; }
.zwin-resize-nw { top: -3px; left: -3px; width: 9px; height: 9px; cursor: nwse-resize; }
.zwin-resize-ne { top: -3px; right: -3px; width: 9px; height: 9px; cursor: nesw-resize; }
.zwin-resize-sw { bottom: -3px; left: -3px; width: 9px; height: 9px; cursor: nesw-resize; }
.zwin-resize-se { bottom: -3px; right: -3px; width: 9px; height: 9px; cursor: nwse-resize; }
body.zwin-dragging iframe { pointer-events: none !important; }

/* ============================================================================
 * AUTHENTIC 1999 LOBBYRES.DLL DLG 2310 RESUME DIALOG & PAUSED LOBBY STATE
 * Matches item4-before-2-launch-paused.png / item2-after-resume-dialog-left-for-member.png
 * ============================================================================ */
.zwin.zwin-paused .zwin-menubar .zmenu-item {
  color: #808080;
  pointer-events: none;
}
.zwin-paused-shield {
  position: absolute;
  inset: 22px 0 0 0;
  z-index: 40;
  background: transparent;
  cursor: default;
}

.zresume-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 12px 14px 12px 12px;
  display: grid;
  grid-template-columns: 126px 1fr;
  gap: 14px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zresume-logo-box {
  width: 125px;
  height: 125px;
  background: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.zresume-logo-box img {
  width: 125px;
  height: 125px;
  display: block;
  image-rendering: pixelated;
}
.zresume-right {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: 4px;
}
.zresume-msg {
  color: #000000;
  line-height: 1.4;
  white-space: pre-line;
}
.zresume-btns {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}
.zresume-btn {
  min-width: 72px;
  height: 22px;
}

/* ============================================================================
 * AUTHENTIC 1999 DIALOGS: zone.exe DLG 272 (Privacy), DLG 275 (General Prefs),
 * LobbyRes.dll DLG 2321 (Zone Tips), CommonRes.dll DLG 1175 (Sysop Edit Alert)
 * ============================================================================ */
.zpriv-dlg,
.zprefs-dlg,
.ztips-dlg,
.zedit-alert-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
}
.zwin-grp {
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080;
  padding: 8px 10px 8px;
  margin: 2px 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.zwin-grp legend {
  padding: 0 4px;
  color: #000000;
  font-size: 11px;
}
.zwin-rad,
.zwin-chk {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  cursor: pointer;
}
.zpriv-custom-grp {
  padding: 6px 8px 8px;
  margin: 2px 0;
}
.zpriv-custom-grid {
  display: grid;
  grid-template-columns: 1fr 148px;
  gap: 8px;
  align-items: start;
}
.zpriv-list {
  height: 82px;
  background: #FFFFFF;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  overflow-y: auto;
  padding: 2px;
}
.zpriv-list-row {
  padding: 1px 4px;
  cursor: pointer;
}
.zpriv-list-row.sel {
  background: #000080;
  color: #FFFFFF;
}
.zedit-alert-ta {
  flex: 1;
  width: 100%;
  resize: none;
  background: #FFFFFF;
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  padding: 4px 6px;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}
.ztips-list {
  margin: 2px 0;
  padding-left: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 5px;
  line-height: 1.35;
}
.ztips-list li {
  position: relative;
  padding-left: 13px;
}
.ztips-list li::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 5px;
  width: 4px;
  height: 4px;
  background: #808080;
}
.ztips-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

/* Authentic 1999 ZoneClient User info window popup (ZoneClient.dll!FUN_600b01b4, WS_POPUP|WS_BORDER, COLOR_WINDOW) */
.zc-user-info {
  position: fixed;
  z-index: 99991;
  min-width: 112px;
  max-width: 240px;
  background: #FFFFFF;
  color: #000000;
  border: 1px solid #000000;
  padding: 2px 6px 3px 4px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  line-height: 14px;
  user-select: none;
  pointer-events: none;
}
.zc-ui-name {
  font-weight: bold;
  color: #000000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zc-ui-line {
  font-weight: normal;
  color: #000000;
  white-space: nowrap;
}
.zc-roster-row.zc-pressing,
.clob-roster-row.zc-pressing {
  background: #000080 !important;
  color: #FFFFFF !important;
}
.zc-roster-row.zc-pressing *,
.clob-roster-row.zc-pressing * {
  color: #FFFFFF !important;
}

/* Authentic Win98 "Opening Application" (arrow + spinning hourglass) busy cursor during game launch */
body.wz-app-launching,
body.wz-app-launching * {
  cursor: var(--wz-launch-cursor, progress) !important;
}

/* Authentic Win98 ChooseFont dialog */
.zfont-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zfont-grid {
  display: grid;
  grid-template-columns: 126px 96px 56px 76px;
  gap: 8px;
  align-items: start;
}
.zfont-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.zfont-list {
  height: 98px;
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  overflow-y: scroll;
  padding: 1px;
}
.zfont-btns {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 16px;
}
.zfont-btns .zbtn {
  width: 75px;
  height: 22px;
}
.zfont-sample-grp {
  margin-top: auto;
  height: 62px;
}
.zfont-sample {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 38px;
  color: #000000;
  overflow: hidden;
}

/* ============================================================================
 * AUTHENTIC ZONE DARK MODE (verbatim palette from ZoneServer/native/zlaunch/ztheme.h)
 *   Face #202020 | Window #000000 | Zebra #181818 | Active Caption #2A2A2A
 *   Inactive Caption #202020 | Text #E8E8E8 | GrayText #808080 | Hi #4A4A4A
 *   Light #343434 | Shadow #121212 | DarkShadow #080808 | Scroll #262626
 *   Select #0060C0 | UserInfo Border #686868
 * ============================================================================ */
body.ztheme-dark {
  --w98-face: #202020;
  --w98-light: #4A4A4A;
  --w98-dark: #121212;
  --w98-darker: #080808;
  --dm-face: #202020;
  --dm-window: #000000;
  --dm-zebra: #181818;
  --dm-cap-active: #2A2A2A;
  --dm-cap-inactive: #202020;
  --dm-cap-text: #F0F0F0;
  --dm-cap-inactive-text: #A0A0A0;
  --dm-text: #E8E8E8;
  --dm-graytext: #808080;
  --dm-hi: #4A4A4A;
  --dm-light: #343434;
  --dm-sh: #121212;
  --dm-dk: #080808;
  --dm-scroll: #262626;
  --dm-sel: #0060C0;
  --dm-userinfo-bg: #202020;
  --dm-userinfo-border: #686868;
}

body.ztheme-dark .zwin {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-light);
  border-left-color: var(--dm-light);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset 1px 1px 0 var(--dm-hi), inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zwin.zwin-frameless {
  border-top-color: var(--dm-light);
  border-left-color: var(--dm-light);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset 1px 1px 0 var(--dm-hi), inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zwin-titlebar {
  background: var(--dm-cap-inactive);
  color: var(--dm-cap-inactive-text);
}
body.ztheme-dark .zwin.active .zwin-titlebar {
  background: var(--dm-cap-active);
  color: var(--dm-cap-text);
}
body.ztheme-dark .zwin.zwin-flash-dim .zwin-titlebar,
body.ztheme-dark .zwin.active.zwin-flash-dim .zwin-titlebar {
  background: var(--dm-cap-inactive);
  color: var(--dm-cap-inactive-text);
}
body.ztheme-dark .zwin.zwin-frameless.zwin-flash-dim {
  outline: 2px solid #4A8FD9;
  outline-offset: -2px;
  box-shadow: inset 2px 2px 0 #6AAAF0, inset -2px -2px 0 #265694;
}
body.ztheme-dark .zwin-btn {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset 1px 1px 0 var(--dm-light), inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zwin-btn:active {
  border-top-color: var(--dm-dk);
  border-left-color: var(--dm-dk);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: inset 1px 1px 0 var(--dm-sh);
}
body.ztheme-dark .zw2k-net-dlg,
body.ztheme-dark .zw2k-tab,
body.ztheme-dark .zw2k-tab-body,
body.ztheme-dark .zw2k-props-dlg,
body.ztheme-dark .zwvol-tray-pop,
body.ztheme-dark .zwvol-mixer-dlg {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
}
body.ztheme-dark .zwvol-tray-hdr,
body.ztheme-dark .zwvol-col-title,
body.ztheme-dark .zwvol-bal-lbl,
body.ztheme-dark .zwvol-vol-lbl,
body.ztheme-dark .zwvol-adv-row {
  color: var(--dm-text);
}
body.ztheme-dark .zwvol-col {
  border-right-color: var(--dm-sh);
  box-shadow: inset -1px 0 0 var(--dm-hi);
}
body.ztheme-dark .zwvol-ticks,
body.ztheme-dark .zwvol-spk-ico {
  color: var(--dm-text);
}
body.ztheme-dark .zwvol-adv-row {
  border-top-color: var(--dm-sh);
  box-shadow: inset 0 1px 0 var(--dm-hi);
}
body.ztheme-dark .zwvol-vslider::-webkit-slider-runnable-track,
body.ztheme-dark .zwvol-bal-slider::-webkit-slider-runnable-track {
  background: var(--dm-window);
  border-top-color: var(--dm-dk);
  border-left-color: var(--dm-dk);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: none;
}
body.ztheme-dark .zwvol-vslider::-webkit-slider-thumb,
body.ztheme-dark .zwvol-bal-slider::-webkit-slider-thumb {
  background: var(--dm-face);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset 1px 1px 0 #5A5A5A, inset -1px -1px 0 #101010;
}
body.ztheme-dark .zw2k-act-hdr,
body.ztheme-dark .zw2k-act-lbl,
body.ztheme-dark .zw2k-sub-meta,
body.ztheme-dark .zw2k-props-desc {
  color: var(--dm-text);
}
body.ztheme-dark .zw2k-props-list {
  background: var(--dm-window);
  color: var(--dm-text);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
}
body.ztheme-dark .zwin-body {
  background: var(--dm-window);
}
body.ztheme-dark .zwin-menubar {
  background: var(--dm-face);
  color: var(--dm-text);
  border-bottom-color: var(--dm-sh);
}
body.ztheme-dark .zmenu-item {
  color: var(--dm-text);
}
body.ztheme-dark .zmenu-item:hover,
body.ztheme-dark .zmenu-item.open {
  background: var(--dm-sel);
  color: #FFFFFF;
}
body.ztheme-dark .zmenu-popup {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: 1px 1px 0 #000000;
}
body.ztheme-dark .zmenu-row {
  color: var(--dm-text);
}
body.ztheme-dark .zmenu-row:hover:not(:disabled) {
  background: var(--dm-sel);
  color: #FFFFFF;
}
body.ztheme-dark .zmenu-row.disabled,
body.ztheme-dark .zmenu-row:disabled {
  color: var(--dm-graytext);
  text-shadow: none;
}
body.ztheme-dark .zmenu-sep {
  background: var(--dm-sh);
  border-bottom-color: var(--dm-hi);
}
body.ztheme-dark .zwin-toolbar {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-bottom-color: var(--dm-sh);
}
body.ztheme-dark .ztool-sep {
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
}
body.ztheme-dark .ztool-btn {
  color: var(--dm-text);
}
body.ztheme-dark .ztool-btn:hover {
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-sh);
  border-bottom-color: var(--dm-sh);
}
body.ztheme-dark .ztool-btn.active {
  border-top-color: var(--dm-dk);
  border-left-color: var(--dm-dk);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  background: var(--dm-light);
}
body.ztheme-dark .zwin-statusbar {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-sh);
  box-shadow: inset 0 1px 0 var(--dm-hi);
}
body.ztheme-dark .zwin-statusbar.zf-statusbar {
  border-top: none;
  box-shadow: none;
}
body.ztheme-dark .zwin-sb-well {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: none;
}
body.ztheme-dark .zwin-statusbar.has-grip {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' shape-rendering='crispEdges'%3E%3Cpath d='M11 3L3 11M11 7L7 11M11 10L10 11' stroke='%23080808'/%3E%3Cpath d='M11 4L4 11M11 8L8 11' stroke='%234A4A4A'/%3E%3C/svg%3E");
}
body.ztheme-dark #taskbar {
  background: var(--dm-face);
  border-top-color: var(--dm-hi);
}
body.ztheme-dark .ztb-item {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .ztb-item.active {
  background: var(--dm-light);
  color: var(--dm-cap-text);
  border-top-color: var(--dm-dk);
  border-left-color: var(--dm-dk);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: inset 1px 1px 0 var(--dm-sh);
}
body.ztheme-dark .ztb-tray {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
}
body.ztheme-dark .zbtn {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zbtn:active {
  border-top-color: var(--dm-dk);
  border-left-color: var(--dm-dk);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: none;
}
body.ztheme-dark .zbtn:disabled {
  color: var(--dm-graytext);
  text-shadow: none;
}
body.ztheme-dark .zbtn:focus-visible {
  outline-color: var(--dm-text);
}
body.ztheme-dark .zbtn-default {
  box-shadow: inset -1px -1px 0 var(--dm-sh), 0 0 0 1px var(--dm-hi);
}
body.ztheme-dark .zwin-edit,
body.ztheme-dark .zwin select,
body.ztheme-dark .zadd-row input,
body.ztheme-dark .zedit-alert-ta,
body.ztheme-dark .zpriv-list,
body.ztheme-dark .zfont-list,
body.ztheme-dark .zlan-listbox {
  background: var(--dm-window);
  color: var(--dm-text);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: inset 1px 1px 0 var(--dm-dk);
}
body.ztheme-dark .zwin-edit:disabled {
  background: var(--dm-light);
  color: var(--dm-graytext);
}
body.ztheme-dark .zwin-edit[readonly] {
  background: var(--dm-scroll);
  color: var(--dm-text);
}
body.ztheme-dark .zwin-chk,
body.ztheme-dark .zwin-rad,
body.ztheme-dark .zwin-grp legend,
body.ztheme-dark .zadd-dlg,
body.ztheme-dark .zadd-hdr,
body.ztheme-dark .zpriv-dlg,
body.ztheme-dark .zprefs-dlg,
body.ztheme-dark .ztips-dlg,
body.ztheme-dark .zedit-alert-dlg,
body.ztheme-dark .zfont-dlg,
body.ztheme-dark .zfont-sample,
body.ztheme-dark .zlp-set-dlg,
body.ztheme-dark .zlp-set-row label,
body.ztheme-dark .zlp-pwd-dlg,
body.ztheme-dark .zlp-pwd-lbl,
body.ztheme-dark .zdyn-inv-dlg,
body.ztheme-dark .zabout-dlg,
body.ztheme-dark .zabout-line,
body.ztheme-dark .zalert-dlg,
body.ztheme-dark .zalert-text,
body.ztheme-dark .zlpad-wait-dlg,
body.ztheme-dark .zlpad-wait-msg,
body.ztheme-dark .zlan-dlg,
body.ztheme-dark .zlan-lead,
body.ztheme-dark .zlan-field label,
body.ztheme-dark .zlan-list-item,
body.ztheme-dark .zinst-dlg,
body.ztheme-dark .zinst-msg,
body.ztheme-dark .zinst-status,
body.ztheme-dark .zresume-dlg,
body.ztheme-dark .zresume-msg,
body.ztheme-dark .zsplash-dlg,
body.ztheme-dark .zsplash-status,
body.ztheme-dark .zgame-controls label {
  color: var(--dm-text);
}
body.ztheme-dark .zadd-dlg,
body.ztheme-dark .zpriv-dlg,
body.ztheme-dark .zprefs-dlg,
body.ztheme-dark .ztips-dlg,
body.ztheme-dark .zedit-alert-dlg,
body.ztheme-dark .zfont-dlg,
body.ztheme-dark .zlp-set-dlg,
body.ztheme-dark .zlp-pwd-dlg,
body.ztheme-dark .zdyn-inv-dlg,
body.ztheme-dark .zabout-dlg,
body.ztheme-dark .zalert-dlg,
body.ztheme-dark .zlpad-wait-dlg,
body.ztheme-dark .zlan-dlg,
body.ztheme-dark .zinst-dlg,
body.ztheme-dark .zresume-dlg,
body.ztheme-dark .zsplash-dlg,
body.ztheme-dark .zgame-controls,
body.ztheme-dark .zgame-chat-bar {
  background: var(--dm-face);
}
body.ztheme-dark .zinst-box {
  background: var(--dm-window);
  color: var(--dm-text);
  border-color: var(--dm-sh) var(--dm-hi) var(--dm-hi) var(--dm-sh);
}
body.ztheme-dark .zinst-box.dragover {
  outline-color: #66AAFF;
  background: #1A2A3E;
}
body.ztheme-dark .zinst-req { color: #88CCFF; }
body.ztheme-dark .zinst-status.err { color: #FF8888; }
body.ztheme-dark .zinst-status.ok { color: #66E088; }
body.ztheme-dark .zinst-cache-bar {
  background: var(--dm-window);
  color: var(--dm-text);
  border-color: var(--dm-sh) var(--dm-hi) var(--dm-hi) var(--dm-sh);
}
body.ztheme-dark .zinst-cache-txt { color: var(--dm-text); }
body.ztheme-dark .zinst-mgr-lead { color: var(--dm-text); }
body.ztheme-dark .zinst-mgr-list {
  background: var(--dm-window);
  color: var(--dm-text);
  border-color: var(--dm-sh) var(--dm-hi) var(--dm-hi) var(--dm-sh);
}
body.ztheme-dark .zinst-mgr-row { border-bottom-color: #2E323A; }
body.ztheme-dark .zinst-mgr-row.sel { background: #1B4E8A; color: #FFFFFF; }
body.ztheme-dark .zinst-mgr-badge { background: var(--dm-face); border-color: var(--dm-sh); color: var(--dm-text); }
body.ztheme-dark .zinst-mgr-meta { color: #A6B0BE; }
body.ztheme-dark .zinst-mgr-empty { color: #8D96A5; }
body.ztheme-dark .zinst-saves-list { background: #14171D; color: #E8ECF2; border-top-color: #101010; border-left-color: #101010; border-right-color: #444C58; border-bottom-color: #444C58; box-shadow: inset 1px 1px 0 #0B0D10; }
body.ztheme-dark .zinst-saves-row { border-bottom-color: #252B36; }
body.ztheme-dark .zinst-roam-chk { color: #E2E6EE; }
body.ztheme-dark .zinst-roam-stat { color: #A6B0BE; }
body.ztheme-dark .zwin-chk input[type="checkbox"] {
  background: #141414;
  border-top-color: #606060;
  border-left-color: #606060;
  border-right-color: #888888;
  border-bottom-color: #888888;
  box-shadow: inset 1px 1px 0 #080808;
}
body.ztheme-dark .zwin-chk input[type="checkbox"]:checked::after {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='7' shape-rendering='crispEdges'%3E%3Cpath d='M0 3h1v1h1v1h1V4h1V3h1V2h1V1h1v2H6v1H5v1H4v1H3v1H2V6H1V5H0z' fill='%23E8E8E8'/%3E%3C/svg%3E");
}
body.ztheme-dark .zwin-rad input[type="radio"] {
  background: var(--dm-window);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: inset 1px 1px 0 var(--dm-dk);
}
body.ztheme-dark .zwin-rad input[type="radio"]:disabled {
  background: var(--dm-light);
}
body.ztheme-dark .zwin-rad input[type="radio"]:checked::after {
  background: var(--dm-text);
}
body.ztheme-dark .zwin-rad input[type="radio"]:disabled:checked::after {
  background: var(--dm-graytext);
}
body.ztheme-dark .zw2k-tab {
  border-bottom-color: var(--dm-hi);
}
body.ztheme-dark .zw2k-tab.active {
  border-bottom-color: var(--dm-face);
}
body.ztheme-dark .zwin-grp {
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: inset 1px 1px 0 var(--dm-hi), inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zpriv-list-row.sel,
body.ztheme-dark .zlan-list-item.selected,
body.ztheme-dark .zc-roster-row:hover {
  background: var(--dm-sel);
  color: #FFFFFF;
}
body.ztheme-dark .zwin-vsplit {
  background: var(--dm-face);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
}
body.ztheme-dark .zwin-hsplit {
  background: var(--dm-face);
  border-top-color: var(--dm-hi);
  border-bottom-color: var(--dm-dk);
}
body.ztheme-dark .zclient-body,
body.ztheme-dark .zclient-left,
body.ztheme-dark .clob-middle {
  background: var(--dm-face);
}
body.ztheme-dark .zclient-floor,
body.ztheme-dark .zclient-list-floor,
body.ztheme-dark .zclient-left .zroom-chat-pane,
body.ztheme-dark .clob-sidebar.zc-sidebar {
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
}
body.ztheme-dark .zroom-chat-pane,
body.ztheme-dark .zchat-main-left,
body.ztheme-dark .zchat-log,
body.ztheme-dark .zchat-form,
body.ztheme-dark .zchat-form input,
body.ztheme-dark .zchat-form-lobby .zchat-input,
body.ztheme-dark .lpad-chat-box {
  background: var(--dm-window);
  color: var(--dm-text);
  border-color: var(--dm-light);
}
body.ztheme-dark .zchat-form.classic input::placeholder {
  color: var(--dm-graytext);
}
body.ztheme-dark .zchat-line-who,
body.ztheme-dark .zchat-line-sys,
body.ztheme-dark .zchat-line-sysop {
  color: var(--dm-text);
}
body.ztheme-dark .zchat-ts {
  color: var(--dm-graytext);
}
body.ztheme-dark .zchat-link {
  color: #7CC4FF;
}
body.ztheme-dark .zchat-link:hover {
  color: #B4DEFF;
}
body.ztheme-dark .zc-roster-colhdr {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zc-colhdr-btn,
body.ztheme-dark .zc-colhdr-sep {
  color: var(--dm-text);
}
body.ztheme-dark .zclient-list-floor,
body.ztheme-dark .zc-list-tbl {
  background: var(--dm-window);
  color: var(--dm-text);
}
body.ztheme-dark .zc-list-tbl thead th {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-sh);
  border-bottom-color: var(--dm-sh);
}
body.ztheme-dark .zc-list-tbl tbody tr {
  background: var(--dm-window);
  color: var(--dm-text);
}
body.ztheme-dark .zc-list-tbl tbody tr:nth-child(even) {
  background: var(--dm-zebra);
}
body.ztheme-dark .zc-list-tbl td,
body.ztheme-dark .zc-list-tbl td.zc-lv-num {
  color: var(--dm-text);
  border-top-color: var(--dm-light);
}
body.ztheme-dark .zc-list-tbl .zc-lock-ico,
body.ztheme-dark .zc-list-tbl .zc-lock-hdr-ico {
  filter: invert(1) brightness(1.2);
}
body.ztheme-dark .zc-user-info {
  background: var(--dm-userinfo-bg);
  color: var(--dm-text);
  border-color: var(--dm-userinfo-border);
}
body.ztheme-dark .zc-ui-name,
body.ztheme-dark .zc-ui-line {
  color: var(--dm-text);
}
body.ztheme-dark .zwin *::-webkit-scrollbar-track,
body.ztheme-dark .zclient-floor::-webkit-scrollbar-track,
body.ztheme-dark .zclient-list-floor::-webkit-scrollbar-track,
body.ztheme-dark .zchat-log::-webkit-scrollbar-track,
body.ztheme-dark .clob-floor::-webkit-scrollbar-track,
body.ztheme-dark .clob-roster-list::-webkit-scrollbar-track,
body.ztheme-dark .lpad-right::-webkit-scrollbar-track,
body.ztheme-dark .zlan-listbox::-webkit-scrollbar-track {
  background: var(--dm-scroll);
}
body.ztheme-dark .zwin *::-webkit-scrollbar-thumb,
body.ztheme-dark .zclient-floor::-webkit-scrollbar-thumb,
body.ztheme-dark .zclient-list-floor::-webkit-scrollbar-thumb,
body.ztheme-dark .zchat-log::-webkit-scrollbar-thumb,
body.ztheme-dark .clob-floor::-webkit-scrollbar-thumb,
body.ztheme-dark .clob-roster-list::-webkit-scrollbar-thumb,
body.ztheme-dark .lpad-right::-webkit-scrollbar-thumb,
body.ztheme-dark .zlan-listbox::-webkit-scrollbar-thumb {
  background: var(--dm-face);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset 1px 1px 0 var(--dm-light), inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zwin *::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zwin *::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .zwin *::-webkit-scrollbar-button:horizontal:start:decrement,
body.ztheme-dark .zwin *::-webkit-scrollbar-button:horizontal:end:increment,
body.ztheme-dark .zclient-floor::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zclient-list-floor::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zchat-log::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .clob-floor::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .clob-roster-list::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .lpad-right::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zlan-listbox::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zclient-floor::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .zclient-list-floor::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .zchat-log::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .clob-floor::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .clob-roster-list::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .lpad-right::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .zlan-listbox::-webkit-scrollbar-button:vertical:end:increment {
  background-color: var(--dm-face);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset 1px 1px 0 var(--dm-light), inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zwin *::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zclient-floor::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zclient-list-floor::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zchat-log::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .clob-floor::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .clob-roster-list::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .lpad-right::-webkit-scrollbar-button:vertical:start:decrement,
body.ztheme-dark .zlan-listbox::-webkit-scrollbar-button:vertical:start:decrement {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='4' shape-rendering='crispEdges'%3E%3Cpath d='M3 0h1v1H2v1H1v1H0v1h7V3H6V2H5V1H4z' fill='%23E8E8E8'/%3E%3C/svg%3E");
}
body.ztheme-dark .zwin *::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .zclient-floor::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .zclient-list-floor::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .zchat-log::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .clob-floor::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .clob-roster-list::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .lpad-right::-webkit-scrollbar-button:vertical:end:increment,
body.ztheme-dark .zlan-listbox::-webkit-scrollbar-button:vertical:end:increment {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='4' shape-rendering='crispEdges'%3E%3Cpath d='M0 0h7v1H6v1H5v1H4v1H3V3H2V2H1V1H0z' fill='%23E8E8E8'/%3E%3C/svg%3E");
}
body.ztheme-dark .zwin *::-webkit-scrollbar-corner,
body.ztheme-dark .zclient-floor::-webkit-scrollbar-corner,
body.ztheme-dark .zclient-list-floor::-webkit-scrollbar-corner,
body.ztheme-dark .zchat-log::-webkit-scrollbar-corner,
body.ztheme-dark .clob-floor::-webkit-scrollbar-corner,
body.ztheme-dark .clob-roster-list::-webkit-scrollbar-corner,
body.ztheme-dark .lpad-right::-webkit-scrollbar-corner,
body.ztheme-dark .zlan-listbox::-webkit-scrollbar-corner {
  background: var(--dm-face);
}

@media (max-width: 1120px) {
  .igz-banner-wrap img.igz-ad-banner { width: 390px; height: 50px; }
}

@media (max-width: 860px) {
  .igz-banner-wrap img.igz-ad-banner { width: 300px; height: 38px; }
  .igz-promo-wrap img { height: 22px; }
}

@media (max-width: 680px) {
  .igz-banner-wrap { display: none; }
}

@media (max-width: 720px) {
  body:not(.zmobile-landscape) .portal-page { grid-template-columns: 1fr; }
  body:not(.zmobile-landscape) .portal-sidebar { display: none; }
  body:not(.zmobile-landscape) .clob-middle { grid-template-columns: 1fr; }
  body:not(.zmobile-landscape) .clob-sidebar { display: none; }
  body:not(.zmobile-landscape) .zclient-body {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(0, 1fr) auto;
  }
  body:not(.zmobile-landscape) .zclient-body .clob-sidebar.zc-sidebar {
    display: flex;
    width: 100% !important;
    min-width: 0 !important;
    max-height: 112px;
  }
  body:not(.zmobile-landscape) .zwin {
    max-width: calc(100vw - 4px);
    max-height: calc(100dvh - 34px - env(safe-area-inset-bottom, 0px));
  }
  .zwin-titlebar { touch-action: none; }
  body:not(.zmobile-landscape) #taskbar {
    height: auto;
    min-height: 28px;
    padding-bottom: calc(2px + env(safe-area-inset-bottom, 0px));
  }
  body:not(.zmobile-landscape) .ztb-windows {
    flex: 1 1 0;
    min-width: 0;
    overflow: hidden;
  }
  body:not(.zmobile-landscape) .ztb-item {
    flex: 1 1 0;
    min-width: 36px;
    max-width: 132px;
    padding: 0 4px 0 3px;
  }
  body:not(.zmobile-landscape) .zc-split-top { flex-direction: column; }
  body:not(.zmobile-landscape) .lpad-shell { grid-template-columns: 1fr; }
  body:not(.zmobile-landscape) .lpad-desc-box {
    height: 42px;
    margin: 4px 8px 4px 12px;
    font-size: 12px;
  }
  body:not(.zmobile-landscape) .lpad-chat-box { margin: 4px 8px 6px 12px; }
  body:not(.zmobile-landscape) .lpad-btn-row { padding-left: 8px; flex-wrap: wrap; }
  body:not(.zmobile-landscape) .zc-roster-col,
  body:not(.zmobile-landscape) .lpad-right {
    width: 100% !important;
    min-width: 0 !important;
    max-height: 120px;
  }
  body:not(.zmobile-landscape) .zwin-vsplit,
  body:not(.zmobile-landscape) .lpad-vsplit { display: none; }
  body:not(.zmobile-landscape) .zgame-stage { min-height: 0; flex: 0 0 auto; overflow: hidden; }
  body:not(.zmobile-landscape) .zgame-canvas {
    width: 100%;
    height: auto;
    max-width: 100%;
    max-height: calc(100dvh - 170px);
    object-fit: contain;
    touch-action: manipulation;
  }
  body:not(.zmobile-landscape) .zgame-chat-bar { height: 74px; }
  .zchat-input { min-height: 26px; touch-action: manipulation; }
}

/* True Native Mobile Landscape Mode + Win98 Switch-to-Landscape Prompt */
body.zmobile-landscape .zwin {
  max-width: calc(100% - 4px);
  max-height: calc(100% - 4px);
}
body.zmobile-landscape #taskbar {
  height: 28px;
  min-height: 28px;
  padding-left: calc(4px + env(safe-area-inset-left, 0px));
  padding-right: calc(4px + env(safe-area-inset-right, 0px));
  padding-bottom: calc(2px + env(safe-area-inset-bottom, 0px));
}
body.zmobile-landscape .ztb-windows {
  flex: 1 1 0;
  min-width: 0;
  overflow: hidden;
}
body.zmobile-landscape .ztb-item {
  flex: 1 1 0;
  min-width: 44px;
  max-width: 150px;
  padding: 0 5px 0 3px;
}
body.zmobile-landscape .zgame-stage {
  min-height: 0;
  overflow: hidden;
}
body.zmobile-landscape .zgame-canvas {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  touch-action: manipulation;
}
body.zmobile-landscape .zgame-chat-bar {
  height: 62px;
}

/* Clamped windows on short/narrow mobile viewports (e.g. virtual keyboard open) stay scrollable
 * so dialog buttons and controls are never clipped off-screen. */
.zwin.zwin-clamped .zwin-body {
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x pan-y;
  overscroll-behavior: contain;
}

/* Compact responsive Sign In layout ONLY when the Sign In window is clamped below its
 * natural 420x233 size (e.g. narrow portrait phone or short landscape with keyboard up).
 * Desktop and full-size landscape stay 100% pixel-exact 414x208 ZPASSPC.DLL DLG 500. */
.zwin.zwin-clamped .zzpa-dlg {
  width: 100%;
  height: auto;
  min-height: 100%;
  padding: 6px 8px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 5px 6px;
  align-items: center;
  background: linear-gradient(115deg, #000000 0%, #062834 48%, #2E5E5E 100%);
  background-image: linear-gradient(115deg, #000000 0%, #062834 48%, #2E5E5E 100%);
  overflow: visible;
}
.zwin.zwin-clamped .zzpa-lbl,
.zwin.zwin-clamped .zzpa-in,
.zwin.zwin-clamped .zzpa-chk,
.zwin.zwin-clamped .zzpa-btn {
  position: static;
  left: auto;
  top: auto;
}
.zwin.zwin-clamped .zzpa-lbl-user {
  grid-column: 1 / 2;
  grid-row: 1;
  width: auto;
}
.zwin.zwin-clamped .zzpa-in-user {
  grid-column: 2 / 5;
  grid-row: 1;
  width: 100%;
  min-width: 0;
  height: 24px;
  font-size: 13px;
}
.zwin.zwin-clamped .zzpa-lbl-pass {
  grid-column: 1 / 2;
  grid-row: 2;
  width: auto;
}
.zwin.zwin-clamped .zzpa-in-pass {
  grid-column: 2 / 5;
  grid-row: 2;
  width: 100%;
  min-width: 0;
  height: 24px;
  font-size: 13px;
}
.zwin.zwin-clamped .zzpa-chk {
  grid-column: 2 / 5;
  grid-row: 3;
}
.zwin.zwin-clamped .zzpa-btn {
  grid-row: 4;
  width: 100%;
  min-width: 0;
  height: 24px;
  min-height: 24px;
  padding: 0 4px;
}
.zwin.zwin-clamped .zzpa-ok { grid-column: 1 / 2; }
.zwin.zwin-clamped .zzpa-signup { grid-column: 2 / 3; }
.zwin.zwin-clamped .zzpa-cancel { grid-column: 3 / 4; }
.zwin.zwin-clamped .zzpa-help { grid-column: 4 / 5; }

/* Give active inputs/dialogs maximum vertical room when mobile keyboard shrinks a landscape screen */
@media (max-height: 300px) {
  body.zmobile-kb-open #taskbar {
    display: none;
  }
  body.zmobile-kb-open .clob-banner,
  body.zmobile-kb-open .zroom-banner {
    display: none;
  }
}

/* Keep lobby/launchpad chat & action buttons reachable on short mobile landscape screens */
@media (max-height: 460px) {
  body.zmobile-landscape .zroom-banner {
    height: 36px;
  }
  body.zmobile-landscape .zroom-banner-logo {
    height: 36px;
    width: auto;
  }
  body.zmobile-landscape .zroom-banner-ad {
    height: 36px;
    width: auto;
    max-width: calc(100% - 84px);
  }
  body.zmobile-landscape .zc-chat-pane,
  body.zmobile-landscape .clob-chat-pane {
    min-height: 82px;
  }
  body.zmobile-landscape .lpad-left {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 4px;
  }
  body.zmobile-landscape .lpad-desc-box {
    height: 34px;
    margin: 2px 8px 2px 24px;
    font-size: 12px;
  }
  body.zmobile-landscape .lpad-chat-box {
    margin: 2px 8px 4px 24px;
  }
  body.zmobile-landscape .lpad-btn-row {
    padding-left: 24px;
  }
}

.ztb-land-ico {
  display: none;
  width: 20px;
  height: 18px;
  align-items: center;
  justify-content: center;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 14px 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Crect x='2' y='4' width='12' height='8' rx='1' fill='%23ffffff' stroke='%23000080' stroke-width='1.5'/%3E%3Crect x='4' y='6' width='8' height='4' fill='%23008080'/%3E%3Cpath d='M12 2l2 2h-4z' fill='%23000080'/%3E%3C/svg%3E");
}
body.zmobile-portrait .ztb-land-ico {
  display: inline-flex;
}

.zland-overlay {
  position: fixed;
  inset: 0;
  z-index: 99990;
  background: rgba(0, 51, 51, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.zland-dlg {
  width: min(336px, calc(100vw - 24px));
  background: #C0C0C0;
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  border-top: 2px solid #FFFFFF;
  border-left: 2px solid #FFFFFF;
  border-right: 2px solid #404040;
  border-bottom: 2px solid #404040;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.45);
}
.zland-titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(90deg, #000080, #1084D0);
  color: #FFFFFF;
  font-weight: bold;
  font-size: 11px;
  padding: 3px 4px 3px 6px;
  user-select: none;
}
.zland-close {
  width: 16px;
  height: 14px;
  padding: 0;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #404040;
  border-bottom: 1px solid #404040;
  background: #C0C0C0;
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 10px;
  font-weight: bold;
  line-height: 12px;
  cursor: pointer;
}
.zland-body {
  display: flex;
  gap: 12px;
  padding: 14px 14px 10px;
  align-items: flex-start;
}
.zland-ico {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
}
.zland-copy {
  flex: 1 1 auto;
  min-width: 0;
  line-height: 1.45;
}
.zland-heading {
  font-weight: bold;
  margin: 0 0 5px;
  color: #000080;
}
.zland-text {
  margin: 0;
}
.zland-status {
  margin: 6px 0 0;
  color: #800000;
  font-size: 10px;
  min-height: 13px;
}
.zland-btns {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 4px 14px 12px;
  flex-wrap: wrap;
}

@media (pointer: coarse) and (max-width: 900px) {
  .ztb-item { min-height: 28px; }
  .zmenu-btn { padding: 4px 8px; }
  .zmenu-item { min-height: 28px; padding: 4px 10px; }
  .zmenu-row { min-height: 30px; padding: 4px 12px 4px 4px; }
  .zwin-titlebar { min-height: 24px; }
  .zwin-btn,
  .zwin-capbtn { width: 22px; height: 20px; }
  .zwin-resize { width: 10px; height: 10px; }
  .zwin-resize-n, .zwin-resize-s { width: auto; height: 10px; }
  .zwin-resize-e, .zwin-resize-w { width: 10px; height: auto; }
  .zwin-switcher { max-width: calc(100vw - 16px); }
  .clob-kibitz-tag { min-height: 18px; padding: 1px 5px; font-size: 10px; }
  .zbtn { min-height: 28px; touch-action: manipulation; }
  .zchat-input { min-height: 28px; font-size: 13px; }
}

/* ============================================================================
 * AUTHENTIC WIN98 CLASSIC IN-GAME MODAL DIALOGS (Score, Last Trick, Options, Info)
 * + Unified Touch / Pointer Ergonomics across desktop & mobile
 * ============================================================================ */
.zwin-titlebar,
.zwin-resize,
.zwin-vsplit,
.zwin-hsplit,
.lpad-vsplit {
  touch-action: none;
}

.zgdlg-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px;
  background: var(--w98-face);
  color: #000000;
  font-family: Tahoma, Arial, sans-serif;
  font-size: 11px;
  flex: 1;
  overflow: hidden;
}

.zgdlg-heading {
  font-weight: bold;
  font-size: 12px;
  color: #000080;
  padding-bottom: 2px;
  border-bottom: 1px solid #808080;
}

.zgdlg-table-wrap {
  flex: 1;
  min-height: 76px;
  overflow-y: auto;
  background: #FFFFFF;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}

.zgdlg-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

.zgdlg-table th {
  position: sticky;
  top: 0;
  background: var(--w98-face);
  color: #000000;
  font-weight: bold;
  text-align: center;
  padding: 2px 5px;
  border-right: 1px solid #808080;
  border-bottom: 1px solid #808080;
}

.zgdlg-table td {
  padding: 2px 6px;
  text-align: center;
  border-bottom: 1px solid #E4E4E0;
  border-right: 1px solid #EFEFEA;
}

.zgdlg-table tr.zgdlg-total-row td {
  font-weight: bold;
  background: #FFFFCC;
  border-top: 1px solid #808080;
}

.zgdlg-table td.zgdlg-empty {
  color: #555555;
  padding: 12px 6px;
}

.zgdlg-trick-canvas {
  display: block;
  margin: 0 auto;
  image-rendering: pixelated;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}

.zgdlg-group {
  border: 1px solid #808080;
  box-shadow: inset 1px 1px 0 #FFFFFF;
  padding: 6px 10px 8px;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.zgdlg-group legend {
  padding: 0 4px;
  font-weight: bold;
}

.zgdlg-check {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  user-select: none;
}

.zgdlg-info,
.zgdlg-kv-box {
  background: #FFFFFF;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.zgdlg-kv-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.zgdlg-kv-k {
  color: #404040;
}

.zgdlg-kv-v {
  font-weight: bold;
  text-align: right;
}

.zgdlg-note {
  color: #202020;
  text-align: center;
  font-size: 11px;
}

.zgdlg-btns {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  margin-top: auto;
  padding-top: 2px;
}

body.ztheme-dark .zgdlg-body {
  background: var(--dm-face);
  color: var(--dm-text);
}
body.ztheme-dark .zgdlg-heading {
  color: #99CCFF;
}
body.ztheme-dark .zgdlg-table-wrap,
body.ztheme-dark .zgdlg-info,
body.ztheme-dark .zgdlg-kv-box {
  background: var(--dm-input);
  color: var(--dm-text);
}
body.ztheme-dark .zgdlg-table th {
  background: var(--dm-face);
  color: var(--dm-text);
}
body.ztheme-dark .zgdlg-table tr.zgdlg-total-row td {
  background: #3A3518;
  color: #FFF4B8;
}
body.ztheme-dark .zgdlg-note,
body.ztheme-dark .zgdlg-kv-k {
  color: var(--dm-muted);
}

/* ============================================================================
 * AUTHENTIC WIN32 / WINDOWS 98 NATIVE FEEL POLISH
 * Default arrow cursors on chrome, pale-yellow tooltips, 4px wireframe drag,
 * 32x32 Alt+` / Ctrl+F6 task switcher, live tray clock, universal Win98
 * checkboxes/radios, #000080 selection, and inactive list dimming.
 * ============================================================================ */

/* 1. Native Win32 arrow cursor on all window chrome, controls, menus, and taskbar
 *    (hyperlinks keep pointer, inputs keep text I-beam, borders keep resize cursors) */
.zwin,
#taskbar,
.zwin button,
.zwin label,
.zwin select,
.ztool-btn,
.ztb-item,
.ztb-tray,
.ztb-tray-ico,
.ztb-clock,
.zbtn-lp-sprite,
.zbtn-lp-pill,
.zbtn-send-pill,
.zbtn-zm,
.zw2k-tab,
.zwin-chk,
.zwin-rad,
.zzpa-chk,
.zf-buddy-row,
.zc-colhdr-btn,
.zinst-mgr-row,
.zlan-list-item,
.zpriv-list-row,
.zfont-item,
.zwin-sysico {
  cursor: default;
}
.zwin a[href] {
  cursor: pointer;
}
.zwin input[type="text"],
.zwin input[type="password"],
.zwin input[type="search"],
.zwin input[type="number"],
.zwin textarea {
  cursor: text;
}

/* 2. Win32 non-selectable chrome + selectable text surfaces with #000080 selection */
.zwin,
#taskbar,
.zwin-menubar,
.zwin-toolbar,
.zwin-statusbar {
  user-select: none;
}
.zwin input,
.zwin textarea,
.zchat-log,
.zchat-log *,
.zcurve-msg-gold,
.zabout-line,
.zalert-text {
  user-select: text;
}
.zwin ::selection {
  background: #000080;
  color: #FFFFFF;
}
.zwin:not(.active) ::selection {
  background: #808080;
  color: #FFFFFF;
}

/* 3. Universal Win98 13x13 checkboxes and 12x12 radios inside every .zwin */
.zwin input[type="checkbox"] {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
  width: 13px;
  height: 13px;
  background: #FFFFFF;
  border-radius: 0;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  position: relative;
  cursor: default;
  flex-shrink: 0;
  vertical-align: middle;
}
.zwin input[type="checkbox"]:active:not(:disabled) {
  background: #D4D0C8;
}
.zwin input[type="checkbox"]:disabled {
  background: #D4D0C8;
}
.zwin input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 2px;
  top: 1px;
  width: 7px;
  height: 7px;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='7' shape-rendering='crispEdges'%3E%3Cpath d='M0 3h1v1h1v1h1V4h1V3h1V2h1V1h1v2H6v1H5v1H4v1H3v1H2V6H1V5H0z' fill='%23000'/%3E%3C/svg%3E") no-repeat center;
}
.zwin input[type="checkbox"]:disabled:checked::after {
  opacity: 0.45;
}
.zwin input[type="radio"] {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #FFFFFF;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040, inset -1px -1px 0 #DFDFDF;
  position: relative;
  cursor: default;
  flex-shrink: 0;
  vertical-align: middle;
}
.zwin input[type="radio"]:active:not(:disabled),
.zwin input[type="radio"]:disabled {
  background: #D4D0C8;
}
.zwin input[type="radio"]:checked::after {
  content: "";
  position: absolute;
  left: 3px;
  top: 3px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #000000;
}
.zwin input[type="radio"]:disabled:checked::after {
  background: #808080;
}

/* 4. Inactive list/tree selection dimming (LVS_SHOWSELALWAYS) */
.zwin:not(.active) .zf-buddy-row.selected,
.zwin:not(.active) .zpriv-list-row.sel,
.zwin:not(.active) .zlan-list-item.selected,
.zwin:not(.active) .zinst-mgr-row.sel,
.zwin:not(.active) .zfont-item.sel {
  background: #D4D0C8;
  color: #000000;
}

/* 5. Background window titlebar alert pulse (FlashWindowEx) */
@keyframes zwinBgAlertPulse {
  0%, 100% { background: linear-gradient(90deg, #808080, #B5B5B5); color: #D4D0C8; }
  50% { background: linear-gradient(90deg, #000080, #1084D0); color: #FFFFFF; }
}
.zwin.zwin-bg-alert:not(.active) .zwin-titlebar {
  animation: zwinBgAlertPulse 0.9s steps(2, start) infinite;
}

/* 6. Live sunken Win98 taskbar tray clock */
.ztb-clock {
  display: inline-flex;
  align-items: center;
  padding: 0 5px 0 4px;
  height: 18px;
  font-family: Tahoma, "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  color: #000000;
  white-space: nowrap;
  flex-shrink: 0;
}

/* 7. Authentic Win98 pale-yellow tooltip (#FFFFE1) */
.zwin-tooltip {
  position: fixed;
  z-index: 100000;
  max-width: 300px;
  background: #FFFFE1;
  color: #000000;
  border: 1px solid #000000;
  box-shadow: 1px 1px 0 rgba(0, 0, 0, 0.28);
  padding: 2px 5px;
  font-family: Tahoma, "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  line-height: 1.3;
  white-space: pre-line;
  pointer-events: none;
  user-select: none;
}

/* 8. Authentic Win98 4px dithered wireframe drag/resize outline */
.zwin-wireframe {
  position: fixed;
  z-index: 99995;
  pointer-events: none;
  box-sizing: border-box;
}
.zwin-wf-t, .zwin-wf-b, .zwin-wf-l, .zwin-wf-r {
  position: absolute;
  background: repeating-conic-gradient(#000000 0% 25%, #FFFFFF 0% 50%) 0 0 / 2px 2px;
  mix-blend-mode: difference;
}
.zwin-wf-t { top: 0; left: 0; right: 0; height: 4px; }
.zwin-wf-b { bottom: 0; left: 0; right: 0; height: 4px; }
.zwin-wf-l { top: 4px; bottom: 4px; left: 0; width: 4px; }
.zwin-wf-r { top: 4px; bottom: 4px; right: 0; width: 4px; }

/* 9. Classic Win98 32x32 Icon Task Switcher (Alt+` / Ctrl+F6) */
.zwin-switcher {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 99998;
  min-width: 240px;
  max-width: 460px;
  background: var(--w98-face);
  color: #000000;
  padding: 10px 12px 9px;
  border-top: 1px solid #DFDFDF;
  border-left: 1px solid #DFDFDF;
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #FFFFFF, inset -1px -1px 0 #808080, 2px 2px 0 rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: Tahoma, "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zwin-sw-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}
.zwin-sw-tile {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid transparent;
  cursor: default;
}
.zwin-sw-tile img {
  width: 32px;
  height: 32px;
  image-rendering: pixelated;
  display: block;
}
.zwin-sw-tile.active {
  border-color: #000080;
}
.zwin-sw-title {
  background: var(--w98-face);
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  padding: 3px 6px;
  font-weight: bold;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Dark mode variants for new Win32 components */
body.ztheme-dark .zbtn:focus,
body.ztheme-dark .zbtn:focus-visible {
  outline-color: var(--dm-text);
}
body.ztheme-dark .zbtn-default:active:not(:disabled),
body.ztheme-dark .zbtn-default.zbtn-kbd-active:not(:disabled) {
  box-shadow: 0 0 0 1px var(--dm-hi);
}
body.ztheme-dark .zmenu-item {
  color: var(--dm-text);
}
body.ztheme-dark .zmenu-item:hover:not(.open):not(.armed) {
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-sh);
  border-bottom-color: var(--dm-sh);
}
body.ztheme-dark .zmenu-item.open {
  color: var(--dm-text);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
}
body.ztheme-dark .zmenu-item.armed,
body.ztheme-dark .zmenu-row:focus:not(:disabled) {
  background: var(--dm-sel);
  color: #FFFFFF;
}
body.ztheme-dark .zwin ::selection {
  background: var(--dm-sel);
  color: #FFFFFF;
}
body.ztheme-dark .zwin:not(.active) ::selection {
  background: #484E5A;
  color: #FFFFFF;
}
body.ztheme-dark .zwin input[type="checkbox"] {
  background: #141414;
  border-top-color: #606060;
  border-left-color: #606060;
  border-right-color: #888888;
  border-bottom-color: #888888;
  box-shadow: inset 1px 1px 0 #080808;
}
body.ztheme-dark .zwin input[type="checkbox"]:active:not(:disabled),
body.ztheme-dark .zwin input[type="checkbox"]:disabled {
  background: var(--dm-light);
}
body.ztheme-dark .zwin input[type="checkbox"]:checked::after {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='7' shape-rendering='crispEdges'%3E%3Cpath d='M0 3h1v1h1v1h1V4h1V3h1V2h1V1h1v2H6v1H5v1H4v1H3v1H2V6H1V5H0z' fill='%23E8E8E8'/%3E%3C/svg%3E");
}
body.ztheme-dark .zwin input[type="radio"] {
  background: var(--dm-window);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: inset 1px 1px 0 var(--dm-dk);
}
body.ztheme-dark .zwin input[type="radio"]:active:not(:disabled),
body.ztheme-dark .zwin input[type="radio"]:disabled {
  background: var(--dm-light);
}
body.ztheme-dark .zwin input[type="radio"]:checked::after {
  background: var(--dm-text);
}
body.ztheme-dark .zwin:not(.active) .zf-buddy-row.selected,
body.ztheme-dark .zwin:not(.active) .zpriv-list-row.sel,
body.ztheme-dark .zwin:not(.active) .zlan-list-item.selected,
body.ztheme-dark .zwin:not(.active) .zinst-mgr-row.sel,
body.ztheme-dark .zwin:not(.active) .zfont-item.sel {
  background: #3A3F4A;
  color: #E0E4EC;
}
body.ztheme-dark .ztb-clock {
  color: var(--dm-text);
}
body.ztheme-dark .zwin-tooltip {
  background: #2C2A1E;
  color: #F4F0D0;
  border-color: #888268;
}
body.ztheme-dark .zwin-switcher {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset 1px 1px 0 var(--dm-light), inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zwin-sw-tile.active {
  border-color: #5FA4F8;
}
body.ztheme-dark .zwin-sw-title {
  background: var(--dm-window);
  color: var(--dm-text);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
}

/* ---- TV / Console Display Mode (Xbox Edge & Smart TVs) + Gamepad Shell Pointer ---- */
body.ztv-mode {
  background: #000000;
  overscroll-behavior: none;
}
body.ztv-mode #app-shell {
  box-shadow: 0 0 0 1px #1a1a1a;
}
body.ztv-mode :focus-visible {
  outline: 2px solid #FFCC00;
  outline-offset: 1px;
}
body.ztv-mode .zmenu-row:focus:not(:disabled) {
  outline: none;
}

.zgp-cursor {
  position: fixed;
  left: 0;
  top: 0;
  width: 16px;
  height: 22px;
  z-index: 100005;
  pointer-events: none;
  user-select: none;
  transform: translate(-1px, -1px);
  filter: drop-shadow(1px 1px 0 rgba(0, 0, 0, 0.55));
}
.zgp-cursor svg {
  display: block;
  width: 16px;
  height: 22px;
}

/* ---- Classic Windows 98 Mouse Cursors (Desktop & Portal Chrome) ---- */
html,
body,
#app-shell,
.zwin,
.zwin-titlebar,
.zwin-menubar,
.zmenu-btn,
.zmenu-item,
.zmenu-row,
#taskbar,
.ztb-item,
.ztb-tray-ico,
.zbtn,
.zwin-capbtn,
.zwin-btn,
button,
select,
label,
button:disabled,
.zbtn:disabled,
.zbtn-lp-sprite:disabled,
.zbtn-lp-pill:disabled,
.zbtn-send-pill:disabled,
.zbtn-zm:disabled,
.zc-info-tag:disabled {
  cursor: var(--w98-cur-arrow);
}

a[href],
a[href] *,
.zchat-link,
.zroom-chair,
.zbtn-lp-sprite:not(:disabled),
.zbtn-lp-pill:not(:disabled),
.zbtn-send-pill:not(:disabled),
.zc-info-tag:not(:disabled),
.clob-kibitz-tag,
.zgame-canvas {
  cursor: var(--w98-cur-hand);
}

input[type="text"],
input[type="password"],
input[type="search"],
input[type="email"],
input:not([type]),
textarea,
.zchat-input,
.zchat-log {
  cursor: var(--w98-cur-ibeam);
}

.zwin-resize-w,
.zwin-resize-e,
.zwin-vsplit {
  cursor: var(--w98-cur-ew);
}
/* CommonRes cursor 1192 (hotspot 9,9): the client's splitter cursor, a bar with a left and a
 * right arrow. It is also what the List View heading shows over its two sizable dividers. */
.lpad-vsplit,
.zc-lv-grip {
  cursor: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAgklEQVR42u2VwQ7AIAhDqfH/f7k7LXEkbuAwXvpuEoIlVIS9QJLjGQCsmPaVAMA23BsXsBsJaN503ngzc0byUgJIMmM2AFYhAv5yXzMS//M8ke18MpJlEcdNeHwEfu0+3H3HZvEKE7Zxz2fqVXXeVz6byk9Jq/i4gB4xmxBCCCF2cgE1GmICT416ZAAAAABJRU5ErkJggg==") 9 9, ew-resize;
}

.zwin-resize-n,
.zwin-resize-s,
.zwin-hsplit {
  cursor: var(--w98-cur-ns);
}

.zwin-resize-nw,
.zwin-resize-se {
  cursor: var(--w98-cur-nwse);
}

.zwin-resize-ne,
.zwin-resize-sw {
  cursor: var(--w98-cur-nesw);
}

/* ---- Toggleable Mobile Win98 Virtual Touch Mouse Cursor ---- */
.ztb-tray-ico.ztb-mouse-ico {
  display: none;
  width: 20px;
  height: 18px;
  align-items: center;
  justify-content: center;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 13px 15px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='18' viewBox='0 0 16 18' shape-rendering='crispEdges'%3E%3Cpolygon points='2,1 2,14 5.5,10.5 8,16 10,15 7.5,9.5 12,9.5' fill='%23ffffff' stroke='%23000000' stroke-width='1.3' stroke-linejoin='miter'/%3E%3C/svg%3E");
}
body.ztouch-mouse-available .ztb-tray-ico.ztb-mouse-ico {
  display: inline-flex;
}
.ztb-mouse-ico.active {
  background-color: #E8E4DC;
  border-top: 1px solid #404040;
  border-left: 1px solid #404040;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}

.ztm-trackpad {
  position: fixed;
  inset: 0 0 28px 0;
  z-index: 99960;
  background: transparent;
  touch-action: none;
  user-select: none;
}

.ztm-bar {
  position: fixed;
  left: 6px;
  bottom: 34px;
  z-index: 99980;
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 3px 4px;
  background: #C0C0C0;
  border-top: 2px solid #FFFFFF;
  border-left: 2px solid #FFFFFF;
  border-right: 2px solid #404040;
  border-bottom: 2px solid #404040;
  box-shadow: 1px 1px 0 rgba(0, 0, 0, 0.45);
  touch-action: none;
  user-select: none;
}
.ztm-grip {
  width: 8px;
  height: 20px;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #808080;
  background: repeating-linear-gradient(0deg, #808080 0 1px, transparent 1px 3px);
  touch-action: none;
}
.ztm-btn {
  min-width: 28px;
  min-height: 24px;
  height: 24px;
  padding: 0 6px;
  font-size: 11px;
  font-weight: bold;
  line-height: 1;
}
.ztm-btn.active {
  background: #000080;
  color: #FFFFFF;
  border-top-color: #404040;
  border-left-color: #404040;
  border-right-color: #FFFFFF;
  border-bottom-color: #FFFFFF;
}
.ztm-close {
  min-width: 24px;
  padding: 0 5px;
}

.ztm-cursor {
  position: fixed;
  left: 0;
  top: 0;
  width: 18px;
  height: 22px;
  z-index: 100006;
  pointer-events: none;
  user-select: none;
  transform: translate(-1px, -1px);
  filter: drop-shadow(1px 1px 0 rgba(0, 0, 0, 0.55));
}
.ztm-cursor.shape-hand {
  transform: translate(-6px, -1px);
}
.ztm-cursor.shape-ibeam {
  transform: translate(-6px, -10px);
}
.ztm-cursor.dragging::after {
  content: "";
  position: absolute;
  left: 11px;
  top: 13px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #FF0000;
  border: 1px solid #FFFFFF;
}
.ztm-cursor svg {
  display: block;
}

/* ============================================================================
 * CASCADING WIN98 SUBMENU ARROW + ZONECOMMANDER (v1.2.460.1 ROCKWELL) UI
 * ============================================================================ */
.zmenu-sub-arrow {
  margin-left: auto;
  padding-left: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  color: inherit;
}
.zmenu-row.sub-open:not(:disabled) {
  background: #000080;
  color: #FFFFFF;
}
body.ztheme-dark .zmenu-row.sub-open:not(:disabled) {
  background: var(--dm-sel);
  color: #FFFFFF;
}

.zc-app-shell {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: var(--w98-face);
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
}
.zc-toolbar {
  padding: 2px 3px;
  gap: 1px;
  min-height: 25px;
  border-top: 1px solid #808080;
  box-shadow: inset 0 1px 0 #FFFFFF;
}
.zc-tb-btn {
  min-width: 23px;
  height: 22px;
  padding: 0 3px;
  gap: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}
.zc-tb-btn.has-lbl {
  padding: 0 6px 0 4px;
}
.zc-tb-btn.is-toggle.active {
  background: var(--w98-face);
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #DFDFDF;
}
.zc-tb-lbl {
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  line-height: 1;
}
.zc-tb-btn:disabled .zc-tb-lbl {
  color: #808080;
  text-shadow: 1px 1px 0 #FFFFFF;
}
.zc-tb-ico {
  display: inline-block;
  width: 16px;
  height: 15px;
  flex: 0 0 16px;
  background-image: url("../assets/win98/zc/toolbar.png");
  background-repeat: no-repeat;
  image-rendering: pixelated;
}
.zc-tb-btn:disabled .zc-tb-ico {
  opacity: 0.35;
  filter: grayscale(1);
}

.zc-app-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  padding: 2px;
  gap: 0;
}
.zc-app-toprow {
  flex: 1;
  display: flex;
  min-height: 140px;
  min-width: 0;
  overflow: hidden;
}
.zc-left-dock,
.zc-right-dock {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
  min-width: 0;
}
.zc-dock-pane {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  background: var(--w98-face);
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #808080;
  border-bottom: 1px solid #808080;
}
.zc-bottom-dock {
  flex: 0 0 auto;
  min-height: 70px;
  min-width: 0;
  overflow: hidden;
}
.zc-pane-hdr {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  height: 18px;
  padding: 0 3px 0 4px;
  background: var(--w98-face);
  border-bottom: 1px solid #808080;
  box-shadow: inset 0 -1px 0 #DFDFDF;
  flex: 0 0 auto;
}
.zc-pane-title {
  flex: 1;
  font-weight: normal;
  font-size: 11px;
  color: #000000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zc-pane-x {
  width: 14px;
  height: 14px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: #000000;
  border: 1px solid transparent;
  cursor: var(--w98-cur-arrow);
}
.zc-pane-x:hover {
  border-top-color: #FFFFFF;
  border-left-color: #FFFFFF;
  border-right-color: #808080;
  border-bottom-color: #808080;
}
.zc-pane-x:active {
  border-top-color: #808080;
  border-left-color: #808080;
  border-right-color: #FFFFFF;
  border-bottom-color: #FFFFFF;
}

.zc-vsplit {
  width: 4px;
  flex: 0 0 4px;
}
.zc-hsplit {
  height: 4px;
  flex: 0 0 4px;
}

/* Room List TreeView */
.zc-tree-wrap {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #FFFFFF;
  color: #000000;
  padding: 2px 2px;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}
.zc-pane-empty {
  padding: 6px;
  color: #606060;
}
.zc-empty-pane {
  flex: 1;
  min-height: 0;
  background: var(--w98-face);
  color: #000000;
  padding: 8px 6px;
  text-align: center;
  font-size: 11px;
  font-weight: normal;
}
.zc-tree-row {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 17px;
  padding: 0 3px;
  white-space: nowrap;
  cursor: var(--w98-cur-arrow);
}
.zc-tree-row.sel {
  background: #000080;
  color: #FFFFFF;
}
.zc-tree-row.hot:not(.sel) {
  color: #C00000;
}
.zc-tree-twisty {
  width: 9px;
  height: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Courier New", monospace;
  font-size: 9px;
  line-height: 8px;
  flex: 0 0 9px;
}
.zc-tree-twisty.has-kids {
  border: 1px solid #808080;
  background: #FFFFFF;
  color: #000000;
}
.zc-tree-ico {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  image-rendering: pixelated;
}
.zc-tree-lbl {
  font-weight: normal;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zc-tree-children {
  margin-left: 7px;
  padding-left: 9px;
  border-left: 1px dotted #808080;
}
.zc-tree-staff-kids {
  margin-left: 12px;
  padding-left: 12px;
}

/* MDI Workspace (authentic Win32 COLOR_APPWORKSPACE flat #808080) */
.zc-mdi-wrap {
  flex: 1;
  min-width: 180px;
  min-height: 120px;
  display: flex;
  border-top: 2px solid #808080;
  border-left: 2px solid #808080;
  border-right: 2px solid #FFFFFF;
  border-bottom: 2px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  overflow: hidden;
}
.zc-mdi-area {
  position: relative;
  flex: 1;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background: #808080;
}
.zc-mdi-win {
  position: absolute;
  display: flex;
  flex-direction: column;
  background: var(--w98-face);
  border-top: 2px solid #FFFFFF;
  border-left: 2px solid #FFFFFF;
  border-right: 2px solid #404040;
  border-bottom: 2px solid #404040;
  box-shadow: inset 1px 1px 0 #DFDFDF, inset -1px -1px 0 #808080;
  overflow: hidden;
}
.zc-mdi-win.maximized {
  border: 0;
  box-shadow: none;
}
.zc-mdi-titlebar {
  height: 19px;
  flex: 0 0 19px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2px 0 3px;
  background: #808080;
  color: #D4D0C8;
  font-weight: bold;
  font-size: 11px;
}
.zc-mdi-win.active .zc-mdi-titlebar {
  background: linear-gradient(90deg, #000080, #1084D0);
  color: #FFFFFF;
}
.zc-mdi-title-left {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  overflow: hidden;
}
.zc-mdi-title-left img {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  image-rendering: pixelated;
}
.zc-mdi-title-txt {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zc-mdi-btns {
  display: flex;
  align-items: center;
  gap: 2px;
  flex: 0 0 auto;
}
.zc-mdi-btns .zwin-btn {
  width: 15px;
  height: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.zc-mdi-body {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
  padding: 0;
  gap: 0;
}
.zc-mdi-win.minimized .zc-mdi-body,
.zc-mdi-win.minimized .zc-mdi-resize {
  display: none;
}
.zc-mdi-lobby-pane {
  flex: 0 1 42%;
  min-height: 52px;
  max-height: 148px;
  overflow: auto;
  background: #006699;
  border-bottom: 1px solid #808080;
  padding: 4px;
}
.zc-mdi-table-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(154px, 1fr));
  gap: 5px;
}
.zc-mdi-tcard {
  background: #FFFFCC;
  color: #000000;
  border: 2px solid #FFCC66;
  padding: 3px 5px;
  font-size: 11px;
}
.zc-mdi-tcard-hdr {
  font-weight: bold;
  color: #003366;
  border-bottom: 1px solid #E0B855;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zc-mdi-tcard-seats {
  font-size: 10px;
  color: #202020;
  word-break: break-word;
}
.zc-mdi-chatlog {
  flex: 1 1 0;
  min-height: 36px;
  background: #FFFFFF;
  color: #000000;
  border: 0;
  padding: 3px 5px;
  overflow-y: auto;
  user-select: text;
}
.zc-mdi-chatform {
  flex: 0 0 auto;
  border-top: 1px solid #808080;
  padding: 2px 4px;
}
.zc-mdi-chatinput {
  flex: 1;
  min-width: 0;
}
.zc-mdi-resize {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 11px;
  height: 11px;
  cursor: var(--w98-cur-nwse);
}

/* Right Dock: User List & Game List */
.zc-user-container,
.zc-game-container {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.zc-userlist-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #000000;
  color: #FFFFFF;
  padding: 2px 4px 4px;
}
.zc-ul-sec {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: normal;
  font-size: 11px;
  color: #FFFFFF;
  padding: 1px 2px 2px;
  border-bottom: 1px solid #808080;
  margin-bottom: 4px;
}
.zc-ul-grp {
  margin-top: 10px;
}
.zc-ul-row {
  display: flex;
  align-items: center;
  padding: 1px 2px 1px 4px;
  color: #FFFFFF;
  white-space: nowrap;
  line-height: 15px;
}
.zc-ul-row.is-staff {
  padding-left: 24px;
}
.zc-ul-row.sel {
  background: #000080;
  color: #FFFFFF;
}
.zc-ul-name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Authentic 06_gaglist.png Right-Dock Game List (yellow rows + Host/Join sprites) */
.zc-gl-wrap {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #FFFFCC;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
}
.zc-gl-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 11px;
  background: #FFFFCC;
  color: #000000;
}
.zc-gl-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--w98-face);
  color: #000000;
  font-weight: normal;
  text-align: left;
  padding: 1px 3px;
  height: 17px;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #808080;
  border-bottom: 1px solid #808080;
  white-space: nowrap;
  overflow: hidden;
}
.zc-gl-table tbody tr {
  height: 16px;
  background: #FFFFCC;
}
.zc-gl-table tbody tr:hover {
  background: #FFEEAA;
}
.zc-gl-table tbody td {
  padding: 0 3px;
  border-bottom: 1px solid #E8D890;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}
.zc-gl-num {
  text-align: center;
}
.zc-gl-c {
  text-align: center;
  padding: 0 1px;
}
button.zc-lv-btn {
  border: 0;
  padding: 0;
  margin: 0;
  background-color: transparent;
  cursor: var(--w98-cur-hand);
  vertical-align: middle;
}
button.zc-lv-btn:focus-visible {
  outline: 1px dotted #000000;
}

/* Win98 ListView Tables (Sysop Activity, Announcements Manager, Gag/Boot List) */
.zc-lv-wrap {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: #FFFFFF;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
}
.zc-lv-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
  table-layout: fixed;
}
.zc-lv-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--w98-face);
  color: #000000;
  font-weight: normal;
  text-align: left;
  padding: 2px 4px;
  border-top: 1px solid #FFFFFF;
  border-left: 1px solid #FFFFFF;
  border-right: 1px solid #808080;
  border-bottom: 1px solid #808080;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zc-lv-table tbody td {
  padding: 1px 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  border-bottom: 1px solid #F0F0F0;
}
.zc-lv-table tbody tr.sel {
  background: #000080;
  color: #FFFFFF;
}
.zc-lv-table tbody tr.sel td {
  border-bottom-color: #000080;
}

/* Announcements Dock (authentic #003333 + ZCommandRes.dll GIF 122 curve, matching 01_connected.png & 02_signedin.png) */
.zc-ann-body {
  flex: 1;
  min-height: 0;
  overflow-y: scroll;
  overflow-x: hidden;
  background-color: #003333;
  background-image: url("../assets/win98/zc/mdi_bg.png");
  background-repeat: no-repeat;
  background-position: left top;
  color: #99EEEE;
  padding: 6px 8px;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #FFFFFF;
  border-bottom: 1px solid #FFFFFF;
  box-shadow: inset 1px 1px 0 #404040;
  font-family: Verdana, Tahoma, Arial, sans-serif;
  font-size: 11px;
  line-height: 1.3;
  user-select: text;
}
.zc-ann-item {
  padding-bottom: 10px;
}
.zc-ann-item:last-child {
  padding-bottom: 2px;
}
.zc-ann-date {
  color: #66CCCC;
  text-decoration: underline;
  margin-bottom: 8px;
}
.zc-ann-posted,
.zc-ann-title {
  font-weight: bold;
  color: #FFFF66;
}
.zc-ann-text {
  margin-top: 2px;
  color: #CCFFFF;
}

/* Status Bar (authentic 4 sunken wells matching 01_connected.png / 05_3rooms.png) */
.zc-statusbar {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 2px 14px 2px 3px;
}
.zc-sb-main {
  flex: 1;
  min-width: 80px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.zc-sb-prog {
  width: 118px;
  flex: 0 0 118px;
}
.zc-sb-ind {
  width: 26px;
  flex: 0 0 26px;
}
.zc-sb-clock {
  width: 68px;
  flex: 0 0 68px;
  text-align: center;
}
.zc-prog-track {
  width: 100%;
  height: 11px;
  background: #FFFFFF;
  border: 1px solid #808080;
  overflow: hidden;
}
.zc-prog-fill {
  height: 100%;
  background: repeating-linear-gradient(90deg, #000080 0 7px, #FFFFFF 7px 9px);
}

/* ZoneCommander Modal Dialogs (verbatim ZCommandRes.dll DLG 105, 106, 115, 141, 142, 203, 206, 217, 221) */
.zc-dlg {
  flex: 1;
  background: var(--w98-face);
  color: #000000;
  padding: 10px 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  min-height: 0;
}
.zc-dlg-2col {
  flex-direction: row;
  align-items: stretch;
  gap: 10px;
}
.zc-dlg-maincol {
  flex: 1;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.zc-dlg-stack {
  gap: 8px;
}
.zc-dlg-box {
  margin: 0;
  padding: 8px 10px 10px;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.zc-dlg-sidebtns {
  width: 76px;
  flex: 0 0 76px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 2px;
}
.zc-dlg-sidebtns .zbtn {
  width: 100%;
  height: 23px;
}
.zc-dlg-intro {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.zc-dlg-intro img,
.zc-dlg-grp-row > img,
.zc-rp-layout > img {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  image-rendering: pixelated;
}
.zc-dlg-copy {
  line-height: 1.35;
  color: #000000;
}
.zc-dlg-indent {
  padding-left: 42px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.zc-rad-stack {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 4px;
}
.zc-conn-auto {
  margin-top: 4px;
}
.zc-conn-logon-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 4px;
}
.zc-conn-logon-row .zbtn {
  min-width: 118px;
  height: 23px;
}
.zc-logon-fields {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 2px 4px;
}
.zc-dlg-row {
  display: flex;
  align-items: center;
  gap: 6px;
}
.zc-dlg-grp-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.zc-chk-col {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 0;
}
.zc-chk-wrap {
  align-items: flex-start;
  white-space: normal;
  line-height: 1.25;
}
.zc-pop-spin {
  padding-left: 18px;
}
.zc-dlg-propsheet {
  gap: 0;
  padding: 8px 10px 10px;
}
.zc-ps-body {
  padding: 10px 12px;
  gap: 8px;
}
.zc-rp-layout {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.zc-rp-grid {
  flex: 1;
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 4px 8px;
  min-width: 0;
}
.zc-rp-k {
  text-align: right;
  color: #000000;
  white-space: nowrap;
}
.zc-rp-v {
  color: #000000;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.zc-sec-rule {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #000000;
}
.zc-rule-line {
  flex: 1;
  height: 0;
  border-top: 1px solid #808080;
  border-bottom: 1px solid #FFFFFF;
}
.zc-layout-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px 10px;
  margin-top: 4px;
}
.zc-layout-opts {
  padding-left: 42px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.zc-dlg-foot {
  margin-top: auto;
  padding-top: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.zc-dlg-foot-end {
  justify-content: flex-end;
}
.zc-dlg-foot-l,
.zc-dlg-foot-r {
  display: flex;
  align-items: center;
  gap: 6px;
}
.zc-dlg-foot .zbtn {
  min-width: 74px;
  height: 23px;
}
.zc-ann-box {
  gap: 8px;
}
.zc-ann-lv {
  flex: 1;
  min-height: 120px;
}
.zc-ann-act-btns {
  display: flex;
  gap: 6px;
}
.zc-ann-act-btns .zbtn {
  min-width: 74px;
  height: 23px;
}
.zc-send-ta {
  flex: 1;
  min-height: 70px;
}
.zc-mod-heading {
  color: #000000;
  font-weight: normal;
}
.zc-mod-lv {
  flex: 1;
  min-height: 112px;
}
.zc-mod-input {
  width: 100%;
  box-sizing: border-box;
  height: 21px;
}
.zc-about-top {
  padding: 10px 10px;
}
.zc-about-meta {
  line-height: 1.35;
}
.zc-about-legal {
  padding: 8px 10px;
  line-height: 1.35;
}

/* DIALOG 107 (Room Properties General tab) & Sysop Macros (STR 40018) */
.zc-dlg-107 {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.zc-107-sec {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.zc-107-hdr {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #000000;
}
.zc-107-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding-left: 8px;
}
.zc-107-row img {
  flex: 0 0 auto;
  image-rendering: pixelated;
  margin-top: 2px;
}
.zc-107-col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.zc-107-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.zc-107-logstat {
  font-size: 10px;
  color: #404040;
}
.zc-dlg-foot-between {
  justify-content: space-between;
}
.zc-dlg-macros {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.zc-macros-grid {
  display: flex;
  gap: 10px;
  flex: 1;
  min-height: 0;
}
.zc-macros-left {
  flex: 0 0 146px;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.zc-macros-list {
  height: 162px;
  padding: 2px;
}
.zc-macro-item {
  padding: 2px 5px;
  font-size: 11px;
  cursor: var(--w98-cur-arrow);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.zc-macro-item.sel {
  background: #000080;
  color: #FFFFFF;
}
.zc-macros-right {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.zc-macros-ta {
  resize: none;
  font-family: var(--w98-font);
  font-size: 11px;
  line-height: 1.3;
  height: 82px;
}
.zc-dlg-gameinfo {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Mobile / Narrow Viewport Collapsible Docks (desktop > 760px unaffected) */
.zc-app-shell.zc-narrow .zc-toolbar {
  overflow-x: auto;
  overflow-y: hidden;
  flex-wrap: nowrap;
  scrollbar-width: none;
}
.zc-app-shell.zc-narrow .zc-top-row {
  position: relative;
}
.zc-app-shell.zc-narrow .zc-dock-col {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 25;
  width: min(260px, 84%) !important;
  max-width: 84%;
  background: var(--w98-face);
}
.zc-app-shell.zc-narrow .zc-dock-left {
  left: 0;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.45);
}
.zc-app-shell.zc-narrow .zc-dock-right {
  right: 0;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.45);
}
.zc-app-shell.zc-narrow .zc-mdi-win {
  left: 0 !important;
  top: 0 !important;
  width: 100% !important;
  height: 100% !important;
}

/* ZoneCommander Dark Mode (matches ztheme.h palette while preserving exact 1999 Light Mode) */
body.ztheme-dark .zc-tb-ico {
  filter: invert(0.88);
}
body.ztheme-dark .zc-tb-btn:disabled .zc-tb-ico {
  opacity: 0.35;
  filter: invert(0.88) grayscale(1);
}
body.ztheme-dark .zc-tb-btn:disabled .zc-tb-lbl {
  color: var(--dm-cap-inactive-text);
  text-shadow: none;
}
body.ztheme-dark .zc-tb-btn.is-toggle.active {
  background: var(--dm-window);
  border-top-color: var(--dm-dk);
  border-left-color: var(--dm-dk);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
  box-shadow: none;
}
body.ztheme-dark .zc-toolbar {
  border-top-color: var(--dm-sh);
  box-shadow: inset 0 1px 0 var(--dm-hi);
}
body.ztheme-dark .zc-app-shell,
body.ztheme-dark .zc-dock-pane,
body.ztheme-dark .zc-pane-hdr,
body.ztheme-dark .zc-empty-pane,
body.ztheme-dark .zc-dlg {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
}
body.ztheme-dark .zc-pane-title,
body.ztheme-dark .zc-pane-x,
body.ztheme-dark .zc-dlg-copy,
body.ztheme-dark .zc-rp-k,
body.ztheme-dark .zc-rp-v,
body.ztheme-dark .zc-sec-rule,
body.ztheme-dark .zc-mod-heading {
  color: var(--dm-text);
}
body.ztheme-dark .zc-pane-hdr {
  border-bottom-color: var(--dm-sh);
  box-shadow: none;
}
body.ztheme-dark .zc-rule-line {
  border-top-color: var(--dm-sh);
  border-bottom-color: var(--dm-hi);
}
body.ztheme-dark .zc-mdi-area {
  background: #20242A;
}
body.ztheme-dark .zc-mdi-body,
body.ztheme-dark .zc-tree-wrap,
body.ztheme-dark .zc-lv-wrap,
body.ztheme-dark .zc-mdi-chatlog,
body.ztheme-dark .zc-mdi-chatform,
body.ztheme-dark .zc-mdi-chatinput {
  background: var(--dm-window);
  color: var(--dm-text);
  border-top-color: var(--dm-sh);
  border-left-color: var(--dm-sh);
  border-right-color: var(--dm-hi);
  border-bottom-color: var(--dm-hi);
}
body.ztheme-dark .zc-gl-wrap,
body.ztheme-dark .zc-gl-table,
body.ztheme-dark .zc-gl-table tbody tr {
  background: var(--dm-window);
  color: var(--dm-text);
}
body.ztheme-dark .zc-gl-table tbody tr:hover {
  background: var(--dm-zebra);
}
body.ztheme-dark .zc-gl-table tbody td {
  border-bottom-color: var(--dm-zebra);
}
body.ztheme-dark .zc-gl-table thead th,
body.ztheme-dark .zc-lv-table thead th {
  background: var(--dm-face);
  color: var(--dm-text);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-sh);
  border-bottom-color: var(--dm-sh);
}
body.ztheme-dark .zc-tree-twisty.has-kids {
  background: var(--dm-face);
  color: var(--dm-text);
  border-color: var(--dm-hi);
}
body.ztheme-dark .zc-tree-row.sel,
body.ztheme-dark .zc-lv-table tbody tr.sel,
body.ztheme-dark .zc-ul-row.sel {
  background: var(--dm-sel);
  color: #FFFFFF;
}
body.ztheme-dark .zc-tree-row.hot:not(.sel) {
  color: #FF6B6B;
}
body.ztheme-dark .zc-lv-table tbody td {
  border-bottom-color: var(--dm-zebra);
}
body.ztheme-dark .zc-pane-empty {
  color: var(--dm-cap-inactive-text);
}
body.ztheme-dark .zc-mdi-win {
  background: var(--dm-face);
  border-top-color: var(--dm-hi);
  border-left-color: var(--dm-hi);
  border-right-color: var(--dm-dk);
  border-bottom-color: var(--dm-dk);
  box-shadow: inset 1px 1px 0 var(--dm-light), inset -1px -1px 0 var(--dm-sh);
}
body.ztheme-dark .zc-mdi-titlebar {
  background: var(--dm-cap-inactive);
  color: var(--dm-cap-inactive-text);
}
body.ztheme-dark .zc-mdi-win.active .zc-mdi-titlebar {
  background: var(--dm-cap-active);
  color: var(--dm-cap-text);
}
body.ztheme-dark .zc-mdi-lobby-pane {
  background: #102838;
}
body.ztheme-dark .zc-mdi-tcard {
  background: #24241C;
  color: var(--dm-text);
  border-color: #887038;
}
body.ztheme-dark .zc-mdi-tcard-hdr {
  color: #FFCC66;
  border-bottom-color: #554826;
}
body.ztheme-dark .zc-mdi-tcard-seats {
  color: var(--dm-text);
}
body.ztheme-dark .zc-prog-track {
  background: var(--dm-window);
  border-color: var(--dm-hi);
}
body.ztheme-dark .zc-prog-fill {
  background: repeating-linear-gradient(90deg, var(--dm-sel) 0 7px, var(--dm-window) 7px 9px);
}
body.ztheme-dark .zc-107-hdr,
body.ztheme-dark .zc-macros-right label {
  color: var(--dm-text);
}
body.ztheme-dark .zc-107-logstat {
  color: var(--dm-cap-inactive-text);
}
body.ztheme-dark .zc-macro-item {
  color: var(--dm-text);
}
body.ztheme-dark .zc-macro-item.sel {
  background: var(--dm-sel);
  color: #FFFFFF;
}
body.ztheme-dark .zc-app-shell.zc-narrow .zc-dock-col {
  background: var(--dm-face);
}

/* ZoneCommander Find Room (Ctrl+F), Active Filter & /911 Alert Styling */
.zc-tree-row.has-alert:not(.sel) {
  color: #B00020;
  font-weight: bold;
}
.zc-tree-empty {
  color: #666666;
  font-style: italic;
  padding-left: 18px;
}
.zc-lv-table tbody tr.zc-act-911:not(.sel) td:first-child {
  color: #B00020;
  font-weight: bold;
}
.zc-dlg-find {
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: 100%;
  box-sizing: border-box;
}
.zc-find-top {
  display: flex;
  align-items: center;
  gap: 8px;
}
.zc-find-top label {
  white-space: nowrap;
}
.zc-find-top input {
  flex: 1 1 auto;
}
.zc-find-opts {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.zc-find-cnt {
  font-size: 11px;
  color: #404040;
}
.zc-find-lv {
  flex: 1 1 0;
  min-height: 120px;
}
body.ztheme-dark .zc-tree-row.has-alert:not(.sel),
body.ztheme-dark .zc-lv-table tbody tr.zc-act-911:not(.sel) td:first-child {
  color: #FF7B7B;
}
body.ztheme-dark .zc-tree-empty,
body.ztheme-dark .zc-find-cnt {
  color: var(--dm-cap-inactive-text);
}

/* === The Village (Dec 1995 Electric Gravity Original Zone) === */
.v95-main-root, .v95-room-root, .v95-table-root {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  background: #d4d0c8;
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  user-select: none;
  cursor: var(--w98-cur-arrow);
}
.v95-pix {
  image-rendering: pixelated;
  display: block;
}
.v95-stage {
  position: relative;
  width: 600px;
  height: 382px;
  margin: 0;
  overflow: hidden;
  background: #000000;
  flex: 0 0 auto;
  cursor: var(--w98-cur-arrow);
}
.v95-stage.is-hand {
  cursor: var(--w98-cur-hand);
}
.v95-bg-img {
  display: block;
  width: 600px;
  height: 382px;
  image-rendering: pixelated;
}
.v95-bldg, .v95-signpost {
  position: absolute;
  image-rendering: pixelated;
}
.v95-bldg {
  pointer-events: none;
}
.v95-signpost {
  cursor: var(--w98-cur-hand);
}
.v95-tooltip {
  position: absolute;
  z-index: 20;
  background: #ffffff;
  color: #000000;
  border: 1px solid #000000;
  padding: 2px 5px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  line-height: 1.2;
  pointer-events: none;
  min-width: 58px;
}
.v95-tip-title {
  font-weight: bold;
}
/* Context menu (right-click Village stage) */
.v95-ctx-menu {
  position: fixed;
  z-index: 9999;
  background: #d4d0c8;
  border-top: 1px solid #ffffff;
  border-left: 1px solid #ffffff;
  border-right: 1px solid #404040;
  border-bottom: 1px solid #404040;
  box-shadow: 1px 1px 0 #000000;
  padding: 2px;
  display: flex;
  flex-direction: column;
  min-width: 158px;
}
.v95-ctx-item {
  background: transparent;
  border: none;
  text-align: left;
  padding: 3px 10px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  color: #000000;
  cursor: var(--w98-cur-arrow);
}
.v95-ctx-item:hover {
  background: #000080;
  color: #ffffff;
}
/* Authentic Dec 1995 Login & New User Dialogs over Castle Gate */
.v95-win-dlg {
  position: absolute;
  background: #d4d0c8;
  border: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #ffffff, inset -1px -1px 0 #808080;
  padding: 2px;
  z-index: 10;
}
.v95-win-login {
  left: 167px;
  top: 44px;
  width: 266px;
}
.v95-win-reg {
  left: 88px;
  top: 28px;
  width: 424px;
}
.v95-dlg-title {
  display: flex;
  align-items: center;
  gap: 5px;
  background: #000080;
  color: #ffffff;
  font-weight: bold;
  font-size: 11px;
  padding: 2px 5px;
  margin-bottom: 2px;
}
.v95-login-box {
  position: relative;
  width: 260px;
  height: 270px;
  background-repeat: no-repeat;
  background-size: 260px 270px;
  image-rendering: pixelated;
}
.v95-login-input {
  position: absolute;
  box-sizing: border-box;
  background: #ffffff;
  color: #000000;
  border: none;
  padding: 1px 4px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  outline: none;
  cursor: var(--w98-cur-ibeam);
}
.v95-login-btn {
  position: absolute;
  padding: 0 !important;
  line-height: 16px;
}
.v95-login-err {
  position: absolute;
  left: 12px;
  right: 12px;
  top: 187px;
  text-align: center;
  color: #ffff66;
  font-size: 10px;
  font-weight: bold;
  background: #000000;
  padding: 1px 3px;
}
.v95-gate-canvas {
  display: block;
  width: 600px;
  height: 382px;
  image-rendering: pixelated;
}
.v95-gate-banner {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  background: #d4d0c8;
  border: 2px solid #000000;
  box-shadow: inset 1px 1px 0 #ffffff, inset -1px -1px 0 #808080;
  padding: 10px 24px;
  z-index: 6;
}
.v95-gate-banner-txt {
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 12px;
  font-weight: bold;
  color: #000000;
  white-space: nowrap;
}
.v95-reg-form {
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.v95-reg-row {
  display: flex;
  align-items: center;
  gap: 6px;
}
.v95-reg-row label {
  width: 82px;
  text-align: right;
  font-weight: bold;
}
.v95-reg-bio {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 2px;
}
.v95-reg-bio label {
  font-weight: bold;
}
.v95-input, .v95-textarea {
  flex: 1;
  background: #ffffff;
  color: #000000;
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #ffffff;
  border-bottom: 1px solid #ffffff;
  box-shadow: inset 1px 1px 0 #404040;
  padding: 2px 4px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  cursor: var(--w98-cur-ibeam);
}
.v95-textarea {
  resize: none;
}
.v95-err {
  background: #ffffff;
  border: 1px solid #990000;
  color: #990000;
  padding: 3px 6px;
  font-size: 11px;
}
.v95-dlg-acts {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  margin-top: 6px;
}
/* Authentic Win95 bevel button matching .zbtn (1px outer black + 1px inner bevel) */
.v95-btn {
  background: #d4d0c8;
  color: #000000;
  border: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #ffffff, inset -1px -1px 0 #808080;
  padding: 2px 10px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  font-weight: bold;
  cursor: var(--w98-cur-arrow);
}
.v95-btn:active:not(:disabled), .v95-btn.is-pressed {
  box-shadow: inset 1px 1px 0 #808080, inset -1px -1px 0 #ffffff;
}
.v95-btn:disabled {
  color: #808080;
  text-shadow: 1px 1px 0 #ffffff;
  cursor: var(--w98-cur-arrow);
}
.v95-btn-primary {
  box-shadow: inset 1px 1px 0 #ffffff, inset -1px -1px 0 #808080, 0 0 0 1px #000000;
}
.v95-sprite-btn {
  border: none;
  padding: 0;
  margin: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  background-position: 0 0;
  image-rendering: pixelated;
  cursor: var(--w98-cur-hand);
  flex: 0 0 auto;
}
/* Welcome, About, Help, Disclaimer, Score, Options Dialogs */
.v95-welcome-win, .v95-help-body {
  width: 100%;
  height: 100%;
  background: #ffffff;
  display: flex;
  flex-direction: column;
}
.v95-welcome-pre {
  flex: 1;
  margin: 0;
  background: #ffffff;
  color: #000000;
  border: none;
  padding: 6px 8px;
  white-space: pre-wrap;
  overflow-y: auto;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 12px;
  line-height: 1.3;
  user-select: text;
}
.v95-about-pure {
  width: 440px;
  height: 340px;
  background: #000000;
  overflow: hidden;
}
.v95-about-img {
  display: block;
  width: 440px;
  height: 340px;
  image-rendering: pixelated;
  cursor: var(--w98-cur-arrow);
}
.v95-disclaim-body, .v95-dlg-pad {
  padding: 8px;
  background: #d4d0c8;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-sizing: border-box;
  gap: 6px;
}
.v95-disclaim-body .v95-welcome-pre {
  border-top: 1px solid #808080;
  border-left: 1px solid #808080;
  border-right: 1px solid #ffffff;
  border-bottom: 1px solid #ffffff;
}
.v95-opts-box {
  justify-content: space-between;
}
.v95-opt-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}
.v95-score-meta {
  font-weight: bold;
  font-size: 11px;
}
.v95-score-tbl {
  width: 100%;
  border-collapse: collapse;
  background: #ffffff;
  border: 1px solid #000000;
  font-size: 11px;
}
.v95-score-tbl th, .v95-score-tbl td {
  border: 1px solid #808080;
  padding: 2px 5px;
  text-align: center;
}
.v95-score-tbl th {
  background: #d4d0c8;
}
.v95-score-total td {
  font-weight: bold;
  background: #ffffcc;
}
.v95-last-trick-stage {
  width: 100%;
  height: 100%;
  background-image: url("../assets/village/felt_green.png");
  background-repeat: repeat;
  image-rendering: pixelated;
  display: flex;
  align-items: center;
  justify-content: center;
}
/* === 1995 ZRoom Lobby (matches win31-hearts-lobby-r100.png) === */
.v95-room-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ffffff;
  border-bottom: 1px solid #000000;
  padding: 2px 4px 2px 8px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-weight: bold;
  font-size: 12px;
  flex: 0 0 auto;
  height: 28px;
  box-sizing: border-box;
}
.v95-room-top-r {
  display: flex;
  align-items: center;
  gap: 14px;
}
.v95-tables-floor {
  flex: 1 1 auto;
  min-height: 148px;
  background: #cfcf98;
  overflow-y: auto;
  overflow-x: hidden;
}
.v95-tables-inner {
  display: grid;
  grid-template-columns: repeat(3, 180px);
  justify-content: start;
  padding: 0 2px;
}
.v95-zcell {
  position: relative;
  width: 180px;
  height: 144px;
}
.v95-zcell-num {
  position: absolute;
  color: #006600;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-weight: bold;
  font-size: 12px;
  line-height: 1;
  pointer-events: none;
  z-index: 5;
}
.v95-ztbl {
  position: absolute;
  image-rendering: pixelated;
  pointer-events: none;
  z-index: 2;
}
.v95-ztbl-ico {
  position: absolute;
  image-rendering: pixelated;
  pointer-events: none;
  z-index: 3;
}
.v95-zseat {
  position: absolute;
  image-rendering: pixelated;
  cursor: var(--w98-cur-hand);
}
.v95-zseat-name {
  position: absolute;
  text-align: center;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-weight: bold;
  font-size: 10px;
  line-height: 12px;
  color: #000000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
  z-index: 7;
}
.v95-zseat-name.is-me {
  color: #000080;
}
.v95-zvote {
  position: absolute;
  width: 16px;
  height: 16px;
  image-rendering: pixelated;
  pointer-events: none;
  z-index: 5;
}
.v95-zstart {
  position: absolute;
  z-index: 8;
}
.v95-zkib {
  position: absolute;
  width: 24px;
  height: 32px;
  image-rendering: pixelated;
  z-index: 6;
}
.v95-hsplit {
  height: 3px;
  background: #000000;
  cursor: var(--w98-cur-ns);
  flex: 0 0 auto;
}
/* 5-column horizontal player roster grid below table floor (exact win31-hearts-lobby-r100.png) */
.v95-roster-grid-wrap {
  height: 54px;
  min-height: 38px;
  background: #ffffff;
  overflow-y: auto;
  flex: 0 0 auto;
}
.v95-roster-tbl {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  font-weight: bold;
}
.v95-roster-tbl td {
  border-right: 1px solid #000000;
  border-bottom: 1px solid #000000;
  height: 17px;
  padding: 0 3px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #000000;
}
.v95-roster-tbl td:last-child {
  border-right: none;
}
.v95-roster-tbl td.is-me {
  color: #000080;
}
/* Shared Table & Room Chat (exact native white log + clean bottom input, no Send button) */
.v95-chat-wrap {
  height: 82px;
  display: flex;
  flex-direction: column;
  border-top: 1px solid #000000;
  background: #ffffff;
  flex: 0 0 auto;
}
.v95-room-chat {
  height: 88px;
  border-top: none;
}
.v95-chat-log {
  flex: 1;
  overflow-y: auto;
  padding: 2px 5px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  line-height: 1.25;
  color: #000000;
  user-select: text;
}
.v95-chat-sys {
  color: #006600;
}
.v95-chat-input {
  border: none;
  border-top: 1px solid #000000;
  background: #ffffff;
  color: #000000;
  padding: 2px 5px;
  height: 20px;
  box-sizing: border-box;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  outline: none;
  cursor: var(--w98-cur-ibeam);
}
/* === Hearts & Bridge Felt Tables (genuine 8x8 dithered felt_green.png) === */
.v95-hearts-felt, .v95-bridge-felt {
  position: relative;
  flex: 1;
  background-color: #006b00;
  background-image: url("../assets/village/felt_green.png");
  background-repeat: repeat;
  image-rendering: pixelated;
  overflow: hidden;
  min-height: 343px;
}
.v95-top-left-ico {
  position: absolute;
  top: 4px;
  left: 4px;
  image-rendering: pixelated;
  z-index: 5;
}
.v95-top-right-bar {
  position: absolute;
  top: 4px;
  right: 4px;
  display: flex;
  gap: 4px;
  z-index: 5;
}
.v95-contract-btn {
  position: absolute;
  top: 4px;
  left: 4px;
  min-width: 34px;
  height: 22px;
  background: #ffffff;
  border: 1px solid #000000;
  padding: 0 5px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 12px;
  font-weight: bold;
  color: #000000;
  cursor: var(--w98-cur-hand);
  z-index: 5;
}
/* Hearts flat light-gray nameplates (exact ss_03_full.jpg: no glow, no +handPts) */
.v95-plate {
  position: absolute;
  background: #c0c0c0;
  border: 1px solid #000000;
  width: 120px;
  padding: 2px 4px;
  box-sizing: border-box;
  text-align: center;
  z-index: 3;
}
.v95-plate-name {
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-weight: bold;
  font-size: 11px;
  line-height: 1.15;
  color: #000000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.v95-plate-pts {
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-weight: bold;
  font-size: 11px;
  line-height: 1.15;
  color: #000000;
}
.v95-plate-top { top: 8px; left: 50%; transform: translateX(-50%); }
.v95-plate-left { left: 8px; top: 112px; }
.v95-plate-right { right: 8px; top: 112px; }
.v95-plate-bottom { bottom: 96px; left: 50%; transform: translateX(-50%); }
/* Bridge 120x28 metallic compass nameplates (exact ss_04_full.jpg!) */
.v95-bplate {
  position: absolute;
  width: 120px;
  height: 28px;
  background-repeat: no-repeat;
  background-size: 120px 28px;
  image-rendering: pixelated;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 7px 0 46px;
  box-sizing: border-box;
  z-index: 3;
}
.v95-bplate-name {
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-weight: bold;
  font-size: 11px;
  color: #000060;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.v95-bplate-top { top: 14px; left: 50%; transform: translateX(-50%); }
.v95-bplate-left { left: 10px; top: 130px; }
.v95-bplate-right { right: 10px; top: 130px; }
.v95-bplate-bottom { bottom: 92px; left: 50%; transform: translateX(-50%); }
/* Hearts & Bridge center trick area + crisp 2px black turn outline */
.v95-hearts-center, .v95-bridge-center {
  position: absolute;
  top: 146px;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 2;
}
.v95-bridge-center {
  top: 136px;
  z-index: 4;
}
.v95-deck-frame {
  border: 2px solid #000000;
  padding: 2px;
  line-height: 0;
}
.v95-deck-back {
  display: block;
  image-rendering: pixelated;
}
.v95-trick-cross {
  position: relative;
  width: 170px;
  height: 152px;
}
.v95-trick-slot {
  position: absolute;
  width: 54px;
  height: 72px;
}
.v95-trick-top { top: 0; left: 58px; }
.v95-trick-bottom { bottom: 0; left: 58px; }
.v95-trick-left { top: 40px; left: 0; }
.v95-trick-right { top: 40px; right: 0; }
.v95-turn-box {
  border: 2px solid #000000;
  box-sizing: border-box;
}
/* Flanking bottom Win95 buttons (Last Trick / Options on left; Play / Auto Play on right) */
.v95-felt-left-btns {
  position: absolute;
  left: 14px;
  bottom: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 6;
}
.v95-felt-right-btns {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 6;
}
.v95-felt-btn {
  width: 80px;
  height: 21px;
  padding: 0;
  text-align: center;
}
/* Own hand fan (tight native overlap, crisp 14px raise on click, zero transition/glow/dim) */
.v95-hand-fan {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: flex-end;
  z-index: 5;
}
.v95-card {
  border: none;
  padding: 0;
  margin-left: -37px;
  background-color: transparent;
  cursor: var(--w98-cur-hand);
  image-rendering: pixelated;
  flex: 0 0 auto;
}
.v95-card:first-child {
  margin-left: 0;
}
.v95-card.is-selected {
  transform: translateY(-14px);
}
.v95-card.is-disabled {
  cursor: var(--w98-cur-arrow);
}
/* Bridge genuine sprite Bidding Box */
.v95-bid-panel {
  background: #d4d0c8;
  border: 1px solid #000000;
  box-shadow: inset 1px 1px 0 #ffffff, inset -1px -1px 0 #808080;
  padding: 3px 5px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}
.v95-bid-hdr-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.v95-bid-vul {
  font-weight: bold;
  font-size: 11px;
  color: #000060;
}
.v95-bid-hist {
  width: 100%;
  max-height: 46px;
  overflow-y: auto;
  background: #ffffff;
  border: 1px solid #000000;
}
.v95-bid-tbl {
  width: 100%;
  border-collapse: collapse;
  font-size: 10px;
}
.v95-bid-tbl th, .v95-bid-tbl td {
  border-right: 1px solid #c0c0c0;
  border-bottom: 1px solid #e0e0e0;
  text-align: center;
  padding: 1px 3px;
  width: 25%;
}
.v95-bid-tbl th {
  background: #d4d0c8;
  font-weight: bold;
}
.v95-bid-srow {
  display: flex;
  gap: 1px;
  align-items: center;
  justify-content: center;
}
.v95-bid-srow-dbl {
  gap: 10px;
}
.v95-bid-sep {
  display: inline-block;
  width: 3px;
}
.v95-bid-spbtn {
  border: none;
  padding: 0;
  margin: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  image-rendering: pixelated;
  cursor: var(--w98-cur-hand);
}
.v95-bid-spbtn:disabled {
  cursor: var(--w98-cur-arrow);
}
.v95-bid-wait {
  font-weight: bold;
  font-size: 11px;
  padding: 3px 6px;
}
/* Bridge rotated small-card Dummy hand positioned cleanly at Dummy's actual seat (exact ss_04_full.jpg!) */
.v95-dummy-side {
  position: absolute;
  top: 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  z-index: 4;
}
.v95-dummy-right {
  right: 134px;
}
.v95-dummy-left {
  left: 134px;
}
.v95-dummy-suit-col {
  display: flex;
  flex-direction: column;
}
.v95-dummy-top {
  position: absolute;
  top: 48px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 4;
}
.v95-dummy-top-col {
  display: flex;
  flex-direction: column;
}
.v95-scard {
  border: none;
  padding: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  image-rendering: pixelated;
  cursor: var(--w98-cur-hand);
  flex: 0 0 auto;
}
.v95-scard-l, .v95-scard-r {
  margin-top: -13px;
}
.v95-scard-l:first-child, .v95-scard-r:first-child {
  margin-top: 0;
}
.v95-scard-v {
  margin-top: -22px;
}
.v95-scard-v:first-child {
  margin-top: 0;
}
.v95-scard.is-disabled {
  cursor: var(--w98-cur-arrow);
}
/* === Chess & Go Boards (exact ss_05_full.jpg & ss_06_full.jpg) === */
.v95-chess-stage, .v95-go-stage {
  position: relative;
  flex: 0 0 auto;
  background: #b89860;
}
.v95-board-canvas {
  display: block;
  cursor: var(--w98-cur-hand);
  image-rendering: pixelated;
}
.v95-chess-help {
  position: absolute;
  left: 608px;
  top: 4px;
  z-index: 5;
}
.v95-chess-movelist {
  position: absolute;
  left: 384px;
  top: 108px;
  width: 235px;
  height: 218px;
  box-sizing: border-box;
  overflow-y: scroll;
  background: #ffff99;
  border: none;
  padding: 3px 6px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  line-height: 1.3;
  color: #000000;
  user-select: text;
}
.v95-chess-mrow {
  display: flex;
  gap: 8px;
}
.v95-chess-mnum {
  width: 22px;
  text-align: left;
}
.v95-chess-m1, .v95-chess-m2 {
  width: 68px;
}
.v95-chess-controls {
  position: absolute;
  left: 384px;
  top: 340px;
  display: flex;
  gap: 15px;
}
.v95-chess-btn {
  width: 100px;
  height: 21px;
  padding: 0;
}
.v95-go-help {
  position: absolute;
  left: 564px;
  top: 4px;
  z-index: 5;
}
.v95-go-controls {
  position: absolute;
  left: 473px;
  top: 220px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100px;
}
.v95-go-btn {
  width: 100px;
  height: 20px;
  padding: 0;
}

/* ============================================================================
 * AUTHENTIC APRIL 1997 MICROSOFT INTERNET GAMING ZONE 2.0 (IGZ 2.0 / ZONE 2)
 * Orbital Hub (640x480), Classic/Retail Room Host, cclient.exe ZoneMessage(tm)
 * ============================================================================ */
.igz2-pix {
  image-rendering: pixelated;
}
.igz2-spr-btn {
  padding: 0;
  margin: 0;
  border: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  cursor: pointer;
  image-rendering: pixelated;
}
.igz2-spr-btn:disabled {
  cursor: default;
}

/* --- Orbital Hub Pop-up (exact 640x480 matching igz2.c) --- */
.igz2-hub-wrap {
  display: flex;
  flex-direction: column;
  width: 640px;
  height: 480px;
  background: #000000;
  color: #E2B8A8;
  font-family: Arial, Helvetica, sans-serif;
  user-select: none;
  outline: none;
}
.igz2-hub-stage {
  position: relative;
  width: 640px;
  height: 480px;
  background-color: #000000;
  background-repeat: no-repeat;
  background-size: 640px 480px;
  overflow: hidden;
  image-rendering: pixelated;
}
.igz2-hub-logo {
  position: absolute;
  left: 170px;
  top: 125px;
  width: 252px;
  height: 174px;
  z-index: 2;
  pointer-events: none;
}
.igz2-hub-logo img {
  display: block;
  width: 252px;
  height: 174px;
}
.igz2-hub-tab {
  position: absolute;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  color: #F0DED4;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
  font-weight: bold;
  font-style: italic;
  cursor: pointer;
  z-index: 4;
}
.igz2-hub-tab-svg,
.igz2-hub-tab-bg {
  position: absolute;
  left: 0;
  top: 0;
  display: block;
  pointer-events: none;
}
.igz2-hub-tab-poly {
  fill: #520808;
  stroke: #9E2A2A;
  stroke-width: 1;
}
.igz2-tab-tri {
  fill: #F0DED4;
  stroke: #F0DED4;
  stroke-width: 1;
}
.igz2-hub-tab:hover .igz2-hub-tab-poly {
  fill: #881212;
  stroke: #E0A838;
}
.igz2-hub-tab:hover {
  color: #FFF8E0;
}
.igz2-hub-tab:hover .igz2-tab-tri {
  fill: #FFF8E0;
  stroke: #FFF8E0;
}
.igz2-hub-tab.is-open .igz2-hub-tab-poly {
  fill: #D89C26;
  stroke: #F2D684;
}
.igz2-hub-tab.is-open:hover .igz2-hub-tab-poly {
  fill: #ECBC4C;
  stroke: #F2D684;
}
.igz2-hub-tab.is-open {
  color: #1A0C00;
}
.igz2-hub-tab.is-open .igz2-tab-tri {
  fill: #1A0C00;
  stroke: #1A0C00;
}
.igz2-hub-tab-lbl {
  position: relative;
  display: block;
  line-height: 26px;
  padding: 0 14px;
  white-space: nowrap;
  overflow: hidden;
  text-shadow: 1px 1px 0 #120000;
  pointer-events: none;
}
.igz2-hub-tab.is-open .igz2-hub-tab-lbl {
  text-shadow: none;
}
.igz2-tab-l .igz2-hub-tab-lbl { text-align: left; }
.igz2-tab-r .igz2-hub-tab-lbl { text-align: right; }
.igz2-tab-games .igz2-hub-tab-lbl { padding-right: 24px; }

.igz2-hub-menu {
  position: absolute;
  left: 214px;
  top: 12px;
  width: 198px;
  box-sizing: border-box;
  padding: 5px 0;
  background-color: #D89E28;
  border: 1px solid #EED488;
  z-index: 6;
}
.igz2-mi {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 19px;
  padding: 0 8px 0 12px;
  border: 0;
  background: transparent;
  color: #241200;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}
.igz2-mi:hover,
.igz2-mi.is-active {
  background-color: #EAD48E;
  color: #120800;
}
.igz2-mi-lbl {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.igz2-mi-pop {
  font-size: 11px;
  font-weight: bold;
  color: #602E00;
  margin-left: 6px;
  flex-shrink: 0;
}

.igz2-hub-card {
  position: absolute;
  left: 456px;
  top: 12px;
  width: 170px;
  height: 222px;
  box-sizing: border-box;
  padding: 9px;
  background-color: #2C0202;
  border: 1px solid #660E0E;
  cursor: pointer;
  z-index: 5;
}
.igz2-hub-card:hover {
  border-color: #E2AE3E;
}
.igz2-card-img {
  width: 150px;
  height: 100px;
  margin-bottom: 6px;
  background-repeat: no-repeat;
  background-size: 150px 1500px;
  image-rendering: pixelated;
}
.igz2-card-title {
  color: #FFF4E0;
  font-size: 13px;
  font-weight: bold;
  line-height: 18px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.igz2-card-rule {
  height: 1px;
  background: #801616;
  margin: 3px 0 4px 0;
}
.igz2-card-desc {
  color: #E8D2C4;
  font-size: 11px;
  line-height: 14px;
  height: 44px;
  overflow: hidden;
}
.igz2-card-pop {
  color: #E4AE3A;
  font-size: 11px;
  font-weight: bold;
  line-height: 18px;
  margin-top: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* --- Zone 2.0 Room Host Outer Chrome (exact igz2.c: 164px sidebar + 46px black banner + 28px maroon bar) --- */
.igz2-host-root {
  display: flex;
  width: 100%;
  height: 100%;
  background: #000000;
  color: #FFFFFF;
  font-family: Arial, Helvetica, sans-serif;
  overflow: hidden;
  user-select: none;
}
.igz2-sidebar {
  position: relative;
  width: 164px;
  flex-shrink: 0;
  background: #000000;
  overflow: hidden;
}
.igz2-sb-curve-bg {
  position: absolute;
  left: 0;
  top: 136px;
  width: 164px;
  height: 600px;
  pointer-events: none;
  z-index: 1;
}
.igz2-sb-logo {
  position: absolute;
  left: 8px;
  top: 15px;
  width: 148px;
  height: 102px;
  cursor: pointer;
  z-index: 2;
}
.igz2-sb-logo img {
  display: block;
  width: 148px;
  height: 102px;
}
.igz2-sb-tab {
  position: absolute;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  z-index: 3;
}
.igz2-sb-tab-svg,
.igz2-sb-tab-bg {
  position: absolute;
  left: 0;
  top: 0;
  display: block;
  pointer-events: none;
}
.igz2-sb-tab-bg polygon {
  fill: #94100C;
  stroke: #D43826;
  stroke-width: 1;
}
.igz2-sb-tab:hover .igz2-sb-tab-bg polygon {
  fill: #C02016;
  stroke: #F6844E;
}
.igz2-sb-tab:active .igz2-sb-tab-bg polygon {
  fill: #7C0E0A;
  stroke: #C43824;
}
.igz2-sb-tab-lbl {
  position: relative;
  display: block;
  padding-left: 8px;
  line-height: 25px;
  color: #FFE086;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
  font-weight: bold;
  font-style: italic;
  text-align: left;
  text-shadow: 1px 1px 0 #240000;
  white-space: nowrap;
  pointer-events: none;
}
.igz2-sb-tab:hover .igz2-sb-tab-lbl {
  color: #FFFCE0;
}
.igz2-sb-tab:active .igz2-sb-tab-lbl {
  transform: translate(1px, 1px);
}

.igz2-main-col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: #000000;
}
.igz2-header {
  height: 74px;
  flex-shrink: 0;
  background: #000000;
  display: flex;
  flex-direction: column;
}
.igz2-header-top {
  height: 46px;
  background: #000000;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  overflow: hidden;
}
.igz2-header-flare {
  width: 66px;
  height: 42px;
  flex-shrink: 0;
}
.igz2-title-strip {
  height: 28px;
  box-sizing: border-box;
  background: #4A0A04;
  border-top: 1px solid #8A2412;
  border-bottom: 1px solid #1C0200;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 8px 0 6px;
}
.igz2-title-text {
  color: #FFE086;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 15px;
  font-weight: bold;
  text-shadow: 1px 1px 0 #1A0200;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.igz2-title-status {
  color: #FCEAA4;
  font-size: 11px;
  font-weight: bold;
  margin-left: 8px;
  flex-shrink: 0;
}

/* --- Embedded Classic & Retail Room Viewports --- */
.igz2-viewport {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #000000;
}
.igz2-room-top {
  flex: 1;
  min-height: 0;
  display: flex;
}
.igz2-classic-scroll {
  flex: 1;
  min-width: 0;
  overflow-y: scroll;
  overflow-x: auto;
  background: #330000;
}
.igz2-classic-grid {
  display: grid;
  grid-template-columns: repeat(3, 162px);
  background: #330000;
  width: 486px;
}
.igz2-tbl-cell {
  position: relative;
  width: 162px;
  height: 144px;
  background-repeat: no-repeat;
  background-size: 162px 144px;
  image-rendering: pixelated;
}
.igz2-tbl-num {
  position: absolute;
  color: #FFCF63;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 12px;
  font-weight: bold;
  text-align: center;
  pointer-events: none;
  z-index: 3;
}
.igz2-tbl-icon {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 2;
}
.igz2-chair-spr {
  position: absolute;
  pointer-events: none;
  z-index: 4;
}
.igz2-chair-spr.is-hover {
  filter: brightness(1.18);
}
.igz2-chair-btn {
  position: absolute;
  padding: 0;
  border: 0;
  background-color: transparent;
  cursor: default;
  z-index: 5;
}
.igz2-chair-btn.is-clickable {
  cursor: pointer;
}
.igz2-seat-name {
  position: absolute;
  color: #FFCC66;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 10px;
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
  z-index: 6;
  text-shadow: 1px 1px 0 #000000;
}
.igz2-seat-name.is-self {
  color: #FFFFFF;
}
.igz2-vote-ico {
  position: absolute;
  z-index: 7;
  pointer-events: none;
}
.igz2-start-btn {
  position: absolute;
  z-index: 8;
}
.igz2-kib-btn {
  position: absolute;
  padding: 0;
  border: 0;
  background-color: transparent;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  image-rendering: pixelated;
  cursor: pointer;
  z-index: 8;
}

/* --- Retail 150x150 3x2 Tile Grid (combat/golf/hellbender/monster/outlaw/xvst/generic) --- */
.igz2-retail-scroll {
  flex: 1;
  min-width: 0;
  overflow-y: scroll;
  overflow-x: auto;
  background: #000000;
}
.igz2-retail-grid {
  display: grid;
  grid-template-columns: repeat(3, 150px);
  background: #000000;
  width: 450px;
}
.igz2-retail-tile {
  position: relative;
  width: 150px;
  height: 150px;
  background-repeat: no-repeat;
  background-size: 150px 150px;
  image-rendering: pixelated;
  box-sizing: border-box;
}
.igz2-rt-num {
  position: absolute;
  left: 4px;
  top: 2px;
  width: 62px;
  height: 16px;
  color: #FFFFFF;
  font-family: Arial, sans-serif;
  font-size: 12px;
  font-weight: bold;
  line-height: 16px;
  text-shadow: 1px 1px 0 #000000;
  pointer-events: none;
  z-index: 3;
}
.igz2-rt-desc {
  position: absolute;
  left: 4px;
  top: 20px;
  width: 142px;
  height: 14px;
  color: #FFFFFF;
  font-family: Arial, sans-serif;
  font-size: 11px;
  font-weight: bold;
  line-height: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 1px 1px 0 #000000;
  pointer-events: none;
  z-index: 4;
}
.igz2-rt-emblem {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 2;
}
.igz2-rt-players {
  position: absolute;
  left: 8px;
  top: 40px;
  width: 134px;
  height: 98px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  pointer-events: none;
  z-index: 5;
}
.igz2-rt-pname {
  color: #FFFFFF;
  font-family: Arial, sans-serif;
  font-size: 10px;
  font-weight: bold;
  line-height: 12px;
  text-shadow: 1px 1px 0 #000000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 132px;
}
.igz2-rt-pname.is-host {
  color: #FCEAA4;
}
.igz2-rt-pname.is-self {
  color: #80FF80;
}
.igz2-rt-prog {
  color: #FF8080;
  font-size: 9px;
  font-weight: bold;
  text-shadow: 1px 1px 0 #000000;
  margin-top: 2px;
}
.igz2-rt-btn {
  position: absolute;
  z-index: 7;
}

/* --- Right-side Player Roster (WinXP measured: #313031 header + #000000 list + #FFCF63 bold names) --- */
.igz2-roster-pane {
  width: 114px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  background: #000000;
  border-left: 1px solid #404040;
}
.igz2-roster-pane.is-retail {
  width: 144px;
}
.igz2-roster-hdr {
  background: #313031;
  border-bottom: 1px solid #555555;
  padding: 3px 6px;
  line-height: 1.3;
}
.igz2-roster-hdr.is-retail {
  background: #313031;
  border-bottom: 1px solid #555555;
}
.igz2-roster-cnt {
  color: #FFFFFF;
  font-size: 12px;
  font-weight: bold;
}
.igz2-roster-sub {
  color: #E0E0E0;
  font-size: 10px;
}
.igz2-roster-sub.is-classic-net {
  display: flex;
  align-items: center;
  gap: 3px;
  color: #FFFFFF;
  font-size: 11px;
  font-weight: bold;
}
.igz2-net-ico {
  display: inline-block;
  width: 20px;
  height: 11px;
  vertical-align: middle;
}
.igz2-roster-list {
  flex: 1;
  min-height: 0;
  overflow-y: scroll;
  background: #000000;
  padding: 3px 4px;
}
.igz2-roster-row {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 1px 3px;
  color: #FFCF63;
  font-size: 11px;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
}
.igz2-roster-row:hover {
  background: #441010;
  color: #FFFFFF;
}
.igz2-roster-row.is-self {
  color: #FFCF63;
}
.igz2-light-ico {
  flex-shrink: 0;
}
.igz2-roster-name {
  overflow: hidden;
  text-overflow: ellipsis;
}

/* --- Bottom Lobby Chat Pane (Classic: pure white; Retail: #323232 + yellow input) --- */
.igz2-chat-pane {
  height: 86px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  border-top: 2px solid #808080;
}
.igz2-chat-pane.is-classic {
  background: #FFFFFF;
}
.igz2-chat-pane.is-retail {
  height: 82px;
  background: #323232;
  border-top-color: #555555;
}
.igz2-chat-log {
  flex: 1;
  min-height: 0;
  overflow-y: scroll;
  padding: 3px 6px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  line-height: 1.3;
  user-select: text;
}
.igz2-chat-log.is-classic {
  background: #FFFFFF;
  color: #000000;
}
.igz2-chat-log.is-retail {
  background: #323232;
  color: #FFFFFF;
}
.igz2-chat-sender {
  font-weight: bold;
}
.igz2-chat-log.is-classic .igz2-chat-sys {
  color: #800000;
  font-style: italic;
}
.igz2-chat-log.is-retail .igz2-chat-sys {
  color: #FFCC66;
  font-style: italic;
}
.igz2-chat-in {
  height: 22px;
  flex-shrink: 0;
  border: 0;
  padding: 2px 6px;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  outline: none;
}
.igz2-chat-in.is-classic {
  border-top: 1px solid #000000;
  background: #FFFFFF;
  color: #000000;
}
.igz2-chat-in.is-retail {
  border-top: 1px solid #6E6E6E;
  background: #181818;
  color: #FFFF80;
}

/* --- April 1997 cclient.exe Send ZoneMessage(tm) & Incoming Reply (exact 352x176 igz2.c) --- */
.igz2-zm-canvas {
  position: relative;
  flex: 1;
  width: 352px;
  height: 176px;
  background-color: #040404;
  background-repeat: no-repeat;
  background-size: 352px 176px;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  color: #FFFFFF;
  user-select: none;
  image-rendering: pixelated;
}
.igz2-zm-nick-btn {
  position: absolute;
  left: 10px;
  top: 10px;
  width: 96px;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
  line-height: 14px;
}
.igz2-zm-zn-lbl {
  color: #FFCC66;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  font-weight: bold;
}
.igz2-zm-nick-val {
  display: block;
  color: #FFECBA;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  font-weight: normal;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.igz2-zm-nick-btn:hover .igz2-zm-zn-lbl,
.igz2-zm-nick-btn:hover .igz2-zm-nick-val {
  color: #FFFFFF;
}
.igz2-zm-logo-frame {
  position: absolute;
  left: 15px;
  top: 47px;
  width: 64px;
  height: 64px;
  border: 1px solid #990000;
  line-height: 0;
}
.igz2-zm-logo-frame img {
  display: block;
  width: 64px;
  height: 64px;
}
.igz2-zm-mute-btn {
  position: absolute;
  left: 12px;
  top: 150px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0;
  margin: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.igz2-zm-mute-box {
  display: inline-block;
  width: 10px;
  height: 10px;
  box-sizing: border-box;
  background: #180000;
  border: 1px solid #D28C40;
}
.igz2-zm-mute-box.is-muted {
  background: #F8B020;
}
.igz2-zm-mute-txt {
  color: #F0C680;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 10px;
  line-height: 14px;
}
.igz2-zm-mute-btn:hover .igz2-zm-mute-txt {
  color: #FFFFFF;
}
.igz2-zm-lbl-to {
  position: absolute;
  left: 144px;
  top: 10px;
  color: #FFFFFF;
  font-size: 11px;
  font-weight: normal;
}
.igz2-zm-to {
  position: absolute;
  left: 144px;
  top: 28px;
  width: 192px;
  height: 20px;
  box-sizing: border-box;
  border-top: 2px solid #808080;
  border-left: 2px solid #808080;
  border-right: 1px solid #DFDFDF;
  border-bottom: 1px solid #DFDFDF;
  background: #FFFFFF;
  color: #000000;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  padding: 1px 3px;
  outline: none;
}
.igz2-zm-lbl-msg {
  position: absolute;
  left: 144px;
  top: 60px;
  color: #FFFFFF;
  font-size: 11px;
  font-weight: normal;
}
.igz2-zm-msg {
  position: absolute;
  left: 144px;
  top: 78px;
  width: 192px;
  height: 46px;
  box-sizing: border-box;
  border-top: 2px solid #808080;
  border-left: 2px solid #808080;
  border-right: 1px solid #DFDFDF;
  border-bottom: 1px solid #DFDFDF;
  background: #FFFFFF;
  color: #000000;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  padding: 2px 4px;
  resize: none;
  outline: none;
}
.igz2-zm-status {
  position: absolute;
  left: 144px;
  top: 128px;
  width: 194px;
  height: 14px;
  line-height: 14px;
  color: #D28070;
  font-size: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.igz2-zm-status.is-online {
  color: #ECBA56;
}
.igz2-zm-from-lbl {
  position: absolute;
  left: 14px;
  top: 10px;
  color: #FFCC66;
  font-size: 11px;
  font-weight: bold;
}
.igz2-zm-from-val {
  position: absolute;
  left: 14px;
  top: 24px;
  width: 92px;
  color: #FFCC66;
  font-size: 11px;
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.igz2-zm-in-lbl {
  position: absolute;
  left: 144px;
  top: 6px;
  color: #FFFFFF;
  font-size: 11px;
}
.igz2-zm-in-body {
  position: absolute;
  left: 144px;
  top: 21px;
  width: 192px;
  height: 44px;
  color: #FFE090;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  line-height: 14px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-break: break-word;
  user-select: text;
}
.igz2-zm-rep-lbl {
  position: absolute;
  left: 144px;
  top: 69px;
  color: #FFFFFF;
  font-size: 11px;
}
.igz2-zm-rep-edit {
  position: absolute;
  left: 144px;
  top: 87px;
  width: 192px;
  height: 45px;
  box-sizing: border-box;
  border-top: 2px solid #808080;
  border-left: 2px solid #808080;
  border-right: 1px solid #DFDFDF;
  border-bottom: 1px solid #DFDFDF;
  background: #FFFFFF;
  color: #000000;
  font-family: "MS Sans Serif", Arial, sans-serif;
  font-size: 11px;
  padding: 2px 4px;
  resize: none;
  outline: none;
}
.igz2-zm-send {
  position: absolute;
  left: 184px;
  top: 144px;
}
.igz2-zm-close {
  position: absolute;
  left: 264px;
  top: 144px;
}

/* --- Zone Sign In Modal (exact 330x180 dark crimson #240202 from igz2.c:3858) & Retail Host Modal --- */
.igz2-si-dlg {
  position: relative;
  flex: 1;
  width: 330px;
  height: 180px;
  background: #240202;
  color: #F5E8D2;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 12px;
  user-select: none;
}
.igz2-si-title {
  position: absolute;
  left: 16px;
  top: 12px;
  width: 300px;
  color: #F5E8D2;
  font-size: 14px;
  font-weight: bold;
}
.igz2-si-lbl-u {
  position: absolute;
  left: 16px;
  top: 46px;
  width: 80px;
  color: #F5E8D2;
  font-size: 12px;
}
.igz2-si-lbl-p {
  position: absolute;
  left: 16px;
  top: 78px;
  width: 80px;
  color: #F5E8D2;
  font-size: 12px;
}
.igz2-si-input {
  position: absolute;
  left: 100px;
  width: 214px;
  height: 22px;
  box-sizing: border-box;
  border-top: 2px solid #808080;
  border-left: 2px solid #808080;
  border-right: 1px solid #DFDFDF;
  border-bottom: 1px solid #DFDFDF;
  background: #FFFFFF;
  color: #000000;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 12px;
  padding: 1px 4px;
  outline: none;
}
.igz2-si-input[type="text"] { top: 42px; }
.igz2-si-input[type="password"] { top: 74px; }
.igz2-si-err {
  position: absolute;
  left: 16px;
  top: 106px;
  width: 298px;
  height: 28px;
  color: #E6B448;
  font-size: 11px;
  line-height: 14px;
}
.igz2-si-ok {
  position: absolute;
  left: 138px;
  top: 142px;
  width: 84px;
  height: 26px;
}
.igz2-si-cancel {
  position: absolute;
  left: 230px;
  top: 142px;
  width: 84px;
  height: 26px;
}
.igz2-host-dlg {
  flex: 1;
  background: #C0C0C0;
  color: #000000;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
}
.igz2-dlg-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.igz2-dlg-row label {
  width: 96px;
  flex-shrink: 0;
  color: #000000;
  font-weight: normal;
}
.igz2-dlg-input,
.igz2-dlg-select {
  flex: 1;
  height: 21px;
  box-sizing: border-box;
  border-top: 2px solid #808080;
  border-left: 2px solid #808080;
  border-right: 1px solid #DFDFDF;
  border-bottom: 1px solid #DFDFDF;
  background: #FFFFFF;
  color: #000000;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  padding: 1px 4px;
}
.igz2-dlg-btns {
  margin-top: auto;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.igz2-dlg-btn {
  min-width: 74px;
  height: 22px;
  background: #680E0E;
  border: 1px solid #B63636;
  color: #F6DFDF;
  font-family: Arial, "MS Sans Serif", sans-serif;
  font-size: 11px;
  font-weight: bold;
  cursor: pointer;
}
.igz2-dlg-btn:hover {
  background: #921616;
  border-color: #F0C44C;
  color: #FFFFFF;
}
.igz2-dlg-btn.is-primary {
  background: #C89020;
  border-color: #FCEAA4;
  color: #180A00;
}
.igz2-dlg-btn.is-primary:hover {
  background: #E8B43C;
  color: #000000;
}
