.py-mechanics {
    --lab-ink: #17130b;
    --lab-panel: #2b2415;
    --lab-panel-high: #382d18;
    --lab-line: #665225;
    --lab-gold: #f6cf3c;
    --lab-gold-light: #ffe982;
    --lab-cream: #fff5c8;
    --lab-red: #c95245;
    --lab-blue: #40447d;
    --lab-cyan: #58a9bf;
    --lab-green: #79ba69;
    color: #eaddad;
}

.py-mechanics [hidden] {
    display: none !important;
}

.py-mechanics button,
.py-mechanics input,
.py-mechanics select {
    font: inherit;
}

.py-mechanics button {
    cursor: pointer;
}

.py-mechanics-hero {
    grid-template-columns: minmax(0, 1fr) 345px;
}

.py-mechanics-live-card {
    position: relative;
    padding: 18px;
    border: 3px solid var(--lab-ink);
    border-radius: 7px;
    background:
        linear-gradient(rgba(64, 68, 125, .08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(64, 68, 125, .08) 1px, transparent 1px),
        var(--lab-gold);
    background-size: 12px 12px;
    color: var(--lab-ink);
    box-shadow: inset 0 0 0 3px var(--lab-gold-light), 7px 7px 0 #9c3a08;
}

.py-mechanics-live-card::before {
    content: "";
    position: absolute;
    inset: 7px;
    border: 1px solid rgba(23, 19, 11, .32);
    pointer-events: none;
}

.py-mechanics-live-card > * {
    position: relative;
}

.py-mechanics-live-card > span {
    color: #4e3a10;
    font-size: 9px;
    font-weight: 950;
    letter-spacing: .13em;
}

.py-mechanics-live-row {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
}

.py-mechanics-live-row small {
    color: #5d4515;
    font-size: 10px;
    font-weight: 850;
    text-transform: uppercase;
}

.py-mechanics-live-row strong {
    color: var(--lab-blue);
    font-size: 27px;
    font-weight: 950;
    line-height: 1;
}

.py-mechanics-live-track {
    height: 9px;
    margin-top: 7px;
    overflow: hidden;
    border: 2px solid var(--lab-ink);
    background: #fff4be;
}

.py-mechanics-live-track i {
    display: block;
    width: 0;
    height: 100%;
    background: repeating-linear-gradient(90deg, var(--lab-blue) 0 13px, #6268ac 13px 26px);
}

.py-mechanics-live-card p {
    margin: 12px 0 0;
    color: #594214;
    font-size: 9px;
    font-weight: 750;
    line-height: 1.45;
}

.py-mechanics-live-card a {
    display: inline-block;
    margin-top: 9px;
    color: #302b6d;
    font-size: 10px;
    font-weight: 950;
    text-transform: uppercase;
}

.py-mechanics-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-top: 14px;
}

.py-mechanics-tabs button {
    position: relative;
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
    gap: 1px 10px;
    min-height: 72px;
    padding: 12px 14px;
    border: 1px solid var(--lab-line);
    border-radius: 7px;
    background: #292112;
    color: #ae9d68;
    text-align: left;
}

.py-mechanics-tabs button::after {
    content: "";
    position: absolute;
    right: 10px;
    bottom: 0;
    left: 10px;
    height: 3px;
    background: transparent;
}

.py-mechanics-tabs button > span {
    grid-row: 1 / span 2;
    align-self: center;
    color: #715d2b;
    font-size: 24px;
    font-weight: 950;
}

.py-mechanics-tabs button strong {
    align-self: end;
    color: #efe1ad;
    font-size: 13px;
}

.py-mechanics-tabs button small {
    font-size: 9px;
}

.py-mechanics-tabs button:hover,
.py-mechanics-tabs button.is-active {
    border-color: #aa842b;
    background: #3a2e17;
}

.py-mechanics-tabs button.is-active > span,
.py-mechanics-tabs button.is-active strong {
    color: var(--lab-gold);
}

.py-mechanics-tabs button.is-active::after {
    background: repeating-linear-gradient(90deg, var(--lab-red) 0 24px, var(--lab-gold) 24px 48px, var(--lab-blue) 48px 72px);
}

.py-mechanics-workbench {
    margin-top: 14px;
}

.py-mechanics-panel {
    display: grid;
    gap: 12px;
}

.py-mechanics-card {
    min-width: 0;
    padding: 17px;
    border: 1px solid var(--lab-line);
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(246, 207, 60, .035), transparent 42%),
        var(--lab-panel);
    box-shadow: inset 0 1px rgba(255, 246, 207, .045);
}

