/* ==========================================================================
   PersianShop Tools & Construction Hardware Demo Stylesheet
   Theme: PersianShop
   ========================================================================== */

:root {
    --ps-orange: #ff5e2b;
    --ps-orange-hover: #e04a1b;
    --ps-dark: #0f172a;
    --ps-slate: #1e293b;
    --ps-gray-border: #e2e8f0;
    --ps-text-muted: #64748b;
    --ps-radius: 12px;
}

/* 1. HERO MOSAIC */
.ps-tools-hero-mosaic {
    margin: 20px 0 35px;
    font-family: inherit;
}
.ps-thm-grid {
    display: grid;
    grid-template-columns: 1.15fr 1fr 1.15fr;
    gap: 18px;
}
.ps-thm-card {
    position: relative;
    border-radius: var(--ps-radius);
    overflow: hidden;
    background-size: cover;
    background-position: center;
    text-decoration: none !important;
    display: block;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.ps-thm-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.16);
}
.ps-thm-tall {
    min-height: 480px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.ps-thm-center-col {
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.ps-thm-half {
    min-height: 231px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}
.ps-thm-overlay {
    padding: 28px 24px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    height: 100%;
    box-sizing: border-box;
    text-align: right;
}
.ps-thm-info {
    margin-top: 14px;
}
.ps-thm-badge {
    align-self: flex-start;
    background: var(--ps-primary, var(--ps-orange));
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    padding: 5px 14px;
    border-radius: 20px;
    box-shadow: 0 4px 10px rgba(255, 94, 43, 0.35);
}
.ps-thm-badge.blue {
    background: #0284c7;
    box-shadow: 0 4px 10px rgba(2, 132, 199, 0.35);
}
.ps-thm-tag {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1px;
    margin-bottom: 6px;
    display: inline-block;
}
.ps-thm-tag.yellow { color: #facc15; }
.ps-thm-tag.orange { color: #ff5e2b; }

.ps-thm-title {
    color: #ffffff;
    font-size: 22px;
    font-weight: 800;
    margin: 0 0 4px 0;
    line-height: 1.35;
}
.ps-thm-title-sm {
    color: #ffffff;
    font-size: 17px;
    font-weight: 800;
    margin: 0 0 6px 0;
}
.ps-thm-sub {
    font-size: 19px;
    font-weight: 800;
    margin: 0 0 16px 0;
}
.ps-thm-sub.orange-glow { color: #ff7e40; }
.ps-thm-sub.blue-glow { color: #38bdf8; }
.ps-thm-desc {
    color: #cbd5e1;
    font-size: 12px;
    margin: 0 0 12px 0;
    line-height: 1.6;
}

.ps-thm-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--ps-primary, var(--ps-orange));
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    padding: 9px 18px;
    border-radius: 8px;
    transition: background 0.2s ease;
    align-self: flex-start;
}
.ps-thm-btn:hover { background: var(--ps-primary-hover, var(--ps-orange-hover)); }
.ps-thm-btn.blue { background: #0284c7; }
.ps-thm-btn.blue:hover { background: #0369a1; }

.ps-thm-btn-sm {
    display: inline-flex;
    align-items: center;
    font-size: 12px;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 6px;
}
.ps-thm-btn-sm.yellow { background: #eab308; color: #0f172a; }
.ps-thm-btn-sm.orange { background: #ff5e2b; color: #ffffff; }

/* 2. SERVICES BAR */
.ps-tools-services-bar {
    margin: 0 0 35px;
}
.ps-ts-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    background: #ffffff;
    border: 1px solid var(--ps-gray-border);
    border-radius: var(--ps-radius);
    padding: 20px 24px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}
.ps-ts-item {
    display: flex;
    align-items: center;
    gap: 14px;
}
.ps-ts-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    background: #fff7ed;
    color: var(--ps-primary, var(--ps-orange));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border: 1px solid #ffedd5;
}
.ps-ts-title {
    display: block;
    color: #0f172a;
    font-size: 13.5px;
    font-weight: 800;
    margin-bottom: 3px;
}
.ps-ts-desc {
    display: block;
    color: var(--ps-text-muted);
    font-size: 11.5px;
    line-height: 1.5;
}

/* 3. DEAL OF THE DAY */
.ps-tools-deal-box {
    background: #ffffff;
    border: 2px solid var(--ps-primary, var(--ps-orange));
    border-radius: var(--ps-radius);
    margin: 0 0 35px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(255, 94, 43, 0.08);
}
.ps-td-header {
    background: #0f172a;
    color: #ffffff;
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}
.ps-td-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}
.ps-td-flash-icon {
    font-size: 18px;
    color: #facc15;
    animation: wmPulse 1.2s infinite;
}
@keyframes wmPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.25); }
}
.ps-td-timer {
    display: flex;
    align-items: center;
    gap: 8px;
}
.ps-td-timer-label {
    font-size: 12px;
    color: #94a3b8;
}
.ps-td-timer-digits {
    display: flex;
    align-items: center;
    gap: 4px;
    direction: ltr;
}
.ps-td-digit {
    background: #1e293b;
    border: 1px solid #334155;
    color: #facc15;
    font-size: 14px;
    font-weight: 800;
    padding: 3px 8px;
    border-radius: 6px;
    min-width: 24px;
    text-align: center;
}
.ps-td-sep {
    color: #facc15;
    font-weight: 800;
}

.ps-td-body {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 30px;
    padding: 24px;
    align-items: center;
}
.ps-td-image-col {
    position: relative;
    text-align: center;
    background: #f8fafc;
    border-radius: 12px;
    padding: 20px;
    border: 1px solid #e2e8f0;
}
.ps-td-discount-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #ef4444;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    padding: 3px 10px;
    border-radius: 20px;
}
.ps-td-img {
    max-width: 100%;
    max-height: 240px;
    object-fit: contain;
    transition: transform 0.3s ease;
}
.ps-td-image-col:hover .ps-td-img {
    transform: scale(1.05);
}
.ps-td-brand {
    font-size: 12px;
    font-weight: 700;
    color: var(--ps-primary, var(--ps-orange));
    display: block;
    margin-bottom: 6px;
}
.ps-td-title {
    font-size: 18px;
    font-weight: 800;
    margin: 0 0 12px 0;
    line-height: 1.5;
}
.ps-td-title a {
    color: #0f172a;
    text-decoration: none;
    transition: color 0.2s;
}
.ps-td-title a:hover {
    color: var(--ps-primary, var(--ps-orange));
}

.ps-td-specs-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}
.ps-td-spec-pill {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    color: #334155;
    font-size: 11.5px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 6px;
}

