/* =========================================================
   Lemonade Empire — Power-Up Shop
   ========================================================= */

.power-shop {
    padding: 26px 0 56px;
}

.power-shop-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 32px;
    padding: 26px 2px 24px;
}

.power-shop-hero h1 {
    margin: 7px 0 10px;
    font-size: clamp(42px, 6vw, 64px);
    line-height: .96;
}

.power-shop-hero-copy > p {
    max-width: 650px;
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.8;
}


/* Golden Lemon balance */

.golden-balance {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 205px;
    padding: 13px 13px 13px 15px;
    background:
        linear-gradient(
            135deg,
            #fff9dc 0%,
            #f6e29a 100%
        );
    border: 1px solid #dfc663;
    border-radius: 15px;
    box-shadow: 0 8px 24px rgba(87, 73, 25, .09);
}

.golden-balance-icon {
    display: grid;
    place-items: center;
    width: 43px;
    height: 43px;
    flex: 0 0 43px;
    background: rgba(255, 255, 255, .55);
    border: 1px solid rgba(159, 127, 28, .18);
    border-radius: 50%;
    font-size: 23px;
}

.golden-balance > div:nth-child(2) {
    min-width: 0;
    flex: 1;
}

.golden-balance span,
.golden-balance small {
    display: block;
}

.golden-balance span {
    color: #75621f;
    font-size: 8px;
    font-weight: 800;
    letter-spacing: .9px;
}

.golden-balance strong {
    display: block;
    margin-top: 1px;
    color: #43370e;
    font-size: 24px;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.golden-balance small {
    margin-top: 4px;
    color: #89783d;
    font-size: 8px;
}

.golden-balance-add {
    width: 35px;
    height: 35px;
    display: grid;
    place-items: center;
    flex: 0 0 35px;
    padding: 0;
    color: #fffbe9;
    background: var(--green);
    border: 0;
    border-radius: 10px;
    cursor: pointer;
    font-size: 21px;
    font-weight: 700;
}

.golden-balance-add:hover {
    transform: translateY(-1px);
}


/* Preview notice */

.power-shop-notice {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px 16px;
    margin-bottom: 28px;
    color: #5f593c;
    background: #f8efc8;
    border: 1px dashed #d5bc5f;
    border-radius: 12px;
}

.power-shop-notice > span {
    flex: 0 0 auto;
    font-size: 17px;
}

.power-shop-notice p {
    margin: 0;
    font-size: 9px;
    line-height: 1.6;
}


/* Section heading */

.power-shop-section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 18px;
}

.power-shop-section-heading h2 {
    margin: 5px 0 0;
    font-size: 31px;
    line-height: 1.05;
}

.power-shop-section-heading > p {
    max-width: 420px;
    margin: 0;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.7;
}


/* Cards */

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

.power-card {
    position: relative;
    min-width: 0;
    display: flex;
    flex-direction: column;
    min-height: 340px;
    padding: 18px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 17px;
    box-shadow: 0 8px 25px rgba(53, 65, 41, .055);
    overflow: hidden;
}

.power-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: #d6ddc9;
}

.power-card-production::before {
    background: #b8cc72;
}

.power-card-sales::before {
    background: #e3c357;
}

.power-card-automation::before {
    background: #94aaa3;
}

.power-card-traffic::before {
    background: #d59a69;
}

.power-card-storage::before {
    background: #9ebbc1;
}

.power-card-economy::before {
    background: #bda67a;
}

.power-card-boost::before {
    background: #b7a3cf;
}

.power-card-premium::before {
    background: linear-gradient(
        90deg,
        #d6b43f,
        #f0dc7e,
        #c79732
    );
}

.power-card.is-featured {
    border-color: #d5bd63;
    box-shadow: 0 10px 30px rgba(119, 91, 15, .10);
}

.power-card-featured {
    position: absolute;
    top: 13px;
    right: -29px;
    width: 112px;
    padding: 5px 0;
    color: #fffbe9;
    background: var(--green);
    transform: rotate(38deg);
    text-align: center;
    font-size: 7px;
    font-weight: 900;
    letter-spacing: .8px;
}

.power-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.power-card-icon {
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    flex: 0 0 58px;
    background: #f4f2e6;
    border: 1px solid #e2e0d2;
    border-radius: 15px;
    font-size: 29px;
}

.power-card-premium .power-card-icon {
    background: #fff7d3;
    border-color: #e0c96d;
}

.power-card-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 5px;
    padding-right: 2px;
}