.py-mechanics-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding-bottom: 11px;
    border-bottom: 1px solid #51401d;
}

.py-mechanics-section-head > div:first-child > span,
.py-mechanics-section-head > span {
    color: var(--lab-gold);
    font-size: 8px;
    font-weight: 950;
    letter-spacing: .13em;
}

.py-mechanics-section-head h2 {
    margin: 2px 0 0;
    color: var(--lab-cream);
    font-size: 19px;
    line-height: 1.1;
}

.py-mechanics-section-head small {
    color: #9c8a5b;
    font-size: 9px;
}

.py-mechanics-section-head button,
.py-mechanics-section-head a {
    padding: 6px 8px;
    border: 1px solid #755d29;
    border-radius: 4px;
    background: #211a0e;
    color: #dac57f;
    font-size: 9px;
    font-weight: 850;
    text-decoration: none;
    text-transform: uppercase;
}

.py-mechanics-section-head > div:last-child {
    display: flex;
    align-items: center;
    gap: 6px;
}

.py-mechanics-section-head .is-danger,
.py-mechanics-card button.is-danger {
    border-color: #82443a;
    color: #e89b88;
}

.py-mechanics-two-column {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(340px, .95fr);
    gap: 12px;
}

.py-mechanics-happiness-readout {
    display: flex;
    align-items: baseline;
    gap: 6px;
    margin-top: 17px;
}

.py-mechanics-happiness-readout strong {
    color: var(--lab-gold);
    font-size: 56px;
    font-weight: 950;
    letter-spacing: -.05em;
    line-height: .9;
}

.py-mechanics-happiness-readout > span {
    color: #8d7842;
    font-size: 16px;
    font-weight: 900;
}

.py-mechanics-happiness-readout small {
    margin-left: auto;
    padding: 5px 8px;
    border: 1px solid #735d2a;
    border-radius: 999px;
    color: #ebd78d;
    font-size: 9px;
    font-weight: 900;
    text-transform: uppercase;
}

.py-mechanics-range {
    display: block;
    margin-top: 18px;
}

.py-mechanics-range > span {
    display: flex;
    justify-content: space-between;
    color: #b8a56f;
    font-size: 10px;
}

.py-mechanics-range output {
    color: var(--lab-gold-light);
    font-weight: 900;
}

.py-mechanics-range input {
    width: 100%;
    margin-top: 8px;
    accent-color: var(--lab-gold);
}