.ps-td-stock-progress {
    margin-bottom: 20px;
}
.ps-td-sp-info {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    margin-bottom: 6px;
}
.ps-td-sp-sold {
    color: #334155;
}
.ps-td-sp-sold strong {
    color: var(--ps-primary, var(--ps-orange));
}
.ps-td-sp-left {
    color: #dc2626;
    font-weight: 700;
}
.ps-td-sp-bar-bg {
    width: 100%;
    height: 8px;
    background: #e2e8f0;
    border-radius: 6px;
    overflow: hidden;
}
.ps-td-sp-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff5e2b, #f97316);
    border-radius: 6px;
    transition: width 0.5s ease;
}

.ps-td-action-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    border-top: 1px solid #f1f5f9;
    padding-top: 16px;
}
.ps-td-price del {
    color: #94a3b8;
    font-size: 14px;
    margin-left: 8px;
}
.ps-td-price ins,
.ps-td-price > .amount {
    color: var(--ps-primary, var(--ps-orange));
    font-size: 22px;
    font-weight: 900;
    text-decoration: none;
}
.ps-td-add-cart-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--ps-primary, var(--ps-orange)) !important;
    color: #fff !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    padding: 10px 22px !important;
    border-radius: 8px !important;
    border: none !important;
    text-decoration: none !important;
    box-shadow: 0 4px 12px rgba(255, 94, 43, 0.3);
    transition: transform 0.2s, background 0.2s;
}
.ps-td-add-cart-btn:hover {
    background: var(--ps-primary-hover, var(--ps-orange-hover)) !important;
    transform: translateY(-2px);
}

