/* Double Tap Shopping — player vending machine stock.
   Layered on styles.css; the accent here is pink, the one colour the rest of
   the site does not already use. */

.shop-main {
    padding: 40px 20px 60px;
}

.shop-back {
    display: inline-block;
    margin-bottom: 25px;
    color: #ff5ec4;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 1px;
    transition: color 0.2s ease;
}

.shop-back:hover {
    color: #ff9adb;
}

.shop-panel {
    background: linear-gradient(135deg, rgba(38, 16, 32, 0.85) 0%, rgba(15, 15, 30, 0.85) 100%);
    border: 2px solid rgba(255, 94, 196, 0.25);
    border-radius: 20px;
    padding: 35px;
    margin-bottom: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
}

.shop-panel h2 {
    color: #ff5ec4;
    font-size: 1.8rem;
    margin-bottom: 12px;
    letter-spacing: 1px;
}

.shop-help {
    color: #c0a8ba;
    margin-bottom: 20px;
}

.shop-cmd {
    background: rgba(255, 94, 196, 0.15);
    border: 1px solid rgba(255, 94, 196, 0.4);
    border-radius: 6px;
    padding: 2px 8px;
    color: #ff9adb;
    font-weight: 700;
}

/* Search */
.shop-search {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.shop-search-input {
    flex: 1 1 280px;
    min-width: 0;
    font-size: 1.2rem;
    font-weight: 600;
    padding: 14px 18px;
    background: rgba(10, 10, 20, 0.8);
    border: 2px solid rgba(255, 94, 196, 0.4);
    border-radius: 12px;
    color: #fff;
    font-family: inherit;
}

.shop-search-input::placeholder {
    color: #7a6a76;
}

.shop-search-input:focus {
    outline: none;
    border-color: #ff5ec4;
    box-shadow: 0 0 20px rgba(255, 94, 196, 0.4);
}

.shop-clear {
    background: linear-gradient(135deg, #ff5ec4 0%, #c72e8f 100%);
    color: #fff;
    border: 2px solid #ff5ec4;
    border-radius: 12px;
    padding: 14px 28px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.25s ease;
}

.shop-clear:hover {
    background: linear-gradient(135deg, #ff85d3 0%, #ff5ec4 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(255, 94, 196, 0.5);
}

.shop-clear:focus-visible,
.shop-search-input:focus-visible,
.shop-coords:focus-visible {
    outline: 2px solid #ff5ec4;
    outline-offset: 3px;
}

.shop-stats {
    margin-top: 18px;
    color: #a898a4;
    font-weight: 600;
    letter-spacing: 1px;
    min-height: 1.3em;
}

.shop-stats strong {
    color: #ff9adb;
}

/* One item for sale. Icon, what it is, what it costs, who has it and where. */
.shop-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.shop-letter {
    margin: 26px 0 6px;
    padding-bottom: 8px;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 6px;
    color: #ff5ec4;
    border-bottom: 2px solid rgba(255, 94, 196, 0.2);
}

.shop-list > .shop-letter:first-child {
    margin-top: 0;
}

.shop-row {
    display: grid;
    grid-template-columns: 60px minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 8px 22px;
    padding: 12px 20px;
    background: linear-gradient(135deg, rgba(30, 15, 26, 0.75) 0%, rgba(15, 15, 30, 0.75) 100%);
    border: 2px solid rgba(255, 94, 196, 0.14);
    border-radius: 14px;
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.shop-row:hover {
    border-color: rgba(255, 94, 196, 0.55);
    transform: translateX(4px);
}

.shop-row-icon {
    position: relative;
    width: 60px;
    height: 60px;
}

.shop-row-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.shop-row-count {
    position: absolute;
    right: -6px;
    bottom: -2px;
    background: rgba(8, 8, 14, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 1px 6px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #fff;
}

.shop-row-about {
    min-width: 0;
}

.shop-row-name {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 1.15rem;
    font-weight: 700;
    color: #ede4ea;
    line-height: 1.3;
}

.shop-row-mods {
    margin-top: 2px;
    font-size: 0.8rem;
    color: #8d7f89;
}

.shop-row-price {
    text-align: right;
    min-width: 110px;
}

.shop-row-coins {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 7px;
    font-size: 1.2rem;
    font-weight: 700;
    color: #ffd24a;
    letter-spacing: 1px;
}

.shop-row-coins img {
    width: 20px;
    height: 20px;
}

.shop-row-each {
    font-size: 0.78rem;
    font-weight: 600;
    color: #8d7f89;
    letter-spacing: 0;
}

.shop-row-noprice {
    color: #8d7f89;
    font-style: italic;
}

.shop-row-seller {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
    min-width: 170px;
}

.shop-row-owner {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    color: #fff;
}

.shop-coords {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 94, 196, 0.12);
    border: 2px solid rgba(255, 94, 196, 0.35);
    border-radius: 20px;
    padding: 4px 14px;
    color: #ff9adb;
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
}

.shop-coords:hover {
    background: rgba(255, 94, 196, 0.25);
    border-color: #ff5ec4;
    color: #fff;
}

.shop-coords.copied {
    border-color: #00ff88;
    color: #00ff88;
}

/* Quality tiers, coloured the way the game colours them (qualityinfo.xml).
   Q5 and Q6 are lifted off the game's near-black blue and purple so they stay
   readable on this background. */
.shop-quality {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 10px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    border: 1px solid currentColor;
}

.shop-quality.q1 { color: #9C8867; }
.shop-quality.q2 { color: #CF7F29; }
.shop-quality.q3 { color: #A2A41B; }
.shop-quality.q4 { color: #42C234; }
.shop-quality.q5 { color: #6E8FE8; }
.shop-quality.q6 { color: #C462E8; }

.shop-empty {
    color: #8d7f89;
    font-style: italic;
}

.shop-freshness {
    margin-top: 35px;
    padding-top: 22px;
    border-top: 2px solid rgba(255, 94, 196, 0.18);
    color: #8d7f89;
    font-size: 0.95rem;
    letter-spacing: 1px;
    text-align: center;
}

.shop-freshness strong {
    color: #c0a8ba;
    font-weight: 700;
}

.shop-loading,
.shop-error {
    color: #a898a4;
    font-weight: 600;
    letter-spacing: 1px;
    padding: 20px 0;
}

.shop-error {
    color: #ff6b6b;
}

/* Narrow screens: the icon keeps its column and everything else stacks under
   the item name, so a row still reads top to bottom without sideways scroll. */
@media (max-width: 720px) {
    .shop-panel {
        padding: 25px 20px;
    }

    .shop-row {
        grid-template-columns: 52px minmax(0, 1fr);
        gap: 6px 16px;
        padding: 14px 16px;
    }

    .shop-row-icon {
        width: 52px;
        height: 52px;
        grid-row: span 2;
    }

    .shop-row-price,
    .shop-row-seller {
        grid-column: 2;
        align-items: flex-start;
        text-align: left;
        min-width: 0;
    }

    .shop-row-coins {
        justify-content: flex-start;
    }

    .shop-row-seller {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 10px;
    }
}