.py-mechanics-number-field {
    display: grid;
    gap: 5px;
    color: #ad9a63;
    font-size: 9px;
    font-weight: 850;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.py-mechanics-bond-console > .py-mechanics-number-field {
    grid-template-columns: 1fr 100px;
    align-items: center;
    margin-top: 10px;
}

.py-mechanics-number-field input,
.py-mechanics-stunt-controls select,
.py-mechanics-walk-plan select {
    min-width: 0;
    padding: 8px 9px;
    border: 1px solid #745e2c;
    border-radius: 4px;
    background: #19140b;
    color: var(--lab-cream);
}

.py-mechanics-happiness-track {
    position: relative;
    height: 13px;
    margin-top: 15px;
    border: 2px solid #110e08;
    background: #594719;
}

.py-mechanics-happiness-track i {
    display: block;
    width: 0;
    height: 100%;
    background: repeating-linear-gradient(90deg, #c84b41 0 18px, var(--lab-gold) 18px 36px);
    transition: width .18s ease;
}

.py-mechanics-happiness-track b {
    position: absolute;
    top: -5px;
    width: 2px;
    height: 19px;
    background: #fff7cf;
    box-shadow: 0 0 0 1px #1b160c;
}

.py-mechanics-next-goal {
    display: grid;
    gap: 3px;
    margin-top: 13px;
    padding: 11px 12px;
    border-left: 4px solid var(--lab-gold);
    background: #211a0e;
}

.py-mechanics-next-goal span {
    color: #9e874d;
    font-size: 8px;
    font-weight: 900;
    letter-spacing: .08em;
}

.py-mechanics-next-goal strong {
    color: #f6e7ad;
    font-size: 13px;
}

.py-mechanics-next-goal small {
    color: #a89767;
    font-size: 9px;
    line-height: 1.45;
}

.py-mechanics-walk-plan {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px 12px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed #5a4821;
}

.py-mechanics-walk-plan > div span {
    display: block;
    color: #8e7a49;
    font-size: 8px;
    font-weight: 900;
    text-transform: uppercase;
}

.py-mechanics-walk-plan > div strong {
    display: block;
    margin-top: 2px;
    color: var(--lab-cream);
    font-size: 11px;
}

.py-mechanics-walk-plan p {
    grid-column: 1 / -1;
    margin: 0;
    color: #b5a36c;
    font-size: 10px;
    line-height: 1.5;
}

.py-mechanics-walk-plan p strong {
    color: var(--lab-gold-light);
}

.py-mechanics-ledger-card {
    display: flex;
    flex-direction: column;
}

.py-mechanics-ledger {
    flex: 1;
    max-height: 405px;
    margin-top: 11px;
    overflow: auto;
}

.py-mechanics-ledger > div {
    display: grid;
    grid-template-columns: 23px 1fr auto;
    align-items: center;
    gap: 9px;
    padding: 8px 4px;
    border-bottom: 1px solid #453718;
}

.py-mechanics-ledger > div > span {
    display: grid;
    width: 21px;
    height: 21px;
    place-items: center;
    border: 1px solid #6f5827;
    border-radius: 50%;
    color: #a79154;
    font-size: 8px;
    font-weight: 900;
}

.py-mechanics-ledger p {
    margin: 0;
}

.py-mechanics-ledger p strong,
.py-mechanics-ledger p small {
    display: block;
}

.py-mechanics-ledger p strong {
    color: #eadba6;
    font-size: 10px;
}

.py-mechanics-ledger p small {
    margin-top: 2px;
    color: #8d7a48;
    font-size: 8px;
}

.py-mechanics-ledger b {
    font-size: 11px;
}

.py-mechanics-ledger .is-gain,
.py-mechanics-action-change.is-gain {
    color: #9fd786;
}

.py-mechanics-ledger .is-loss,
.py-mechanics-action-change.is-loss {
    color: #eb8c79;
}

.py-mechanics-action-change.is-zero {
    color: #9b8b60;
}

.py-mechanics-empty {
    margin: 0;
    padding: 18px;
    border: 1px dashed #604d24;
    border-radius: 6px;
    color: #938151;
    font-size: 10px;
    line-height: 1.5;
    text-align: center;
}

.py-mechanics-ledger-card > footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    padding: 11px 12px;
    border: 1px solid #75602a;
    background: #1e180d;
}

.py-mechanics-ledger-card > footer span {
    color: #a3915d;
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.py-mechanics-ledger-card > footer strong {
    color: var(--lab-gold);
    font-size: 25px;
}

.py-mechanics-action-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
    margin-top: 12px;
}

.py-mechanics-action-grid > button {
    display: grid;
    grid-template-columns: 38px 1fr;
    grid-template-rows: auto auto;
    align-items: center;
    gap: 3px 9px;
    min-height: 72px;
    padding: 9px;
    border: 1px solid #58461f;
    border-radius: 5px;
    background: #241d10;
    color: #d7c58d;
    text-align: left;
}

.py-mechanics-action-grid > button:hover {
    border-color: var(--lab-gold);
    background: #312713;
    transform: translateY(-1px);
}

.py-mechanics-action-change {
    grid-row: 1 / span 2;
    font-size: 20px;
    font-weight: 950;
    text-align: center;
}

.py-mechanics-action-grid button > span:nth-child(2) strong,
.py-mechanics-action-grid button > span:nth-child(2) small {
    display: block;
}

.py-mechanics-action-grid button > span:nth-child(2) strong {
    color: #eadba9;
    font-size: 10px;
}

.py-mechanics-action-grid button > span:nth-child(2) small {
    margin-top: 2px;
    color: #8e7c4c;
    font-size: 7px;
}

.py-mechanics-action-grid i {
    grid-column: 2;
    display: flex;
    gap: 3px;
    font-style: normal;
}

.py-mechanics-action-grid i b {
    min-width: 26px;
    padding: 2px 4px;
    border-radius: 3px;
    background: #17130b;
    color: #9e8b56;
    font-size: 7px;
    text-align: center;
}

.py-mechanics-milestone-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 12px;
}