.power-card-category {
    color: var(--green);
    font-size: 7px;
    font-weight: 900;
    letter-spacing: .85px;
}

.power-card-duration {
    padding: 4px 7px;
    color: var(--muted);
    background: #f1f0e5;
    border-radius: 20px;
    font-size: 8px;
    white-space: nowrap;
}

.power-card-copy {
    flex: 1;
    padding-top: 18px;
}

.power-card h3 {
    margin: 0;
    font-size: 23px;
    line-height: 1.08;
}

.power-card-tagline {
    display: block;
    min-height: 31px;
    margin-top: 7px;
    color: var(--green);
    font-size: 10px;
    line-height: 1.45;
}

.power-card p {
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.65;
}

.power-card-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding-top: 16px;
    margin-top: 16px;
    border-top: 1px solid #e5e4d7;
}

.power-card-price {
    display: grid;
    grid-template-columns: auto auto;
    align-items: center;
    column-gap: 5px;
}

.power-card-price-icon {
    grid-row: 1 / span 2;
    font-size: 18px;
}

.power-card-price strong {
    color: var(--ink);
    font-size: 17px;
    line-height: 1;
}

.power-card-price > span:last-child {
    color: var(--muted);
    font-size: 7px;
}

.power-card-buy {
    min-height: 38px;
    padding: 8px 15px;
    color: #fffced;
    background: var(--green);
    border: 0;
    border-radius: 9px;
    cursor: pointer;
    font-size: 9px;
    font-weight: 800;
}

.power-card-buy:hover {
    transform: translateY(-1px);
    filter: brightness(1.04);
}


/* Information cards */

.power-shop-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-top: 28px;
}

.power-shop-info article {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 22px;
    background: #eef2e5;
    border: 1px solid #d2dcc5;
    border-radius: 15px;
}

.power-shop-info article:last-child {
    background: #f7edc7;
    border-color: #dfcf91;
}

.power-shop-info-icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    background: rgba(255, 255, 255, .55);
    border-radius: 12px;
    font-size: 22px;
}

.power-shop-info h2 {
    margin: 4px 0 7px;
    font-size: 20px;
}

.power-shop-info p {
    margin: 0;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.7;
}


/* Coming later */

.power-shop-coming {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 25px;
    margin-top: 16px;
    padding: 25px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 15px;
}

.power-shop-coming h2 {
    margin: 5px 0 7px;
    font-size: 23px;
}

.power-shop-coming p {
    max-width: 600px;
    margin: 0;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.7;
}

.power-shop-coming-items {
    display: flex;
    gap: 7px;
}

.power-shop-coming-items span {
    display: grid;
    place-items: center;
    width: 43px;
    height: 43px;
    background: #f1f0e5;
    border: 1px solid var(--line);
    border-radius: 10px;
    font-size: 19px;
}


/* Mock interaction toast */

.shop-preview-toast {
    position: fixed;
    z-index: 120;
    right: 18px;
    bottom: 18px;
    max-width: min(360px, calc(100vw - 36px));
    padding: 12px 15px;
    color: #fffdeb;
    background: #213d2d;
    border: 1px solid rgba(255, 255, 255, .13);
    border-radius: 11px;
    box-shadow: 0 13px 35px rgba(24, 39, 27, .23);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition:
        opacity .18s ease,
        transform .18s ease,
        visibility .18s ease;
    pointer-events: none;
    font-size: 9px;
    line-height: 1.5;
}

.shop-preview-toast.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}


/* Responsive */

@media (max-width: 980px) {

    .power-shop-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

}

@media (max-width: 760px) {

    .power-shop-hero {
        grid-template-columns: 1fr;
        align-items: start;
        gap: 18px;
    }

    .golden-balance {
        width: 100%;
        max-width: 330px;
    }

    .power-shop-section-heading {
        display: block;
    }

    .power-shop-section-heading > p {
        margin-top: 8px;
    }

    .power-shop-info {
        grid-template-columns: 1fr;
    }

}

@media (max-width: 520px) {

    .power-shop {
        padding-top: 10px;
    }

    .power-shop-hero h1 {
        font-size: 41px;
    }

    .power-shop-grid {
        grid-template-columns: 1fr;
    }

    .power-card {
        min-height: 0;
    }

    .power-shop-coming {
        align-items: flex-start;
        flex-direction: column;
    }

    .power-shop-coming-items {
        flex-wrap: wrap;
    }

    .shop-preview-toast {
        right: 12px;
        bottom: 12px;
        max-width: calc(100vw - 24px);
    }

}

