/* RentalAjay Store & Following */
.store-avatar {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    border-radius: 50%;
    background: #fff;
    object-fit: cover;
}

.store-avatar-fallback {
    color: #fff;
    font-weight: 900;
    border-color: transparent;
    background: linear-gradient(135deg, #2f62f5, #784df3);
}

.store-avatar-sm {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
    font-size: .78rem;
}

.store-avatar-lg {
    width: 76px;
    height: 76px;
    flex-basis: 76px;
    font-size: 1.5rem;
}

.store-avatar-xl {
    width: 96px;
    height: 96px;
    flex-basis: 96px;
    font-size: 2rem;
}

.store-mini {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    margin-top: 9px;
    color: #526079;
    text-decoration: none;
}

.store-mini:hover strong {
    color: #2f62f5;
}

.store-mini-copy {
    min-width: 0;
}

.store-mini-copy strong,
.store-mini-copy span {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.store-mini-copy strong {
    color: #24314b;
    font-size: .78rem;
}

.store-mini-copy span {
    margin-top: 1px;
    color: #8490a3;
    font-size: .68rem;
}

.market-product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.market-card {
    display: flex;
    min-width: 0;
    height: 100%;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #e4e9f2;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 4px 16px rgba(30, 49, 85, .06);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.market-card:hover {
    transform: translateY(-3px);
    border-color: #bdcaf2;
    box-shadow: 0 14px 32px rgba(30, 49, 85, .13);
}

.market-card-image-link {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    background: #f7f8fb;
}

.market-card-image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    padding: 10px;
    transition: transform .2s ease;
}

.market-card:hover .market-card-image {
    transform: scale(1.035);
}

.market-stock {
    position: absolute;
    top: 9px;
    right: 9px;
    z-index: 1;
    padding: 5px 8px;
    color: #2052dc;
    font-size: .7rem;
    font-weight: 900;
    border: 1px solid rgba(47, 98, 245, .15);
    border-radius: 999px;
    background: rgba(239, 243, 255, .94);
}

.market-card-body {
    display: flex;
    flex: 1;
    min-width: 0;
    flex-direction: column;
    padding: 13px 14px 14px;
}

.market-card-category {
    overflow: hidden;
    color: #8490a3;
    font-size: .7rem;
    font-weight: 800;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

.market-card-title {
    display: -webkit-box;
    min-height: 42px;
    margin: 6px 0 0;
    overflow: hidden;
    color: #18243a;
    font-size: .96rem;
    font-weight: 850;
    line-height: 1.38;
    text-decoration: none;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.market-card-title:hover {
    color: #2f62f5;
}

.market-card-price {
    margin-top: auto;
    padding-top: 12px;
    color: #e54a2f;
    font-size: 1.02rem;
    font-weight: 900;
}

.market-card-price small {
    color: #8490a3;
    font-size: .68rem;
    font-weight: 600;
}

.store-hero {
    position: relative;
    overflow: hidden;
    margin-bottom: 24px;
    color: #fff;
    border-radius: 24px;
    background:
        radial-gradient(circle at 88% 20%, rgba(255,255,255,.20), transparent 30%),
        linear-gradient(135deg, #172552, #2f62f5 70%, #7048ef);
    box-shadow: 0 18px 48px rgba(23, 37, 82, .22);
}

.store-hero-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 30px;
}

.store-identity {
    display: flex;
    align-items: center;
    gap: 18px;
    min-width: 0;
}

.store-identity h1 {
    margin: 0 0 6px;
    color: #fff;
    font-size: clamp(1.65rem, 4vw, 2.55rem);
}

.store-identity p {
    max-width: 720px;
    margin: 0;
    color: #dce4ff;
    line-height: 1.6;
}

.store-hero-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.store-follow-button {
    min-width: 126px;
    border-color: #fff;
    background: #fff;
    color: #2452d4;
}

.store-follow-button.is-following {
    border-color: rgba(255,255,255,.35);
    background: rgba(255,255,255,.12);
    color: #fff;
}

.store-stats {
    display: flex;
    gap: 22px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.store-stats span {
    color: #dce4ff;
    font-size: .82rem;
}

.store-stats strong {
    display: block;
    color: #fff;
    font-size: 1.15rem;
}

.store-filter {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(180px, .38fr) auto;
    gap: 12px;
    margin-bottom: 22px;
    padding: 18px;
}

.store-profile-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: center;
    padding: 20px;
}

.store-profile-main {
    display: flex;
    align-items: center;
    gap: 15px;
    min-width: 0;
}

.store-profile-main h3 {
    margin: 0 0 4px;
}

.store-profile-main p {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: #6f7b90;
    line-height: 1.5;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.following-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.following-card {
    display: flex;
    height: 100%;
    flex-direction: column;
    padding: 20px;
}

.following-card-head {
    display: flex;
    align-items: center;
    gap: 13px;
}

.following-card h3 {
    margin: 0 0 3px;
}

.following-card-description {
    display: -webkit-box;
    min-height: 48px;
    margin: 14px 0;
    overflow: hidden;
    color: #6f7b90;
    line-height: 1.55;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.following-card-stats {
    display: flex;
    gap: 16px;
    margin-top: auto;
    padding: 12px 0;
    border-top: 1px solid #edf0f5;
}

.following-card-stats span {
    color: #7a8699;
    font-size: .75rem;
}

.following-card-stats strong {
    color: #26334d;
}

.following-actions {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 9px;
}

.store-seller-panel {
    margin: 24px 0;
    padding: 20px;
}

.store-seller-panel-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: center;
}

.store-seller-info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.store-seller-info h2 {
    margin: 0 0 4px;
    font-size: 1.18rem;
}

.store-seller-info p {
    margin: 0;
    color: #6f7b90;
}

.store-seller-actions {
    display: flex;
    gap: 9px;
    flex-wrap: wrap;
}

.store-admin-grid {
    display: grid;
    grid-template-columns: minmax(260px, .62fr) minmax(0, 1.38fr);
    gap: 20px;
    align-items: start;
}

.store-admin-preview {
    position: sticky;
    top: 92px;
}

.store-section-kicker {
    display: inline-flex;
    padding: 6px 10px;
    color: #2f62f5;
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
    border-radius: 999px;
    background: #edf2ff;
}

.store-preview-identity {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 18px 0;
}

.store-preview-identity h3 {
    margin: 0 0 5px;
}

.store-preview-identity p {
    margin: 0;
    line-height: 1.5;
}

.store-metric-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin: 18px 0;
}

.store-metric-row > div {
    padding: 14px;
    text-align: center;
    border: 1px solid #e7ebf2;
    border-radius: 13px;
    background: #f8faff;
}

.store-metric-row strong,
.store-metric-row span {
    display: block;
}

.store-metric-row strong {
    color: #1c2942;
    font-size: 1.35rem;
}

.store-metric-row span {
    margin-top: 2px;
    color: #7b879b;
    font-size: .76rem;
}

.store-remove-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: -4px 0 18px;
    color: #b42318;
    font-size: .86rem;
}

.nav-follow-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 21px;
    height: 21px;
    padding: 0 6px;
    margin-left: 3px;
    color: #fff;
    font-size: .67rem;
    font-weight: 900;
    border-radius: 999px;
    background: #2f62f5;
}

@media (max-width: 1024px) {
    .market-product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

    .store-admin-grid {
        grid-template-columns: 1fr;
    }

    .store-admin-preview {
        position: static;
    }
}

@media (max-width: 720px) {
    .market-product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 9px;
    }

    .market-card {
        border-radius: 11px;
    }

    .market-card-body {
        padding: 10px;
    }

    .market-card-title {
        min-height: 38px;
        font-size: .82rem;
        line-height: 1.36;
    }

    .market-card-price {
        font-size: .9rem;
    }

    .store-mini {
        gap: 6px;
    }

    .store-mini-copy strong {
        font-size: .69rem;
    }

    .store-mini-copy span {
        display: none;
    }

    .store-avatar-sm {
        width: 27px;
        height: 27px;
        flex-basis: 27px;
        font-size: .66rem;
    }

    .store-hero-inner,
    .store-profile-card,
    .store-seller-panel-grid {
        grid-template-columns: 1fr;
        flex-direction: column;
        align-items: stretch;
    }

    .store-hero-inner {
        display: flex;
        padding: 22px;
    }

    .store-identity {
        align-items: flex-start;
    }

    .store-avatar-lg {
        width: 62px;
        height: 62px;
        flex-basis: 62px;
    }

    .store-hero-actions,
    .store-seller-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        width: 100%;
    }

    .store-filter {
        grid-template-columns: 1fr;
    }

    .following-grid {
        grid-template-columns: 1fr;
    }

    .store-profile-card {
        display: grid;
    }

    .store-seller-panel-grid {
        display: grid;
    }
}

@media (max-width: 380px) {
    .market-product-grid {
        gap: 7px;
    }

    .market-card-body {
        padding: 8px;
    }

    .market-card-title {
        font-size: .76rem;
    }

    .market-card-category,
    .market-stock {
        font-size: .62rem;
    }
}

.admin-profile-avatar[src] {
    object-fit: cover;
}