.py-mechanics-milestone-grid article {
    display: grid;
    grid-template-columns: 53px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 11px;
    border: 1px solid #58471f;
    border-radius: 5px;
    background: #241d10;
}

.py-mechanics-milestone-grid article > span {
    color: #8a7440;
    font-size: 24px;
    font-weight: 950;
}

.py-mechanics-milestone-grid article strong {
    color: #eadca7;
    font-size: 11px;
}

.py-mechanics-milestone-grid article p {
    margin: 3px 0 0;
    color: #9c8a5b;
    font-size: 8px;
    line-height: 1.4;
}

.py-mechanics-milestone-grid article a {
    display: inline-block;
    margin-top: 5px;
    color: #e2bf43;
    font-size: 8px;
    font-weight: 850;
}

.py-mechanics-milestone-grid article > b {
    color: #8d7a49;
    font-size: 7px;
}

.py-mechanics-milestone-grid article.is-reached {
    border-color: #668d4d;
    background: #243019;
}

.py-mechanics-milestone-grid article.is-reached > span,
.py-mechanics-milestone-grid article.is-reached > b {
    color: var(--lab-green);
}

.py-mechanics-source-note {
    margin: 12px 0 0;
    padding: 9px 11px;
    border-left: 3px solid #735d2a;
    background: #211a0e;
    color: #a79664;
    font-size: 9px;
    line-height: 1.5;
}

.py-mechanics-rival-layout {
    display: grid;
    grid-template-columns: minmax(420px, 1fr) minmax(320px, .78fr);
    gap: 12px;
}

.py-mechanics-choice-group {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
    margin: 15px 0 0;
    padding: 0;
    border: 0;
}

