:root {
    --surface-color: #ffffff;
    --on-surface-high-emphasis: rgba(0, 0, 0, 0.87);
    --on-surface-medium-emphasis: rgba(0, 0, 0, 0.60);
    --primary-color: #46ad56;
}

/* Remove underlines from all links */
a, 
a:hover, 
a:focus, 
a:active {
    text-decoration: none !important;
}

.modern-product-card {
    text-decoration: none !important;
}

.product-title a,
.product-info a,
.modern-product-card a {
    text-decoration: none !important;
}

/* استایل عمومی برای کادر محصول */
.custom-product-box {
    display: flex;
    flex-wrap: wrap;
    background: #ffffff;
    border: none;
    padding: 25px;
    border-radius: 16px;
    margin: 30px 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.custom-product-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.12);
}

.custom-product-box .product-image {
    flex: 1;
    max-width: 45%;
    position: relative;
    overflow: hidden;
}

.custom-product-box .product-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    transition: transform 0.3s ease;
}

.custom-product-box .product-image img:hover {
    transform: scale(1.05);
}

.custom-product-box .product-details {
    flex: 1;
    padding-left: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.custom-product-box .product-details h2 {
    margin: 0 0 20px 0;
    font-size: 1.8em;
    color: #2c3e50;
    font-weight: 600;
    line-height: 1.3;
}

.custom-product-box .product-details ul {
    list-style-type: none;
    padding: 0;
    margin: 0 0 20px 0;
}

.custom-product-box .product-details ul li {
    margin-bottom: 12px;
    padding: 8px 15px;
    background: #f8f9fa;
    border-radius: 8px;
    font-size: 0.95em;
    color: #4a5568;
}

.custom-product-box .buy-now-button {
    display: inline-block;
    padding: 12px 30px;
    background-color: #46ad56;
    color: #fff;
    text-decoration: none;
    border-radius: 12px;
    font-size: 1.1em;
    font-weight: 500;
    transition: all 0.3s ease;
    text-align: center;
    max-width: 200px;
}

.custom-product-box .buy-now-button:hover {
    background-color: #3d9549;
    transform: translateY(-2px);
}

/* استایل برای موبایل */
@media (max-width: 767px) {
    .custom-product-box {
        padding: 15px;
        flex-direction: column;
    }

    .custom-product-box .product-image {
        max-width: 100%;
        margin-bottom: 20px;
    }

    .custom-product-box .product-details {
        padding-left: 0;
    }

    .custom-product-box .product-details h2 {
        font-size: 1.3em;
        margin-bottom: 15px;
    }

    .custom-product-box .product-details ul li {
        font-size: 0.9em;
        padding: 6px 12px;
    }

    .custom-product-box .buy-now-button {
        width: 100%;
        max-width: none;
        padding: 10px 20px;
        font-size: 1em;
    }
}

/* استایل برای تبلت */
@media (min-width: 768px) and (max-width: 1024px) {
    .custom-product-box {
        padding: 20px;
    }

    .custom-product-box .product-image {
        max-width: 45%;
    }

    .custom-product-box .product-details h2 {
        font-size: 1.5em;
    }

    .custom-product-box .product-details ul li {
        font-size: 0.92em;
    }
}

/* استایل برای لپ‌تاپ */
@media (min-width: 1025px) {
    .custom-product-box .product-image {
        max-width: 40%;
    }
}

/* Minimal Product Card Styles */
.minimal-product-card {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 2rem;
    padding: 2rem;
    margin: 1.5rem 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.minimal-product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.minimal-product-card .product-image {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    background: #f8f9fa;
}

.minimal-product-card .image-link {
    display: block;
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
}

.minimal-product-card .image-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.minimal-product-card .image-link:hover img {
    transform: scale(1.08);
}

.minimal-product-card .product-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.minimal-product-card h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.4;
}

.minimal-product-card h2 a {
    color: #1a1a1a;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: all 0.3s ease;
}

.minimal-product-card h2 a i {
    color: var(--primary-color, #46ad56);
    font-size: 1.4em;
    transition: transform 0.3s ease;
}

.minimal-product-card h2 a:hover i {
    transform: rotate(-15deg);
}

.minimal-product-card .specs-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.875rem;
}


.minimal-product-card .price {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: auto;
}

.minimal-product-card .sale-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color, #46ad56);
}

.minimal-product-card .regular-price {
    font-size: 1rem;
    color: #a0aec0;
    text-decoration: line-through;
    opacity: 0.8;
}

.minimal-product-card .details-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    background: var(--primary-color, #46ad56);
    color: white;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 600;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: fit-content;
    position: relative;
    overflow: hidden;
}

.minimal-product-card .details-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent 0%, rgba(255,255,255,0.2) 100%);
    transform: translateX(-100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.minimal-product-card .details-button:hover::before {
    transform: translateX(0);
}

.minimal-product-card .details-button i {
    font-size: 1.25em;
    transition: transform 0.3s ease;
}

.minimal-product-card .details-button:hover i:last-child {
    animation: bounceLeft 0.8s infinite;
}

@keyframes bounceLeft {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(-5px); }
}