/* 4. CATEGORIES SECTION */
.ps-tools-categories-section {
    margin: 0 0 40px;
}
.ps-tc-header {
    margin-bottom: 20px;
}
.ps-tc-title {
    font-size: 20px;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 4px 0;
}
.ps-tc-sub {
    font-size: 13px;
    color: var(--ps-text-muted);
    margin: 0;
}
.ps-tc-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
}
.ps-tc-item {
    background: #ffffff;
    border: 1px solid var(--ps-gray-border);
    border-radius: var(--ps-radius);
    padding: 18px 12px;
    text-align: center;
    text-decoration: none !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.25s ease;
}
.ps-tc-item:hover {
    border-color: var(--ps-primary, var(--ps-orange));
    transform: translateY(-4px);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
}
.ps-tc-icon-wrap {
    width: 64px;
    height: 64px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.ps-tc-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.ps-tc-name {
    color: #0f172a;
    font-size: 12.5px;
    font-weight: 700;
    margin-bottom: 4px;
    display: block;
}
.ps-tc-count {
    color: var(--ps-text-muted);
    font-size: 11px;
}

/* 5. PRODUCT TABS & GRID */
.ps-tools-tabs-section {
    margin: 0 0 40px;
}
.ps-tt-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    border-bottom: 2px solid #f1f5f9;
    padding-bottom: 14px;
    margin-bottom: 22px;
}
.ps-tt-title {
    font-size: 20px;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
}
.ps-tt-nav-chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.ps-tt-chip {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    color: #475569;
    font-size: 12.5px;
    font-weight: 700;
    padding: 6px 16px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.ps-tt-chip:hover,
.ps-tt-chip.is-active {
    background: var(--ps-primary, var(--ps-orange));
    color: #ffffff;
    border-color: var(--ps-primary, var(--ps-orange));
}

.ps-tt-product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.ps-tt-card {
    background: #ffffff;
    border: 1px solid var(--ps-gray-border);
    border-radius: var(--ps-radius);
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    transition: all 0.25s ease;
}
.ps-tt-card:hover {
    border-color: var(--ps-primary, var(--ps-orange));
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.07);
    transform: translateY(-4px);
}
.ps-tt-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.ps-tt-sale-tag {
    background: #ef4444;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 4px;
}
.ps-tt-stock-tag {
    font-size: 11px;
    color: #16a34a;
    font-weight: 600;
}
.ps-tt-card-img-wrap {
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
    background: #f8fafc;
    border-radius: 8px;
    padding: 10px;
}
.ps-tt-card-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.25s ease;
}
.ps-tt-card:hover .ps-tt-card-img {
    transform: scale(1.06);
}
.ps-tt-brand-name {
    font-size: 11px;
    color: var(--ps-primary, var(--ps-orange));
    font-weight: 700;
    display: block;
    margin-bottom: 4px;
}
.ps-tt-card-title {
    font-size: 13.5px;
    font-weight: 700;
    line-height: 1.5;
    margin: 0 0 8px 0;
    min-height: 40px;
}
.ps-tt-card-title a {
    color: #0f172a;
    text-decoration: none;
    transition: color 0.2s;
}
.ps-tt-card-title a:hover {
    color: var(--ps-primary, var(--ps-orange));
}

.ps-tt-rating-row {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
}
.ps-tt-stars {
    color: #eab308;
    font-size: 12px;
    letter-spacing: 2px;
}
.ps-tt-rating-val {
    color: #94a3b8;
    font-size: 11px;
}
.ps-tt-specs-preview {
    font-size: 11px;
    color: var(--ps-text-muted);
    margin: 0 0 12px 0;
    line-height: 1.5;
}