.py-mechanics-choice-group:first-of-type {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.py-mechanics-choice-group legend {
    grid-column: 1 / -1;
    margin-bottom: 4px;
    color: #a99559;
    font-size: 9px;
    font-weight: 900;
    text-transform: uppercase;
}

.py-mechanics-choice-group label {
    position: relative;
    min-width: 0;
}

.py-mechanics-choice-group input {
    position: absolute;
    opacity: 0;
}

.py-mechanics-choice-group label > span {
    display: block;
    min-height: 62px;
    padding: 10px;
    border: 1px solid #57451f;
    border-radius: 5px;
    background: #211a0e;
}

.py-mechanics-choice-group strong,
.py-mechanics-choice-group small {
    display: block;
}

.py-mechanics-choice-group strong {
    color: #e5d49a;
    font-size: 10px;
}

.py-mechanics-choice-group small {
    margin-top: 4px;
    color: #8c7948;
    font-size: 8px;
    line-height: 1.35;
}

.py-mechanics-choice-group input:checked + span {
    border-color: var(--lab-gold);
    background: #3b3018;
    box-shadow: inset 4px 0 var(--lab-gold);
}

.py-mechanics-choice-group input:focus-visible + span {
    outline: 3px solid var(--lab-gold);
    outline-offset: 2px;
}

.py-mechanics-choice-group.is-disabled {
    opacity: .42;
}

.py-mechanics-rival-result {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 325px;
    padding: 24px;
    overflow: hidden;
    border: 2px solid #93802f;
    border-radius: 8px;
    background:
        radial-gradient(circle at 80% 15%, rgba(255,255,255,.13), transparent 25%),
        linear-gradient(145deg, #4e4120, #272010 70%);
    text-align: center;
    box-shadow: inset 0 0 0 5px #17130b, inset 0 0 0 7px rgba(246, 207, 60, .18);
}

.py-mechanics-rival-result.is-jolteon {
    --rival-color: #f6cf3c;
}

.py-mechanics-rival-result.is-flareon {
    --rival-color: #e36a47;
}

.py-mechanics-rival-result.is-vaporeon {
    --rival-color: #64b7ce;
}

.py-mechanics-rival-result > span {
    color: #ad9b67;
    font-size: 8px;
    font-weight: 950;
    letter-spacing: .14em;
}

.py-mechanics-eevee-orbit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 13px;
    margin: 24px 0 10px;
}

.py-mechanics-eevee-orbit i,
.py-mechanics-eevee-orbit strong {
    display: grid;
    width: 84px;
    height: 84px;
    place-items: center;
    border: 3px solid #17130b;
    border-radius: 50%;
    font-size: 10px;
    font-style: normal;
    box-shadow: 0 0 0 3px #806e31;
}

.py-mechanics-eevee-orbit i {
    background: #b78f5a;
    color: #30200d;
}

.py-mechanics-eevee-orbit strong {
    background: var(--rival-color);
    color: #17130b;
}

.py-mechanics-eevee-orbit b {
    color: var(--rival-color);
    font-size: 25px;
}

.py-mechanics-rival-result h2 {
    margin: 3px 0 0;
    color: var(--rival-color);
    font-size: 34px;
    letter-spacing: -.03em;
}

.py-mechanics-rival-result > small {
    color: #c7b77d;
    font-size: 9px;
    font-weight: 900;
    text-transform: uppercase;
}

.py-mechanics-rival-result p {
    max-width: 360px;
    margin: 12px auto 0;
    color: #b9a875;
    font-size: 10px;
    line-height: 1.5;
}

.py-mechanics-rival-result footer {
    margin-top: 16px;
    color: #8d7b4b;
    font-size: 8px;
    font-weight: 850;
    text-transform: uppercase;
}

.py-mechanics-rival-table {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 7px;
    margin-top: 12px;
}

.py-mechanics-rival-table > div {
    padding: 11px;
    border: 1px solid #56441f;
    border-radius: 5px;
    background: #221b0f;
}

.py-mechanics-rival-table > div.is-active {
    border-color: var(--lab-gold);
    background: #3a2e16;
}

.py-mechanics-rival-table span {
    display: block;
    color: #8f7b48;
    font-size: 8px;
}

.py-mechanics-rival-table strong {
    display: block;
    margin-top: 7px;
    color: var(--lab-gold-light);
    font-size: 15px;
}

.py-mechanics-rival-table p {
    margin: 5px 0 0;
    color: #a59360;
    font-size: 8px;
    line-height: 1.45;
}

.py-mechanics-surf-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(350px, .85fr);
    gap: 12px;
}

.py-mechanics-stunt-controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
    margin-top: 14px;
}

.py-mechanics-stunt-controls > label:first-child {
    display: grid;
    gap: 5px;
    color: #a18d55;
    font-size: 9px;
    font-weight: 850;
    text-transform: uppercase;
}

.py-mechanics-stunt-controls .py-ref-toggle {
    padding: 8px 10px;
    border: 1px solid #58461f;
    border-radius: 5px;
    background: #211a0e;
}

.py-mechanics-stunt-preview {
    display: grid;
    place-items: center;
    min-height: 145px;
    margin-top: 12px;
    border: 2px solid #816a2c;
    border-radius: 7px;
    background:
        radial-gradient(circle at 50% 110%, rgba(88, 169, 191, .3), transparent 48%),
        repeating-linear-gradient(0deg, rgba(255,255,255,.02) 0 2px, transparent 2px 7px),
        #1d2022;
    text-align: center;
}

