/* Greenback's visual system. All fonts and artwork work without a network. */
:root {
    --paper:#f4f0e5;
    --paper-light:#fbf9f2;
    --ink:#293b30;
    --muted:#7c8071;
    --green:#375b3c;
    --green-deep:#264132;
    --green-pale:#e7edd8;
    --line:#dedfd1;
    --gold:#af813c;
    --serif:Georgia,'Times New Roman',serif;
    --sans:-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif
}

* {
    box-sizing:border-box
}

html {
    scroll-behavior:smooth
}

body {
    margin:0;
    background:var(--paper);
    color:var(--ink);
    font-family:var(--sans);
    font-size:14px;
    -webkit-font-smoothing:antialiased;
    background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Cpath fill='%236e704d' opacity='.045' filter='url(%23n)' d='M0 0h180v180H0z'/%3E%3C/svg%3E")
}

button,input {
    font:inherit
}

button,a {
    -webkit-tap-highlight-color:transparent
}

button {
    cursor:pointer
}

button:disabled {
    cursor:default
}

button {
    touch-action:manipulation
}

button:focus-visible,a:focus-visible,input:focus-visible {
    outline:3px solid #92733b;
    outline-offset:5px
}

a {
    color:inherit
}

button {
    color:inherit
}

svg {
    display:block
}

.icon {
    width:21px;
    height:21px;
    flex:none;
    fill:none;
    stroke:currentColor;
    stroke-width:1.65;
    stroke-linecap:round;
    stroke-linejoin:round
}

.svg-defs {
    position:absolute;
    width:0;
    height:0;
    overflow:hidden
}

button[hidden],[hidden] {
    display:none!important
}

.sr-only {
    position:absolute;
    width:1px;
    height:1px;
    padding:0;
    margin:-1px;
    overflow:hidden;
    clip:rect(0,0,0,0);
    white-space:nowrap;
    border:0
}

.skip-link {
    position:fixed;
    top:-100px;
    left:20px;
    background:var(--green-deep);
    color:white;
    padding:15px;
    z-index:20
}

.skip-link:focus {
    top:10px
}

.site-header {
    height:82px;
    max-width:1320px;
    margin:auto;
    display:flex;
    align-items:center;
    justify-content:space-between;
    border-bottom:1px solid var(--line);
    gap:16px;
    padding:0 2px
}

.site-link {
    font-size:11px;
    letter-spacing:2px;
    font-weight:650;
    text-decoration:none;
    display:flex;
    align-items:center;
    gap:10px
}

.site-link .icon {
    width:15px;
    height:15px
}

.site-link:hover {
    color:var(--gold)
}

.experiment-number {
    font-size:9px;
    letter-spacing:2.1px;
    color:#717565
}

.header-actions {
    display:flex;
    gap:5px
}

.icon-button {
    display:grid;
    place-items:center;
    width:36px;
    height:36px;
    border:1px solid transparent;
    background:transparent;
    border-radius:50%;
    transition:background .2s,border-color .2s
}

.icon-button:hover {
    background:#e8e7da;
    border-color:#d5d8c7
}

.icon-button .icon {
    width:19px;
    height:19px
}

.icon-button[aria-pressed=true] {
    color:var(--green);
    background:var(--green-pale)
}

main {
    max-width:1320px;
    margin:auto;
    padding:35px 0 0
}

.title-row {
    display:flex;
    align-items:center;
    justify-content:space-between;
    margin-bottom:35px
}

.brand {
    display:flex;
    align-items:center;
    gap:13px
}

.brand-symbol {
    height:35px;
    width:35px;
    background:var(--green-deep);
    color:var(--paper-light);
    font:bold italic 30px/29px var(--serif);
    border-radius:50%;
    text-align:center;
    letter-spacing:-3px;
    padding-right:3px
}

.brand h1 {
    margin:0;
    font:normal 37px/.95 var(--serif);
    letter-spacing:-1.8px
}

.brand-period {
    color:#758c56
}

.edition {
    font-size:8px;
    letter-spacing:1.4px;
    padding-left:15px;
    border-left:1px solid #cccebf;
    margin-left:4px;
    line-height:18px
}

.live-badge {
    font-size:8px;
    font-weight:600;
    letter-spacing:1.2px;
    display:flex;
    gap:7px;
    align-items:center;
    background:#e8ecdc;
    border:1px solid #d8dfc7;
    border-radius:30px;
    padding:9px 12px
}

.live-badge>span,.income-dot,.save-dot {
    width:5px;
    height:5px;
    border-radius:50%;
    background:#6a9251;
    display:inline-block
}

.game-layout {
    display:grid;
    grid-template-columns:1fr 1.02fr;
    align-items:start;
    gap:40px
}

.eyebrow {
    font-size:8px;
    font-weight:650;
    letter-spacing:1.65px;
    line-height:1.6
}

.earn-panel {
    position:relative;
    padding:31px 31px 0;
    background:#eeecdf99;
    border:1px solid #e0e0d1;
    border-radius:4px;
    overflow:hidden
}

.earn-topline {
    display:flex;
    justify-content:space-between;
    gap:10px;
    align-items:center
}

.earn-topline>.eyebrow {
    font-size:7px;
    letter-spacing:1.4px
}

.rank {
    font-size:9px;
    padding:5px 8px;
    border:1px solid #cbd4ba;
    border-radius:20px;
    color:#546747;
    white-space:nowrap;
    background:#e7ebda
}