@media (prefers-reduced-motion: reduce) {

    .power-card-buy,
    .golden-balance-add,
    .shop-preview-toast {
        transition: none;
    }

}

/* =========================================================
   Golden Lemon packages / live shop state
   ========================================================= */

.golden-package-section {
    margin: 28px 0 34px;
    padding: 24px;
    background: linear-gradient(145deg, #fff8d8 0%, #f7eed0 100%);
    border: 1px solid #dfcf8b;
    border-radius: 20px;
}

.golden-package-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.golden-package-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: 18px;
    background: #fffdf4;
    border: 1px solid #e4d7a2;
    border-radius: 15px;
    box-shadow: 0 8px 22px rgba(93, 72, 12, .06);
}

.golden-package-card.is-featured {
    border-color: #caa431;
    box-shadow: 0 10px 28px rgba(160, 123, 13, .14);
}

.golden-package-featured {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 4px 7px;
    color: #fffbea;
    background: #8d6810;
    border-radius: 999px;
    font-size: 7px;
    font-weight: 800;
    letter-spacing: .8px;
}

.golden-package-icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    margin-bottom: 12px;
    background: #fff2af;
    border: 1px solid #e7cf65;
    border-radius: 50%;
    font-size: 24px;
}

.golden-package-card h3 {
    margin: 6px 0 8px;
    font-size: 19px;
}

.golden-package-amount {
    display: block;
    color: #8d6810;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 28px;
    line-height: 1;
}

.golden-package-amount span {
    display: block;
    margin-top: 5px;
    color: var(--muted);
    font-family: inherit;
    font-size: 9px;
    font-weight: 400;
}

.golden-package-card p {
    flex: 1;
    margin: 13px 0;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.55;
}

.golden-package-price {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 10px;
}

.golden-package-price strong {
    color: var(--ink);
    font-size: 15px;
}

.golden-package-price small {
    color: var(--muted);
    font-size: 7px;
}

.golden-package-buy {
    min-height: 42px;
    padding: 9px 11px;
    color: #8b805d;
    background: #ece7d6;
    border: 1px solid #d8d0b6;
    border-radius: 9px;
    font-size: 9px;
    font-weight: 700;
    cursor: not-allowed;
}

.golden-package-note {
    margin: 14px 0 0;
    color: #7b704d;
    font-size: 9px;
    line-height: 1.55;
}

.power-card-owned {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 5px;
    margin: 4px 0 -2px;
    color: var(--muted);
    font-size: 8px;
}

.power-card-owned strong {
    min-width: 22px;
    padding: 2px 6px;
    color: var(--green);
    background: #edf2e4;
    border-radius: 999px;
    text-align: center;
    font-size: 9px;
}

.power-card-buy:disabled {
    opacity: .46;
    cursor: not-allowed;
    filter: grayscale(.25);
}

.power-shop-notice.is-error {
    background: #f8ebe6;
    border-color: #dfc0b5;
}

.shop-preview-toast.is-error {
    background: #713c31;
}

@media (max-width: 900px) {
    .golden-package-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .golden-package-section {
        padding: 16px;
    }

    .golden-package-grid {
        grid-template-columns: 1fr;
    }
}


/* Permanent shop upgrades */
.permanent-upgrade-section { margin-bottom: 34px; }
.permanent-upgrade-grid { display: grid; grid-template-columns: minmax(0, 520px); gap: 14px; }
.permanent-upgrade-card { min-height: 0; }
.permanent-upgrade-card.is-owned { border-color: #8ca57c; background: #f3f6e9; }
.permanent-upgrade-card.is-owned::before { background: #789566; }
.permanent-upgrade-specs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 14px;
}
.permanent-upgrade-specs span {
    padding: 9px 10px;
    color: var(--muted);
    background: #f2f1e5;
    border: 1px solid var(--line);
    border-radius: 9px;
    font-size: 8px;
}
.permanent-upgrade-specs strong { display: block; margin-bottom: 2px; color: var(--ink); font-size: 13px; }
.permanent-upgrade-card.is-owned .power-card-buy { background: #8ca57c; }


/* PayPal Checkout */
.golden-package-card paypal-button {
    display: block;
    width: 100%;
    min-height: 45px;
    margin-top: 2px;
}

.golden-package-card paypal-button[hidden] {
    display: none !important;
}

.golden-package-card [data-paypal-unavailable][hidden],
.golden-package-card [data-paypal-setup-message][hidden] {
    display: none !important;
}