.py-mechanics-stunt-preview span,
.py-mechanics-stunt-preview strong,
.py-mechanics-stunt-preview small {
    display: block;
}

.py-mechanics-stunt-preview span {
    color: #8ab8c1;
    font-size: 8px;
    font-weight: 950;
    letter-spacing: .12em;
}

.py-mechanics-stunt-preview strong {
    color: var(--lab-gold);
    font-size: 49px;
    font-weight: 950;
    line-height: 1;
    text-shadow: 3px 3px #834124;
}

.py-mechanics-stunt-preview small {
    color: #c5b77e;
    font-size: 9px;
}

.py-mechanics-primary {
    width: 100%;
    margin-top: 9px;
    padding: 10px;
    border: 2px solid #17130b;
    border-radius: 5px;
    background: var(--lab-gold);
    color: #17130b;
    font-size: 10px;
    font-weight: 950;
    text-transform: uppercase;
    box-shadow: inset 0 0 0 2px #ffe783;
}

.py-mechanics-stunt-reference {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    margin-top: 10px;
}

.py-mechanics-stunt-reference > div {
    padding: 6px;
    border: 1px solid #4f411e;
    background: #211a0e;
    text-align: center;
}

.py-mechanics-stunt-reference span,
.py-mechanics-stunt-reference strong {
    display: block;
}

.py-mechanics-stunt-reference span {
    min-height: 20px;
    color: #8e7b4b;
    font-size: 6px;
}

.py-mechanics-stunt-reference strong {
    margin-top: 3px;
    color: #e5c94d;
    font-size: 10px;
}

.py-mechanics-score-totals {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 14px;
}

.py-mechanics-score-totals > div {
    padding: 12px;
    border: 1px solid #5c4921;
    background: #211a0e;
}

.py-mechanics-score-totals span,
.py-mechanics-score-totals strong {
    display: block;
}

.py-mechanics-score-totals span {
    color: #8d7948;
    font-size: 8px;
    font-weight: 850;
    text-transform: uppercase;
}

.py-mechanics-score-totals strong {
    margin-top: 5px;
    color: var(--lab-gold);
    font-size: 27px;
}

.py-mechanics-surf-score-card > .py-mechanics-number-field {
    grid-template-columns: 1fr 145px;
    align-items: center;
    margin-top: 10px;
}

.py-mechanics-score-gap {
    margin-top: 10px;
    padding: 11px;
    border-left: 4px solid var(--lab-cyan);
    background: #1c2020;
}

.py-mechanics-score-gap span,
.py-mechanics-score-gap strong,
.py-mechanics-score-gap small {
    display: block;
}

.py-mechanics-score-gap span {
    color: #7eaab1;
    font-size: 8px;
    font-weight: 900;
}

.py-mechanics-score-gap strong {
    margin-top: 3px;
    color: #e6d99f;
    font-size: 15px;
}

.py-mechanics-score-gap small {
    margin-top: 3px;
    color: #96a4a0;
    font-size: 8px;
    line-height: 1.4;
}

.py-mechanics-stunt-ledger {
    max-height: 248px;
    margin-top: 10px;
    overflow: auto;
}

.py-mechanics-stunt-ledger > div {
    display: grid;
    grid-template-columns: 22px 1fr auto 24px;
    align-items: center;
    gap: 8px;
    padding: 7px 3px;
    border-bottom: 1px solid #493a1b;
}

.py-mechanics-stunt-ledger > div > span {
    color: #7f6d3f;
    font-size: 8px;
}

.py-mechanics-stunt-ledger > div > strong {
    color: #d8ca98;
    font-size: 9px;
}

.py-mechanics-stunt-ledger > div > b {
    color: var(--lab-gold);
    font-size: 10px;
}

.py-mechanics-stunt-ledger button {
    width: 22px;
    height: 22px;
    padding: 0;
    border: 1px solid #714139;
    border-radius: 50%;
    background: transparent;
    color: #d98472;
}

.py-mechanics-access-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.py-mechanics-access-card > div {
    padding: 12px;
    border: 1px solid #58471f;
    background: #211a0e;
}