.earn-panel h2 {
    font:normal clamp(40px,4.1vw,59px)/1.06 var(--serif);
    letter-spacing:-2px;
    margin:24px 0 13px
}

.earn-panel h2 em {
    font-weight:normal;
    color:#687e54
}

.intro {
    color:#757967;
    font-size:11px;
    line-height:1.8;
    margin:0
}

.balance-block {
    margin:29px 0 19px
}

.balance-block>.eyebrow {
    font-size:8px;
    color:#7b806e;
    letter-spacing:1.5px
}

.balance {
    font:normal 54px/1.2 var(--serif);
    letter-spacing:-2px;
    font-variant-numeric:tabular-nums;
    margin-top:4px;
    white-space:nowrap
}

.balance-cents {
    font-size:.52em;
    color:#90977d;
    letter-spacing:-1px
}

.earning-stats {
    display:flex;
    align-items:center;
    gap:21px
}

.earning-stats>div {
    display:flex;
    align-items:center;
    gap:9px
}

.earning-stats strong {
    font-size:13px;
    font-weight:600;
    font-variant-numeric:tabular-nums
}

.earning-stats small {
    font-size:9px;
    color:#7c806f;
    display:block;
    margin-top:3px
}

.stat-symbol {
    font-size:24px;
    font-weight:300;
    color:#7c8e63
}

.stat-divider {
    height:26px;
    width:1px;
    background:#d8dccc
}

.income-dot {
    width:6px;
    height:6px;
    box-shadow:0 0 0 4px #dfe6ce
}

.boost-badge {
    font-size:8px;
    background:var(--green-pale);
    color:var(--green);
    border-radius:4px;
    padding:6px;
    margin-left:auto
}

.bill-stage {
    position:relative;
    margin:18px -8px 17px;
    padding:34px 0 0;
    isolation:isolate
}

