/* ==========================================================================
   TarahNaab Skincare Styles (Simple & Clean)
   ========================================================================== */

/* Profile Section */
.tn-profile-info-section {
    margin-bottom: 25px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 12px;
}

.tn-profile-title {
    font-size: 1.5rem;
    color: #333;
    margin-bottom: 15px;
}

.tn-profile-description {
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
}

.tn-divider {
    border: 0;
    height: 1px;
    background: #eaeaea;
    margin: 30px 0;
}

.tn-notice {
    padding: 15px;
    background-color: #fff3cd;
    color: #856404;
    border-radius: 8px;
    border: 1px solid #ffeeba;
}

/* Products Grid Container */
.tn-skincare-container {
    width: 100%;
    margin: 0 auto;
}

/* Desktop: 3 Columns */
.tn-products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

/* Product Card */
.tn-product-card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.tn-product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}

.tn-product-image {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background-color: #f5f5f5;
}

.tn-product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tn-product-info {
    padding: 15px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    justify-content: space-between;
}

.tn-product-title {
    font-size: 1.1rem;
    margin: 0 0 15px 0;
    color: #222;
    line-height: 1.4;
    text-align: center;
}

/* Add to Cart Button */
.tn-add-to-cart-btn {
    background-color: #FD7000;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 10px 15px;
    font-size: 0.95rem;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s ease;
    width: 100%;
}

.tn-add-to-cart-btn:hover {
    background-color: #e06300;
}

.tn-add-to-cart-btn.added {
    background-color: #a0aec0;
    cursor: default;
}

/* ==========================================================================
   Cart Popup Styles
   ========================================================================== */
.tn-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    backdrop-filter: blur(3px);
}

.tn-popup-content {
    background: #fff;
    width: 90%;
    max-width: 450px;
    padding: 30px;
    border-radius: 16px;
    position: relative;
    box-shadow: 0 20px 25px rgba(0, 0, 0, 0.15);
}

.tn-popup-close {
    position: absolute;
    top: 15px;
    left: 15px;
    background: transparent;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #888;
}

.tn-popup-close:hover {
    color: #e53e3e;
}

.tn-popup-content h3 {
    text-align: center;
    margin-top: 0;
    margin-bottom: 20px;
}

#tn-cart-items-list {
    list-style: none;
    padding: 0;
    margin-bottom: 20px;
}

#tn-cart-items-list li {
    padding: 8px 0;
    border-bottom: 1px dashed #eee;
    font-size: 14px;
}

.tn-checkout-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

#tn-user-phone {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 8px;
    text-align: center;
    direction: ltr;
}

.tn-submit-btn {
    background-color: #FD7000;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 12px;
    font-weight: bold;
    cursor: pointer;
}

.tn-submit-btn:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

/* Support Links in Success Message */
#tn-order-success-message {
    text-align: center;
}

.tn-support-links {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    justify-content: center;
}

.tn-support-links a {
    padding: 10px;
    border-radius: 8px;
    color: #fff;
    text-decoration: none;
    flex: 1;
    font-size: 13px;
    font-weight: bold;
}

.tn-support-links a[href*="wa.me"] { background-color: #25D366; }
.tn-support-links a[href*="instagram"] { background-color: #E1306C; }
.tn-support-links a[href*="ble.ir"] { background-color: #26a69a; }

/* ==========================================================================
   Mobile Responsive (1.5 Columns Horizontal Scroll)
   ========================================================================== */
@media (max-width: 768px) {
    .tn-products-grid {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 15px;
        padding-bottom: 15px; /* Space for scrollbar */
        -webkit-overflow-scrolling: touch;
    }

    /* Hide Scrollbar for cleaner look */
    .tn-products-grid::-webkit-scrollbar {
        height: 6px;
    }
    .tn-products-grid::-webkit-scrollbar-thumb {
        background-color: #ddd;
        border-radius: 4px;
    }

    .tn-product-card {
        flex: 0 0 65%; /* 65% width to show 1 full card + half of the next */
        scroll-snap-align: start;
    }
}