.py-mechanics-access-card span,
.py-mechanics-access-card strong {
    display: block;
}

.py-mechanics-access-card span {
    color: var(--lab-gold);
    font-size: 8px;
    font-weight: 900;
}

.py-mechanics-access-card strong {
    margin-top: 5px;
    color: #d8ca99;
    font-size: 10px;
    line-height: 1.5;
}

.py-mechanics-access-card p {
    grid-column: 1 / -1;
    margin: 0;
    color: #9e8c59;
    font-size: 9px;
    line-height: 1.5;
}

.py-mechanics-corner-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
}

.py-mechanics-corner-summary > div {
    padding: 13px 14px;
    border: 1px solid #705927;
    border-radius: 6px;
    background: #2a2212;
}

.py-mechanics-corner-summary span,
.py-mechanics-corner-summary strong,
.py-mechanics-corner-summary small {
    display: block;
}

.py-mechanics-corner-summary span {
    color: #9a864f;
    font-size: 8px;
    font-weight: 850;
    text-transform: uppercase;
}

.py-mechanics-corner-summary strong {
    margin-top: 4px;
    color: var(--lab-gold);
    font-size: 25px;
}

.py-mechanics-corner-summary strong.is-negative {
    color: #e98572;
}

.py-mechanics-corner-summary small {
    margin-top: 3px;
    color: #8e7b4b;
    font-size: 8px;
}

.py-mechanics-corner-grid {
    display: grid;
    grid-template-columns: minmax(300px, .8fr) minmax(0, 1.2fr);
    gap: 12px;
}

.py-mechanics-wallet-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 13px;
}

.py-mechanics-free-list {
    display: grid;
    gap: 6px;
    margin-top: 12px;
}

.py-mechanics-free-list > div {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 6px;
}

.py-mechanics-free-list button {
    display: grid;
    grid-template-columns: 28px 1fr auto;
    align-items: center;
    gap: 8px;
    padding: 8px;
    border: 1px solid #56451f;
    border-radius: 4px;
    background: #211a0e;
    color: #d7c793;
    text-align: left;
}

.py-mechanics-free-list > div.is-selected button {
    border-color: #668d4d;
    background: #26311b;
}

.py-mechanics-free-list button i {
    display: grid;
    width: 25px;
    height: 25px;
    place-items: center;
    border: 1px solid #76602b;
    border-radius: 50%;
    color: var(--lab-gold);
    font-size: 9px;
    font-style: normal;
}

.py-mechanics-free-list button strong,
.py-mechanics-free-list button small {
    display: block;
}

.py-mechanics-free-list button strong {
    font-size: 9px;
}

.py-mechanics-free-list button small {
    margin-top: 2px;
    color: #867443;
    font-size: 7px;
}

.py-mechanics-free-list button b {
    color: #99d47d;
    font-size: 12px;
}

.py-mechanics-free-list a {
    align-self: stretch;
    display: grid;
    padding: 0 8px;
    place-items: center;
    border: 1px solid #594820;
    border-radius: 4px;
    color: #d8bb45;
    font-size: 8px;
    font-weight: 850;
    text-decoration: none;
}

.py-mechanics-hidden-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    margin-top: 12px;
}

.py-mechanics-hidden-grid button {
    display: grid;
    grid-template-columns: 29px 1fr auto;
    align-items: center;
    gap: 8px;
    padding: 9px;
    border: 1px solid #57451f;
    border-radius: 4px;
    background: #221b0f;
    color: #d7c793;
    text-align: left;
}

.py-mechanics-hidden-grid button:hover {
    border-color: #a17d2b;
}

.py-mechanics-hidden-grid button.is-selected {
    border-color: #668d4d;
    background: #26301b;
}

.py-mechanics-hidden-grid button > span {
    color: #756334;
    font-size: 15px;
    font-weight: 950;
}

.py-mechanics-hidden-grid strong,
.py-mechanics-hidden-grid small {
    display: block;
}

.py-mechanics-hidden-grid strong {
    color: #d9ca95;
    font-size: 9px;
}

