:root {
    --game-bg: #000;
    --game-accent: #ceff00;
    --game-text: #fff;
    --game-muted: #a0a0a0;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body.game-shell {
    font-family: 'Space Grotesk', sans-serif;
    line-height: 1.5;
    color: var(--game-text);
    background: var(--game-bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.game-header {
    display: flex;
    justify-content: flex-end;
    padding: 24px 40px;
}

.game-header img {
    height: 36px;
    width: auto;
}

.game-main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 40px 64px;
}

.game-content {
    width: 100%;
    max-width: 640px;
    text-align: center;
}

.game-content h1 {
    font-family: 'Bison Bold', sans-serif;
    font-weight: 200;
    font-size: clamp(2rem, 5vw, 3rem);
    line-height: 1.05;
    margin-bottom: 16px;
}

.game-content h1 .accent {
    color: var(--game-accent);
}

.game-content p {
    color: var(--game-muted);
    font-size: 1.125rem;
    max-width: 480px;
    margin: 0 auto 32px;
}

.game-badge {
    display: inline-block;
    border: 1px solid var(--game-accent);
    color: var(--game-accent);
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 0.875rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.game-badge-error {
    border-color: #ff6b6b;
    color: #ff6b6b;
}

.game-panel[hidden] {
    display: none !important;
}

.game-lead {
    color: var(--game-muted);
    font-size: 1.125rem;
    max-width: 520px;
    margin: 0 auto 32px;
}

.game-form {
    text-align: left;
    max-width: 420px;
    margin: 0 auto;
}

.game-setup-extra {
    margin: 20px auto 0;
    max-width: 420px;
    text-align: center;
}

/* Landing / setup panel */
.game-content:has(#game-panel-setup:not([hidden])) {
    max-width: 720px;
}

.game-panel--landing .game-lead--hero {
    font-size: 1.25rem;
    color: var(--game-text);
    margin-bottom: 20px;
}

.game-landing-copy {
    max-width: 560px;
    margin: 0 auto 28px;
    text-align: center;
}

.game-landing-copy p {
    font-size: 1.05rem;
    line-height: 1.6;
    margin-bottom: 14px;
    max-width: none;
}

.game-landing-copy p:last-child {
    margin-bottom: 0;
}

.game-landing-copy strong {
    color: var(--game-text);
    font-weight: 600;
}

.game-landing-cta-line {
    color: var(--game-accent) !important;
    font-weight: 600;
    margin-top: 18px !important;
}

.game-landing-features {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    max-width: 520px;
    margin: 0 auto 32px;
    padding: 0;
    text-align: left;
}

.game-landing-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border: 1px solid #222;
    border-radius: 10px;
    background: #0a0a0a;
    font-size: 0.9rem;
    color: var(--game-text);
    margin: 0;
}

.game-landing-features i {
    color: var(--game-accent);
    font-size: 1rem;
    width: 1.25rem;
    text-align: center;
    flex-shrink: 0;
}

.game-landing-signin-label {
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--game-muted);
    margin: 0 auto 16px !important;
    max-width: none !important;
}

@media (max-width: 480px) {
    .game-landing-features {
        grid-template-columns: 1fr;
    }

    .game-main:has(#game-panel-setup:not([hidden])) {
        align-items: flex-start;
        padding-top: 16px;
    }
}

.game-field {
    margin-bottom: 16px;
}

.game-field label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.game-field input {
    width: 100%;
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid #333;
    background: #111;
    color: var(--game-text);
    font: inherit;
}

.game-field select {
    width: 100%;
    padding: 12px 36px 12px 14px;
    border-radius: 8px;
    border: 1px solid #333;
    background-color: #111;
    color: var(--game-text);
    font: inherit;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23ceff00' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    cursor: pointer;
}

.game-field input:focus,
.game-field select:focus {
    outline: 2px solid var(--game-accent);
    outline-offset: 2px;
    border-color: var(--game-accent);
}

.game-field select option {
    background: #111;
    color: var(--game-text);
}

.game-field-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.game-field-label-row label {
    margin-bottom: 0;
}

.game-link-button {
    border: 0;
    background: none;
    color: var(--game-accent);
    font: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.game-link-button:hover {
    color: var(--game-text);
}

.game-name-suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.game-name-suggestion {
    border: 1px solid #333;
    background: #111;
    color: var(--game-text);
    padding: 8px 14px;
    border-radius: 999px;
    font: inherit;
    font-size: 0.875rem;
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease;
}

.game-name-suggestion:hover,
.game-name-suggestion.is-selected {
    border-color: var(--game-accent);
    color: var(--game-accent);
}

.game-consents {
    border: 0;
    margin: 0 0 16px;
    padding: 0;
}

.game-checkbox {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 12px;
    font-size: 0.95rem;
    color: var(--game-muted);
}

.game-checkbox input {
    margin-top: 4px;
}

.game-privacy-note {
    font-size: 0.85rem;
    color: var(--game-muted);
    margin-bottom: 20px;
}

.game-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 14px 20px;
    border: 0;
    border-radius: 999px;
    background: var(--game-accent);
    color: #000;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.game-button-secondary {
    background: transparent;
    color: var(--game-accent);
    border: 1px solid var(--game-accent);
}

.game-error {
    margin-top: 16px;
    color: #ff6b6b;
    font-size: 0.95rem;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.game-panel-play {
    max-width: none;
    width: 100%;
    text-align: left;
}

.game-panel-play h1,
.game-panel-result h1 {
    text-align: left;
    margin-left: 0;
}

.game-panel-play .game-lead,
.game-panel-result .game-lead {
    margin-left: 0;
}

.game-badge-compact {
    padding: 4px 10px;
    font-size: 0.75rem;
    margin-bottom: 4px;
}

.game-play-topbar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.game-play-rail {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
    width: 100%;
    margin-bottom: 16px;
}

.game-tunables-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 12px;
    width: 100%;
    margin-bottom: 0;
}

.game-play-summary-feed-row {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    margin-bottom: 12px;
    min-width: 0;
}

.game-play-summary-column {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-width: 0;
}

.game-play-summary-column .game-tunables-row {
    margin-bottom: 0;
}

.game-play-summary-column .game-play-status {
    margin-bottom: 0;
}

.game-tunables-row .game-team-roster {
    grid-column: 1;
    grid-row: 1 / span 2;
}

.game-tunables-row .game-marketing-knob {
    grid-column: 2;
    grid-row: 1 / span 2;
}

.game-tunables-row .game-pricing-knob {
    grid-column: 3;
    grid-row: 1;
}

.game-tunables-row .game-office-card {
    grid-column: 4;
    grid-row: 1;
}

.game-tunables-row .game-office-card[hidden] {
    display: none;
}

.game-tunables-row .game-decisions-card {
    grid-column: 3 / span 2;
    grid-row: 2;
}

.game-tunables-row:has(.game-office-card[hidden]) .game-pricing-knob {
    grid-column: 3 / span 2;
}

.game-play-rail--assets {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    margin-bottom: 16px;
}

.game-rail-card {
    border: 1px solid #222;
    border-radius: 16px;
    padding: 12px;
    background: #0a0a0a;
    min-width: 0;
}

.game-tunable-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 0;
}

.game-tunable-heading,
.game-team-heading {
    font-family: 'Bison Bold', sans-serif;
    font-size: 1.1rem;
    margin: 0;
    color: var(--game-text);
}

.game-office-heading {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--game-muted);
}

.game-play-topbar-main {
    min-width: 0;
    flex: 1;
}

.game-play-topbar-row {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    width: 100%;
}

.game-play-topbar-row .game-agency-title {
    flex-shrink: 0;
}

.game-play-topbar-actions {
    flex: 0 0 auto;
    padding-top: 2px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.game-feed-drawer-open,
.game-feed-drawer-close,
.game-feed-drawer-backdrop {
    display: none;
}

.game-start-again-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 8px;
}

.game-start-again-actions .game-button {
    flex: 1 1 160px;
}

.game-agency-title {
    font-family: 'Bison Bold', sans-serif;
    font-size: clamp(1.25rem, 4vw, 2rem);
    line-height: 1.1;
    margin: 0;
}

.game-play-layout {
    display: block;
    min-height: 0;
}

.game-play-dashboard {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
    min-height: 0;
}

.game-play-dashboard-main {
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.game-play-feed-sidebar {
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 0;
}

.game-play-feed-sidebar .game-slack-channel {
    flex: 1;
    min-height: 0;
}

body.game-shell--play .game-panel-play {
    display: flex;
    flex-direction: column;
}

body.game-shell--play .game-main--play {
    align-items: stretch;
    justify-content: flex-start;
    padding-top: 0;
}

body.game-shell--play .game-header {
    padding-top: 10px;
    padding-bottom: 4px;
}

body.game-shell--play .game-play-timeline-bar {
    flex-shrink: 0;
    margin-bottom: 8px;
}

body.game-shell--play .game-timeline {
    position: static;
    flex-shrink: 0;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    margin-top: 0;
    width: 100%;
    padding: 10px 12px;
    background: rgba(0, 0, 0, 0.94);
    border: 1px solid #2a2a2a;
    border-radius: 14px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.55);
}

