/* display_product.css - MOBILE FIRST APPROACH */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@100;200;300;400;500;600;700&display=swap');

:root {
    --primary: #00a8a8;
    --primary-dark: #008888;
    --primary-light: #00c8c8;
    --primary-extra-light: #e6f7f7;
    --secondary: #f59e0b;
    --dark: #1e293b;
    --light: #f8fafc;
    --gray: #64748b;
    --light-gray: #e2e8f0;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 25px rgba(0, 0, 0, 0.12);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Roboto, -apple-system, sans-serif;
    background-color: #f8fafc;
    color: var(--dark);
    line-height: 1.6;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Home Button - Mobile Optimized */
.home-button {
    position: fixed;
    top: 1rem;
    left: 1rem;
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.75rem 1rem;
    border-radius: 50px;
    cursor: pointer;
    z-index: 1000;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
    font-weight: 500;
    font-size: 0.9rem;
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.home-button:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 168, 168, 0.3);
}

/* Product Gallery - Mobile First */
.product-gallery {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.main-image-container {
    position: relative;
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    aspect-ratio: 1/1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.main-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: var(--transition);
}

.zoom-icon {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.zoom-icon:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: scale(1.1);
}

.thumbnails {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    padding: 0.5rem 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.thumbnails::-webkit-scrollbar {
    display: none;
}

.thumbnail {
    width: 80px;
    height: 80px;
    min-width: 80px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
    background: white;
    padding: 0.25rem;
}

.thumbnail:hover, .thumbnail.active {
    border-color: var(--primary);
    transform: scale(1.05);
}

/* Product Info - Mobile First */
.product-info {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 1.5rem;
}

.product-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--dark);
    line-height: 1.3;
}

.product-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.rating {
    color: var(--warning);
    font-size: 0.85rem;
}

.review-count {
    color: var(--gray);
    font-size: 0.85rem;
}

.stock-status {
    font-size: 0.8rem;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-weight: 500;
}

.in-stock {
    background-color: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.low-stock {
    background-color: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

/* Price Container */
.price-container {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 1rem 0;
    flex-wrap: wrap;
}

.original-price {
    text-decoration: line-through;
    color: var(--gray);
    font-size: 1rem;
}

.discount-price {
    color: var(--danger);
    font-weight: 700;
    font-size: 1.5rem;
}

.discount-badge {
    background: linear-gradient(135deg, var(--danger), #ff6b6b);
    color: white;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Product Highlights */
.product-highlights {
    margin: 1.5rem 0;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    padding: 1.25rem;
    background: var(--primary-extra-light);
}

.section-title {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--dark);
    font-weight: 600;
    position: relative;
    padding-bottom: 0.5rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--primary);
    border-radius: 2px;
}

.highlight-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.highlight-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.highlight-icon {
    width: 36px;
    height: 36px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.highlight-content h4 {
    margin: 0 0 0.25rem 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--dark);
}

.highlight-content p {
    margin: 0;
    color: var(--gray);
    font-size: 0.85rem;
    line-height: 1.4;
}

/* Product Meta Information */
.product-meta-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--light-gray);
}

.meta-label {
    font-weight: 600;
    color: var(--gray);
    font-size: 0.9rem;
}

.meta-value {
    color: var(--dark);
    font-size: 0.95rem;
}

/* Specifications */
.specifications-container {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.spec-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0.75rem;
    background: var(--light);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--primary);
}

.spec-label {
    font-weight: 600;
    color: var(--dark);
    font-size: 0.9rem;
}

.spec-value {
    color: var(--gray);
    font-size: 0.9rem;
    line-height: 1.4;
}

/* Quantity Selector */
.quantity-selector {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 1.5rem 0;
    flex-wrap: wrap;
}

.quantity-btn {
    width: 44px;
    height: 44px;
    border: 1px solid var(--light-gray);
    background: white;
    font-size: 1.1rem;
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.quantity-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.quantity-input {
    width: 70px;
    height: 44px;
    text-align: center;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
}

.quantity-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 168, 168, 0.1);
}

/* Action Buttons */
.action-buttons {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.btn {
    padding: 1rem 1.5rem;
    border-radius: var(--radius);
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    text-decoration: none;
    font-size: 0.95rem;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 15px rgba(0, 168, 168, 0.3);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 168, 168, 0.4);
}

.btn-whatsapp {
    background: #25D366;
    color: white;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp:hover {
    background: #128C7E;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

/* Product Tags */
.product-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.tag {
    background: var(--light);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--gray);
    border: 1px solid var(--light-gray);
    transition: var(--transition);
}

.tag:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-1px);
}