.py-mechanics-hidden-grid small {
    margin-top: 2px;
    color: #857243;
    font-size: 7px;
}

.py-mechanics-hidden-grid i {
    color: #8f7b49;
    font-size: 7px;
    font-style: normal;
    font-weight: 900;
}

.py-mechanics-hidden-grid .is-selected i {
    color: var(--lab-green);
}

.py-mechanics-prize-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-top: 12px;
}

.py-mechanics-prize-grid article {
    position: relative;
    padding: 12px;
    border: 1px solid #58471f;
    border-radius: 5px;
    background: #221b0f;
}

.py-mechanics-prize-grid article.is-selected {
    border-color: var(--lab-gold);
    background: #352a15;
}

.py-mechanics-prize-grid article > span {
    color: #8e7a48;
    font-size: 7px;
    font-weight: 900;
    letter-spacing: .07em;
    text-transform: uppercase;
}

.py-mechanics-prize-grid h3 {
    margin: 5px 0 0;
    color: #eee0ad;
    font-size: 14px;
}

.py-mechanics-prize-grid p {
    margin: 5px 0 0;
    color: var(--lab-gold);
    font-size: 9px;
    font-weight: 850;
}

.py-mechanics-prize-grid article > small {
    display: block;
    margin-top: 4px;
    color: #897747;
    font-size: 7px;
}

.py-mechanics-prize-grid article > div {
    display: grid;
    grid-template-columns: 30px 1fr 30px;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
}

.py-mechanics-prize-grid button {
    width: 30px;
    height: 27px;
    padding: 0;
    border: 1px solid #735d29;
    border-radius: 4px;
    background: #17130b;
    color: var(--lab-gold);
    font-weight: 950;
}

.py-mechanics-prize-grid article > div strong {
    color: #e9d99f;
    font-size: 13px;
    text-align: center;
}

@media (max-width: 1120px) {
    .py-mechanics-action-grid,
    .py-mechanics-hidden-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .py-mechanics-rival-table {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .py-mechanics-stunt-reference {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .py-mechanics-hero,
    .py-mechanics-two-column,
    .py-mechanics-rival-layout,
    .py-mechanics-surf-layout,
    .py-mechanics-corner-grid {
        grid-template-columns: 1fr;
    }

    .py-mechanics-tabs {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .py-mechanics-live-card {
        max-width: 470px;
    }

    .py-mechanics-corner-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .py-mechanics-tabs,
    .py-mechanics-action-grid,
    .py-mechanics-milestone-grid,
    .py-mechanics-rival-table,
    .py-mechanics-hidden-grid,
    .py-mechanics-prize-grid,
    .py-mechanics-access-card,
    .py-mechanics-wallet-fields {
        grid-template-columns: 1fr;
    }

    .py-mechanics-tabs button {
        min-height: 59px;
    }

    .py-mechanics-choice-group,
    .py-mechanics-choice-group:first-of-type {
        grid-template-columns: 1fr;
    }

    .py-mechanics-stunt-controls,
    .py-mechanics-score-totals,
    .py-mechanics-corner-summary {
        grid-template-columns: 1fr 1fr;
    }

    .py-mechanics-milestone-grid article {
        grid-template-columns: 45px 1fr;
    }

    .py-mechanics-milestone-grid article > b {
        grid-column: 2;
    }

    .py-mechanics-access-card p {
        grid-column: 1;
    }
}

@media (max-width: 430px) {
    .py-mechanics-card {
        padding: 12px;
    }

    .py-mechanics-section-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .py-mechanics-section-head > div:last-child {
        flex-wrap: wrap;
    }

    .py-mechanics-stunt-controls,
    .py-mechanics-score-totals,
    .py-mechanics-corner-summary {
        grid-template-columns: 1fr;
    }

    .py-mechanics-stunt-reference {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .py-mechanics-eevee-orbit i,
    .py-mechanics-eevee-orbit strong {
        width: 68px;
        height: 68px;
        font-size: 8px;
    }

    .py-mechanics-rival-result {
        min-height: 300px;
        padding: 18px;
    }
}