.banknote-button {
    display:block;
    position:relative;
    width:100%;
    padding:0;
    border:none;
    background:none;
    transform:rotate(-7deg);
    transform-origin:center;
    filter:drop-shadow(0 14px 9px #44533424);
    transition:transform .22s,filter .2s;
    user-select:none;
    -webkit-user-select:none;
    z-index:2
}

.banknote-button:hover {
    transform:rotate(-5deg) translateY(-4px);
    filter:drop-shadow(0 17px 10px #44533430)
}

.banknote-button:active,.banknote-button.pressed {
    transform:rotate(-5deg) translateY(3px) scale(.965);
    filter:drop-shadow(0 5px 4px #44533426);
    transition:transform .07s,filter .07s
}

.banknote {
    width:100%;
    height:auto;
    pointer-events:none
}

.bill-doodle {
    position:absolute;
    font:italic 12px var(--serif);
    color:#8d8e76;
    transform:rotate(-6deg);
    right:3px;
    top:7px
}

.doodle-arrow {
    position:absolute;
    right:13px;
    top:20px;
    width:50px;
    height:40px;
    fill:none;
    stroke:#9a9c83;
    stroke-width:1;
    transform:rotate(12deg)
}

.click-prompt {
    display:flex;
    justify-content:center;
    align-items:center;
    gap:6px;
    font-size:10px;
    color:#59664d;
    margin-top:29px
}

.click-prompt .icon {
    width:15px;
    height:15px;
    transform:rotate(-15deg)
}

.click-prompt>span {
    color:#8c907c;
    font-size:9px;
    margin-left:3px
}

kbd {
    font:8px var(--sans);
    border:1px solid #cdd2c0;
    border-radius:3px;
    padding:2px 5px;
    background:#f5f3e9
}

.particles {
    position:absolute;
    inset:0;
    pointer-events:none;
    z-index:4;
    overflow:visible
}

.cash-particle {
    position:absolute;
    font:italic bold 24px var(--serif);
    color:#355933;
    text-shadow:0 1px 0 #f4f0e5;
    pointer-events:none;
    animation:float-cash .95s ease-out forwards;
    white-space:nowrap
}

.spark-particle {
    position:absolute;
    background:#a8b36b;
    border-radius:1px;
    width:5px;
    height:5px;
    pointer-events:none;
    animation:scatter .7s ease-out forwards
}

@keyframes float-cash {
    0% {
        opacity:0;
        transform:translate(-50%,0) scale(.75)
    }
    15% {
        opacity:1;
        transform:translate(-50%,-14px) scale(1)
    }
    100% {
        opacity:0;
        transform:translate(calc(-50% + var(--dx)), -100px) scale(.9)
    }
}

@keyframes scatter {
    from {
        opacity:.8;
        transform:translate(0,0) rotate(0)
    }
    to {
        opacity:0;
        transform:translate(var(--dx),var(--dy)) rotate(100deg)
    }
}

.milestone {
    padding-top:19px;
    border-top:1px solid #d8ddc9
}

.milestone-heading {
    display:flex;
    justify-content:space-between;
    font-size:8px;
    font-weight:600;
    letter-spacing:1.1px;
    gap:8px
}

.milestone-heading>span:last-child {
    color:#7b826c;
    font-size:9px;
    letter-spacing:0;
    font-variant-numeric:tabular-nums
}

.progress-track {
    height:5px;
    background:#dce0cd;
    border-radius:4px;
    overflow:hidden;
    margin-top:10px
}

.progress-track>div {
    width:0;
    height:100%;
    background:#82996a;
    border-radius:4px;
    transition:width .3s
}

.milestone p {
    font:italic 11px var(--serif);
    color:#8a8c76;
    margin:9px 0 22px
}

.playbook {
    margin:0 -31px;
    background:#e4e7d54d;
    border-top:1px solid #dfe2d0;
    padding:15px 25px 17px
}

.playbook-title {
    font-size:7px;
    font-weight:650;
    letter-spacing:1.5px;
    color:#8a8d78
}

.playbook>div {
    display:flex;
    align-items:center;
    justify-content:space-between;
    margin-top:8px;
    gap:6px
}

.playbook>div>span {
    font-size:9px;
    white-space:nowrap;
    color:#626e54
}

.playbook b {
    font-size:8px;
    color:#929b7d;
    font-weight:500;
    margin-right:5px
}

.playbook i {
    font-style:normal;
    color:#a6ad93;
    font-size:12px
}

.empire-panel {
    padding-top:9px
}

.panel-topline {
    display:flex;
    justify-content:space-between;
    align-items:center
}

.panel-topline>.eyebrow {
    color:#7d8271
}

.income-label {
    font-size:9px;
    color:#8a8e7b
}

.panel-heading {
    display:flex;
    align-items:center;
    justify-content:space-between;
    margin-top:8px
}

.panel-heading h2 {
    font:normal 35px/1.2 var(--serif);
    letter-spacing:-1px;
    margin:0
}

.panel-flower {
    width:31px;
    height:31px;
    color:#9d9e78;
    stroke-width:1.1;
    margin-right:4px
}

.panel-intro {
    font-size:11px;
    color:#7d8271;
    margin:8px 0 24px
}

.tabs {
    display:flex;
    gap:26px;
    border-bottom:1px solid #d9ddcc
}

.tabs>button {
    background:none;
    border:none;
    padding:0 0 14px;
    position:relative;
    color:#858977;
    font-size:11px;
    font-weight:500;
    display:flex;
    gap:7px;
    align-items:center;
    min-height:34px
}

.tabs>button[aria-selected=true] {
    color:var(--green-deep);
    font-weight:650
}

.tabs>button[aria-selected=true]:after {
    content:'';
    position:absolute;
    bottom:-1px;
    left:0;
    right:0;
    height:2px;
    background:var(--green-deep)
}

.tabs>button>span:not(.tab-dot) {
    font-size:8px;
    background:#e4e9d6;
    border-radius:4px;
    padding:2px 5px;
    color:#66804d;
    min-width:16px;
    text-align:center
}

.tab-dot {
    width:5px;
    height:5px;
    background:#91a369;
    border-radius:50%
}

.store-toolbar {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:8px;
    padding:17px 0 13px
}

.store-toolbar>span {
    font-size:9px;
    color:#868b77
}

.quantity-control {
    display:flex;
    background:#e9eadd;
    border:1px solid #dedfce;
    padding:3px;
    border-radius:5px;
    gap:1px
}

.quantity-control button {
    border:0;
    background:none;
    padding:4px 8px;
    border-radius:3px;
    color:#899078;
    font-size:9px;
    min-width:30px
}

.quantity-control button[aria-pressed=true] {
    background:#fbfaf3;
    color:var(--green-deep);
    box-shadow:0 1px 3px #28362713
}

.business-list {
    display:grid;
    gap:9px
}

.business-card {
    background:#fbfaf4b3;
    border:1px solid #dedfd1;
    border-radius:5px;
    padding:14px;
    display:grid;
    grid-template-columns:43px minmax(0,1fr) auto;
    align-items:center;
    gap:13px;
    position:relative;
    transition:border-color .25s,background .25s,transform .2s
}

.business-card.affordable {
    border-color:#a7ba8b;
    background:#f9faf0
}

.business-card.bought {
    animation:purchase-flash .5s ease-out
}

.business-icon,.upgrade-icon {
    display:grid;
    place-items:center;
    width:43px;
    height:43px;
    background:#ebeddf;
    border-radius:8px;
    color:#788560;
    border:1px solid #e0e4d1;
    flex:none
}

.business-icon .icon {
    width:25px;
    height:25px;
    stroke-width:1.25
}

.business-card[data-business=coffee] .business-icon {
    background:#f0e8d9;
    border-color:#e8deca;
    color:#9a825a
}

.business-card[data-business=shop] .business-icon {
    background:#e9e8d9;
    color:#8e8e5e;
    border-color:#dedfca
}

.business-card[data-business=studio] .business-icon {
    background:#e4e9e3;
    color:#718675;
    border-color:#d7e0d5
}

.business-card[data-business=greenhouse] .business-icon {
    background:#e5ebd8;
    color:#7d945c;
    border-color:#d9e2c9
}

.business-card[data-business=workshop] .business-icon {
    background:#ece5dc;
    color:#9b8164;
    border-color:#e2d8ca
}

.business-name {
    display:flex;
    align-items:center;
    gap:8px;
    flex-wrap:wrap
}

.business-name h3 {
    font-size:12px;
    font-weight:600;
    margin:0;
    line-height:1.4
}

.owned-pill {
    font-size:8px;
    line-height:1.4;
    padding:2px 5px;
    background:#e9ecdf;
    border-radius:4px;
    color:#7d876b;
    white-space:nowrap
}

.business-description {
    font-size:9px;
    color:#8b8e7e;
    margin:4px 0 6px;
    line-height:1.5
}

.business-rate {
    display:flex;
    gap:5px;
    align-items:center;
    color:#7a8c61;
    font-size:9px;
    font-variant-numeric:tabular-nums
}

.business-rate .icon {
    width:11px;
    height:11px;
    stroke-width:1.5
}

.buy-button {
    border:1px solid #d4dac4;
    color:#85916f;
    background:#e9eddc;
    border-radius:5px;
    min-width:87px;
    padding:9px 9px 7px;
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:2px;
    transition:background .2s,transform .15s,border-color .2s
}

.buy-button:not(:disabled) {
    background:var(--green-deep);
    color:#f4f6e7;
    border-color:var(--green-deep)
}

.buy-button:not(:disabled):hover {
    background:#426247;
    border-color:#426247;
    transform:translateY(-1px)
}

.buy-button:not(:disabled):active {
    transform:translateY(1px)
}

.buy-button .buy-price {
    font-size:11px;
    font-weight:600;
    font-variant-numeric:tabular-nums
}

.buy-button .buy-label {
    font-size:8px;
    letter-spacing:.15px;
    opacity:.75
}

.business-card.maxed .buy-button {
    background:transparent;
    border-color:transparent
}

.store-footnote {
    font-size:9px;
    color:#8d927e;
    display:flex;
    align-items:center;
    justify-content:center;
    gap:6px;
    margin-top:18px
}

.store-footnote .icon {
    width:12px;
    height:12px
}

.tab-description {
    font-size:10px;
    line-height:1.8;
    color:#858b75;
    margin:17px 0
}

.upgrade-list {
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:10px
}

.upgrade-card {
    display:flex;
    flex-direction:column;
    align-items:flex-start;
    padding:16px 14px;
    border:1px solid #dfe2d0;
    background:#fbfaf4b3;
    border-radius:5px;
    gap:8px
}

.upgrade-card .upgrade-icon {
    width:31px;
    height:31px;
    border-radius:50%
}

.upgrade-card .icon {
    width:17px;
    height:17px
}

.upgrade-card h3 {
    font-size:11px;
    margin:0;
    font-weight:650
}

.upgrade-card p {
    font-size:10px;
    color:#858b75;
    line-height:1.6;
    margin:0 0 3px;
    flex:1
}

.upgrade-card .buy-button {
    width:100%;
    flex-direction:row;
    justify-content:space-between;
    padding:8px 10px
}

.upgrade-card.purchased {
    background:#e8eddc66
}

.upgrade-card.purchased .buy-button {
    background:transparent;
    color:#6d8158;
    border:0;
    padding-left:0
}

.ledger-stats {
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:18px 10px;
    margin:23px 0 26px
}

.ledger-stats>div {
    display:flex;
    flex-direction:column;
    gap:7px
}

.ledger-stats span {
    font-size:9px;
    color:#848b75
}

.ledger-stats strong {
    font:normal 25px var(--serif);
    font-variant-numeric:tabular-nums
}

.achievements-heading {
    display:flex;
    justify-content:space-between;
    align-items:center;
    border-top:1px solid var(--line);
    padding-top:19px;
    margin-bottom:14px
}

.achievements-heading h3 {
    font:normal 21px var(--serif);
    margin:0
}

.achievements-heading span {
    font-size:10px;
    color:#8b927a
}

.achievement-list {
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:8px
}

.achievement {
    padding:11px 7px;
    border:1px solid #dfe3d1;
    border-radius:4px;
    text-align:center;
    opacity:.62;
    background:#eaece14d
}

.achievement.unlocked {
    opacity:1;
    background:#e8eed9;
    border-color:#becda7
}

.achievement .icon {
    margin:0 auto 8px;
    width:19px;
    height:19px;
    color:#72865a
}

.achievement h4 {
    font-size:9px;
    font-weight:600;
    line-height:1.5;
    margin:0 0 4px
}

.achievement p {
    font-size:8px;
    color:#858d74;
    line-height:1.5;
    margin:0
}

.chapter-card {
    display:flex;
    gap:12px;
    background:#e8eada;
    border:1px solid #d6ddc5;
    border-radius:5px;
    padding:16px;
    margin-top:21px
}

.chapter-card>.icon {
    color:#7e9261;
    margin-top:3px
}

.chapter-card h3 {
    font:normal 20px var(--serif);
    margin:0 0 7px
}

.chapter-card p {
    font-size:10px;
    line-height:1.7;
    color:#7a846b;
    margin:0 0 10px
}

.text-button {
    border:0;
    padding:0;
    background:none;
    font-size:10px;
    font-weight:600;
    display:flex;
    gap:8px;
    align-items:center;
    text-align:left;
    line-height:1.6
}

.text-button:disabled {
    color:#8c957d
}

.text-button:not(:disabled) {
    text-decoration:underline;
    text-underline-offset:4px
}

.text-button span {
    font-size:14px
}

.game-footer {
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:15px;
    border-top:1px solid #dce0d0;
    margin-top:35px;
    padding:21px 0 30px;
    color:#8e9380;
    font-size:9px
}

.game-footer a {
    font-size:9px;
    text-decoration:none;
    color:#687956
}

.game-footer a:hover {
    text-decoration:underline
}

.game-footer>span:first-child {
    display:flex;
    align-items:center;
    gap:6px
}

.save-dot {
    width:4px;
    height:4px
}

.save-error {
    color:#a57442!important
}

.toast-region {
    position:fixed;
    bottom:24px;
    left:50%;
    transform:translateX(-50%);
    display:flex;
    align-items:center;
    flex-direction:column;
    gap:8px;
    z-index:30;
    pointer-events:none;
    width:min(430px,calc(100vw - 32px))
}

.toast {
    background:var(--green-deep);
    color:#f3f1df;
    border:1px solid #5b7050;
    border-radius:9px;
    padding:13px 17px;
    display:flex;
    align-items:center;
    gap:12px;
    box-shadow:0 6px 30px #273c3026;
    animation:toast-in .25s ease-out;
    max-width:100%;
    font-size:11px;
    line-height:1.6
}

.toast .icon {
    color:#b8cf8e;
    width:20px;
    height:20px
}

.toast strong {
    display:block;
    font-size:11px
}

.toast small {
    font-size:10px;
    color:#bbc8ab
}

.toast.out {
    opacity:0;
    transform:translateY(10px);
    transition:opacity .2s,transform .2s
}

@keyframes toast-in {
    from {
        opacity:0;
        transform:translateY(10px)
    }
    to {
        opacity:1;
        transform:translateY(0)
    }
}

@keyframes purchase-flash {
    0% {
        box-shadow:0 0 0 0 #8da76b66
    }
    100% {
        box-shadow:0 0 0 7px #8da76b00
    }
}

.game-dialog {
    border:1px solid #d9deca;
    background:var(--paper-light);
    color:var(--ink);
    border-radius:12px;
    padding:22px 26px 28px;
    width:min(490px,calc(100vw - 32px));
    max-height:85dvh;
    box-shadow:0 30px 100px #20352830
}

.game-dialog::backdrop {
    background:#1b2f2266;
    backdrop-filter:blur(4px)
}

.dialog-top {
    display:flex;
    justify-content:space-between;
    align-items:center
}

.dialog-top>.eyebrow {
    color:#879074
}

.dialog-top .icon-button {
    margin-right:-8px
}

.game-dialog h2 {
    font:normal 33px/1.15 var(--serif);
    letter-spacing:-1px;
    margin:16px 0 13px
}

.game-dialog p {
    font-size:12px;
    line-height:1.85;
    color:#7a836c
}

.game-dialog .dialog-lead {
    font:italic 20px/1.5 var(--serif);
    color:#668150
}

.game-dialog ol {
    padding-left:20px;
    margin:22px 0
}

.game-dialog li {
    font-size:12px;
    line-height:1.9;
    color:#7a836c;
    padding-left:5px;
    margin-bottom:10px
}

.game-dialog li strong {
    color:#3c513b
}

.dialog-divider {
    border:0;
    border-top:1px solid var(--line);
    margin:22px 0
}

.dialog-action {
    background:var(--green-deep);
    color:#f7f7e9;
    border:1px solid var(--green-deep);
    border-radius:6px;
    padding:12px 18px;
    font-size:12px;
    font-weight:600
}

.dialog-action:hover {
    background:#426247
}

.dialog-actions {
    display:flex;
    gap:10px;
    flex-wrap:wrap;
    margin-top:21px
}

.dialog-action.secondary {
    background:transparent;
    color:var(--ink);
    border-color:#cbd3ba
}

.dialog-action.danger {
    background:#8c4c39;
    border-color:#8c4c39
}

.settings-actions {
    display:grid;
    gap:10px;
    margin:24px 0
}

.settings-row {
    display:flex;
    align-items:center;
    gap:11px;
    padding:13px;
    border:1px solid var(--line);
    border-radius:6px;
    background:transparent;
    text-align:left
}

.settings-row:hover {
    background:#edf0e1
}

.settings-row .icon {
    color:#73845a
}

.settings-row span {
    display:flex;
    flex-direction:column;
    gap:4px;
    font-size:12px;
    font-weight:600
}

.settings-row small {
    font-size:10px;
    font-weight:400;
    color:#7f8871
}

.settings-note {
    font-size:10px!important;
    color:#8d927d!important
}

.offline-amount {
    font:normal 54px/1.2 var(--serif);
    color:var(--green);
    letter-spacing:-1px;
    margin:20px 0
}

.dialog-note {
    border-left:2px solid #bdcba4;
    padding-left:12px
}

.tab-warning {
    background:#e8d9b0;
    color:#564a2b;
    padding:12px;
    text-align:center;
    font-size:12px
}

.tab-warning button {
    background:none;
    border:0;
    color:inherit;
    text-decoration:underline;
    font-weight:600;
    margin-left:8px
}

.noscript {
    position:fixed;
    inset:auto 15px 15px;
    padding:20px;
    background:var(--green-deep);
    color:white;
    z-index:50;
    border-radius:5px;
    text-align:center
}

@media(min-width:1500px) {
    .site-header,main {
        max-width:1340px
    }
    .game-layout {
        gap:55px
    }
    .earn-panel {
        padding-left:38px;
        padding-right:38px
    }
    .playbook {
        margin-left:-38px;
        margin-right:-38px;
        padding-left:32px;
        padding-right:32px
    }
}

@media(max-width:1420px) {
    .site-header,main {
        margin-left:5vw;
        margin-right:5vw
    }
}

@media(max-width:1100px) {
    .game-layout {
        gap:26px
    }
    .earn-panel {
        padding-left:24px;
        padding-right:24px
    }
    .earn-topline>.eyebrow {
        font-size:6.5px;
        letter-spacing:.9px
    }
    .rank {
        font-size:8px
    }
    .earn-panel h2 {
        font-size:48px
    }
    .business-card {
        padding:12px 10px;
        gap:9px;
        grid-template-columns:37px minmax(0,1fr) auto
    }
    .business-icon {
        width:37px;
        height:40px
    }
    .business-icon .icon {
        width:22px;
        height:22px
    }
    .business-name h3 {
        font-size:11px
    }
    .business-description {
        font-size:8px
    }
    .buy-button {
        min-width:74px
    }
    .panel-heading h2 {
        font-size:31px
    }
    .playbook {
        margin-left:-24px;
        margin-right:-24px;
        padding-left:19px;
        padding-right:19px
    }
    .playbook>div>span {
        font-size:8px
    }
    .playbook b {
        margin-right:3px
    }
    .bill-stage {
        padding-top:39px
    }
    .experiment-number {
        font-size:8px;
        letter-spacing:1.2px
    }
    .store-toolbar>span {
        font-size:8px
    }
    .tabs {
        gap:21px
    }
    .edition {
        font-size:7px
    }
    .earning-stats {
        gap:15px
    }
    .boost-badge {
        font-size:7px;
        padding:4px
    }
}

@media(max-width:820px) {
    .game-layout {
        grid-template-columns:1fr;
        gap:32px;
        max-width:600px;
        margin:auto
    }
    .site-header {
        height:68px
    }
    .experiment-number {
        display:none
    }
    main {
        padding-top:25px
    }
    .title-row {
        max-width:600px;
        margin-left:auto;
        margin-right:auto;
        margin-bottom:25px
    }
    .brand h1 {
        font-size:33px
    }
    .edition {
        display:none
    }
    .earn-panel {
        padding:24px 28px 0
    }
    .earn-topline>.eyebrow {
        font-size:8px;
        letter-spacing:1.3px
    }
    .rank {
        font-size:9px
    }
    .earn-panel h2 {
        font-size:54px;
        margin-top:21px
    }
    .intro {
        font-size:12px
    }
    .balance-block {
        margin-top:26px
    }
    .balance {
        font-size:56px
    }
    .bill-stage {
        max-width:480px;
        margin:10px auto 18px;
        padding-top:30px
    }
    .bill-doodle {
        top:1px
    }
    .doodle-arrow {
        top:11px
    }
    .banknote-button {
        width:94%;
        margin:0 auto
    }
    .click-prompt {
        margin-top:28px
    }
    .playbook {
        margin-left:-28px;
        margin-right:-28px;
        padding:16px 28px
    }
    .playbook>div>span {
        font-size:10px
    }
    .playbook b {
        font-size:9px;
        margin-right:6px
    }
    .panel-heading h2 {
        font-size:34px
    }
    .panel-topline>.eyebrow {
        font-size:8px
    }
    .panel-intro {
        font-size:12px
    }
    .store-toolbar>span {
        font-size:10px
    }
    .business-card {
        padding:16px;
        gap:15px;
        grid-template-columns:44px minmax(0,1fr) auto
    }
    .business-icon {
        width:44px;
        height:45px
    }
    .business-icon .icon {
        width:25px;
        height:25px
    }
    .business-name h3 {
        font-size:13px
    }
    .business-description {
        font-size:10px
    }
    .business-rate {
        font-size:10px
    }
    .buy-button {
        min-width:94px;
        padding:11px 10px 9px
    }
    .buy-button .buy-price {
        font-size:12px
    }
    .buy-button .buy-label {
        font-size:9px
    }
    .game-footer {
        max-width:600px;
        margin-left:auto;
        margin-right:auto;
        flex-wrap:wrap;
        font-size:9px
    }
    .game-footer>span:nth-child(2) {
        order:3;
        width:100%;
        text-align:center;
        margin-top:6px
    }
    .tabs>button {
        font-size:12px
    }
    .tabs {
        gap:30px
    }
    .upgrade-card h3 {
        font-size:12px
    }
    .upgrade-card p {
        font-size:11px
    }
    .upgrade-card {
        padding:17px
    }
    .achievement h4 {
        font-size:10px
    }
    .achievement p {
        font-size:9px
    }
    .store-footnote {
        font-size:10px
    }
}

@media(max-width:440px) {
    .site-header,main {
        margin-left:20px;
        margin-right:20px
    }
    .site-link {
        font-size:9px;
        letter-spacing:1.6px
    }
    .header-actions {
        gap:0
    }
    .icon-button {
        width:33px;
        height:33px
    }
    .brand {
        gap:9px
    }
    .brand h1 {
        font-size:31px
    }
    .brand-symbol {
        width:29px;
        height:29px;
        font-size:26px;
        line-height:24px
    }
    .live-badge {
        font-size:6px;
        letter-spacing:.7px;
        padding:7px 9px
    }
    .earn-panel {
        padding:22px 19px 0
    }
    .earn-topline>.eyebrow {
        font-size:6px;
        letter-spacing:1px
    }
    .rank {
        font-size:8px;
        padding:4px 7px
    }
    .earn-panel h2 {
        font-size:46px;
        letter-spacing:-1.7px
    }
    .intro {
        font-size:10px
    }
    .balance {
        font-size:49px
    }
    .balance-block {
        margin-top:23px;
        margin-bottom:17px
    }
    .bill-stage {
        margin:14px -2px 16px;
        padding-top:26px
    }
    .bill-doodle {
        font-size:10px
    }
    .doodle-arrow {
        width:40px;
        right:4px;
        top:9px
    }
    .click-prompt {
        font-size:9px;
        margin-top:23px
    }
    .click-prompt>span {
        font-size:8px
    }
    .playbook {
        margin-left:-19px;
        margin-right:-19px;
        padding:14px 18px
    }
    .playbook>div>span {
        font-size:8px
    }
    .playbook b {
        font-size:7px;
        margin-right:3px
    }
    .playbook-title {
        font-size:6px
    }
    .milestone-heading {
        font-size:7px;
        letter-spacing:.65px
    }
    .milestone-heading>span:last-child {
        font-size:8px
    }
    .milestone p {
        font-size:10px
    }
    .business-card {
        padding:13px 10px;
        gap:10px;
        grid-template-columns:37px minmax(0,1fr) auto
    }
    .business-icon {
        width:37px;
        height:39px
    }
    .business-icon .icon {
        width:22px;
        height:22px
    }
    .business-name h3 {
        font-size:11px
    }
    .business-name {
        gap:4px
    }
    .business-description {
        font-size:9px
    }
    .business-rate {
        font-size:9px
    }
    .buy-button {
        min-width:77px;
        padding:10px 7px 8px
    }
    .buy-button .buy-price {
        font-size:11px
    }
    .buy-button .buy-label {
        font-size:8px
    }
    .store-toolbar>span {
        font-size:8px;
        max-width:160px;
        line-height:1.5
    }
    .quantity-control button {
        min-width:28px;
        padding:5px 6px
    }
    .panel-heading h2 {
        font-size:31px
    }
    .tabs {
        gap:24px
    }
    .tabs>button {
        font-size:11px
    }
    .upgrade-card {
        padding:13px 11px
    }
    .upgrade-card h3 {
        font-size:11px
    }
    .upgrade-card p {
        font-size:10px
    }
    .upgrade-card .buy-button {
        min-width:0
    }
    .achievement {
        padding:10px 5px
    }
    .achievement h4 {
        font-size:9px
    }
    .achievement p {
        font-size:8px
    }
    .game-dialog {
        padding:18px 21px 24px
    }
    .game-dialog h2 {
        font-size:29px
    }
    .game-footer {
        font-size:8px
    }
    .game-footer a {
        font-size:8px
    }
    .store-footnote {
        font-size:9px
    }
}

@media(prefers-reduced-motion:reduce) {
    html {
        scroll-behavior:auto
    }
    *,*:before,*:after {
        animation:none!important;
        transition:none!important
    }
    .banknote-button,.banknote-button:hover,.banknote-button:active,.banknote-button.pressed {
        transform:rotate(-5deg)
    }
    .cash-particle,.spark-particle {
        display:none
    }
}

/* Final readability and touch refinements. */
.intro,.panel-intro,.business-description,.tab-description,.earning-stats small,.upgrade-card p,.store-footnote,.income-label,.game-footer,.game-footer a,.store-toolbar>span,.ledger-stats span,.achievement p,.chapter-card p,.milestone p,.settings-note {
    color:#69725f
}

.bill-doodle {
    top:-8px
}

.doodle-arrow {
    top:8px
}

.mobile-dock {
    display:none
}

@media(max-width:820px) {
    .header-actions .icon-button {
        width:44px;
        height:44px
    }
    .tabs>button {
        min-height:44px
    }
    .buy-button {
        min-height:44px
    }
    .quantity-control button {
        min-width:36px;
        min-height:32px
    }
    .bill-doodle {
        top:-6px
    }
    .doodle-arrow {
        top:4px
    }
    body.bill-offscreen .mobile-dock {
        display:flex;
        position:fixed;
        bottom:0;
        left:0;
        right:0;
        z-index:12;
        align-items:center;
        justify-content:space-between;
        padding:12px 20px calc(12px + env(safe-area-inset-bottom));
        gap:15px;
        background:#f8f6edfa;
        border-top:1px solid #cfd7bd;
        box-shadow:0 -5px 25px #293b3010;
        backdrop-filter:blur(12px)
    }
    .mobile-dock>div {
        display:flex;
        flex-direction:column;
        gap:3px
    }
    .mobile-dock>div>span {
        font:24px var(--serif);
        font-variant-numeric:tabular-nums
    }
    .mobile-dock small {
        font-size:10px;
        color:#69725f
    }
    .mobile-dock button {
        background:var(--green-deep);
        color:#f4f0e5;
        border:0;
        border-radius:6px;
        min-height:44px;
        padding:10px 22px;
        font-weight:600;
        font-size:13px;
        display:flex;
        gap:20px;
        align-items:center
    }
    .game-footer {
        padding-bottom:95px
    }
    body.bill-offscreen .toast-region {
        bottom:95px
    }
}

/* Shared leaderboard and first-visit player setup. */
.player-button {
    display: flex;
    align-items: center;
    gap: 7px;
    background: transparent;
    border: 1px solid #d5ddc7;
    padding: 3px 10px 3px 4px;
    border-radius: 30px;
    font-size: 10px;
    margin-right: 8px;
    max-width: 200px;
}
.player-button:hover { background: #e7eddc; }
#player-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-avatar, .board-avatar {
    width: 29px;
    height: 29px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: #e3ead4;
    color: #5d7748;
    flex: none;
}
.profile-avatar .icon, .board-avatar .icon { width: 16px; height: 16px; }
.leaderboard-section {
    margin-top: 42px;
    padding: 28px 32px 22px;
    background: #fbfaf3b3;
    border: 1px solid var(--line);
    border-radius: 5px;
}
.leaderboard-top { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.leaderboard-top .eyebrow { color: #717c61; }
.leaderboard-top h2 { font: normal 36px/1.2 var(--serif); letter-spacing: -1px; margin: 8px 0 7px; }
.leaderboard-top p { color: #69725f; font-size: 11px; margin: 0; line-height: 1.7; }
.board-season { font-size: 8px; letter-spacing: 1px; color: #6b795a; border: 1px solid #d9e0c9; background: #e9eede; border-radius: 20px; padding: 9px 11px; white-space: nowrap; }
.board-controls { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); margin-top: 22px; }
.board-tabs { display: flex; gap: 25px; }
.board-tabs button { border: 0; background: transparent; min-height: 44px; font-size: 12px; color: #707b62; padding: 0 0 13px; position: relative; }
.board-tabs button[aria-selected=true] { color: #29422f; font-weight: 600; }
.board-tabs button[aria-selected=true]::after { content: ''; position: absolute; height: 2px; left: 0; right: 0; bottom: -1px; background: var(--green-deep); }
.board-refresh { display: flex; align-items: center; gap: 6px; border: 0; background: transparent; color: #6b7b59; font-size: 10px; padding: 10px 0 13px 12px; min-height: 44px; }
.board-refresh .icon { width: 14px; height: 14px; }
.board-refresh:disabled { opacity: .6; }
.board-table { border-collapse: collapse; width: 100%; table-layout: fixed; }
.board-table th { font-size: 8px; font-weight: 500; letter-spacing: 1.1px; color: #727e63; padding: 19px 8px 12px; text-align: left; }
.board-table th:first-child { width: 75px; }
.board-table th:last-child { text-align: right; width: 32%; }
.board-table td { padding: 13px 8px; border-bottom: 1px solid #e6e8dc; font-size: 12px; }
.board-table tr.is-you { background: #e8efda; }
.rank-cell { font: italic 20px var(--serif) !important; color: #83916e; }
.rank-cell.medal-1 { color: #a17e37; }
.rank-cell.medal-2 { color: #7a847c; }
.rank-cell.medal-3 { color: #9a785d; }
.board-player { display: flex; align-items: center; gap: 10px; min-width: 0; }
.board-player > span:not(.board-avatar) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.you-badge { font-size: 7px; color: #648047; letter-spacing: 1px; }
.score-cell { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.board-table td.board-empty { text-align: center; padding: 37px 18px; color: #6e7b60; font: italic 17px/1.7 var(--serif); }
.your-ranking { background: #e8eddb; border: 1px solid #d8e1c8; border-radius: 4px; padding: 13px 15px; display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 16px; }
.your-ranking > span { font-size: 11px; color: #63764e; }
.your-ranking strong { font-size: 13px; color: #304c32; font-variant-numeric: tabular-nums; }
.board-footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 19px; line-height: 1.7; }
.board-footer > span { font-size: 10px; color: #6a775c; }
.board-footer .text-button { white-space: nowrap; }
.board-fine-print { font-size: 9px; line-height: 1.7; color: #737d67; margin: 15px 0 0; }
.profile-label, .avatar-picker legend { display: block; font-size: 8px; font-weight: 600; letter-spacing: 1.3px; color: #687958; margin: 23px 0 8px; }
#nickname { display: block; width: 100%; padding: 13px 14px; border: 1px solid #c8d3b6; border-radius: 5px; background: #fffef8; color: var(--ink); font-size: 16px; }
#nickname::placeholder { color: #a0a68f; font-size: 13px; }
.game-dialog .profile-hint { color: #6e7a61; font-size: 10px; line-height: 1.7; margin: 8px 0 0; }
.avatar-picker { border: 0; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 7px; margin: 0; }
.avatar-picker legend { padding: 0; margin-bottom: 11px; }
.avatar-picker button { min-height: 47px; display: grid; place-items: center; border-radius: 6px; border: 1px solid #d9dfcb; background: #edefe2; color: #6f8457; }
.avatar-picker button:hover { background: #e3ebd2; }
.avatar-picker button[aria-pressed=true] { background: #dce9c6; border: 2px solid #65864b; color: #375833; }
.game-dialog .profile-disclosure { margin: 19px 0 0; font-size: 10px; line-height: 1.8; color: #68755c; }
.game-dialog .profile-error { font-size: 11px; color: #98583c; line-height: 1.7; margin: 12px 0 0; }
.dialog-action:disabled { opacity: .55; cursor: not-allowed; }
@media (max-width: 820px) {
    .leaderboard-section { max-width: 600px; margin-left: auto; margin-right: auto; padding: 24px; }
    .player-button { min-height: 38px; }
    .header-actions { align-items: center; }
}
@media (max-width: 600px) {
    #player-name { display: none; }
    .player-button { padding: 3px; margin-right: 0; border-color: transparent; }
    .leaderboard-section { padding: 22px 16px; }
    .leaderboard-top { align-items: flex-start; gap: 8px; }
    .leaderboard-top h2 { font-size: 31px; }
    .leaderboard-top p { font-size: 10px; }
    .board-season { font-size: 6px; letter-spacing: .4px; padding: 7px; margin-top: 23px; }
    .board-table th:first-child { width: 44px; }
    .board-table th:last-child { width: 34%; }
    .board-table th { font-size: 6px; letter-spacing: .5px; padding-left: 3px; padding-right: 3px; }
    .board-table td { padding: 12px 3px; font-size: 11px; }
    .board-avatar { width: 25px; height: 25px; }
    .board-avatar .icon { width: 14px; height: 14px; }
    .board-player { gap: 6px; }
    .rank-cell { font-size: 17px !important; }
    .you-badge { font-size: 6px; letter-spacing: .3px; }
    .board-footer { flex-direction: column; align-items: flex-start; gap: 9px; }
    .board-footer .text-button { min-height: 30px; }
    .board-fine-print { font-size: 8px; }
}