.ps-tt-bottom-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid #f1f5f9;
    padding-top: 12px;
    margin-top: auto;
}
.ps-tt-price-box del {
    color: #94a3b8;
    font-size: 12px;
    display: block;
}
.ps-tt-price-box ins,
.ps-tt-price-box > .amount {
    color: var(--ps-primary, var(--ps-orange));
    font-size: 16px;
    font-weight: 800;
    text-decoration: none;
}
.ps-tt-cart-btn {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    background: #0f172a !important;
    color: #ffffff !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: none !important;
    padding: 0 !important;
    transition: background 0.2s, transform 0.2s !important;
}
.ps-tt-cart-btn:hover {
    background: var(--ps-primary, var(--ps-orange)) !important;
    transform: scale(1.08);
}

/* 6. TECHNICAL BUYING GUIDE */
.ps-tools-guide-section {
    background: #0f172a;
    border-radius: var(--ps-radius);
    padding: 36px 32px;
    margin: 0 0 40px;
    color: #ffffff;
}
.ps-tg-header {
    text-align: center;
    max-width: 650px;
    margin: 0 auto 30px;
}
.ps-tg-pill {
    background: rgba(255, 94, 43, 0.15);
    border: 1px solid var(--ps-primary, var(--ps-orange));
    color: var(--ps-primary, var(--ps-orange));
    font-size: 11.5px;
    font-weight: 800;
    padding: 4px 14px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 8px;
}
.ps-tg-title {
    font-size: 22px;
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 8px 0;
}
.ps-tg-sub {
    font-size: 13px;
    color: #94a3b8;
    margin: 0;
}
.ps-tg-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.ps-tg-card {
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 10px;
    padding: 24px;
    transition: border-color 0.25s, transform 0.25s;
}
.ps-tg-card:hover {
    border-color: var(--ps-primary, var(--ps-orange));
    transform: translateY(-4px);
}
.ps-tg-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}
.ps-tg-icon {
    font-size: 28px;
}
.ps-tg-badge {
    background: rgba(255, 255, 255, 0.08);
    color: #cbd5e1;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 4px;
}
.ps-tg-card-title {
    font-size: 15px;
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 10px 0;
}
.ps-tg-card-desc {
    font-size: 12.5px;
    color: #94a3b8;
    line-height: 1.8;
    margin: 0;
    text-align: justify;
}

/* 7. BRANDS ROW */
.ps-tools-brands-section {
    margin: 0 0 45px;
    text-align: center;
}
.ps-tb-header {
    margin-bottom: 22px;
}
.ps-tb-title {
    font-size: 18px;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 4px 0;
}
.ps-tb-sub {
    font-size: 12.5px;
    color: var(--ps-text-muted);
}
.ps-tb-row {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
}
.ps-tb-item {
    background: #ffffff;
    border: 1px solid var(--ps-gray-border);
    border-radius: 10px;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 140px;
    height: 60px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
    transition: all 0.2s ease;
}
.ps-tb-item:hover {
    border-color: var(--ps-primary, var(--ps-orange));
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
}
.ps-tb-img {
    max-height: 38px;
    max-width: 110px;
    object-fit: contain;
}

/* RESPONSIVE BREAKPOINTS */
@media (max-width: 1024px) {
    .ps-thm-grid {
        grid-template-columns: 1fr;
    }
    .ps-thm-tall {
        min-height: 340px;
    }
    .ps-ts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .ps-td-body {
        grid-template-columns: 1fr;
    }
    .ps-tc-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .ps-tt-product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .ps-tg-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .ps-ts-grid {
        grid-template-columns: 1fr;
    }
    .ps-tc-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .ps-tt-product-grid {
        grid-template-columns: 1fr;
    }
    .ps-td-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .ps-td-action-row {
        flex-direction: column;
        align-items: stretch;
    }
    .ps-td-add-cart-btn {
        width: 100%;
        justify-content: center;
    }
}