/* Product Description */
.product-description {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.description-content {
    line-height: 1.7;
    color: var(--dark);
    font-size: 0.95rem;
}

/* Related Products */
.related-section {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.related-section .section-title {
    text-align: center;
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
}

.related-section .section-title::after {
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
}

.related-slider-container {
    position: relative;
    overflow: hidden;
}

.related-slider {
    display: flex;
    transition: transform 0.5s ease-in-out;
    gap: 1rem;
}

.related-card {
    flex: 0 0 calc(100% - 1rem);
    background: white;
    border-radius: var(--radius);
    padding: 1.25rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: var(--transition);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid var(--light-gray);
    position: relative;
    overflow: hidden;
}

.related-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(to right, var(--primary-light), var(--primary));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.related-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.related-card:hover::before {
    transform: scaleX(1);
}

.related-card img {
    width: 100%;
    height: 140px;
    object-fit: contain;
    margin-bottom: 1rem;
    transition: transform 0.3s ease;
}

.related-card:hover img {
    transform: scale(1.05);
}

.related-card h4 {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--dark);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.8em;
}

.related-card p {
    color: var(--dark);
    font-weight: 700;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.related-card .btn-outline {
    background: transparent;
    color: var(--dark);
    border: 2px solid var(--primary);
    padding: 0.6rem 1rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
    width: 100%;
    font-size: 0.9rem;
}

.related-card .btn-outline:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
}

/* Slider Controls */
.slider-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 1.5rem;
    gap: 1rem;
}

.slider-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.75rem 1.25rem;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    box-shadow: 0 2px 8px rgba(0, 168, 168, 0.2);
}

.slider-btn:hover:not(:disabled) {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 168, 168, 0.3);
}

.slider-btn:disabled {
    background: #cccccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.slider-dots {
    display: flex;
    gap: 0.5rem;
}

.slider-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ddd;
    cursor: pointer;
    transition: var(--transition);
}

.slider-dot.active {
    background: var(--primary);
    transform: scale(1.2);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.95);
    overflow: auto;
    backdrop-filter: blur(5px);
}

.modal-content {
    margin: auto;
    display: block;
    width: 95%;
    max-width: 800px;
    max-height: 90vh;
    position: relative;
    top: 50%;
    transform: translateY(-50%);
    border-radius: var(--radius);
}

.close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    color: white;
    font-size: 2.5rem;
    font-weight: bold;
    cursor: pointer;
    z-index: 1001;
    transition: var(--transition);
}

.close:hover {
    color: var(--primary);
}

/* Tablet Styles */
@media (min-width: 768px) {
    body {
        font-size: 15px;
    }
    
    .container {
        padding: 0 1.5rem;
    }
    
    .product-detail {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 2.5rem;
        margin-bottom: 3rem;
    }
    
    .product-gallery {
        display: grid;
        grid-template-columns: 100px 1fr;
        gap: 1.5rem;
    }
    
    .thumbnails {
        flex-direction: column;
        max-height: 500px;
        overflow-y: auto;
    }
    
    .thumbnail {
        width: 100%;
        height: 80px;
        min-width: auto;
    }
    
    .product-title {
        font-size: 1.6rem;
    }
    
    .highlight-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem;
    }
    
    .product-meta-item {
        flex-direction: row;
        align-items: flex-start;
    }
    
    .meta-label {
        min-width: 120px;
    }
    
    .spec-item {
        flex-direction: row;
        align-items: center;
    }
    
    .spec-label {
        min-width: 120px;
    }
    
    .action-buttons {
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }
    
    .related-card {
        flex: 0 0 calc(50% - 0.5rem);
    }
    
    .slider-controls {
        margin-top: 2rem;
    }
}

/* Desktop Styles */
@media (min-width: 1024px) {
    body {
        font-size: 16px;
    }
    
    .container {
        padding: 0 2rem;
    }
    
    .product-gallery {
        grid-template-columns: 120px 1fr;
    }
    
    .main-image-container {
        aspect-ratio: 1/1;
        height: auto;
    }
    
    .product-title {
        font-size: 1.8rem;
    }
    
    .highlight-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .related-card {
        flex: 0 0 calc(33.333% - 0.75rem);
    }
    
    .action-buttons {
        gap: 1.5rem;
    }
    
    .btn {
        padding: 1.1rem 1.75rem;
    }
}

/* Large Desktop */
@media (min-width: 1200px) {
    .related-card {
        flex: 0 0 calc(25% - 0.75rem);
    }
    
    .highlight-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mb-1 {
    margin-bottom: 1rem;
}

.mb-2 {
    margin-bottom: 2rem;
}

.mt-1 {
    margin-top: 1rem;
}

.mt-2 {
    margin-top: 2rem;
}

/* Loading Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* Alert Styles */
.cart-alert {
    position: fixed;
    top: 1rem;
    right: 1rem;
    padding: 1rem 1.5rem;
    border-radius: var(--radius);
    color: white;
    display: flex;
    align-items: center;
    z-index: 1000;
    animation: slideIn 0.3s ease-out;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.alert-success {
    background: linear-gradient(135deg, var(--success), #34d399);
}

.alert-error {
    background: linear-gradient(135deg, var(--danger), #f87171);
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes slideOut {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(100%); opacity: 0; }
}