/* Canonical Typography Declarations: House of $QUIT v6 Platform */

/* 1. Jersey 20 and QUIT Display */
@font-face {
  font-family: "Jersey 20";
  src: url("./fonts/jersey-1.woff2") format("woff2"),
       url("../fonts/jersey-1.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "QUIT Display";
  src: url("./fonts/jersey-1.woff2") format("woff2"),
       url("../fonts/jersey-1.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  size-adjust: 118.66%;
  ascent-override: 86.38%;
  descent-override: 23.18%;
  line-gap-override: 0%;
  unicode-range: U+0000-0023, U+0025-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "QUIT Display";
  src: url("./fonts/ibm-plex-mono-latin-600-normal.woff2") format("woff2"),
       url("../fonts/ibm-plex-mono-latin-600-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  size-adjust: 77.76%;
  ascent-override: 131.82%;
  descent-override: 35.37%;
  line-gap-override: 0%;
  unicode-range: U+0024;
}

/* 2. IBM Plex Mono */
@font-face {
  font-family: "IBM Plex Mono";
  src: url("./fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2"),
       url("../fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("./fonts/ibm-plex-mono-latin-600-normal.woff2") format("woff2"),
       url("../fonts/ibm-plex-mono-latin-600-normal.woff2") format("woff2");
  font-weight: 600 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("./fonts/ibm-plex-mono-cyrillic-400-normal.woff2") format("woff2"),
       url("../fonts/ibm-plex-mono-cyrillic-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("./fonts/ibm-plex-mono-cyrillic-600-normal.woff2") format("woff2"),
       url("../fonts/ibm-plex-mono-cyrillic-600-normal.woff2") format("woff2");
  font-weight: 600 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

/* 3. Silkscreen */
@font-face {
  font-family: "Silkscreen";
  src: url("./fonts/Silkscreen-Regular.ttf") format("truetype"),
       url("../fonts/Silkscreen-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Silkscreen";
  src: url("./fonts/Silkscreen-Bold.ttf") format("truetype"),
       url("../fonts/Silkscreen-Bold.ttf") format("truetype");
  font-weight: 700 900;
  font-style: normal;
  font-display: swap;
}

/* 4. VT323 */
@font-face {
  font-family: "VT323";
  src: url("./fonts/VT323-Regular.ttf") format("truetype"),
       url("../fonts/VT323-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* 5. Playfair Display */
@font-face {
  font-family: "Playfair Display";
  src: url("./fonts/playfair-display-latin-700.woff2") format("woff2"),
       url("../fonts/playfair-display-latin-700.woff2") format("woff2");
  font-weight: 500 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Playfair Display";
  src: url("./fonts/playfair-cyrillic.woff2") format("woff2"),
       url("../fonts/playfair-cyrillic.woff2") format("woff2");
  font-weight: 500 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: "House Serif";
  src: url("./fonts/playfair-display-latin-700.woff2") format("woff2"),
       url("../fonts/playfair-display-latin-700.woff2") format("woff2");
  font-weight: 500 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "House Serif";
  src: url("./fonts/playfair-cyrillic.woff2") format("woff2"),
       url("../fonts/playfair-cyrillic.woff2") format("woff2");
  font-weight: 500 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

/* Canonical v6 Design-Token & Shared Shell Layout Sheet (P01..P17 + TMA).
   Token-efficient single stylesheet giving pixel parity with designs/v6/final/*.png
   across both skins:
     1. [data-quit-skin="factory"] (default): Pixel-Comic Dark Office (#030805, #08110e, #f4e7cb, #25dc71, #ff610b)
     2. [data-quit-skin="house"]: House of $QUIT Luxury (#050403, #d8b45e, #efe6d2)
   Zero SVG/Canvas procedural graphics, zero round status dots (square chips only). */

:root,
[data-quit-skin="factory"],
[data-quit-skin="office"],
[data-quit-skin="tma"],
[data-quit-skin="tma_dark_v6"] {
  --q6-bg: #030805;
  --q6-header: #0b1311;
  --q6-plate: #08110e;
  --q6-steel: #101915;
  --q6-rim: #333a32;
  --q6-cream: #f4e7cb;
  --q6-muted: #9aa594;
  --q6-green: #25dc71;
  --q6-orange: #ff610b;
  --q6-blue: #4a9eff;
  --q6-violet: #a585ff;
  --q6-amber: #ffa21f;
  --q6-gold: #ffd23f;
  --q6-red: #ff4757;
  --q6-font-display: "Jersey 20", "QUIT Display", Silkscreen, Impact, ui-sans-serif, system-ui, sans-serif;
  --q6-font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --q6-font-pixel: Silkscreen, "Jersey 20", monospace;
  --q6-font-terminal: VT323, "IBM Plex Mono", monospace;
  --q6-font-serif: "Playfair Display", "House Serif", Georgia, "Times New Roman", serif;
  --q6-topbar-h: 70px;
  --q6-rail-w: 248px;
  --q6-bottombar-h: 64px;
}

[data-quit-skin="house"],
[data-quit-skin="house_gold_v6"],
[data-skin="house_gold_v6"],
.q6-skin-house,
.skin-house-gold {
  --q6-bg: #050403;
  --q6-header: #050403;
  --q6-plate: #0a0806;
  --q6-steel: #120e09;
  --q6-rim: #d8b45e;
  --q6-cream: #efe6d2;
  --q6-muted: #b5a689;
  --q6-green: #d8b45e;
  --q6-orange: #d8b45e;
  --q6-gold: #d8b45e;
  --q6-font-display: "Playfair Display", "House Serif", Georgia, "Times New Roman", serif;
  --q6-font-mono: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --q6-font-serif: "Playfair Display", "House Serif", Georgia, "Times New Roman", serif;
  --q6-font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-variant-numeric: lining-nums;
  font-feature-settings: "lnum" 1;
  background-color: #050403;
  color: #efe6d2;
}

:is(
  [data-quit-skin="house"],
  [data-quit-skin="house_gold_v6"],
  [data-skin="house_gold_v6"],
  .q6-skin-house,
  .skin-house-gold
) :is(h1, h2, h3) {
  font-family: "Playfair Display", Georgia, serif;
}

.q6-shell,
.q6-shell *,
.q6-shell *::before,
.q6-shell *::after {
  box-sizing: border-box;
}

.q6-shell {
  min-height: 100vh;
  background: var(--q6-bg);
  color: var(--q6-cream);
  font-family: var(--q6-font-mono);
  display: flex;
  flex-direction: column;
}

.q6-topbar {
  min-height: var(--q6-topbar-h);
  padding: 0 20px;
  background: linear-gradient(180deg, #121c17 0%, #0a110e 100%);
  border-bottom: 2px solid #222d27;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 4px 16px rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1560px;
  width: 100%;
  margin: 0 auto;
}

.q6-topbar__brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}

.q6-topbar__logo-img {
  width: 42px;
  height: 35px;
  object-fit: contain;
  display: block;
}

.q6-topbar__brand-text {
  display: inline-block;
  font-family: var(--q6-font-display, "Jersey 20", sans-serif);
  font-size: 24px;
  color: #f4d57b;
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1;
  color: var(--q6-cream);
  text-transform: uppercase;
  white-space: nowrap;
}

.q6-topbar__balances {
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: var(--q6-font-mono, monospace);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.q6-topbar__pyramid-img {
  width: 34px;
  height: 29px;
  object-fit: contain;
  vertical-align: middle;
  flex-shrink: 0;
}

.q6-topbar__btn-icon {
  display: inline-block;
  object-fit: contain;
  vertical-align: middle;
  flex-shrink: 0;
  pointer-events: none;
  image-rendering: auto;
}

.q6-topbar__btn-icon--chair {
  width: 15px;
  height: 20px;
}

.q6-topbar__btn-icon--speaker {
  width: 18px;
  height: 15px;
}

.q6-topbar__btn-icon--globe {
  width: 16px;
  height: 16px;
}

.q6-topbar__btn-icon--person {
  width: 14px;
  height: 17px;
}

.q6-topbar__btn-label {
  display: inline-block;
  line-height: 1;
}

.q6-topbar__bell-btn {
  appearance: none;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.q6-topbar__bell-count {
  font-family: var(--q6-font-display, "Jersey 20", sans-serif);
  font-size: 22px;
  line-height: 1;
  color: var(--q6-green);
  font-weight: 700;
}

.q6-topbar__bell-img {
  width: 31px;
  height: 40px;
  object-fit: contain;
  display: block;
}

.q6-topbar__avatar-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--q6-cream);
  cursor: pointer;
}

.q6-topbar__avatar-img {
  width: 52px;
  height: 42px;
  object-fit: contain;
  display: block;
}

.q6-topbar__handle-text {
  font-family: var(--q6-font-mono, monospace);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--q6-cream);
}

.q6-topbar__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.q6-frame {
  flex: 1;
  display: grid;
  grid-template-columns: var(--q6-rail-w) minmax(0, 1fr);
  gap: 20px;
  padding: 20px;
  max-width: 1560px;
  width: 100%;
  margin: 0 auto;
}

[hidden],
.q6-shell [hidden],
.q6-studio-bar[hidden] {
  display: none !important;
}

/* Mode 1: Office Layout (248px rail + 70px topbar) */
.q6-shell--office,
.q6-shell[data-layout-mode="office"] {
  --q6-rail-w: 248px;
  --q6-topbar-h: 70px;
}

.q6-frame--office,
.q6-shell--office .q6-frame,
.q6-frame[data-layout-mode="office"] {
  flex: 1;
  display: grid;
  grid-template-columns: var(--q6-rail-w) minmax(0, 1fr);
  gap: 20px;
  padding: 20px;
  max-width: 1560px;
  width: 100%;
  margin: 0 auto;
}

/* Mode 1: Office Layout (70px single-row QUIT FACTORY topbar, 248px left rail, hidden desktop bottombar) */
.q6-shell--office .q6-topbar,
.q6-shell[data-layout-mode="office"] .q6-topbar {
  display: flex !important;
  flex-wrap: nowrap;
  min-height: 70px;
  height: 70px;
  padding: 0 20px;
  background: var(--q6-header);
  border-bottom: 2px solid var(--q6-rim);
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1560px;
  width: 100%;
  margin: 0 auto;
}

.q6-shell--office .q6-rail {
  display: flex;
  flex-direction: column;
  width: 248px;
}

.q6-frame--office,
.q6-shell--office .q6-frame,
.q6-frame[data-layout-mode="office"] {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  gap: 20px;
  padding: 20px;
  max-width: 1560px;
  width: 100%;
  margin: 0 auto;
}

.q6-shell--office .q6-topbar__brand-text {
  display: inline-block;
}

.q6-shell--office .q6-topbar__balances,
.q6-shell--office .q6-topbar__btn-apply,
.q6-shell--office .q6-topbar__btn-buy,
.q6-shell--office .q6-topbar__btn-lang {
  display: none !important;
}

@media (min-width: 769px) {
  .q6-shell--office .q6-topbar__actions .c-sound {
    display: none !important;
  }
}

.q6-shell--office .q6-topbar__bell-btn,
.q6-shell--office .q6-topbar__btn-share {
  display: inline-flex !important;
}

.q6-shell--office .q6-topbar__actions {
  margin-left: auto;
  flex-wrap: nowrap;
}

/* Mode 2: Floor Layout (Full-width floor max-width 1520px, no left rail, Public Floor Topbar) */
.q6-shell--floor,
.q6-shell[data-layout-mode="floor"] {
  --q6-bg: #070d0a;
  --q6-header: #07120d;
  --q6-plate: #08110e;
  --q6-steel: #0f1c16;
  --q6-rim: #1f3328;
  --q6-cream: #efe6d2;
  --q6-muted: #728a7c;
  --q6-green: #25dc71;
  --q6-orange: #ff610b;
  --q6-gold: #d4af37;
  background-color: var(--q6-bg);
  color: var(--q6-cream);
}

.q6-shell--floor .q6-rail,
.q6-shell[data-layout-mode="floor"] .q6-rail {
  display: none !important;
}

.q6-frame--floor,
.q6-shell--floor .q6-frame,
.q6-frame[data-layout-mode="floor"] {
  display: block !important;
  flex: 1;
  min-height: 0;
  width: 100%;
  max-width: 1520px;
  margin: 0 auto;
  padding: 20px;
}

.q6-frame--floor > .q6-rail,
.q6-shell--floor .q6-frame > .q6-rail,
.q6-frame[data-layout-mode="floor"] > .q6-rail {
  display: none !important;
}

.q6-frame--floor > .q6-main,
.q6-shell--floor .q6-frame > .q6-main,
.q6-frame[data-layout-mode="floor"] > .q6-main {
  display: block;
  width: 100%;
  max-width: 1520px;
  margin: 0 auto;
}

/* Public Floor Topbar matching PL01, EA01, OW01, SH01 */
.q6-shell--floor .q6-topbar,
.q6-shell[data-layout-mode="floor"] .q6-topbar {
  display: flex !important;
  flex-wrap: nowrap;
  min-height: 70px;
  height: 70px;
  padding: 0 24px;
  background: var(--q6-header, #07120d);
  border-bottom: 2px solid var(--q6-rim, #1f3328);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.85);
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  max-width: 1520px;
  width: 100%;
  margin: 0 auto;
}

.q6-shell--floor .q6-topbar__actions {
  display: contents;
}

.q6-shell--floor .q6-topbar__brand { order: 1; }
.q6-shell--floor .q6-topbar__btn-apply { display: inline-flex !important; order: 2; }
.q6-shell--floor .q6-topbar__btn-menu { display: inline-flex !important; order: 3; }
.q6-shell--floor .q6-topbar .c-sound,
.q6-shell--floor .q-sound-toggle { display: inline-flex !important; order: 4; }
.q6-shell--floor .q6-topbar__btn-lang { display: inline-flex !important; order: 5; }
.q6-shell--floor .q6-topbar__balances { order: 6; margin-left: auto; }
.q6-shell--floor .q6-topbar[data-unauthenticated="true"] .q6-topbar__balances {
  display: none !important;
}
.q6-shell--floor .q6-topbar__btn-signin { order: 7; }
.q6-shell--floor .q6-topbar[data-unauthenticated="true"] .q6-topbar__btn-signin {
  margin-left: auto;
}
.q6-shell--floor .q6-topbar__avatar-btn { order: 8; }
.q6-shell--floor .q6-topbar__btn-buy { display: inline-flex !important; order: 9; }

.q6-shell--floor .q6-topbar__bell-btn,
.q6-shell--floor .q6-topbar__btn-share,
.q6-shell--floor .q6-topbar__cash,
.q6-shell--floor .q6-topbar__active-status,
.q6-shell--floor .q6-topbar__brand-text {
  display: none !important;
}

/* Mode 3: House Luxury Layout (760px centered column on #050403 obsidian black) */
.q6-shell--house,
.q6-shell[data-layout-mode="house"] {
  --q6-bg: #050403;
  --q6-header: #050403;
  --q6-plate: #0a0806;
  --q6-steel: #120e09;
  --q6-rim: #d8b45e;
  --q6-cream: #efe6d2;
  --q6-muted: #b5a689;
  --q6-green: #d8b45e;
  --q6-orange: #d8b45e;
  --q6-gold: #d8b45e;
  background-color: #050403;
  color: #efe6d2;
}

/* Suppression rule: rail and bottombar are hidden in House Mode */
.q6-shell--house .q6-rail,
.q6-shell[data-layout-mode="house"] .q6-rail,
.q6-shell--house .q6-bottombar,
.q6-shell[data-layout-mode="house"] .q6-bottombar {
  display: none !important;
}

/* Minimal centered luxury header matching DK01-desktop.png */
.q6-shell--house .q6-topbar,
.q6-shell[data-layout-mode="house"] .q6-topbar {
  display: flex !important;
  flex-wrap: nowrap;
  min-height: 70px;
  height: 70px;
  padding: 0 24px;
  background: #050403;
  border-bottom: 1px solid #d8b45e;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.85);
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 760px;
  width: 100%;
  margin: 0 auto;
}

/* Suppress outer topbar when bespoke House headers (.house-gold-header, .dk01-header, .qu06-topbar) are mounted */
.q6-shell--house:has(.p06-hold-view, .p06-boardroom-view, .p12-desk-landing) > .q6-topbar,
.q6-shell[data-layout-mode="house"]:has(.p06-hold-view, .p06-boardroom-view, .p12-desk-landing) > .q6-topbar {
  display: none !important;
}

.q6-shell--house .q6-topbar__btn-apply,
.q6-shell--house .q6-topbar__btn-share,
.q6-shell--house .q6-topbar__bell-btn,
.q6-shell--house .q6-topbar__cash,
.q6-shell--house .q6-topbar__active-status,
.q6-shell--house .q6-topbar__btn-lang,
.q6-shell--house .q6-topbar__brand-text {
  display: none !important;
}

.q6-frame--house,
.q6-shell--house .q6-frame,
.q6-frame[data-layout-mode="house"] {
  display: block !important;
  flex: 1;
  min-height: 0;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: 32px 16px;
  background-color: #050403;
}

.q6-frame--house > .q6-rail,
.q6-shell--house .q6-frame > .q6-rail,
.q6-frame[data-layout-mode="house"] > .q6-rail {
  display: none !important;
}

.q6-frame--house > .q6-main,
.q6-shell--house .q6-frame > .q6-main,
.q6-frame[data-layout-mode="house"] > .q6-main {
  display: block;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .q6-frame--house,
  .q6-shell--house .q6-frame,
  .q6-frame[data-layout-mode="house"] {
    max-width: 560px;
  }
}

/* Mode 3: TMA Mobile Layout (Centered 420px desktop frame isolation, 100% full-bleed mobile) */
html:has(.q6-shell--tma),
html:has(.q6-shell[data-layout-mode="tma"]),
body:has(.q6-shell--tma),
body:has(.q6-shell[data-layout-mode="tma"]),
html[data-layout-mode="tma"],
body[data-layout-mode="tma"] {
  overflow-x: hidden !important;
  max-width: 100vw;
}

.q6-shell--tma,
.q6-shell[data-layout-mode="tma"] {
  --q6-topbar-h: 56px;
  --q6-bottombar-h: 72px;
  overflow-x: hidden;
  box-sizing: border-box;
}

.q6-shell--tma .q6-rail,
.q6-shell[data-layout-mode="tma"] .q6-rail {
  display: none !important;
}

.q6-shell--tma .q6-topbar__balances,
.q6-shell[data-layout-mode="tma"] .q6-topbar__balances,
.q6-shell--tma .q6-topbar__actions,
.q6-shell[data-layout-mode="tma"] .q6-topbar__actions,
.q6-shell--tma .q6-topbar__btn-apply,
.q6-shell[data-layout-mode="tma"] .q6-topbar__btn-apply,
.q6-shell--tma .q6-topbar__btn-buy,
.q6-shell[data-layout-mode="tma"] .q6-topbar__btn-buy {
  display: none !important;
}

.q6-shell--tma .q6-topbar,
.q6-shell[data-layout-mode="tma"] .q6-topbar {
  min-height: 56px;
  height: 56px;
  padding: 0 16px;
  background: #0b1311;
  border-bottom: 2px solid var(--q6-rim);
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

/* Eliminate duplicate topbar and duplicate 5-tab bottom bar when p17_tma mounts inside SharedAppShell */
.q6-shell--tma:has(.tg02-tma-header, .tg07-header, .tg08-header) > .q6-topbar,
.q6-shell[data-layout-mode="tma"]:has(.tg02-tma-header, .tg07-header, .tg08-header) > .q6-topbar {
  display: none !important;
}

.q6-shell--tma .p17-phone .tg02-bottom-bar,
.q6-shell[data-layout-mode="tma"] .p17-phone .tg02-bottom-bar {
  display: none !important;
}

.q6-frame--tma,
.q6-shell--tma .q6-frame,
.q6-frame[data-layout-mode="tma"] {
  display: block !important;
  width: 100%;
  min-height: 844px;
  margin: 0 auto;
  padding: 0 0 calc(var(--q6-bottombar-h) + 12px) 0;
  position: relative;
}

.q6-frame--tma > .q6-rail,
.q6-shell--tma .q6-frame > .q6-rail,
.q6-frame[data-layout-mode="tma"] > .q6-rail {
  display: none !important;
}

.q6-frame--tma > .q6-main,
.q6-shell--tma .q6-frame > .q6-main,
.q6-frame[data-layout-mode="tma"] > .q6-main {
  display: block;
  width: 100%;
  margin: 0 auto;
}

/* TMA Desktop Frame Isolation on screens greater than 600px */
@media (min-width: 601px) {
  .q6-shell--tma,
  .q6-shell[data-layout-mode="tma"] {
    max-width: 420px;
    width: 100%;
    margin: 24px auto;
    border: 2px solid #1a2522;
    border-radius: 12px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.85);
    overflow: hidden;
    position: relative;
  }

  .q6-frame--tma,
  .q6-shell--tma .q6-frame,
  .q6-frame[data-layout-mode="tma"] {
    max-width: 420px;
    width: 100%;
    margin: 0 auto;
    padding-bottom: 12px;
  }

  .q6-frame--tma > .q6-main,
  .q6-shell--tma .q6-frame > .q6-main,
  .q6-frame[data-layout-mode="tma"] > .q6-main {
    max-width: 420px;
    width: 100%;
    margin: 0 auto;
  }

  .q6-shell--tma .q6-bottombar,
  .q6-shell[data-layout-mode="tma"] .q6-bottombar {
    display: grid !important;
    position: sticky;
    bottom: 0;
    left: auto;
    transform: none;
    width: 100%;
    max-width: 420px;
    z-index: 50;
    height: var(--q6-bottombar-h);
    background: #060c0b;
    border-top: 2px solid #1a2522;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    padding: 6px 8px;
  }
}

/* TMA Mobile Full-Bleed Layout on screens 600px or less */
@media (max-width: 600px) {
  .q6-shell--tma,
  .q6-shell[data-layout-mode="tma"] {
    overflow-x: hidden !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }

  .q6-shell--tma .q6-topbar,
  .q6-shell[data-layout-mode="tma"] .q6-topbar {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  .q6-frame--tma,
  .q6-shell--tma .q6-frame,
  .q6-frame[data-layout-mode="tma"],
  .q6-frame--tma > .q6-main,
  .q6-shell--tma .q6-frame > .q6-main,
  .q6-frame[data-layout-mode="tma"] > .q6-main,
  .p17-tma-home,
  .q6-shell--tma .p17-tma-home,
  .q6-shell[data-layout-mode="tma"] .p17-tma-home {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    border-left: none !important;
    border-right: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }

  .q6-shell--tma .q6-bottombar,
  .q6-shell[data-layout-mode="tma"] .q6-bottombar {
    display: grid !important;
    position: fixed;
    left: 0 !important;
    transform: none !important;
    bottom: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    z-index: 50;
    height: var(--q6-bottombar-h);
    background: #060c0b;
    border-top: 2px solid #1a2522;
    border-radius: 0 !important;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    padding: 6px 4px;
  }
}

/* Mode 4: Bare Layout (clean unstyled full-width wrapper for presentations and research papers) */
.q6-shell--bare .q6-topbar,
.q6-shell[data-layout-mode="bare"] .q6-topbar,
.q6-shell--bare .q6-rail,
.q6-shell[data-layout-mode="bare"] .q6-rail,
.q6-shell--bare .q6-bottombar,
.q6-shell[data-layout-mode="bare"] .q6-bottombar {
  display: none !important;
}

.q6-frame--bare,
.q6-shell--bare .q6-frame,
.q6-frame[data-layout-mode="bare"] {
  display: block !important;
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  border: none;
}

.q6-frame--bare > .q6-rail,
.q6-shell--bare .q6-frame > .q6-rail,
.q6-frame[data-layout-mode="bare"] > .q6-rail {
  display: none !important;
}

.q6-frame--bare > .q6-main,
.q6-shell--bare .q6-frame > .q6-main,
.q6-frame[data-layout-mode="bare"] > .q6-main {
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
}

.q6-rail {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: var(--q6-rail-w);
}

.q6-rail__item {
  appearance: none;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 10px;
  background: var(--q6-steel);
  border-style: solid;
  border-width: 8px 10px;
  border-image: url("/runtime/products/assets/shell/panel.webp") 32 50 fill / 8px 10px stretch;
  color: var(--q6-cream);
  text-decoration: none;
  cursor: pointer;
  transition: border-color 140ms ease, background-color 140ms ease, box-shadow 140ms ease;
  box-sizing: border-box;
}

.q6-rail__icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  object-fit: contain;
  image-rendering: pixelated;
  display: block;
}

.q6-rail__label,
.q6-rail__item > span {
  font-family: var(--q6-font-display, "Jersey 20", sans-serif);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--q6-cream);
  line-height: 1.05;
  white-space: normal;
  min-width: 0;
}

/* Neon-emerald active indicator matching OF01-desktop.png */
.q6-rail__item[aria-current="page"],
.q6-rail__item[aria-selected="true"] {
  border: 2px solid #25dc71;
  background: #0c1c14;
  color: #25dc71;
  box-shadow: 0 0 12px rgba(37, 220, 113, 0.35), inset 0 0 8px rgba(37, 220, 113, 0.15);
}

.q6-rail__item[aria-current="page"] .q6-rail__label,
.q6-rail__item[aria-current="page"] > span {
  color: #25dc71;
  text-shadow: 0 0 8px rgba(37, 220, 113, 0.4);
}

.q6-rail__item:hover:not([aria-current="page"]) {
  border-color: #4a5c51;
  background: #13201a;
}

.q6-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.q6-plate,
.q6-plate-riveted,
.q6-gunmetal-plate,
.q6-plate-gunmetal {
  border-style: solid;
  border-width: 16px 20px;
  border-image: url("/runtime/products/assets/shell/panel.webp") 32 50 fill / 16px 20px stretch;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
  box-sizing: border-box;
}

.q6-rim-green { border-color: var(--q6-green); }
.q6-rim-blue { border-color: var(--q6-blue); }
.q6-rim-violet { border-color: var(--q6-violet); }
.q6-rim-amber { border-color: var(--q6-amber); }
.q6-rim-orange { border-color: var(--q6-orange); }
.q6-rim-gold { border-color: var(--q6-gold); }
.q6-rim-red { border-color: var(--q6-red); }

span.q6-chip:empty,
.q6-chip:empty {
  display: inline-block;
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: var(--q6-green);
  margin-right: 6px;
  vertical-align: middle;
  flex-shrink: 0;
}

.q6-chip:not(:empty),
button.q6-chip {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: auto;
  height: auto;
  padding: 6px 12px;
  border-radius: 0;
  background: var(--q6-steel);
  border: 1px solid var(--q6-rim);
  color: var(--q6-cream);
  font-family: var(--q6-font-mono);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  vertical-align: middle;
}

.q6-plate > .q6-chip:not(:empty),
header > .q6-chip:not(:empty) {
  align-self: flex-start;
}

.q6-chip--active,
.q6-chip:not(:empty).q6-chip--active,
button.q6-chip.q6-chip--active,
.q6-chip[aria-pressed="true"],
button.q6-chip[aria-pressed="true"] {
  border: 2px solid var(--q6-green);
  color: var(--q6-green);
  background: #0b1d15;
}

.q6-chip--held,
button.q6-chip.q6-chip--held {
  border-style: dashed;
  border-color: var(--q6-amber);
  color: var(--q6-muted);
}

:is(
  [data-quit-skin="house"],
  [data-quit-skin="house_gold_v6"],
  [data-skin="house_gold_v6"],
  .q6-skin-house,
  .skin-house-gold
) :is(
  .q6-chip--active,
  .q6-chip[aria-pressed="true"],
  .q6-rail__item[aria-current="page"],
  .q6-rail__item[aria-selected="true"]
) {
  background: #17120a;
  border-color: #d8b45e;
  color: #d8b45e;
}

.q6-key,
.q6-key--dark {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-style: solid;
  border-width: 8px 11px 10px 11px;
  border-image: url("/runtime/products/assets/shell/panel.webp") 32 50 fill / 8px 11px 10px 11px stretch;
  background: #101915;
  color: var(--q6-cream);
  font-family: var(--q6-font-display, "Jersey 20", sans-serif);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 6px 14px;
  text-transform: uppercase;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  box-sizing: border-box;
}

.q6-key--green-outline {
  border-style: solid;
  border-width: 9px 13px 11px 13px;
  border-image: url("/runtime/products/assets/shell/key-dark.webp") 42 46 50 46 fill / 9px 13px 11px 13px stretch;
  background: transparent;
  color: var(--q6-green);
}

.q6-key--orange {
  border-style: solid;
  border-width: 8px 11px 10px 11px;
  border-image: url("/runtime/products/assets/shell/key-orange.webp") 22 24 34 24 fill / 8px 11px 10px 11px stretch;
  background: transparent;
  color: #080b09;
}

.q6-key--green {
  border-style: solid;
  border-width: 8px 11px 10px 11px;
  border-image: url("/runtime/products/assets/shell/key-green.webp") 22 24 34 24 fill / 8px 11px 10px 11px stretch;
  background: transparent;
  color: #080b09;
}

.q6-key--gold {
  background: linear-gradient(180deg, #e7c873 0%, #c89d42 100%);
  border-color: #f0d78c;
  color: #050403;
}

.q6-key--gold-outline {
  background: #120e09;
  border-color: #d8b45e;
  color: #efe6d2;
}

.q6-key.q6-key--gold-rim,
.q6-topbar .q6-key.q6-key--gold-rim,
.q6-shell--floor .q6-topbar .q6-key.q6-key--gold-rim,
.q6-shell--house .q6-topbar .q6-key.q6-key--gold-rim,
.q6-shell--office .q6-topbar .q6-key.q6-key--gold-rim {
  border-image: none;
  border: 2px solid #d4af37;
  border-radius: 2px;
  background: linear-gradient(180deg, #13211a 0%, #09120e 100%);
  color: #25dc71;
  padding: 7px 14px;
  box-shadow: inset 0 1px 0 rgba(255, 224, 130, 0.28), inset 0 -2px 0 rgba(0, 0, 0, 0.72), 0 2px 6px rgba(0, 0, 0, 0.65);
}

.q6-key.q6-key--riveted-green,
.q6-topbar button.c-sound.q6-key--riveted-green {
  border-radius: 0 !important;
  border-style: solid;
  border-width: 7px 10px 9px 10px;
  border-image: url("/runtime/products/assets/shell/panel.webp") 32 50 fill / 7px 10px 9px 10px stretch;
  background: #0d1713;
  color: #25dc71 !important;
  font-family: var(--q6-font-display, "Jersey 20", sans-serif);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 5px 11px;
  line-height: 1;
  min-height: 0;
  height: auto;
  box-shadow: none;
}

/* Glowing Neon Rounded-Square Bays */
.q6-neon-bay,
.q6-icon-bay--neon {
  border-radius: 10px;
  border: 2px solid var(--neon, #25dc71);
  box-shadow: 0 0 12px var(--neon-glow, rgba(37, 220, 113, 0.4)), inset 0 0 6px var(--neon-glow, rgba(37, 220, 113, 0.2));
  background: #08110e;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-sizing: border-box;
}

.q6-neon-bay--blue { --neon: #4a9eff; --neon-glow: rgba(74, 158, 255, 0.4); }
.q6-neon-bay--violet { --neon: #a585ff; --neon-glow: rgba(165, 133, 255, 0.4); }
.q6-neon-bay--amber { --neon: #ffa21f; --neon-glow: rgba(255, 162, 31, 0.4); }
.q6-neon-bay--orange { --neon: #ff610b; --neon-glow: rgba(255, 97, 11, 0.4); }
.q6-neon-bay--gold { --neon: #ffd23f; --neon-glow: rgba(255, 210, 63, 0.4); }

/* Glossy Glass XP Progress Tubes */
.q6-xp-tube {
  position: relative;
  height: 14px;
  background: #040906;
  border: 1px solid #1c2b22;
  border-radius: 7px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.8), 0 1px 0 rgba(255, 255, 255, 0.06);
  box-sizing: border-box;
}

.q6-xp-tube::after {
  content: "";
  position: absolute;
  top: 1px;
  left: 4px;
  right: 4px;
  height: 4px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.45) 0%, rgba(255, 255, 255, 0) 100%);
  border-radius: 2px;
  pointer-events: none;
  z-index: 2;
}

.q6-xp-tube__fill {
  height: 100%;
  background: linear-gradient(180deg, #38ef7d 0%, #11998e 100%);
  box-shadow: 0 0 10px rgba(37, 220, 113, 0.6);
  border-radius: 6px;
  transition: width 300ms ease;
}

.q6-xp-tube__fill--amber {
  background: linear-gradient(180deg, #ffd23f 0%, #ff853d 100%);
  box-shadow: 0 0 10px rgba(255, 162, 31, 0.6);
}

.q6-xp-tube__fill--blue {
  background: linear-gradient(180deg, #4a9eff 0%, #1e5db0 100%);
  box-shadow: 0 0 10px rgba(74, 158, 255, 0.6);
}

.q6-kanban {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.q6-pillars {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.q6-bottombar {
  display: none;
}

.q6-shell .p04-phone-bar {
  display: none !important;
}

@media (min-width: 769px) {
  .q6-shell:not(.q6-shell--tma):not([data-layout-mode="tma"]) .q6-bottombar {
    display: none !important;
  }
}

.q6-drawer[hidden],
.q6-share-sheet[hidden] {
  display: none;
}

.q6-drawer,
.q6-share-sheet {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(3, 8, 5, 0.86);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.q6-drawer__panel,
.q6-share-sheet__panel {
  width: min(520px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  background: var(--q6-plate);
  border: 2px solid var(--q6-green);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.q6-row-between {
  justify-content: space-between;
  width: 100%;
}

.q6-share-sheet__preview {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  border: 1px solid var(--q6-rim);
  display: block;
}

.q6-share-sheet__note {
  margin: 0;
  font-size: 13px;
}

.q6-drawer__hint {
  color: var(--q6-muted);
  font-weight: 500;
  text-transform: none;
}

.qo-inline-input {
  margin-left: 8px;
}

.qo-full-input {
  width: 100%;
  box-sizing: border-box;
}

.qo-qa-fieldset {
  border: 1px solid var(--q6-rim);
  padding: 8px;
}

.qo-qa-choice {
  display: block;
}

@media (max-width: 768px) {
  .q6-frame,
  .q6-frame--office,
  .q6-shell--office .q6-frame,
  .q6-frame[data-layout-mode="office"] {
    grid-template-columns: 1fr;
    padding: 12px 12px calc(var(--q6-bottombar-h) + 20px);
  }
  .q6-frame--floor,
  .q6-shell--floor .q6-frame,
  .q6-frame[data-layout-mode="floor"],
  .q6-frame--house,
  .q6-shell--house .q6-frame,
  .q6-frame[data-layout-mode="house"] {
    padding: 12px;
  }
  .q6-rail,
  .q6-shell--office .q6-rail {
    display: none !important;
  }
  .q6-kanban,
  .q6-pillars {
    grid-template-columns: 1fr;
  }
  .q6-shell--office .q6-topbar,
  .q6-shell[data-layout-mode="office"] .q6-topbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    height: auto;
    min-height: 64px;
    padding: 8px 10px;
    gap: 6px;
    box-sizing: border-box;
    max-width: 100%;
  }
  .q6-shell--office .q6-topbar__brand {
    order: 1;
    min-width: 0;
    flex-shrink: 1;
  }
  .q6-shell--office .q6-topbar__logo-img {
    width: 96px;
    height: auto;
  }
  .q6-shell--office .q6-topbar__brand-text,
  .q6-shell--office .q6-topbar__btn-share,
  .q6-shell--office .q6-topbar__btn-lang {
    display: none !important;
  }
  .q6-shell--office .q6-topbar__actions {
    display: contents;
  }
  .q6-shell--office .q6-topbar .c-sound {
    order: 2;
    margin-left: auto;
    padding: 4px 8px;
    font-size: 11px;
  }
  .q6-shell--office .q6-topbar__btn-buy {
    display: inline-flex !important;
    order: 3;
    padding: 4px 10px;
    font-size: 13px;
    border-width: 6px 8px;
    border-image-width: 6px 8px;
  }
  .q6-shell--office .q6-topbar__btn-menu {
    order: 4;
    padding: 4px 10px;
    font-size: 13px;
    border: 2px solid #d4af37;
    border-image: none;
  }
  .q6-shell--office .q6-topbar__avatar-btn,
  .q6-shell--office .q6-topbar__btn-signin {
    order: 5;
  }
  .q6-shell--office .q6-topbar__bell-btn {
    order: 6;
    margin-left: auto;
  }
  .q6-shell--office .q6-topbar__balances {
    order: 7;
    flex: 1 0 100%;
    min-width: 0;
    max-width: 100%;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 8px;
    padding: 6px 10px;
    border: 2px solid var(--q6-rim);
    background: #07110d;
    font-size: 12px;
    box-sizing: border-box;
  }
  @media (max-width: 380px) {
    .q6-shell--office .q6-topbar {
      padding: 6px 8px;
      gap: 4px;
    }
    .q6-shell--office .q6-topbar__logo-img {
      width: 78px;
    }
    .q6-shell--office .q6-topbar__btn-buy {
      padding: 3px 6px;
      font-size: 11px;
      border-width: 4px 6px;
      border-image-width: 4px 6px;
    }
    .q6-shell--office .q6-topbar__btn-menu {
      padding: 3px 6px;
      font-size: 11px;
      border: 2px solid #d4af37;
      border-image: none;
    }
    .q6-shell--office .q6-topbar .c-sound {
      padding: 3px 6px;
      font-size: 10px;
    }
  }
  .q6-shell--floor .q6-topbar,
  .q6-shell[data-layout-mode="floor"] .q6-topbar,
  .q6-shell--house .q6-topbar,
  .q6-shell[data-layout-mode="house"] .q6-topbar,
  .q6-shell--app .q6-topbar,
  .q6-shell[data-layout-mode="app"] .q6-topbar {
    flex-wrap: wrap;
    height: auto;
    min-height: 60px;
    padding: 8px 10px;
    gap: 6px;
    box-sizing: border-box;
    max-width: 100%;
  }
  .q6-shell--floor .q6-topbar__actions,
  .q6-shell--house .q6-topbar__actions,
  .q6-shell--app .q6-topbar__actions,
  .q6-shell[data-layout-mode="app"] .q6-topbar__actions,
  .q6-shell--floor .q6-topbar__balances,
  .q6-shell--house .q6-topbar__balances,
  .q6-shell--app .q6-topbar__balances,
  .q6-shell[data-layout-mode="app"] .q6-topbar__balances {
    flex-wrap: wrap;
    min-width: 0;
    max-width: 100%;
    gap: 6px;
  }
  .q6-shell--floor .q6-topbar__brand-text,
  .q6-shell--house .q6-topbar__brand-text,
  .q6-shell--app .q6-topbar__brand-text,
  .q6-shell[data-layout-mode="app"] .q6-topbar__brand-text,
  .q6-shell--floor .q6-topbar__btn-apply,
  .q6-shell--floor .q6-topbar__btn-lang,
  .q6-shell--floor .q6-topbar .c-sound,
  .q6-shell--house .q6-topbar__btn-apply,
  .q6-shell--house .q6-topbar__btn-lang,
  .q6-shell--house .q6-topbar__btn-share,
  .q6-shell--house .q6-topbar .c-sound,
  .q6-shell--app .q6-topbar__btn-apply,
  .q6-shell[data-layout-mode="app"] .q6-topbar__btn-apply,
  .q6-shell--app .q6-topbar__btn-lang,
  .q6-shell[data-layout-mode="app"] .q6-topbar__btn-lang,
  .q6-shell--app .q6-topbar__btn-share,
  .q6-shell[data-layout-mode="app"] .q6-topbar__btn-share,
  .q6-shell--app .q6-topbar .c-sound,
  .q6-shell[data-layout-mode="app"] .q6-topbar .c-sound {
    display: none !important;
  }
  .q6-shell--floor .q6-topbar__logo-img,
  .q6-shell--house .q6-topbar__logo-img,
  .q6-shell--app .q6-topbar__logo-img,
  .q6-shell[data-layout-mode="app"] .q6-topbar__logo-img {
    width: 92px;
    height: auto;
  }
  .q6-shell--floor .q6-topbar .q6-key:not(.q6-key--gold-rim),
  .q6-shell--house .q6-topbar .q6-key:not(.q6-key--gold-rim),
  .q6-shell--app .q6-topbar .q6-key:not(.q6-key--gold-rim),
  .q6-shell[data-layout-mode="app"] .q6-topbar .q6-key:not(.q6-key--gold-rim) {
    padding: 4px 8px;
    font-size: 12px;
    border-width: 5px 7px;
    border-image-width: 5px 7px;
  }
  .q6-shell--floor .q6-topbar .q6-key.q6-key--gold-rim,
  .q6-shell--house .q6-topbar .q6-key.q6-key--gold-rim,
  .q6-shell--app .q6-topbar .q6-key.q6-key--gold-rim,
  .q6-shell[data-layout-mode="app"] .q6-topbar .q6-key.q6-key--gold-rim {
    padding: 5px 10px;
    font-size: 12px;
    border: 2px solid #d4af37;
    border-image: none;
  }
  .q6-shell--floor .q6-bottombar,
  .q6-shell[data-layout-mode="floor"] .q6-bottombar,
  .q6-shell--house .q6-bottombar,
  .q6-shell[data-layout-mode="house"] .q6-bottombar {
    display: none !important;
  }
  .q6-shell--office .q6-bottombar,
  .q6-shell[data-layout-mode="office"] .q6-bottombar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;
    height: var(--q6-bottombar-h);
    background: var(--q6-header);
    border-top: 2px solid var(--q6-rim);
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    padding: 4px 6px;
  }
  .q6-shell--office .q6-bottombar .q6-key,
  .q6-shell[data-layout-mode="office"] .q6-bottombar .q6-key {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 3px 2px;
    border-width: 4px 6px;
    border-image-width: 4px 6px;
    font-size: 11px;
    letter-spacing: 0.02em;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .q6-bottombar__icon {
    width: 22px;
    height: 22px;
    object-fit: contain;
    display: block;
    flex-shrink: 0;
  }
}

@media (max-width: 480px) {
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center;
    justify-content: flex-start;
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
    padding: 0 8px !important;
    gap: 6px !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box;
    overflow: hidden;
  }
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar__actions {
    display: contents !important;
  }
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) :is(
    .q6-topbar__brand-text,
    .q6-topbar__btn-apply,
    .q6-topbar__balances,
    .q6-topbar__btn-share,
    .q6-topbar__btn-lang,
    .q6-topbar__bell-btn,
    .q6-topbar__btn-signin,
    .q6-topbar__avatar-btn
  ) {
    display: none !important;
  }
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar__brand {
    order: 1;
    margin-right: auto;
    min-width: 0;
    flex-shrink: 1;
  }
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar__logo-img {
    width: 82px;
    height: 26px;
  }
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar .q6-topbar__btn-sound {
    display: inline-flex !important;
    order: 2;
    margin-left: 0;
    padding: 4px 5px;
    border-width: 4px 5px;
    border-image-width: 4px 5px;
    flex-shrink: 0;
  }
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar .q6-topbar__btn-sound .q6-topbar__btn-label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar__btn-buy {
    display: inline-flex !important;
    order: 3;
    padding: 3px 7px;
    font-size: 12px;
    border-width: 4px 6px 5px 6px;
    border-image-width: 4px 6px 5px 6px;
    white-space: nowrap;
    flex-shrink: 0;
  }
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar__btn-menu {
    display: inline-flex !important;
    order: 4;
    padding: 5px 8px;
    font-size: 12px;
    border: 2px solid #d4af37;
    border-image: none;
    white-space: nowrap;
    flex-shrink: 0;
  }
}

@media (max-width: 359px) {
  :is(
    .q6-shell--floor,
    .q6-shell[data-layout-mode="floor"],
    .q6-shell--house,
    .q6-shell[data-layout-mode="house"],
    .q6-shell--app,
    .q6-shell[data-layout-mode="app"],
    .q6-shell--office,
    .q6-shell[data-layout-mode="office"]
  ) .q6-topbar__logo-img {
    width: 68px;
    height: 22px;
  }
}

@media (max-width: 600px) {
  .q6-topbar {
    padding: 8px 12px;
    gap: 8px;
  }
  .q6-plate {
    padding: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .q6-shell *,
  .q6-shell *::before,
  .q6-shell *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Shared Topbar Button & Growth Job Board (.qo-*) v6 Pixel-Parity Chrome */
.q6-topbar button:not(.q6-key):not(.q6-topbar__bell-btn),
.qo-key {
  appearance: none;
  padding: 10px 14px;
  border: 1px solid var(--q6-rim);
  background: var(--q6-steel);
  color: var(--q6-cream);
  font-family: var(--q6-font-mono);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
}

/* Studio Layout Sheet (strict CSP safe, zero runtime <style> injection) */
.q6-app-body { margin: 0; background: var(--q6-bg, #030805); color: var(--q6-cream, #f4e7cb); }
.q6-studio-bar { background: #060d0a; border-bottom: 2px solid #25dc71; padding: 8px 14px; font-family: var(--q6-font-mono, monospace); position: sticky; top: 0; z-index: 95; }
.q6-studio-bar__row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; max-width: 1680px; margin: 0 auto; }
.q6-studio-bar__badge { font-size: 11px; font-weight: 900; letter-spacing: 0.06em; color: #25dc71; padding: 5px 8px; border: 1px solid #25dc71; background: #0b1d15; white-space: nowrap; }
.q6-studio-select { background: #101915; color: #f4e7cb; border: 1px solid #333a32; padding: 7px 10px; font: inherit; font-size: 12px; font-weight: 700; max-width: 280px; }
.q6-studio-bar__Quick, .q6-studio-bar__modes { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.q6-studio-bar .q6-key { padding: 6px 10px; font-size: 11px; }
.q6-stage-wrap { display: block; width: 100%; }
.q6-stage-wrap[data-viewport-mode="mobile"] .q6-app-mount { max-width: 390px; margin: 18px auto; border: 2px solid #333a32; box-shadow: 0 20px 60px rgba(0,0,0,0.65); }
.q6-stage-wrap[data-compare-open="true"] { display: grid; grid-template-columns: minmax(0, 64%) minmax(320px, 36%); gap: 14px; align-items: start; padding: 10px; }
.q6-design-ref { position: sticky; top: 62px; max-height: calc(100vh - 76px); overflow-y: auto; }
.q6-design-ref__head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; }
.q6-design-ref__img { width: 100%; height: auto; display: block; border: 1px solid #333a32; background: #050807; }
@media (max-width: 960px) {
  .q6-stage-wrap[data-compare-open="true"] { grid-template-columns: 1fr; }
}

.qo-key--orange {
  background: var(--q6-orange);
  border-color: #ff853d;
  color: #080b09;
}

.qo-key--green {
  border-color: var(--q6-green);
  color: var(--q6-green);
  background: #0b1d15;
}

.qo-panel {
  background: var(--q6-plate);
  border: 1px solid var(--q6-rim);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.qo-growth-milestone {
  border: 2px solid var(--q6-green);
  background: linear-gradient(180deg, #091711 0%, #07100d 100%);
}

.qo-growth-verified {
  border-color: var(--q6-green);
}

.qo-kicker {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--q6-green);
}

.qo-panel h2 {
  margin: 0;
  font-family: var(--q6-font-display);
  font-size: 24px;
  letter-spacing: 0.04em;
  color: var(--q6-orange);
  text-transform: uppercase;
}

.qo-panel h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.03em;
  color: var(--q6-cream);
  text-transform: uppercase;
}

.qo-panel p {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
  color: var(--q6-muted);
}

.qo-details {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.qo-details > div {
  background: var(--q6-steel);
  border: 1px solid var(--q6-rim);
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.qo-details dt {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--q6-muted);
  text-transform: uppercase;
}

.qo-details dd {
  margin: 0;
  font-size: 15px;
  font-weight: 900;
  color: var(--q6-cream);
}

.qo-growth-card {
  background: var(--q6-steel);
  border: 1px solid var(--q6-rim);
}

.qo-growth-reward {
  font-size: 12px;
  color: var(--q6-cream);
}

.qo-growth-reward strong {
  color: var(--q6-gold);
  font-weight: 900;
}

.q6-shell .c-tabs,
.q6-shell [role="tablist"] {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.q6-shell [role="tab"] {
  appearance: none;
  padding: 8px 12px;
  background: var(--q6-steel);
  border: 1px solid var(--q6-blue);
  color: var(--q6-cream);
  font-family: var(--q6-font-mono);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
}

.q6-shell [role="tab"][aria-selected="true"] {
  background: #0b1d15;
  border: 2px solid var(--q6-green);
  color: var(--q6-green);
}

.q6-shell input:not([type="checkbox"]):not([type="radio"]),
.q6-shell select,
.q6-shell textarea {
  background: var(--q6-steel);
  border: 1px solid var(--q6-rim);
  color: var(--q6-cream);
  padding: 8px 10px;
  font-family: var(--q6-font-mono);
  font-size: 12px;
}

@media (max-width: 960px) {
  .qo-details {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ST01 PAPERS & TOKENOMICS SHOWCASE SECTION (P14-S006-ST01-papers) */

.st01-papers-showcase,
.q-papers-showcase {
  margin: 32px 0;
  padding: 28px 24px;
  background: #050807;
  border: 1px solid #1c2b22;
  border-top: 2px solid #d4af37;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.7), 0 0 16px rgba(212, 175, 55, 0.06);
}

.st01-papers-header,
.q-papers-showcase__header {
  margin-bottom: 24px;
  text-align: left;
}

.st01-papers-title,
.q-papers-showcase__title {
  margin: 8px 0;
  font-family: var(--q6-font-display, 'Jersey 20', sans-serif);
  font-size: 28px;
  letter-spacing: 0.04em;
  color: #f4e7cb;
}

.st01-papers-lead,
.q-papers-showcase__lead {
  max-width: 820px;
  margin: 0;
  font-family: var(--q6-font-mono, monospace);
  font-size: 13px;
  line-height: 1.6;
  color: #9cb2a3;
}

.st01-papers-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 12px;
  margin-bottom: 28px;
}

.st01-papers-metrics .q-telem-cell {
  padding: 14px 16px;
  background: #080f0b;
  border: 1px solid #1c2b22;
  border-image: none;
  border-radius: 2px;
  box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.q-telem-label {
  font-family: var(--q6-font-mono, monospace);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: #728a7c;
  text-transform: uppercase;
}

.q-telem-val {
  font-family: var(--q6-font-mono, monospace);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.q-telem-val.gold { color: #d4af37; }
.q-telem-val.green { color: #25dc71; }
.q-telem-val.orange { color: #ffa21f; }

.q-telem-sub {
  font-size: 11px;
  color: #5d7568;
  line-height: 1.4;
}

.st01-papers-cards,
.q-papers-showcase__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 16px;
}

.st01-paper-card,
.q-papers-card {
  padding: 24px;
  background: #080f0b;
  border: 1px solid #233429;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.st01-paper-card:hover,
.q-papers-card:hover {
  border-color: #d4af37;
  box-shadow: 0 4px 20px rgba(212, 175, 55, 0.12);
}

.st01-paper-card__badge,
.q-papers-card__badge {
  font-family: var(--q6-font-mono, monospace);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 4px 8px;
  align-self: flex-start;
  border: 1px solid currentColor;
}
.st01-paper-card__badge.blue { color: #4a9eff; border-color: #1a4575; background: #0a1828; }
.st01-paper-card__badge.violet { color: #a585ff; border-color: #49337d; background: #160d2e; }
.st01-paper-card__badge.orange { color: #ffa21f; border-color: #7d4410; background: #261304; }

.st01-paper-card__title,
.q-papers-card__title {
  margin: 0;
  font-family: var(--q6-font-display, 'Jersey 20', sans-serif);
  font-size: 22px;
  letter-spacing: 0.04em;
  color: #f4e7cb;
}

.st01-paper-card__desc,
.q-papers-card__desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: #9cb2a3;
  flex: 1;
}

.st01-paper-card__meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-family: var(--q6-font-mono, monospace);
  font-size: 10px;
  color: #5d7568;
}

.st01-paper-card__actions {
  margin-top: 8px;
}

.q6-key-gold {
  background: #d4af37;
  color: #050403;
  border: 1px solid #ffd700;
  font-weight: 800;
  padding: 8px 16px;
  display: inline-block;
  text-decoration: none;
  font-family: var(--q6-font-mono, monospace);
  font-size: 12px;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: background 120ms ease, box-shadow 120ms ease;
}

.q6-key-gold:hover {
  background: #f5c542;
  box-shadow: 0 0 14px rgba(212, 175, 55, 0.4);
}

/* Keep the far-right VAULT tab on /play and .et-shell unobstructed by floating support bubbles */
.q6-shell:has(.et-shell) .p03-support-bubble,
.q6-shell[data-active-section="play"] .p03-support-bubble,
.p03-container:has(.et-shell) .p03-support-bubble,
body:has(.et-shell) .p03-support-bubble,
body:has(.et-shell) .qs-bubble,
body:has(.q6-shell[data-active-section="play"]) .qs-bubble {
  display: none !important;
  pointer-events: none !important;
}