@media (max-width: 768px) {
    .minimal-product-card {
        grid-template-columns: 1fr;
        padding: 1.5rem;
        gap: 1.5rem;
    }

    .minimal-product-card .product-image {
        max-height: 300px;
    }

    .minimal-product-card .price {
        margin: 1rem 0;
    }

    .minimal-product-card .details-button {
        width: 100%;
    }

    .sale-price {
        font-size: 11px;
    }

    .regular-price {
        font-size: 12px;
        opacity: 0.7;
    }

    .buy-button {
        padding: 0.4rem 0.75rem;
        font-size: 0.75rem;
        width: 100%;
        justify-content: center;
        gap: 0.5rem;
    }

    .buy-button .isax {
        font-size: 1.1em;
    }

    .buy-button .text {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .minimal-product-card {
        padding: 1rem;
    }

    .minimal-product-card h2 {
        font-size: 1.25rem;
    }

    .minimal-product-card .specs-container {
        gap: 0.5rem;
    }

    .minimal-product-card .spec-item {
        padding: 0.4rem 0.8rem;
        font-size: 0.875rem;
    }

    .minimal-product-card .sale-price {
        font-size: 0.8125rem;
    }

    .sale-price {
        font-size: 12px;
    }

    .regular-price {
        font-size: 11px;
    }

    .buy-button {
        padding: 0.35rem 0.625rem;
        font-size: 0.7rem;
        gap: 0.375rem;
    }

    .buy-button .isax {
        font-size: 1em;
    }
}

/* Modern Product Card Styles */
.modern-product-card {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 600px;
    margin: 0.75rem auto;
    padding: 0.75rem;
    background: #ffffff;
    border: #f0f0f0 1px solid;
    border-radius: 12px;
    box-shadow: var(--card-elevation);
    transition: transform 0.2s ease-in-out;
    box-sizing: border-box;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
}

.modern-product-card,
.modern-product-card *,
.product-title a,
.product-info a,
.image-wrapper,
.buy-button,
a {
    text-decoration: none;
}

/* Remove the link styles from individual elements */
.product-title a,
.image-wrapper,
.buy-button {
    text-decoration: none;
    color: inherit;
    pointer-events: none;
}

.modern-product-card-link {
    text-decoration: none;
    display: block;
}

.product-image {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    position: relative;
    border-radius: 12px;
    overflow: hidden;
}

.image-wrapper {
    display: block;
    aspect-ratio: 1;
}

.image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease-in-out;
}

.image-wrapper:hover img {
    transform: scale(1.03);
}

.product-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-width: 0;
    color: var(--on-surface-high-emphasis);
    padding-left: 0.75rem;
}

.product-title {
    margin: 0;
    font-size: 0.875rem;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-title a {
    color: var(--on-surface-high-emphasis);
    text-decoration: none;
}

.product-description {
    font-size: 0.7rem;
    line-height: 1.3;
    color: var(--on-surface-medium-emphasis);
    margin: 0;
}

.specs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    width: 100%;
    overflow-x: hidden;
}

.spec-pill {
    padding: 0.2rem 0.4rem;
    background: rgba(0, 0, 0, 0.08);
    border-radius: 16px;
    font-size: 0.625rem;
    color: var(--on-surface-medium-emphasis);
    transition: all 0.2s ease-in-out;
    white-space: nowrap;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.price-wrapper {
    margin-top: auto;
}

.price {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sale-price {
    font-size: 1rem;
    font-weight: 500;
    color: var(--primary-color);
}

.regular-price {
    font-size: 0.75rem;
    color: var(--on-surface-medium-emphasis);
    text-decoration: line-through;
}

.action-area {
    margin-top: 0;
}

.buy-button {
    display: none;
}

/* Media Queries */
@media (max-width: 768px) {
    .modern-product-card {
        flex-direction: row;
        align-items: center;
        max-width: 100%;
    }

    .product-image {
        width: 80px;
        height: 80px;
        border-radius: 10px;
    }

    .product-info {
        padding-left: 0.5rem;
    }

    .product-description {
        display: none;
    }

    .product-title {
        font-size: 0.75rem;
    }

    .spec-pill {
        font-size: 0.5625rem;
        padding: 0.15rem 0.3rem;
    }

    .sale-price {
        font-size: 0.75rem;
    }

    .regular-price {
        font-size: 0.625rem;
    }

    .buy-button {
        padding: 0.2rem 0.4rem;
        font-size: 0.625rem;
    }

    .buy-button .isax {
        font-size: 0.75rem;
    }
}

@media (max-width: 480px) {
    .modern-product-card {
        padding: 0.5rem;
    }

    .product-title {
        font-size: 0.6875rem;
    }

    .spec-pill {
        font-size: 0.5rem;
        padding: 0.1rem 0.2rem;
    }

    .sale-price {
        font-size: 0.6875rem;
    }

    .regular-price {
        font-size: 0.5625rem;
    }

    .buy-button {
        padding: 0.15rem 0.3rem;
        font-size: 0.5625rem;
    }

    .buy-button .isax {
        font-size: 0.6875rem;
    }
}