/* Source: screens-grocery-store.css — Grocery Store interaction screen */

/* ── GROCERY STORE INTERACTION SCREEN ─────────────────────── */
.groceryStoreInteractionContainer {
    width: 90%;
    height: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
    background-size: cover;
    background-position: center;
    border-radius: 12px;
    padding: 2rem;
    overflow-y: auto;
}

.groceryStoreInteractionContainer h2 {
    text-align: center;
    color: #e67e22;
    font-size: 2rem;
    text-shadow: 2px 2px 4px rgb(0 0 0 / 80%);
}

/* Needs panel */
.groceryNeedsPanel {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem 1.5rem;
    background: rgb(0 0 0 / 55%);
    border-radius: 10px;
    border: 1px solid rgb(255 255 255 / 10%);
    width: 100%;
    max-width: 700px;
    flex-wrap: wrap;
    justify-content: center;
}

.groceryNeedsChar {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.5rem 1rem 0.5rem 0.5rem;
    border-right: 1px solid rgb(255 255 255 / 10%);
    flex-shrink: 0;
}

.groceryNeedsCharImg {
    width: 80px;
    height: 80px;
    object-fit: contain;
    border-radius: 8px;
    background: rgb(255 255 255 / 5%);
}

.groceryNeedsCharInfo {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.groceryNeedsCharName {
    font-size: 1.05rem;
    font-weight: bold;
    color: #e67e22;
}

.groceryNeedsCharLevel {
    font-size: 0.85rem;
    color: #aaa;
}

.groceryNeedsCharMood {
    font-size: 0.85rem;
    color: var(--primary-color);
}

.groceryNeedsBars {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    flex: 1;
    min-width: 200px;
}

.groceryNeedBarRow {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.groceryNeedBarIcon {
    font-size: 0.9rem;
    width: 1.3rem;
    text-align: center;
    flex-shrink: 0;
}

.groceryNeedBarLabel {
    font-size: 0.75rem;
    color: #ccc;
    min-width: 3.2rem;
    flex-shrink: 0;
    font-weight: bold;
}

.groceryNeedBarTrack {
    flex: 1;
    height: 10px;
    background: rgb(255 255 255 / 10%);
    border-radius: 5px;
    overflow: hidden;
    min-width: 0;
}

.groceryNeedBar {
    height: 100%;
    border-radius: 5px;
    transition: width 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
}

.groceryNeedBarHunger {
    background: linear-gradient(90deg, #ff6b6b, #ff8787);
}

.groceryNeedBarEnergy {
    background: linear-gradient(90deg, #60a5fa, #3b82f6);
}

.groceryNeedBar.low {
    box-shadow: 0 0 8px rgb(255 0 0 / 50%);
    animation: groceryNeedBarLowPulse 1s ease-in-out infinite;
}

@keyframes groceryNeedBarLowPulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.6;
    }
}

.groceryNeedBarValue {
    font-size: 0.8rem;
    color: #fff;
    min-width: 1.8rem;
    text-align: right;
    font-weight: bold;
    flex-shrink: 0;
}

/* Grocery items area */
.groceryItemsArea {
    width: 100%;
    max-width: 700px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.groceryItemsArea h3 {
    font-size: 1.1rem;
    color: #ccc;
    margin: 0;
    letter-spacing: 1px;
}

/* No-fridge warning */
.groceryNoFridge {
    background: rgb(0 0 0 / 65%);
    border: 2px dashed #e67e22;
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    max-width: 450px;
    width: 100%;
}

.groceryNoFridgeIcon {
    font-size: 3.5rem;
    line-height: 1;
    animation: groceryFridgePulse 2.5s ease-in-out infinite;
}

@keyframes groceryFridgePulse {
    0%,
    100% {
        transform: scale(1) rotate(0deg);
    }
    25% {
        transform: scale(1.08) rotate(-3deg);
    }
    75% {
        transform: scale(1.08) rotate(3deg);
    }
}

.groceryNoFridgeText {
    font-size: 1.1rem;
    color: #fff;
    font-weight: bold;
}

.groceryNoFridgeHint {
    font-size: 0.85rem;
    color: #aaa;
}

/* Items grid (shown when fridge owned) */
.groceryItemsGrid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 0.9rem;
    width: 100%;
}

.groceryItemCard {
    background: rgb(0 0 0 / 60%);
    border: 2px solid rgb(255 255 255 / 12%);
    border-radius: 10px;
    padding: 1rem 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    position: relative;
    overflow: hidden;
}

.groceryItemCard:hover:not(.owned) {
    border-color: #e67e22;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgb(230 126 34 / 30%);
    background: rgb(0 0 0 / 78%);
}

.groceryItemCard.owned {
    opacity: 0.5;
    cursor: default;
    border-color: var(--success-color);
}

.groceryItemImg {
    width: 80px;
    height: 80px;
    object-fit: contain;
    border-radius: 6px;
    background: rgb(255 255 255 / 5%);
    transition: transform 0.3s ease;
}

.groceryItemCard:hover:not(.owned) .groceryItemImg {
    transform: scale(1.08);
}

.groceryItemName {
    font-size: 0.9rem;
    font-weight: bold;
    color: #fff;
}

.groceryItemDesc {
    font-size: 0.72rem;
    color: #aaa;
    line-height: 1.3;
}

.groceryItemPrice {
    font-size: 0.95rem;
    font-weight: bold;
    color: var(--success-color);
}

.groceryItemOwned {
    display: none;
    font-size: 0.8rem;
    color: var(--success-color);
    font-weight: bold;
}

.groceryItemCard.owned .groceryItemOwned {
    display: block;
}

.groceryItemCard.owned .groceryItemPrice {
    display: none;
}

/* Buy button on item cards */
.groceryItemBuyBtn {
    background: linear-gradient(135deg, var(--success-color), #3dbb50);
    color: white;
    border: none;
    padding: 0.4rem 1.2rem;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.15s ease;
    margin-top: 0.2rem;
    box-shadow:
        0 2px 6px rgb(0 0 0 / 25%),
        inset 0 1px 0 rgb(255 255 255 / 15%);
}

.groceryItemBuyBtn:hover:not(:disabled) {
    background: linear-gradient(135deg, #40c057, #2f9e44);
    transform: translateY(-1px);
    box-shadow:
        0 4px 12px rgb(81 207 102 / 40%),
        inset 0 1px 0 rgb(255 255 255 / 20%);
}

.groceryItemBuyBtn:active:not(:disabled) {
    transform: translateY(1px) scale(0.97);
    transition: all 0.05s ease;
}

.groceryItemBuyBtn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Quantity display on owned items */
.groceryItemQty {
    font-size: 0.8rem;
    color: var(--success-color);
    font-weight: bold;
}

.groceryItemCard.owned .groceryItemQty {
    display: block;
}

/* ── COOKING OVERLAY ─────────────────────────────────────── */
#cookingOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgb(0 0 0 / 80%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: cookingOverlayFadeIn 0.2s ease-out;
}

@keyframes cookingOverlayFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.cookingOverlayContainer,
.cookingResultContainer {
    background: #1a1a2e;
    border: 2px solid #e67e22;
    border-radius: 16px;
    padding: 2.5rem 3rem;
    text-align: center;
    max-width: 420px;
    width: 90%;
    box-shadow: 0 8px 32px rgb(0 0 0 / 50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.cookingOverlayHeader {
    font-size: 1.3rem;
    font-weight: bold;
    color: #e67e22;
    letter-spacing: 1px;
}

.cookingStepDisplay {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.cookingStepEmoji {
    font-size: 3rem;
    line-height: 1;
    animation: cookingEmojiBounce 0.6s ease-in-out infinite alternate;
}

@keyframes cookingEmojiBounce {
    from {
        transform: translateY(0) scale(1);
    }
    to {
        transform: translateY(-6px) scale(1.1);
    }
}

.cookingStepText {
    font-size: 1rem;
    color: #ccc;
    font-weight: bold;
}

.cookingProgressTrack {
    width: 100%;
    height: 12px;
    background: rgb(255 255 255 / 10%);
    border-radius: 6px;
    overflow: hidden;
}

.cookingProgressBar {
    height: 100%;
    width: 0%;
    border-radius: 6px;
    background: linear-gradient(90deg, #e67e22, #f39c12);
    transition: width 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 0 0 12px rgb(230 126 34 / 40%);
}

/* Result stage */
.cookingResultEmoji {
    font-size: 4rem;
    line-height: 1;
    animation: cookingResultPop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes cookingResultPop {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    60% {
        transform: scale(1.3);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.cookingResultName {
    font-size: 1.4rem;
    font-weight: bold;
    color: #fff;
}

.cookingResultDesc {
    font-size: 0.95rem;
    color: #aaa;
    line-height: 1.4;
}

.cookingResultActions {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.cookingActionBtn {
    padding: 0.8rem 1.8rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.15s ease;
    border: none;
    box-shadow:
        0 2px 8px rgb(0 0 0 / 25%),
        inset 0 1px 0 rgb(255 255 255 / 15%);
}

.cookingEatBtn {
    background: linear-gradient(135deg, var(--success-color), #3dbb50);
    color: white;
}

.cookingEatBtn:hover {
    background: linear-gradient(135deg, #40c057, #2f9e44);
    transform: translateY(-2px);
    box-shadow:
        0 6px 20px rgb(81 207 102 / 40%),
        inset 0 1px 0 rgb(255 255 255 / 20%);
}

.cookingSellBtn {
    background: linear-gradient(135deg, #f39c12, #d68910);
    color: white;
}

.cookingSellBtn:hover {
    background: linear-gradient(135deg, #f1c40f, #e67e22);
    transform: translateY(-2px);
    box-shadow:
        0 6px 20px rgb(243 156 18 / 40%),
        inset 0 1px 0 rgb(255 255 255 / 20%);
}

.cookingActionBtn:active {
    transform: translateY(1px) scale(0.97);
    transition: all 0.05s ease;
}

.cookingOverlayContainer.cooking-finished {
    display: none;
}

#cookingOverlay.cooking-finished .cookingOverlayContainer {
    display: none;
}

#cookingOverlay.cooking-finished .cookingResultContainer {
    display: flex;
}

/* ── HOME COOKING SKILL DISPLAY ──────────────────────────── */
.homeCookingSkillDisplay {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.8rem 1rem;
    background: rgb(0 0 0 / 45%);
    border-radius: 8px;
    border: 1px solid rgb(230 126 34 / 30%);
    width: 100%;
    max-width: 650px;
}

.homeCookingSkillIcon {
    font-size: 2rem;
    line-height: 1;
    flex-shrink: 0;
}

.homeCookingSkillInfo {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    min-width: 0;
}

.homeCookingSkillLevel {
    font-size: 0.85rem;
    font-weight: bold;
    color: #e67e22;
}

.homeCookingSkillBarTrack {
    height: 6px;
    background: rgb(255 255 255 / 10%);
    border-radius: 3px;
    overflow: hidden;
}

.homeCookingSkillBar {
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(90deg, #e67e22, #f39c12);
    transition: width 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.homeCookingSkillXP {
    font-size: 0.72rem;
    color: #aaa;
}

/* ── HOME COOK CARD ──────────────────────────────────────── */
.homeRestCard#homeRestCook {
    border-color: #e67e22;
}

.homeRestCard#homeRestCook:hover:not(.disabled) {
    border-color: #f39c12;
    box-shadow: 0 4px 14px rgb(243 156 18 / 25%);
}

.homeRestCard#homeRestCook.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: rgb(255 255 255 / 6%);
}

/* Sell price preview on cook card */
.homeCookPrice {
    font-size: 0.75rem;
    font-weight: bold;
    color: #f39c12;
    margin-top: 0.2rem;
}

.homeRestCard#homeRestCook.disabled .homeCookPrice {
    display: none;
}

/* Bottom bar */
.groceryBottom {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-top: 0.5rem;
}

.groceryBottom .moneyDisplay {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--success-color);
}

.groceryLeaveBtn {
    background: linear-gradient(135deg, rgb(255 255 255 / 12%), rgb(255 255 255 / 6%));
    color: #ccc;
    border: 1px solid rgb(255 255 255 / 20%);
    padding: 0.9rem 2rem;
    border-radius: 8px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.15s ease;
    box-shadow:
        0 1px 4px rgb(0 0 0 / 15%),
        inset 0 1px 0 rgb(255 255 255 / 8%);
}

.groceryLeaveBtn:hover {
    background: linear-gradient(135deg, rgb(230 126 34 / 30%), rgb(230 126 34 / 15%));
    color: #fff;
    border-color: #e67e22;
    transform: translateY(-1px);
}