body.game-shell--play .game-timeline .game-sim-month {
    flex-shrink: 0;
    margin: 0;
    padding-right: 10px;
    border-right: 1px solid #333;
    font-size: 0.72rem;
    line-height: 1.25;
    white-space: nowrap;
}

body.game-shell--play .game-timeline-months {
    flex: 1;
    min-width: 0;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 3px;
    overflow-x: auto;
    overflow-y: hidden;
    max-height: none;
    width: auto;
    scrollbar-width: thin;
}

body.game-shell--play .game-clock-speed {
    flex-shrink: 0;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding-left: 10px;
    border-left: 1px solid #333;
}

body.game-shell--play .game-clock-speed-label {
    font-size: 0.6rem;
    line-height: 1;
}

body.game-shell--play .game-speed-toggle {
    min-width: 36px;
    min-height: 26px;
    padding: 4px 8px;
    font-size: 0.75rem;
}

body.game-shell--play .game-timeline-month {
    flex: 0 0 auto;
    width: 30px;
    height: 26px;
    font-size: 0.68rem;
}

.game-timeline {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 4px 0;
}

.game-play-main {
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 0;
}

.game-play-status {
    margin-bottom: 12px;
}

.game-play-status-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.game-sim-month {
    color: var(--game-accent);
    font-size: 0.85rem;
    font-weight: 700;
    margin: 0;
    letter-spacing: 0.02em;
}

.game-clock-speed {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.game-clock-speed-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--game-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.game-speed-toggle {
    min-width: 44px;
    min-height: 32px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid #333;
    background: #111;
    color: var(--game-text);
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}

.game-speed-toggle:hover {
    border-color: var(--game-accent);
    color: var(--game-accent);
}

.game-speed-toggle[aria-pressed="true"] {
    border-color: var(--game-accent);
    background: rgba(206, 255, 0, 0.12);
    color: var(--game-accent);
}

.game-scores-row {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
    width: 100%;
}

.game-scores {
    display: contents;
}

.game-scores-row > .game-workload {
    border: 1px solid #222;
    border-radius: 12px;
    padding: 12px 16px;
    background: #0a0a0a;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.game-scores-row > .game-workload .game-workload-lights {
    margin: 2px 0;
}

.game-score {
    border: 1px solid #222;
    border-radius: 12px;
    padding: 12px 16px;
    background: #0a0a0a;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.game-score-sparkline {
    margin-top: 8px;
    width: 100%;
    height: 28px;
}

.game-score-sparkline-svg {
    display: block;
    width: 100%;
    height: 100%;
}

.game-score-sparkline-slot {
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
}

.game-score-sparkline-now {
    stroke: rgba(255, 255, 255, 0.12);
    stroke-width: 1;
    stroke-dasharray: 2 3;
    vector-effect: non-scaling-stroke;
}

.game-score-sparkline-line {
    fill: none;
    stroke-width: 1.75;
    vector-effect: non-scaling-stroke;
}

.game-score-sparkline-line--empty {
    stroke-opacity: 0.25;
    stroke-dasharray: 3 4;
}

.game-workload-barchart {
    margin-top: 8px;
    width: 100%;
    height: 28px;
}

.game-workload-barchart-svg {
    display: block;
    width: 100%;
    height: 100%;
}

.game-workload-barchart-slot {
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
}

.game-workload-barchart-now {
    stroke: rgba(255, 255, 255, 0.12);
    stroke-width: 1;
    stroke-dasharray: 2 3;
    vector-effect: non-scaling-stroke;
}

.game-workload-barchart-bar.is-current {
    filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.2));
}

.game-team-roster {
    flex-shrink: 0;
}

.game-team-policy-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.game-team-policy-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px solid #333;
    background: #111;
    color: var(--game-text);
    font-size: 0.72rem;
    line-height: 1.2;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.game-team-policy-badge:hover {
    border-color: var(--game-accent);
    background: #141414;
}

.game-team-policy-badge:focus-visible {
    outline: 2px solid var(--game-accent);
    outline-offset: 2px;
}

