/* Installment products listing */

.inst-page {
    --inst-bg: #f3f6fb;
    --inst-card: #ffffff;
    --inst-text: #0f172a;
    --inst-muted: #64748b;
    --inst-line: rgba(148, 163, 184, 0.32);
    direction: rtl;
    text-align: right;
    font-family: iransans, yekan, Tahoma, sans-serif;
    color: var(--inst-text);
    padding: 16px 0 40px;
    background-color: var(--inst-bg);
    background-image: linear-gradient(
        180deg,
        #e7eef9 0%,
        #eef3fa 120px,
        #f3f6fb 260px,
        #f3f6fb 100%
    );
}

.inst-page a { text-decoration: none !important; }

.inst-crumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    font-size: 13px;
    color: var(--inst-muted);
}

.inst-crumb a {
    color: #4338ca !important;
    font-weight: 600;
}

.inst-crumb-sep { opacity: 0.4; }

.inst-crumb-current {
    margin: 0;
    display: inline;
    font-family: yekan, iransans;
    font-size: 15px;
    font-weight: 700;
    color: var(--inst-text);
}

.inst-hero {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
    padding: 20px 22px;
    border-radius: 20px;
    border: 1px solid var(--inst-line);
    background:
        radial-gradient(ellipse 60% 80% at 0% 0%, rgba(59, 130, 246, 0.12), transparent 55%),
        radial-gradient(ellipse 50% 70% at 100% 100%, rgba(16, 185, 129, 0.1), transparent 50%),
        var(--inst-card);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.05);
}

.inst-hero-main {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.inst-hero-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    flex: 0 0 auto;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.18), rgba(59, 130, 246, 0.14));
    color: #059669;
    font-size: 18px;
}

.inst-hero-kicker {
    margin: 0 0 4px;
    font-size: 12px;
    color: var(--inst-muted);
}

.inst-hero-title {
    margin: 0;
    font-family: yekan, iransans;
    font-size: clamp(18px, 3vw, 22px);
    font-weight: 700;
}

.inst-count {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    background: #ecfdf5;
    color: #047857;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

.inst-notes {
    display: grid;
    gap: 10px;
    margin-bottom: 16px;
}

.inst-note {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    padding: 14px 16px;
    border-radius: 16px;
    background: var(--inst-card);
    border: 1px solid var(--inst-line);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
    font-size: 13px;
    line-height: 1.9;
    color: #334155;
}

.inst-note i {
    color: #3b82f6;
}

.inst-note strong {
    color: #0f172a;
}

.inst-note-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 999px;
    background: #fef9c3;
    color: #854d0e !important;
    font-weight: 700;
    border: 1px solid #fde047;
}

.inst-note-link:hover {
    background: #fef08a;
}

.inst-empty {
    padding: 48px 24px;
    text-align: center;
    border-radius: 20px;
    background: var(--inst-card);
    border: 1px solid var(--inst-line);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.05);
}

.inst-empty-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    margin-bottom: 14px;
    border-radius: 20px;
    background: #ecfdf5;
    color: #059669;
    font-size: 28px;
}

.inst-empty-title {
    margin: 0 0 8px;
    font-family: yekan, iransans;
    font-size: 20px;
    font-weight: 700;
}

.inst-empty-desc {
    margin: 0 auto;
    max-width: 380px;
    font-size: 14px;
    line-height: 1.9;
    color: var(--inst-muted);
}

.inst-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.inst-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 12px;
    border-radius: 18px;
    background: var(--inst-card);
    border: 1px solid var(--inst-line);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.04);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
    overflow: hidden;
}

.inst-card:hover {
    transform: translateY(-3px);
    border-color: rgba(16, 185, 129, 0.35);
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.1);
}

.inst-card-link {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    color: inherit !important;
    min-height: 0;
}

.inst-badges {
    position: absolute;
    top: 12px;
    right: 12px;
    left: 12px;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 6px;
    pointer-events: none;
}

.inst-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
}

.inst-badge-special {
    background: #0f172a;
    color: #fff;
}

.inst-badge-service {
    background: #3b82f6;
    color: #fff;
}

.inst-thumb {
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1;
    margin-bottom: 12px;
    border-radius: 14px;
    background: #fff;
    overflow: hidden;
}

.inst-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform .25s ease;
}

.inst-card:hover .inst-thumb img {
    transform: scale(1.04);
}

.inst-card-title {
    margin: 0 0 10px;
    min-height: 2.8em;
    max-height: 2.8em;
    overflow: hidden;
    font-size: 13px;
    line-height: 1.7;
    color: #334155;
}

.inst-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin-bottom: 10px;
    color: #94a3b8;
    font-size: 12px;
}

.inst-card-meta span {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.inst-card-meta .is-inst {
    color: #059669;
    font-weight: 700;
}

.inst-card-price {
    margin-top: auto;
    padding-top: 8px;
    border-top: 1px solid #f1f5f9;
    text-align: center;
}

.inst-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--inst-text);
}

.inst-price small {
    margin-right: 4px;
    font-size: 12px;
    font-weight: 600;
    color: var(--inst-muted);
}

.inst-old-price {
    margin-bottom: 2px;
    font-size: 12px;
    color: #94a3b8;
    text-decoration: line-through;
}

.inst-unavailable {
    color: #94a3b8;
    font-size: 13px;
    font-weight: 600;
}

.inst-call {
    color: #3b82f6;
    font-size: 13px;
    font-weight: 700;
}

.inst-page .pt-pager {
    margin-top: 16px;
    margin-bottom: 0;
}

@media screen and (max-width: 1100px) {
    .inst-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media screen and (max-width: 800px) {
    .inst-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media screen and (max-width: 480px) {
    .inst-hero { padding: 16px; }
    .inst-grid { gap: 10px; }
    .inst-card { padding: 10px; border-radius: 14px; }
    .inst-price { font-size: 17px; }
}