.game-team-policy-badge-label {
    color: var(--game-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 0.65rem;
}

.game-team-policy-badge-value {
    font-weight: 600;
    color: var(--game-accent);
}

.game-team-roster .game-team-members {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.game-team-roster .game-team-member {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 6px;
    border: 1px solid #222;
    border-radius: 10px;
    background: #111;
    min-width: 0;
    text-align: center;
}

.game-team-roster .game-team-avatar {
    grid-row: auto;
    width: 40px;
    height: 40px;
    flex-shrink: 0;
}

.game-team-roster .game-team-name {
    font-size: 0.75rem;
    line-height: 1.2;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.game-team-roster .game-team-role {
    font-size: 0.65rem;
    line-height: 1.2;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.game-tunable-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 8px;
}

.game-tunable-card-header .game-tunable-heading {
    margin-bottom: 0;
    min-width: 0;
}

.game-tunable-info-btn {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--game-muted);
    font-size: 0.85rem;
    line-height: 1;
    cursor: pointer;
    transition: color 0.15s ease, background 0.15s ease;
}

.game-tunable-info-btn:hover {
    color: var(--game-accent);
    background: rgba(206, 255, 0, 0.08);
}

.game-tunable-info-btn:focus-visible {
    outline: 2px solid var(--game-accent);
    outline-offset: 2px;
}

.game-tunable-help-body {
    color: var(--game-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

.game-tunable-help-body p {
    margin: 0 0 12px;
    color: var(--game-text);
}

.game-tunable-help-body ul {
    margin: 0;
    padding-left: 1.2rem;
}

.game-tunable-help-body li {
    margin-bottom: 8px;
}

.game-tunable-help-body li:last-child {
    margin-bottom: 0;
}

.game-tunable-help-body strong {
    color: var(--game-text);
    font-weight: 600;
}

.game-team-heading-row .game-tunable-heading,
.game-team-heading-row .game-team-heading,
.game-office-heading-row .game-office-heading,
.game-office-heading-row .game-tunable-heading {
    margin-bottom: 0;
}

.game-team-heading-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}

.game-team-heading {
    font-family: 'Bison Bold', sans-serif;
    font-size: 1.1rem;
    margin-bottom: 12px;
    color: var(--game-text);
}

.game-team-members {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.game-team-member {
    display: grid;
    grid-template-columns: 44px 1fr;
    grid-template-rows: auto auto;
    column-gap: 10px;
    align-items: center;
}

.game-team-avatar {
    grid-row: 1 / span 2;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid #333;
    background: #111;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    color: #444;
    font-size: 1.1rem;
}

.game-team-initials {
    position: absolute;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--game-accent);
    letter-spacing: 0.02em;
}

.game-team-name {
    font-size: 0.9rem;
    color: var(--game-text);
    line-height: 1.2;
}

.game-team-role {
    font-size: 0.75rem;
    color: var(--game-muted);
    line-height: 1.2;
}

.game-team-member--solo .game-team-role {
    color: var(--game-accent);
    font-style: italic;
}

.game-team-member--founder .game-team-avatar {
    border-color: var(--game-accent);
    box-shadow: 0 0 0 1px rgba(206, 255, 0, 0.15);
}

.game-team-member--manage {
    cursor: pointer;
    font-family: inherit;
    text-align: center;
    border-color: rgba(255, 159, 67, 0.45);
    background: rgba(255, 140, 40, 0.16);
    transition: border-color 0.15s ease, background 0.15s ease;
}

.game-team-member--manage:hover {
    border-color: #ff9f43;
    background: rgba(255, 140, 40, 0.24);
}

.game-team-member--manage:focus-visible {
    outline: 2px solid #ff9f43;
    outline-offset: 2px;
}

.game-team-member--manage .game-team-avatar {
    border-color: rgba(255, 159, 67, 0.5);
    background: rgba(255, 140, 40, 0.2);
    color: #ffb347;
}

.game-team-member--manage .game-team-avatar .fa-users {
    font-size: 0.95rem;
}

.game-team-member--manage .game-team-name {
    color: #ffb347;
    font-weight: 600;
}

.game-team-member--manage .game-team-role {
    color: rgba(255, 179, 71, 0.82);
}

.game-team-empty {
    color: var(--game-muted);
    font-size: 0.85rem;
    margin: 0;
}

.game-timeline-months {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
    margin: 0;
    padding: 0;
    max-height: 100%;
    overflow-y: auto;
}

.game-timeline-month {
    width: 28px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    color: #444;
    border-radius: 4px;
    position: relative;
}

.game-timeline-month span {
    position: relative;
    z-index: 1;
}

.game-timeline-month.is-past {
    color: var(--game-muted);
}

.game-timeline-month.is-current {
    color: #000;
    background: var(--game-accent);
    font-weight: 700;
}

.game-timeline-month.is-birthday.is-current,
.game-timeline-month.is-birthday.is-past {
    box-shadow: 0 0 0 1px var(--game-accent);
}

.game-section-heading {
    font-family: 'Bison Bold', sans-serif;
    font-size: 0.95rem;
    margin: 0 0 8px;
    color: var(--game-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.game-score-label {
    display: block;
    color: var(--game-muted);
    font-size: 0.85rem;
    margin-bottom: 2px;
    line-height: 1.2;
}

.game-score-hint {
    display: block;
    color: var(--game-muted);
    font-size: 0.68rem;
    line-height: 1.25;
    margin-bottom: 6px;
    opacity: 0.85;
}

.game-score-value {
    font-size: 1.5rem;
    color: var(--game-accent);
}

.game-score--changed .game-score-value {
    animation: game-score-pulse 0.8s ease;
}

@keyframes game-score-pulse {
    0% { transform: scale(1); }
    35% { transform: scale(1.08); color: #fff; }
    100% { transform: scale(1); }
}

.game-play-stack {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
    gap: 20px;
    min-height: 0;
    flex: 1;
}

.game-play-stack--feed-only {
    grid-template-columns: minmax(0, 1fr);
}

.game-play-actions,
.game-play-feed-wrap {
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.game-play-feed-wrap .game-slack-channel {
    flex: 1;
    min-height: 0;
    max-height: 100%;
}

.game-coaching-hints--top {
    margin: 0;
    flex: 1;
    min-width: 0;
}

.game-coaching-hints--top:not([hidden]) {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.game-coaching-hints--top .game-coaching-hint {
    padding: 6px 8px;
    font-size: 0.7rem;
    line-height: 1.3;
}

.game-cards {
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow-y: auto;
    min-height: 0;
}

.game-card {
    border: 1px solid #222;
    border-radius: 16px;
    padding: 20px;
    background: #0a0a0a;
    transition: border-color 0.2s ease, opacity 0.25s ease, transform 0.25s ease;
}

.game-card.is-submitting {
    border-color: var(--game-accent);
    opacity: 0.88;
    pointer-events: none;
    transform: scale(0.995);
}

.game-card-submitting-feedback {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 14px 0 0;
    color: var(--game-accent);
    font-size: 0.9rem;
    font-weight: 600;
}

.game-card-submitting-feedback::before {
    content: '';
    width: 14px;
    height: 14px;
    border: 2px solid rgba(206, 255, 0, 0.25);
    border-top-color: var(--game-accent);
    border-radius: 50%;
    animation: game-card-spin 0.7s linear infinite;
    flex-shrink: 0;
}

@keyframes game-card-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (prefers-reduced-motion: reduce) {
    .game-card {
        transition: none;
    }

    .game-card-submitting-feedback::before {
        animation: none;
        border-top-color: rgba(206, 255, 0, 0.25);
    }
}

.game-card h3 {
    font-family: 'Bison Bold', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.game-card p {
    color: var(--game-muted);
    margin: 0 0 16px;
    max-width: none;
    text-align: left;
}

.game-card-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.game-card-option {
    width: 100%;
    justify-content: flex-start;
    text-align: left;
    white-space: normal;
    line-height: 1.35;
    min-height: 44px;
    transition: border-color 0.15s ease, background-color 0.15s ease, opacity 0.15s ease;
}

.game-card-option.is-selected {
    border-color: var(--game-accent);
    background: rgba(206, 255, 0, 0.14);
    color: var(--game-text);
}

.game-card.is-submitting .game-card-option:not(.is-selected) {
    opacity: 0.45;
}

.game-card--interruption {
    border-color: #ff6b4a;
    box-shadow: 0 0 0 1px rgba(255, 107, 74, 0.15);
}

.game-card--opportunity {
    border-color: #4ad4ff;
}

.game-card--strategic {
    border-color: #222;
}

.game-card--consequence {
    border-color: #c77dff;
}

.game-card--ambient {
    border-color: #333;
    opacity: 0.92;
}

.game-card--reduced-motion {
    transition: none;
}

.game-card-timer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    margin: 0 0 16px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid #2a2a2a;
}

.game-card-timer.is-warning {
    border-color: #ffb347;
    background: rgba(255, 179, 71, 0.08);
}

.game-card-timer.is-paused {
    border-color: var(--game-accent);
    background: rgba(206, 255, 0, 0.06);
}

.game-card-timer-bar {
    flex: 1 1 120px;
    height: 6px;
    border-radius: 999px;
    background: #1f1f1f;
    overflow: hidden;
    position: relative;
}

.game-card-timer-bar::after {
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: var(--timer-progress, 100%);
    background: linear-gradient(90deg, var(--game-accent), #b8e600);
    border-radius: inherit;
    transition: width 0.35s linear;
}

.game-card-timer.is-warning .game-card-timer-bar::after {
    background: linear-gradient(90deg, #ffb347, #ff6b4a);
}

.game-card-timer.is-paused .game-card-timer-bar::after {
    background: #666;
}

.game-card-timer-text {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--game-muted);
    min-width: 7rem;
}

.game-card-pause {
    margin-left: auto;
    font-size: 0.8rem;
}

.game-link-button {
    background: none;
    border: none;
    color: var(--game-accent);
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
}

.game-link-button:hover {
    color: var(--game-text);
}

.game-slider,
.game-allocation,
.game-ranking {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.game-slider-label {
    font-size: 0.9rem;
    color: var(--game-muted);
}

.game-slider-input {
    width: 100%;
    accent-color: var(--game-accent);
}

.game-slider-output {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--game-accent);
    line-height: 1.3;
}

.game-slider-stops {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.75rem;
    color: var(--game-muted);
    line-height: 1.25;
}

.game-slider-stop {
    flex: 1 1 0;
    text-align: center;
}

.game-slider-stop.is-active {
    color: var(--game-accent);
    font-weight: 600;
}

.game-slider-choice {
    margin: 0;
    font-size: 0.85rem;
    color: var(--game-muted);
}

.game-slider-ends {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.75rem;
    color: var(--game-muted);
}

.game-allocation-note,
.game-ranking-note {
    margin: 0;
    font-size: 0.85rem;
    color: var(--game-muted);
}

.game-allocation-row,
.game-ranking-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.game-allocation-row input,
.game-ranking-row input {
    width: 5rem;
    padding: 8px 10px;
    border-radius: 8px;
    border: 1px solid #333;
    background: #111;
    color: var(--game-text);
}

.game-allocation-remainder {
    margin: 0;
    font-size: 0.85rem;
    color: var(--game-muted);
}

.game-card-inline-error {
    margin: 0;
    color: #ff6b4a;
    font-size: 0.85rem;
    font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
    .game-card-timer-bar::after {
        transition: none;
    }
}

/* Slack-style agency channel */
.game-slack-channel {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    height: 100%;
    border: 1px solid #222;
    border-radius: 12px;
    overflow: hidden;
    background: var(--game-bg);
}

.game-slack-channel-header {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 13px 15px 11px;
    border-bottom: 1px solid #222;
    background: #0d0d0d;
    flex-shrink: 0;
}

.game-slack-channel-title-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    min-width: 0;
}

.game-slack-channel-title-row > div {
    min-width: 0;
}

.game-slack-channel-kicker {
    margin: 0 0 2px;
    color: var(--game-muted);
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.game-slack-channel-name {
    margin: 0;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.25;
    color: var(--game-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.game-slack-hash {
    color: var(--game-muted);
    margin-right: 2px;
    font-weight: 400;
}

.game-slack-channel-topic {
    margin: 0;
    font-size: 0.68rem;
    color: var(--game-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.game-slack-messages {
    list-style: none;
    margin: 0;
    padding: 4px 0 12px;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
    background: var(--game-bg);
}

.game-slack-messages:hover {
    scrollbar-color: rgba(255, 255, 255, 0.28) transparent;
}

.game-slack-messages::-webkit-scrollbar {
    width: 8px;
}

.game-slack-messages::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.16);
    border-radius: 999px;
    border: 2px solid transparent;
    background-clip: padding-box;
}

.game-slack-messages:hover::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.28);
    background-clip: padding-box;
}

.game-slack-messages:empty::before {
    content: 'No messages yet — decisions and consequences will appear here.';
    display: block;
    padding: 12px 14px;
    color: var(--game-muted);
    font-size: 0.65rem;
}

.game-slack-day-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px 14px 7px;
}

.game-slack-day-divider span {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border: 1px solid #222;
    border-radius: 999px;
    background: #0a0a0a;
    color: var(--game-muted);
    font-size: 0.62rem;
    font-weight: 600;
    line-height: 1.2;
}

.game-slack-message {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 0 9px;
    padding: 5px 14px 4px;
    align-items: start;
}

.game-slack-message:hover {
    background: rgba(255, 255, 255, 0.04);
}

.game-slack-message--new {
    animation: game-slack-message-highlight 2.4s ease-out forwards;
}

@keyframes game-slack-message-highlight {
    0% {
        background: rgba(206, 255, 0, 0.14);
    }
    100% {
        background: transparent;
    }
}

@media (prefers-reduced-motion: reduce) {
    .game-slack-message--new {
        animation: none;
        background: rgba(206, 255, 0, 0.08);
    }

    body.game-feed-drawer-ready .game-play-feed-sidebar {
        transition: none;
    }
}

.game-slack-message--compact {
    padding-top: 2px;
    padding-bottom: 2px;
}

.game-slack-message-gutter {
    width: 34px;
    min-height: 1px;
    position: relative;
}

.game-slack-timestamp--hover {
    position: absolute;
    top: 2px;
    right: 4px;
    opacity: 0;
    font-size: 0.56rem;
    color: var(--game-muted);
    white-space: nowrap;
    transition: opacity 0.12s ease;
}

.game-slack-message--compact:hover .game-slack-timestamp--hover {
    opacity: 1;
}

.game-slack-avatar {
    width: 34px;
    height: 34px;
    border-radius: 7px;
    background: #3f0e40;
    border: none;
    color: #fff;
    font-size: 0.64rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.game-slack-avatar--logo {
    object-fit: contain;
    padding: 6px 5px;
    background: #111;
}

.game-slack-message--feedback .game-slack-avatar {
    background: #385a86;
}

.game-slack-message--decision .game-slack-avatar,
.game-slack-message--warning .game-slack-avatar,
.game-slack-message--calendar .game-slack-avatar,
.game-slack-message--ops .game-slack-avatar {
    background: #4a154b;
}

.game-slack-message--team .game-slack-avatar {
    background: #1264a3;
}

.game-slack-message--timeline .game-slack-avatar {
    background: #2f6f4e;
}

.game-slack-message--consequence .game-slack-avatar {
    background: #8f4b16;
}

.game-slack-message--finance .game-slack-avatar {
    background: #7b4f12;
}

.game-slack-message--employee .game-slack-avatar {
    background: #2c6e49;
}

.game-slack-message-content {
    min-width: 0;
    padding-top: 2px;
}

.game-slack-message-header {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0 8px;
    margin-bottom: 2px;
    line-height: 1.3;
}

.game-slack-author {
    font-weight: 700;
    font-size: 0.76rem;
    color: var(--game-text);
}

.game-slack-timestamp {
    font-size: 0.6rem;
    color: var(--game-muted);
    font-weight: 400;
}

.game-slack-message-text {
    margin: 0;
    color: var(--game-muted);
    font-size: 0.74rem;
    line-height: 1.45;
    word-break: break-word;
}

.game-slack-system-message {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 7px 14px;
    padding: 7px 9px;
    border-left: 2px solid rgba(206, 255, 0, 0.55);
    background: rgba(206, 255, 0, 0.045);
    color: var(--game-muted);
}

.game-slack-system-message p {
    margin: 0;
    font-size: 0.66rem;
    line-height: 1.35;
}

.game-slack-system-message strong {
    color: var(--game-text);
    font-weight: 600;
}

.game-slack-system-message p span {
    margin-left: 4px;
    color: var(--game-muted);
}

.game-slack-system-icon {
    color: var(--game-accent);
    font-weight: 700;
}

/* Result + share */
.game-panel-result {
    max-width: none;
    width: 100%;
    text-align: left;
}

.game-result-root {
    width: 100%;
}

body.game-shell--result .game-main,
body.game-shell--leaderboard .game-main {
    align-items: stretch;
    justify-content: flex-start;
    width: 100%;
    padding: 12px 24px 48px;
}

body.game-shell--result .game-content,
body.game-shell--leaderboard .game-content {
    max-width: none;
    width: 100%;
    text-align: left;
}

body.game-shell--result .game-lead,
body.game-shell--leaderboard .game-lead,
body.game-shell--result .game-content > p,
body.game-shell--leaderboard .game-content > p {
    max-width: none;
    margin-left: 0;
    margin-right: 0;
}

.game-result-leaderboard {
    margin-top: 0;
    width: 100%;
}

.game-result-outcome {
    margin-bottom: 24px;
}

.game-result-outcome-badge {
    display: inline-block;
    margin: 0 0 8px;
    padding: 4px 10px;
    border: 1px solid #333;
    border-radius: 999px;
    color: var(--game-muted);
    font-size: 0.85rem;
}

.game-result-outcome-title {
    font-family: 'Bison Bold', sans-serif;
    font-size: clamp(2rem, 5vw, 2.75rem);
    margin: 0 0 8px;
    line-height: 1.05;
}

.game-result-outcome-lead {
    color: var(--game-muted);
    font-size: 1rem;
    line-height: 1.5;
    margin: 0;
    max-width: none;
}

.game-result-outcome-metric {
    margin: 8px 0 0;
    font-family: 'Bison Bold', sans-serif;
    font-size: 1.35rem;
    color: var(--game-accent);
    font-variant-numeric: tabular-nums;
}

.game-result-leaderboard-toolbar {
    margin-bottom: 12px;
}

.game-result-view-more {
    width: 100%;
    margin: 10px 0;
}

.game-leaderboard-row--you {
    border-color: rgba(200, 155, 255, 0.45);
    background: rgba(200, 155, 255, 0.06);
}

.game-leaderboard-row--detailed {
    display: grid;
    grid-template-columns: 40px 1fr auto;
    grid-template-areas:
        "rank meta score"
        "details details details";
    align-items: start;
}

.game-leaderboard-row--detailed .game-leaderboard-rank {
    grid-area: rank;
}

.game-leaderboard-row--detailed .game-leaderboard-meta {
    grid-area: meta;
}

.game-leaderboard-row--detailed .game-leaderboard-score {
    grid-area: score;
}

.game-leaderboard-details {
    grid-area: details;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #222;
}

.game-leaderboard-details-heading {
    margin: 0 0 10px;
    color: var(--game-muted);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.game-leaderboard-details-scores {
    margin: 0 0 12px;
}

.game-leaderboard-breakdown-scroll {
    overflow-x: auto;
    margin: 0 0 12px;
    -webkit-overflow-scrolling: touch;
}

.game-leaderboard-breakdown-table {
    width: 100%;
    min-width: 640px;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.game-leaderboard-breakdown-table th,
.game-leaderboard-breakdown-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #222;
    white-space: nowrap;
}

.game-leaderboard-breakdown-table th {
    color: var(--game-muted);
    font-weight: 500;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.game-leaderboard-breakdown-table td {
    color: var(--game-accent);
    font-weight: 700;
    font-size: 1rem;
}

.game-leaderboard-breakdown-table .game-leaderboard-breakdown-name {
    color: #fff;
    font-weight: 600;
}

.game-leaderboard-table--result {
    margin-top: 8px;
}

.game-result-share-inline {
    padding-top: 16px;
    border-top: 1px solid #222;
}

.game-share-friends-btn {
    width: 100%;
    justify-content: center;
}

.game-result-share-inline .game-share-copied {
    margin-bottom: 10px;
}

.game-result-toolbar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 8px;
}

.game-result-scores {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 20px 0;
}

.game-result-chronicle {
    color: var(--game-muted);
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 24px;
    max-width: none;
    text-align: left;
}

.game-share-block {
    border: 1px solid #222;
    border-radius: 16px;
    padding: 20px;
    background: #0a0a0a;
    text-align: left;
}

.game-share-heading {
    font-family: 'Bison Bold', sans-serif;
    font-size: 1.25rem;
    margin-bottom: 8px;
}

.game-share-note {
    color: var(--game-muted);
    font-size: 0.95rem;
    margin: 0 0 16px;
    max-width: none;
    text-align: left;
}

.game-share-preview {
    width: 100%;
    min-height: 10.5rem;
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid #333;
    background: #111;
    color: var(--game-text);
    font: inherit;
    font-size: 0.9rem;
    line-height: 1.5;
    resize: none;
    overflow: hidden;
    margin-bottom: 12px;
}

.game-share-copied {
    color: var(--game-accent);
    font-size: 0.85rem;
    margin-bottom: 12px;
}

.game-share-buttons {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.game-share-btn {
    width: auto;
    padding: 12px 14px;
    font-size: 0.9rem;
    gap: 8px;
}

.game-share-btn i {
    margin-right: 6px;
}

@media (min-width: 769px) {
    body.game-shell--play .game-content {
        max-width: min(1480px, calc(100vw - 48px));
        text-align: left;
    }

    body.game-shell--play .game-main--play {
        align-items: stretch;
        justify-content: flex-start;
        max-width: 100%;
        padding: 0 24px 24px;
    }

    body.game-shell--play .game-header {
        padding: 10px 24px 4px;
    }

    body.game-shell--play .game-header img {
        height: 28px;
    }

    .game-panel-play {
        display: flex;
        flex-direction: column;
        min-height: calc(100vh - 72px);
    }

    .game-play-topbar {
        margin-bottom: 12px;
    }

    .game-play-rail {
        gap: 14px;
        margin-bottom: 18px;
    }

    .game-tunables-row {
        gap: 14px;
    }

    .game-play-summary-feed-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(260px, 300px);
        gap: 14px;
        align-items: stretch;
        margin-bottom: 14px;
    }

    .game-play-dashboard {
        display: flex;
        flex-direction: column;
        flex: 1;
        min-height: 0;
    }

    .game-play-dashboard-main {
        min-height: 0;
    }

    .game-play-feed-sidebar {
        min-height: 0;
        display: flex;
        flex-direction: column;
    }

    .game-play-feed-sidebar .game-slack-channel {
        max-height: none;
        height: 100%;
    }

    .game-finance {
        display: grid;
        grid-template-columns: minmax(0, 3fr) minmax(0, 2fr) minmax(0, 2fr);
        gap: 12px;
        width: 100%;
    }

    .game-finance:has(#game-assets-card[hidden]) {
        grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    }

    .game-team-roster {
        min-width: 0;
    }
}

@media (max-width: 768px) {
    body.game-shell--play {
        overflow: hidden;
        height: 100dvh;
    }

    body.game-shell--play .game-header {
        padding: 8px 16px 2px;
    }

    body.game-shell--play .game-header img {
        height: 28px;
    }

    body.game-shell--play .game-main--play {
        align-items: stretch;
        justify-content: stretch;
        padding: 0 12px 12px;
        flex: 1;
        min-height: 0;
        overflow: hidden;
    }

    body.game-shell--play .game-content {
        max-width: none;
        height: 100%;
        display: flex;
        flex-direction: column;
        min-height: 0;
    }

    .game-panel-play {
        max-width: none;
        flex: 1;
        display: flex;
        flex-direction: column;
        min-height: 0;
        padding-bottom: 0;
    }

    body.game-shell--play .game-play-timeline-bar {
        margin-bottom: 8px;
    }

    body.game-shell--play .game-timeline .game-sim-month {
        font-size: 0.62rem;
        padding-right: 8px;
        max-width: 7.5rem;
        white-space: normal;
    }

    body.game-shell--play .game-clock-speed {
        padding-left: 8px;
    }

    .game-play-topbar {
        margin-bottom: 8px;
        flex-shrink: 0;
    }

    .game-play-topbar-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .game-play-rail {
        display: flex;
        flex-wrap: nowrap;
        gap: 8px;
        overflow-x: auto;
        margin-bottom: 10px;
        padding-bottom: 2px;
        scrollbar-width: thin;
    }

    .game-tunables-row {
        display: flex;
        flex-wrap: nowrap;
        gap: 8px;
        overflow-x: auto;
        margin-bottom: 0;
        padding-bottom: 2px;
        scrollbar-width: thin;
    }

    .game-play-summary-feed-row {
        display: flex;
        flex-direction: row;
        gap: 8px;
        align-items: stretch;
        min-height: 0;
        flex: 0 0 auto;
        margin-bottom: 10px;
        min-width: 0;
    }

    .game-play-summary-column {
        flex: 1;
        min-width: 0;
        gap: 8px;
    }

    .game-play-summary-feed-row .game-tunables-row {
        flex: 1;
        min-width: 0;
    }

    .game-tunables-row .game-rail-card {
        flex: 0 0 min(220px, 78vw);
        padding: 10px;
    }

    .game-tunables-row .game-team-roster {
        flex: 0 0 min(300px, 88vw);
    }

    .game-tunables-row .game-knob-card {
        flex: 0 0 min(220px, 78vw);
    }

    .game-tunables-row .game-decisions-card {
        flex: 0 0 min(260px, 88vw);
    }

    .game-rail-card {
        flex: 0 0 min(240px, 78vw);
        padding: 10px;
    }

    .game-tunables-row .game-team-members {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 6px;
    }

    .game-tunables-row .game-team-policy-badges {
        margin-bottom: 6px;
    }

    .game-tunables-row .game-team-policy-badge {
        padding: 3px 8px;
        font-size: 0.68rem;
    }

    .game-tunables-row .game-team-name,
    .game-tunables-row .game-team-role,
    .game-tunables-row .game-team-empty {
        display: none;
    }

    .game-tunables-row .game-team-member {
        display: block;
        grid-template-columns: none;
        padding: 0;
        border: 0;
        background: transparent;
        border-radius: 0;
    }

    .game-tunables-row .game-team-member--manage {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 0;
        border: 1px solid rgba(255, 159, 67, 0.45);
        border-radius: 10px;
        background: rgba(255, 140, 40, 0.16);
    }

    .game-tunables-row .game-team-member--manage .game-team-avatar {
        width: 36px;
        height: 36px;
    }

    .game-tunables-row .game-team-avatar {
        width: 36px;
        height: 36px;
        grid-row: auto;
    }

    .game-tunables-row .game-team-initials {
        font-size: 0.65rem;
    }

    .game-play-layout {
        flex: 1;
        min-height: 0;
    }

    .game-play-dashboard {
        flex: 1;
        min-height: 0;
    }

    .game-play-dashboard-main {
        flex: 1 1 auto;
        min-height: 0;
        overflow: hidden;
    }

    .game-play-feed-sidebar {
        flex: 0 0 38%;
        min-height: 0;
        overflow: hidden;
    }

    body.game-feed-drawer-ready .game-play-feed-sidebar {
        position: fixed;
        inset: 0 0 0 auto;
        z-index: 1201;
        width: min(92vw, 420px);
        height: 100dvh;
        min-height: 100dvh;
        overflow: hidden;
        background: var(--game-bg);
        transform: translateX(102%);
        visibility: hidden;
        pointer-events: none;
        transition: transform 180ms ease, visibility 0s linear 180ms;
    }

    body.game-feed-drawer-ready .game-play-feed-sidebar.is-open {
        transform: translateX(0);
        visibility: visible;
        pointer-events: auto;
        transition-delay: 0s;
    }

    .game-play-feed-sidebar .game-slack-channel {
        max-height: none;
        height: 100%;
    }

    body.game-feed-drawer-ready .game-play-feed-sidebar .game-slack-channel {
        border-width: 0 0 0 1px;
        border-radius: 0;
    }

    body.game-feed-drawer-ready .game-feed-drawer-open {
        display: inline-flex;
        align-items: center;
        gap: 7px;
        min-height: 34px;
        padding: 6px 10px;
        border: 1px solid rgba(206, 255, 0, 0.5);
        border-radius: 999px;
        background: rgba(206, 255, 0, 0.08);
        color: var(--game-text);
        font: inherit;
        font-size: 0.7rem;
        font-weight: 700;
        cursor: pointer;
    }

    .game-feed-unread {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 20px;
        height: 20px;
        padding: 0 5px;
        border-radius: 999px;
        background: var(--game-accent);
        color: #080808;
        font-size: 0.65rem;
        line-height: 1;
    }

    .game-feed-unread[hidden] {
        display: none;
    }

    body.game-feed-drawer-ready .game-feed-drawer-close {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 36px;
        height: 36px;
        flex: 0 0 36px;
        border: 0;
        border-radius: 8px;
        background: rgba(255, 255, 255, 0.07);
        color: var(--game-text);
        font-size: 1rem;
        cursor: pointer;
    }

    body.game-feed-drawer-ready .game-feed-drawer-open:focus-visible,
    body.game-feed-drawer-ready .game-feed-drawer-close:focus-visible {
        outline: 2px solid var(--game-accent);
        outline-offset: 2px;
    }

    body.game-feed-drawer-ready .game-feed-drawer-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1200;
        display: block;
        width: 100%;
        height: 100%;
        padding: 0;
        border: 0;
        background: rgba(0, 0, 0, 0.72);
        cursor: default;
    }

    body.game-feed-drawer-ready .game-feed-drawer-backdrop[hidden] {
        display: none;
    }

    body.game-shell--play .game-timeline-month {
        width: 24px;
        height: 22px;
        font-size: 0.6rem;
    }

    .game-play-main {
        flex: 1;
        min-height: 0;
    }

    .game-play-status {
        margin-bottom: 8px;
        flex-shrink: 0;
    }

    .game-scores-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
    }

    .game-scores-row > .game-workload {
        grid-column: 1 / -1;
        padding: 8px 10px;
        border-radius: 8px;
    }

    .game-score {
        padding: 8px 10px;
        border-radius: 8px;
    }

    .game-score-label {
        font-size: 0.7rem;
    }

    .game-score-hint {
        font-size: 0.6rem;
        margin-bottom: 4px;
    }

    .game-score-value {
        font-size: 1.1rem;
    }

    .game-play-stack {
        flex: 1;
        display: flex;
        flex-direction: column;
        gap: 8px;
        min-height: 0;
        grid-template-columns: none;
    }

    .game-play-feed-wrap {
        min-height: 0;
        overflow: hidden;
    }

    .game-section-heading {
        font-size: 0.8rem;
        margin-bottom: 6px;
    }

    .game-cards {
        flex: 1;
        gap: 10px;
    }

    .game-card {
        padding: 14px;
        border-radius: 12px;
    }

    .game-card h3 {
        font-size: 1.15rem;
    }

    .game-card p {
        font-size: 0.9rem;
        margin-bottom: 12px;
    }

    .game-card-option {
        padding: 12px 14px;
        font-size: 0.9rem;
    }

    .game-slack-channel {
        flex: 1;
        min-height: 0;
        max-height: 100%;
    }

    .game-slack-channel-header {
        padding: 14px 16px 11px;
    }

    .game-slack-channel-name {
        font-size: 0.9rem;
    }

    .game-slack-message {
        padding-left: 14px;
        padding-right: 14px;
    }

    .game-share-buttons {
        grid-template-columns: 1fr;
    }

    body.game-shell--result .game-main {
        padding: 16px;
        align-items: flex-start;
    }
}

@media (max-width: 768px) and (prefers-reduced-motion: reduce) {
    body.game-feed-drawer-ready .game-play-feed-sidebar {
        transition: none;
    }
}

/* ------------------------------------------------------------------ */
/* Finance: D$ tickers, marketing knob, workload lights               */
/* ------------------------------------------------------------------ */

.game-finance {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: stretch;
    margin: 10px 0;
    width: 100%;
}

.game-finance-summary {
    flex: 1 1 340px;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    min-width: 0;
}

.game-finance-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
}

.game-finance-metric {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    padding: 0 12px;
}

.game-finance-metric:not(:last-child) {
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.game-finance-metric:first-child {
    padding-left: 0;
}

.game-finance-metric:last-child {
    padding-right: 0;
}

.game-money-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--game-muted);
}

.game-money-label small {
    text-transform: none;
    letter-spacing: normal;
    opacity: 0.8;
}

.game-money-value {
    font-size: 1.25rem;
    font-variant-numeric: tabular-nums;
    color: var(--game-text);
    white-space: nowrap;
}

.game-finance-metric--bank .game-money-value,
.game-money-tile--bank .game-money-value {
    color: var(--game-accent);
}

.game-money-value.is-negative {
    color: #ff6b6b;
}

.game-money-rate {
    font-size: 0.72rem;
    color: var(--game-muted);
    font-variant-numeric: tabular-nums;
}

.game-finance-chart-wrap {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.game-finance-chart {
    width: 100%;
    height: 150px;
}

.game-finance-chart-svg {
    display: block;
    width: 100%;
    height: 100%;
}

.game-finance-chart-grid {
    stroke: rgba(255, 255, 255, 0.06);
    stroke-width: 1;
}

.game-finance-chart-now {
    stroke: rgba(206, 255, 0, 0.35);
    stroke-width: 1;
    stroke-dasharray: 3 3;
}

.game-finance-chart-line {
    fill: none;
    stroke-width: 2;
    vector-effect: non-scaling-stroke;
}

.game-finance-chart-line--actual {
    stroke-opacity: 1;
}

.game-finance-chart-line--forecast {
    stroke-opacity: 0.55;
    stroke-dasharray: 5 4;
    stroke-width: 1.5;
}

.game-finance-chart-axis {
    fill: var(--game-muted);
    font-size: 9px;
    font-family: 'Space Grotesk', sans-serif;
}

.game-finance-chart-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 14px;
    margin: 8px 0 0;
    padding: 0;
    list-style: none;
    font-size: 0.68rem;
    color: var(--game-muted);
}

.game-finance-chart-legend li {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.game-finance-chart-swatch {
    width: 10px;
    height: 3px;
    border-radius: 2px;
}

.game-costs-card {
    flex: 1 1 220px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    min-width: 0;
}

.game-costs-card-header {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.game-costs-breakdown {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 8px;
}

.game-costs-breakdown li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.78rem;
    color: var(--game-muted);
}

.game-costs-amount {
    color: var(--game-text);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.game-finance-controls {
    display: none;
}

.game-knob-meta {
    margin: 0 0 10px;
    font-size: 0.78rem;
    line-height: 1.35;
    color: var(--game-muted);
    font-variant-numeric: tabular-nums;
}

.game-office-label {
    margin: 0 0 4px;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.2;
    color: var(--game-text);
}

.game-office-summary {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
}

.game-office-badge {
    text-transform: none;
    letter-spacing: normal;
    font-weight: 600;
    align-self: flex-start;
}

.game-office-upgrade-btn {
    width: 100%;
    padding: 5px 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: transparent;
    color: var(--game-muted);
    font-family: inherit;
    font-size: 0.72rem;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.game-office-upgrade-btn:hover {
    border-color: var(--game-accent);
    color: var(--game-text);
    background: rgba(206, 255, 0, 0.06);
}

.game-office-upgrade-btn:focus-visible {
    outline: 2px solid var(--game-accent);
    outline-offset: 2px;
}

.game-office-capacity {
    margin: 0;
    font-size: 0.78rem;
    line-height: 1.35;
    color: var(--game-muted);
    font-variant-numeric: tabular-nums;
}

.game-office-capacity-total {
    opacity: 0.6;
}

.game-knob-card-buttons {
    margin-top: 0;
}

.game-knob-card--compact {
    gap: 6px;
}

.game-knob-meta--compact {
    margin-bottom: 4px;
}

.game-knob-card-buttons--inline {
    flex-wrap: nowrap;
}

.game-knob-card--compact .game-marketing-option,
.game-pricing-knob .game-marketing-option {
    flex: 1 1 0;
    min-width: 0;
    padding: 5px 2px;
    font-size: 0.72rem;
}

.game-tunables-row .game-office-blocked {
    display: none;
}

.game-tunables-row .game-office-summary {
    gap: 6px;
}

.game-tunables-row .game-office-pending {
    margin-top: 2px;
    padding: 4px 6px;
    font-size: 0.68rem;
}

.game-decisions-card {
    justify-content: flex-start;
    gap: 0;
    padding: 0;
    overflow: hidden;
}

.game-decisions-trigger {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 8px;
    width: 100%;
    min-height: 52px;
    margin-top: 0;
    padding: 10px 12px;
    border: none;
    border-radius: 16px;
    background: #111;
    color: var(--game-text);
    font-family: inherit;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.game-decisions-trigger-head {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
}

.game-decisions-trigger-title {
    margin: 0;
    font-size: 1rem;
}

.game-decisions-trigger:hover {
    background: #141414;
}

.game-decisions-trigger:focus-visible {
    outline: 2px solid var(--game-accent);
    outline-offset: 2px;
}

.game-decisions-count {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1;
    color: var(--game-muted);
    font-variant-numeric: tabular-nums;
}

.game-decisions-count-wrap {
    display: inline-flex;
    align-items: baseline;
    gap: 6px;
    flex-shrink: 0;
}

.game-decisions-count-label {
    font-size: 0.72rem;
    color: var(--game-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.game-decisions-card--has-items .game-decisions-count {
    color: var(--game-accent);
}

.game-decisions-preview {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
    width: 100%;
}

.game-decisions-preview-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    padding: 6px 8px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.game-decisions-preview-item.is-urgent {
    background: rgba(255, 140, 40, 0.16);
    border-color: rgba(255, 159, 67, 0.45);
}

.game-decisions-preview-title {
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--game-text);
}

.game-decisions-preview-item.is-urgent .game-decisions-preview-title {
    color: #ffb347;
}

.game-decisions-preview-timer {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: #ff9f43;
    font-variant-numeric: tabular-nums;
}

.game-decisions-card--new .game-decisions-trigger,
.game-decisions-trigger--pulse {
    box-shadow: inset 0 0 0 1px rgba(206, 255, 0, 0.35);
    animation: game-decisions-pulse 1.4s ease-in-out infinite;
}

@keyframes game-decisions-pulse {
    0%, 100% {
        box-shadow: inset 0 0 0 1px rgba(206, 255, 0, 0.35);
    }
    50% {
        box-shadow: inset 0 0 0 2px rgba(206, 255, 0, 0.22);
    }
}

.game-decisions-modal-inner {
    width: min(760px, 100%);
}

.game-decisions-modal-empty {
    margin: 0;
    color: var(--game-muted);
    font-size: 0.95rem;
    line-height: 1.45;
}

.game-cards--modal {
    overflow: visible;
    min-height: 0;
}

@media (prefers-reduced-motion: reduce) {
    .game-decisions-card--new .game-decisions-trigger,
    .game-decisions-trigger--pulse {
        animation: none;
    }
}

.game-tunable-card .game-marketing-buttons {
    flex-wrap: wrap;
}

.game-tunable-card .game-marketing-option {
    flex: 1 1 calc(50% - 2px);
    min-width: 3.5rem;
}

.game-finance-control-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--game-muted);
}

.game-marketing-buttons {
    display: flex;
    gap: 4px;
}

.game-marketing-option {
    flex: 1;
    padding: 6px 4px;
    font-size: 0.75rem;
    font-family: inherit;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: transparent;
    color: var(--game-muted);
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.game-marketing-option:hover:not(:disabled) {
    border-color: var(--game-accent);
    color: var(--game-text);
}

.game-marketing-option.is-active {
    background: var(--game-accent);
    border-color: var(--game-accent);
    color: #000;
    font-weight: 600;
}

.game-marketing-option[data-level="Turbo"].is-active {
    border-color: #ff9f43;
    color: #ff9f43;
    background: rgba(255, 159, 67, 0.12);
}

.game-marketing-funnel {
    margin: 4px 0 0;
    padding: 10px 8px 8px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.game-marketing-funnel-viz {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
}

.game-marketing-funnel-svg {
    display: block;
    width: 100%;
    height: auto;
    overflow: visible;
}

.game-marketing-funnel-seg polygon {
    stroke: rgba(0, 0, 0, 0.35);
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
    transition: fill 0.35s ease;
}

.game-marketing-funnel-seg--leads polygon {
    fill: rgba(120, 200, 140, 0.9);
}

.game-marketing-funnel-seg--convert polygon {
    fill: rgba(100, 170, 220, 0.88);
}

.game-marketing-funnel-seg--won polygon {
    fill: rgba(206, 255, 0, 0.78);
}

.game-marketing-funnel-seg--delivered polygon {
    fill: rgba(220, 140, 60, 0.85);
}

.game-marketing-funnel-seg-title {
    fill: #000;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.02em;
    pointer-events: none;
}

.game-marketing-funnel-seg-sub {
    fill: rgba(0, 0, 0, 0.72);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 8px;
    font-weight: 500;
    font-variant-numeric: tabular-nums;
    pointer-events: none;
}

.game-marketing-funnel-footnote {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 4px;
    font-size: 0.62rem;
    line-height: 1.3;
    color: var(--game-muted);
    text-align: center;
}

.game-marketing-funnel-footnote-sep {
    opacity: 0.55;
}

.game-marketing-funnel-drivers {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
    max-width: 100%;
}

.game-marketing-funnel-driver {
    font-size: 0.58rem;
    line-height: 1.2;
    padding: 2px 5px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--game-muted);
    white-space: nowrap;
}

.game-marketing-funnel-driver--up {
    border-color: rgba(206, 255, 0, 0.35);
    color: rgba(206, 255, 0, 0.9);
}

.game-marketing-funnel-driver--down {
    border-color: rgba(255, 107, 107, 0.35);
    color: #ff8f8f;
}

.game-marketing-funnel-driver--neutral {
    opacity: 0.85;
}

.game-finance-note {
    font-size: 0.7rem;
    color: var(--game-muted);
}

.game-coaching-hints {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.game-coaching-hint {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 8px;
    font-size: 0.75rem;
    line-height: 1.35;
    color: var(--game-text);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.game-coaching-hint i {
    color: var(--game-accent);
    margin-top: 2px;
    flex-shrink: 0;
}

.game-coaching-hint--warning {
    border-color: rgba(255, 200, 87, 0.45);
    background: rgba(255, 200, 87, 0.08);
}

.game-coaching-hint--critical {
    border-color: rgba(255, 107, 107, 0.5);
    background: rgba(255, 107, 107, 0.1);
}

.game-coaching-hint--critical i {
    color: #ff8a8a;
}

.game-coaching-target {
    cursor: help;
    outline-offset: 2px;
}

.game-coaching-target--warning {
    box-shadow: inset 0 0 0 1px rgba(255, 200, 87, 0.35);
    border-radius: 8px;
}

.game-coaching-target--critical {
    box-shadow: inset 0 0 0 1px rgba(255, 107, 107, 0.45);
    border-radius: 8px;
}

.game-workload-lights {
    display: flex;
    gap: 4px;
    align-items: center;
    height: 26px;
}

.game-workload-light {
    flex: 1;
    height: 14px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.08);
    transition: background 0.3s ease;
}

.game-workload-light.is-on.is-ok {
    background: #7ed957;
}

.game-workload-light.is-on.is-warm {
    background: #ffc857;
}

.game-workload-light.is-on.is-hot {
    background: #ff6b6b;
}

.game-workload-light.is-burnout {
    animation: game-workload-flash 1s ease-in-out infinite;
}

@keyframes game-workload-flash {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}

/* ------------------------------------------------------------------ */
/* Gamemaker overlay (designer lightstacks)                           */
/* ------------------------------------------------------------------ */

.game-gamemaker {
    margin: 0 0 1rem;
    padding: 1rem 1.1rem;
    border-radius: 14px;
    background: rgba(8, 12, 20, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

.game-gamemaker-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.85rem;
}

.game-gamemaker-title {
    margin: 0;
    font-size: 0.95rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--game-muted);
}

.game-gamemaker-section + .game-gamemaker-section {
    margin-top: 1rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.game-gamemaker-section-title {
    margin: 0 0 0.55rem;
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--game-muted);
}

.game-gamemaker-grid {
    display: grid;
    gap: 0.65rem;
}

.game-gamemaker-grid--factors {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.game-gamemaker-grid--economy,
.game-gamemaker-grid--founder {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.game-gamemaker-grid--scores {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.game-gamemaker-grid--team {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.game-gamemaker-score,
.game-gamemaker-member {
    padding: 0.65rem 0.75rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.game-gamemaker-member--founder {
    border-color: rgba(206, 255, 0, 0.22);
    background: rgba(206, 255, 0, 0.04);
}

.game-gamemaker-score-header,
.game-gamemaker-member-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.45rem;
}

.game-gamemaker-score-header h3,
.game-gamemaker-member-header h3 {
    margin: 0;
    font-size: 0.85rem;
}

.game-gamemaker-member-header span {
    font-size: 0.72rem;
    color: var(--game-muted);
}

.game-gamemaker-score-contributors,
.game-gamemaker-member-metrics {
    display: grid;
    gap: 0.4rem;
}

.game-gamemaker-empty {
    margin: 0;
    font-size: 0.8rem;
    color: var(--game-muted);
}

.game-lightstack {
    display: grid;
    gap: 0.25rem;
}

.game-lightstack--compact .game-lightstack-label {
    font-size: 0.68rem;
}

.game-lightstack-label {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.35rem;
    font-size: 0.72rem;
    color: var(--game-muted);
}

.game-lightstack-label strong {
    color: #fff;
    font-size: 0.72rem;
}

.game-lightstack-segments {
    display: flex;
    gap: 3px;
    align-items: center;
    min-height: 12px;
}

.game-lightstack-segment {
    flex: 1;
    height: 10px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.08);
}

.game-lightstack-segment.is-on.is-ok {
    background: #7ed957;
}

.game-lightstack-segment.is-on.is-warm {
    background: #ffc857;
}

.game-lightstack-segment.is-on.is-hot {
    background: #ff6b6b;
}

.game-shell--gamemaker .game-play-summary-feed-row {
    margin-top: 0;
}

/* ------------------------------------------------------------------ */
/* Team management modal                                              */
/* ------------------------------------------------------------------ */

.game-team-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.game-team-modal[hidden] {
    display: none;
}

.game-team-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.72);
}

.game-team-modal-inner {
    position: relative;
    width: min(680px, 100%);
    max-height: 86vh;
    overflow-y: auto;
    background: #101010;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 16px;
    padding: 20px 22px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.game-team-modal-inner--leaderboard {
    width: min(1480px, 100%);
}

.game-leaderboard-table--modal {
    max-height: none;
    overflow: visible;
}

.game-team-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.game-team-modal-header h2 {
    font-size: 1.3rem;
    margin: 0;
}

.game-team-modal-close {
    background: none;
    border: none;
    color: var(--game-muted);
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
}

.game-team-modal-close:hover {
    color: var(--game-text);
}

.game-team-modal-note {
    font-size: 0.85rem;
    color: var(--game-muted);
    margin: 0 0 12px;
}

.game-team-office-warning {
    margin: 0 0 12px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(255, 200, 87, 0.45);
    background: rgba(255, 200, 87, 0.1);
}

.game-team-office-warning-text {
    margin: 0;
    font-size: 0.84rem;
    line-height: 1.45;
    color: #f5d08a;
}

.game-team-office-warning-link {
    display: inline;
    margin: 0;
    padding: 0;
    border: none;
    background: none;
    font: inherit;
    color: #ffc857;
    text-decoration: underline;
    text-underline-offset: 2px;
    cursor: pointer;
}

.game-team-office-warning-link:hover {
    color: #ffe08a;
}

.game-team-office-warning-link:focus-visible {
    outline: 2px solid #ffc857;
    outline-offset: 2px;
    border-radius: 2px;
}

#game-office-modal {
    z-index: 1100;
}

.game-team-policy {
    margin-bottom: 16px;
}

.game-team-policy-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.game-team-policy-knob {
    padding: 12px;
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
}

.game-team-policy-knob .game-team-modal-subheading {
    margin-bottom: 8px;
}

.game-team-modal-subheading {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--game-muted);
    margin: 0 0 8px;
}

.game-team-modal-empty {
    font-size: 0.85rem;
    color: var(--game-muted);
}

.game-team-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.game-team-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
}

.game-team-row--founder {
    border-color: rgba(206, 255, 0, 0.25);
    background: rgba(206, 255, 0, 0.04);
}

.game-team-row-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.game-team-row-main strong {
    font-size: 0.9rem;
}

.game-team-row-main span {
    font-size: 0.75rem;
    color: var(--game-muted);
}

.game-team-row-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    font-size: 0.75rem;
    color: var(--game-muted);
    font-variant-numeric: tabular-nums;
}

.game-team-fire {
    padding: 6px 10px;
    font-size: 0.72rem;
    font-family: inherit;
    border: 1px solid rgba(255, 107, 107, 0.6);
    border-radius: 8px;
    background: transparent;
    color: #ff6b6b;
    cursor: pointer;
}

.game-team-fire:hover {
    background: rgba(255, 107, 107, 0.15);
}

.game-hire-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.game-hire-role h4 {
    font-size: 0.9rem;
    margin: 0 0 6px;
}

.game-hire-role h4 small {
    font-weight: normal;
    font-size: 0.72rem;
    color: var(--game-muted);
}

.game-hire-role.is-locked {
    opacity: 0.55;
}

.game-hire-role-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
}

.game-hire-option {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px 10px;
    font-family: inherit;
    text-align: left;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--game-text);
    cursor: pointer;
    transition: border-color 0.15s ease;
}

.game-hire-option:hover:not(:disabled) {
    border-color: var(--game-accent);
}

.game-hire-option.is-busy {
    opacity: 0.6;
    pointer-events: none;
}

.game-hire-option:disabled {
    cursor: not-allowed;
}

.game-hire-option strong {
    font-size: 0.85rem;
}

.game-hire-option span {
    font-size: 0.75rem;
    color: var(--game-accent);
    font-variant-numeric: tabular-nums;
}

.game-hire-option small {
    font-size: 0.68rem;
    color: var(--game-muted);
}

@media (max-width: 720px) {
    .game-finance-summary,
    .game-costs-card,
    .game-assets-card {
        flex: 1 1 100%;
    }

    .game-finance-metrics {
        gap: 8px;
    }

    .game-finance-metric {
        padding: 0 8px;
    }

    .game-finance-metric:not(:last-child) {
        border-right: 0;
        border-bottom: 0;
    }

    .game-money-value {
        font-size: 1.05rem;
    }

    .game-hire-role-options {
        grid-template-columns: 1fr;
    }
}

/* Reveal sequence (PHASE-09) */
.game-reveal-stages {
    display: flex;
    flex-direction: column;
    gap: 28px;
    margin: 24px 0;
}

.game-reveal-stage {
    border: 1px solid #222;
    border-radius: 16px;
    padding: 20px;
    background: #0a0a0a;
}

.game-reveal-stage--enter {
    animation: game-reveal-fade 0.7s ease;
}

@keyframes game-reveal-fade {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .game-reveal-stage--enter {
        animation: none;
    }
}

.game-reveal-heading {
    font-size: clamp(1.5rem, 4vw, 2rem);
    margin: 8px 0 12px;
}

.game-reveal-meta {
    color: var(--game-muted);
    font-size: 0.9rem;
}

.game-reveal-milestones {
    margin: 12px 0 0;
    padding-left: 1.2rem;
    color: var(--game-muted);
}

.game-consent-fieldset {
    border: 1px solid #222;
    border-radius: 12px;
    padding: 16px;
    margin: 16px 0;
}

.game-consent-label {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin-bottom: 12px;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* Leaderboard page (PHASE-10) */
.game-leaderboard-page {
    max-width: none;
    width: 100%;
}

.game-leaderboard-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.game-leaderboard-tab {
    border: 1px solid #333;
    border-radius: 999px;
    background: transparent;
    color: var(--game-text);
    padding: 8px 14px;
    cursor: pointer;
}

.game-leaderboard-tab.is-active {
    border-color: var(--game-accent);
    color: var(--game-accent);
}

.game-leaderboard-context {
    margin-top: 12px;
}

.game-leaderboard-context-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.game-leaderboard-context--compact .game-leaderboard-context-grid {
    grid-template-columns: 1fr;
}

@media (min-width: 900px) {
    .game-leaderboard-context--compact .game-leaderboard-context-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.game-leaderboard-period-title {
    font-size: 1rem;
    margin: 0 0 8px;
}

.game-leaderboard-rank-note {
    margin: 0 0 10px;
    color: var(--game-muted);
    font-size: 0.9rem;
}

.game-leaderboard-table--compact .game-leaderboard-row {
    padding: 10px 12px;
}

.game-leaderboard-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 16px 0;
}

.game-leaderboard-table-host {
    margin-top: 16px;
    width: 100%;
}

.game-leaderboard-table-host--result .game-leaderboard-data-scroll {
    max-height: min(70vh, 720px);
    overflow-y: auto;
    overscroll-behavior: contain;
}

.game-leaderboard-data-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
}

.game-leaderboard-data-table {
    width: 100%;
    min-width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    table-layout: auto;
}

@media (max-width: 900px) {
    .game-leaderboard-data-table {
        min-width: 900px;
    }
}

.game-leaderboard-data-table th,
.game-leaderboard-data-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #222;
    white-space: nowrap;
}

.game-leaderboard-data-table th {
    color: var(--game-muted);
    font-weight: 500;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    background: #0a0a0a;
    position: sticky;
    top: 0;
    z-index: 1;
}

.game-leaderboard-data-table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.02);
}

.game-leaderboard-data-table tbody tr:hover {
    background: rgba(200, 155, 255, 0.04);
}

.game-leaderboard-data-rank {
    color: var(--game-accent);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.game-leaderboard-data-agency {
    color: #fff;
    font-weight: 600;
    min-width: 8rem;
}

.game-leaderboard-data-money {
    color: var(--game-accent);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.game-leaderboard-data-row--you {
    background: rgba(200, 155, 255, 0.08) !important;
}

.game-leaderboard-data-row--you td:first-child {
    box-shadow: inset 3px 0 0 var(--game-accent);
}

.game-leaderboard-data-row--bust .game-leaderboard-data-money {
    color: var(--game-muted);
}

.game-leaderboard-table--modal .game-leaderboard-data-scroll {
    max-height: min(52vh, 520px);
    overflow-y: auto;
    overscroll-behavior: contain;
}

/* Legacy card rows — kept for reference; table host is canonical */
.game-leaderboard-table {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 16px;
}

.game-leaderboard-row {
    display: grid;
    grid-template-columns: 40px 1fr auto;
    gap: 12px;
    align-items: center;
    border: 1px solid #222;
    border-radius: 12px;
    padding: 14px 16px;
    background: #0a0a0a;
}

.game-leaderboard-rank {
    color: var(--game-accent);
    font-weight: 700;
}

.game-leaderboard-meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.game-leaderboard-agency {
    font-size: 1rem;
}

.game-leaderboard-player,
.game-leaderboard-archetype {
    font-size: 0.85rem;
    color: var(--game-muted);
}

.game-leaderboard-score {
    font-size: 1.25rem;
    color: var(--game-accent);
}

@media (max-width: 720px) {
    .game-leaderboard-row {
        grid-template-columns: 32px 1fr;
    }

    .game-leaderboard-row--detailed {
        grid-template-areas:
            "rank meta"
            "score score"
            "details details";
    }

    .game-leaderboard-score {
        grid-column: 2;
    }

    .game-leaderboard-row--detailed .game-leaderboard-score {
        grid-column: auto;
        grid-area: score;
        justify-self: start;
        padding-left: 44px;
    }
}

.game-office-heading-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 10px;
}

.game-office-cap-bar {
    height: 6px;
    border-radius: 999px;
    background: #1a1a1a;
    border: 1px solid #262626;
    overflow: hidden;
}

.game-office-cap-fill {
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: var(--game-accent);
    transition: width 0.25s ease;
}

.game-office-cap-bar.is-warning .game-office-cap-fill {
    background: #f5c76b;
}

.game-office-cap-bar.is-full .game-office-cap-fill {
    background: #ff6b6b;
}

.game-office-pending,
.game-office-blocked {
    margin: 0;
    font-size: 0.72rem;
    line-height: 1.35;
    padding: 6px 8px;
    border-radius: 8px;
}

.game-office-pending {
    color: #f5c76b;
    background: rgba(245, 199, 107, 0.08);
    border: 1px solid rgba(245, 199, 107, 0.2);
}

.game-office-blocked {
    color: #ff9b9b;
    background: rgba(255, 107, 107, 0.08);
    border: 1px solid rgba(255, 107, 107, 0.2);
}

.game-office-modal-note {
    margin: 0 0 10px;
    font-size: 0.82rem;
    color: var(--game-muted);
}

.game-office-options {
    display: grid;
    gap: 8px;
    margin-bottom: 18px;
}

.game-office-option {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    gap: 2px 8px;
    padding: 10px 12px;
    text-align: left;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 10px;
    background: transparent;
    color: var(--game-text);
    font-family: inherit;
    cursor: pointer;
}

.game-office-option:hover:not(:disabled) {
    border-color: var(--game-accent);
}

.game-office-option.is-current,
.game-office-option:disabled {
    opacity: 0.75;
    cursor: default;
}

.game-office-option-label {
    font-weight: 600;
    font-size: 0.9rem;
}

.game-office-option-meta {
    grid-column: 1;
    font-size: 0.78rem;
    color: var(--game-muted);
}

.game-office-option-action {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: center;
    font-size: 0.75rem;
    color: var(--game-accent);
}

.game-assets-list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.game-assets-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
}

.game-assets-item-label {
    font-size: 0.9rem;
    font-weight: 600;
}

.game-assets-item-meta {
    font-size: 0.78rem;
    color: var(--game-muted);
}
