/* ===================================================================
   PRODUCT PAGE STYLES - CLEAN VERSION (NO DUPLICATES)
   =================================================================== */

/* Product Page Specific Styles */

/* Star Rating Styles */
.rating-container {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 20px 0;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 8px;
}

.stars {
    display: flex;
    gap: 5px;
}

.star {
    font-size: 24px;
    color: #ddd;
}

.star.filled {
    color: #ffb400;
}

.star.half {
    position: relative;
    color: #ddd;
}

.star.half::before {
    content: 'â˜…';
    position: absolute;
    left: 0;
    color: #ffb400;
    overflow: hidden;
    width: 50%;
}

.rating-text {
    font-size: 1.2rem;
    font-weight: bold;
    color: #003366;
}

/* Breadcrumbs - Single Definition */
.breadcrumbs {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    background: white;
    padding: 10px 15px;
    margin: 10px 0;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    width: 100%;
}

.breadcrumbs ol {
    list-style: none;
    display: flex !important;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0;
    padding: 0;
    align-items: center;
}

.breadcrumbs li {
    display: inline-flex !important;
    align-items: center;
    font-size: 13px;
    color: #666;
}

.breadcrumbs li:not(:last-child)::after {
    content: '›';
    margin: 0 6px;
    color: #999;
    font-size: 14px;
}

.breadcrumbs a {
    color: #0066cc;
    text-decoration: none;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

.breadcrumbs .current {
    color: #333;
    font-weight: 500;
}

/* View Count Badge */
.view-count-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #e3f2fd;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 13px;
    color: #1976D2;
    margin-left: 10px;
}

/* Review Star Rating */
.star-rating {
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
    gap: 5px;
    font-size: 32px;
    margin: 15px 0;
}

.star-rating input {
    display: none;
}

.star-rating label {
    cursor: pointer;
    color: #ddd;
    transition: color 0.2s;
}

.star-rating label:hover,
.star-rating label:hover ~ label,
.star-rating input:checked ~ label {
    color: #ffc107;
}

/* Reviews Display */
.review-display {
    margin-bottom: 30px;
}

.review-item-new {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 15px;
    background: #fafafa;
}

.review-header-new {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.review-rating-stars {
    color: #ffc107;
    font-size: 14px;
    margin-left: 10px;
}

.review-text-new {
    line-height: 1.8;
    color: #333;
}

.average-rating-box {
    background: linear-gradient(135deg, #f5f5f5 0%, #e8f5e9 100%);
    padding: 25px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 30px;
    border: 2px solid #e0e0e0;
}

.average-rating-number {
    font-size: 48px;
    color: #ffc107;
    font-weight: bold;
}

/* Alert Messages */
.alert {
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.alert-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

/* Mobile Navigation */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px 10px;
    margin-left: auto;
}

.mobile-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    min-width: 200px;
    z-index: 1000;
    margin-top: 10px;
}

.mobile-menu.active {
    display: block;
}

.mobile-menu ul {
    list-style: none;
    padding: 10px 0;
}

.mobile-menu ul li {
    padding: 0;
}

.mobile-menu ul li a {
    display: block;
    padding: 12px 20px;
    color: #003366;
    text-decoration: none;
}

.mobile-menu ul li a:hover {
    background: #f0f0f0;
}

/* Price Range Display */
.price-range-display {
    background: #f5f5f5;
    color: #333;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 20px 0;
    border: 1px solid #e0e0e0;
}

.price-range-text {
    font-size: 1rem;
    color: #666;
}

.price-range-text strong {
    color: #333;
    font-weight: 600;
}

.price-highlight {
    color: #ff6b6b;
    font-weight: bold;
}

/* Key Features Block */
.key-features-block {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.feature-icon {
    font-size: 2rem;
    color: #003366;
    min-width: 40px;
    text-align: center;
}

.feature-info {
    flex: 1;
}

.feature-name {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 3px;
}

.feature-value {
    font-size: 1rem;
    font-weight: 600;
    color: #003366;
}

/* Tab Styles - Single Definition */
.tabs {
    display: flex;
    background: #f0f0f0;
    border-radius: 8px 8px 0 0;
    overflow-x: visible;
    margin-top: 20px;
    flex-wrap: wrap;
    gap: 0;
}

.tab-button {
    flex: 1 1 auto;
    min-width: 120px;
    padding: 12px 15px;
    background: #f0f0f0;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    color: #555;
    transition: all 0.3s;
    border-bottom: 3px solid transparent;
    white-space: nowrap;
}

.tab-button:hover {
    background: #e0e0e0;
}

.tab-button.active {
    background: white;
    color: #003366;
    border-bottom: 3px solid #003366;
}

.tab-content {
    display: none;
    padding: 30px;
    background: white;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Product Header */
.product-header-section {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.product-title-section {
    margin-bottom: 20px;
}

.product-title-section h1 {
    color: #003366;
    font-size: 2rem;
    margin-bottom: 15px;
}

.product-main-content {
    display: block;
    margin-bottom: 30px;
}

.product-image-section {
    text-align: center;
    margin: 20px 0;
}

.product-main-image {
    width: 100%;
    max-width: 300px;
    border: 2px solid #f0f0f0;
    border-radius: 8px;
    padding: 20px;
    background: #fafafa;
}

.product-info-section {
    margin-top: 20px;
}

.price-update-badge {
    background: #ffe6e6;
    padding: 12px 15px;
    margin: 20px 0;
    font-weight: bold;
    color: #333;
}

.overview-text {
    line-height: 1.8;
    color: #555;
    margin: 20px 0;
}

/* Price Table - Desktop */
.price-table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 20px 0;
}

.price-comparison-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}

.price-comparison-table th {
    background: #003366;
    color: white;
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

.price-comparison-table td {
    padding: 15px 12px;
    border-bottom: 1px solid #e0e0e0;
    vertical-align: middle;
}

.price-comparison-table tr:hover {
    background: #f8f9fa;
}

.store-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.store-logo {
    width: 50px;
    height: 30px;
    object-fit: contain;
}

.store-name {
    font-weight: 600;
    color: #003366;
}

.price-value {
    font-size: 1.2rem;
    font-weight: bold;
    color: #ff6b6b;
    white-space: nowrap;
}

.shop-button {
    background: #003366;
    color: white;
    padding: 8px 20px;
    border-radius: 5px;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
    white-space: nowrap;
}

.shop-button:hover {
    background: #0066cc;
}

/* Mobile Price Cards */
.price-cards {
    display: none;
}

.price-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 15px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.price-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.price-card-store-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.price-card-store-logo {
    width: 60px;
    height: 35px;
    object-fit: contain;
}

.price-card-store {
    font-size: 1.1rem;
    font-weight: 600;
    color: #003366;
}

.price-card-price {
    font-size: 1.3rem;
    font-weight: bold;
    color: #ff6b6b;
}

.price-card-details {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.6;
}

.price-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.price-card-date {
    font-size: 0.85rem;
    color: #999;
}

/* Media Gallery */
.media-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.media-item {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.media-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    cursor: pointer;
    transition: transform 0.3s;
}

.media-item img:hover {
    transform: scale(1.05);
}

.media-item iframe {
    width: 100%;
    height: 200px;
    border: none;
}

.media-caption {
    padding: 10px;
    background: #f9f9f9;
    text-align: center;
    font-size: 0.9rem;
    color: #666;
}

/* Specification Table */
.spec-category {
    margin-bottom: 30px;
}

.spec-category h3 {
    background: #003366;
    color: white;
    padding: 12px 15px;
    margin: 0 0 10px 0;
    border-radius: 5px;
}

.spec-table-new {
    width: 100%;
    border-collapse: collapse;
    background: white;
    margin-bottom: 20px;
}

.spec-table-new td {
    padding: 12px 15px;
    border-bottom: 1px solid #e0e0e0;
}

.spec-table-new td:first-child {
    font-weight: 600;
    color: #003366;
    width: 35%;
    background: #f9f9f9;
}

/* Bootstrap Modal Customization */
.modal-header {
    background: #003366;
    color: white;
    border-radius: 5px 5px 0 0;
}

.modal-header .close {
    color: white;
    opacity: 0.8;
}

.modal-header .close:hover {
    opacity: 1;
}

.modal-title {
    color: white;
}

.modal-body {
    padding: 20px;
    line-height: 1.8;
    white-space: pre-wrap;
}

.contact-store-btn {
    background: #28a745 !important;
    border-color: #28a745 !important;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.contact-store-btn:hover {
    background: #218838 !important;
    border-color: #1e7e34 !important;
}

.contact-store-btn i {
    font-size: 14px;
}

/* SEARCH BAR - Single Definition */
.search-section {
    background: #f0f0f0;
    padding: 20px;
    margin-bottom: 0;
}

.search-section .navbar-form {
    margin: 0;
    padding: 0;
    border: 0;
    position: relative;
}

.search-section .input-group {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: stretch;
}

.search-section .form-control {
    flex: 1;
    padding: 16px 20px;
    font-size: 16px;
    border: none;
    border-radius: 50px 0 0 50px;
    background: white;
    color: #333;
    line-height: 1.2;
    height: auto;
    margin: 0;
}

.search-section .form-control::placeholder {
    color: #999;
}

.search-section .form-control:focus {
    outline: none;
    border-color: transparent;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.search-section .input-group-btn {
    display: flex;
}

.search-section .input-group-btn .btn {
    padding: 16px 25px;
    font-size: 16px;
    border: none;
    border-radius: 0 50px 50px 0;
    background: white;
    color: #003366;
    cursor: pointer;
    transition: background 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1.2;
    height: auto;
    margin: 0;
    border-left: 1px solid #f0f0f0;
}

.search-section .input-group-btn .btn:hover {
    background: #f0f0f0;
    color: #0066cc;
}

.search-section .input-group-btn .btn i {
    font-size: 18px;
}

/* Live search results */
.search-results-live {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    margin-top: 10px;
    max-width: 1200px;
    max-height: 400px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
}

.search-results-live.active {
    display: block;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 15px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
    color: inherit;
}

.search-result-item:hover {
    background: #f8f9fa;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    flex-shrink: 0;
}

.search-result-info {
    flex: 1;
}

.search-result-name {
    font-weight: 600;
    color: #003366;
    margin-bottom: 3px;
    font-size: 14px;
}

.search-result-price {
    color: #ff6b6b;
    font-size: 13px;
}

.no-results {
    padding: 20px;
    text-align: center;
    color: #999;
    font-size: 14px;
}

/* Spacing */
.container {
    padding: 0 20px;
}

.search-section + .container {
    margin-top: 0;
}

.product-header-section {
    margin-top: 10px;
    padding-top: 15px;
}

.product-title-section {
    margin-bottom: 15px;
}

/* MOBILE RESPONSIVE - Single Definition */
@media (max-width: 768px) {
    nav ul {
        display: none;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .product-title-section h1 {
        font-size: 1.4rem;
        margin: 0;
    }

    .breadcrumbs {
        padding: 8px 12px;
        margin: 8px 0;
    }

    .breadcrumbs ol {
        flex-wrap: wrap;
        gap: 4px 6px;
    }

    .breadcrumbs li {
        font-size: 12px;
    }

    .tabs {
        flex-wrap: wrap;
        margin-top: 15px;
        border-radius: 8px;
    }

    .tab-button {
        flex: 1 1 calc(50% - 2px);
        min-width: 0;
        font-size: 0.9rem;
        padding: 10px 12px;
        border-radius: 0;
    }

    .tab-button:first-child {
        border-radius: 8px 0 0 0;
    }

    .tab-button:nth-child(2) {
        border-radius: 0 8px 0 0;
    }

    .tab-content {
        padding: 20px 15px;
    }

    .key-features-block {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        padding: 15px;
        gap: 10px;
    }

    .feature-item {
        padding: 12px;
    }

    .feature-icon {
        font-size: 1.5rem;
    }

    .price-table-wrapper {
        display: none;
    }

    .price-cards {
        display: block;
    }

    .media-gallery {
        grid-template-columns: 1fr;
    }

    .spec-table-new td:first-child {
        width: 45%;
        font-size: 0.9rem;
    }

    .rating-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .search-section {
        padding: 15px;
    }

    .search-section .form-control {
        padding: 14px 18px;
        font-size: 14px;
    }

    .search-section .input-group-btn .btn {
        padding: 14px 20px;
        font-size: 16px;
    }

    .container {
        padding: 0 15px;
    }

    .product-header-section {
        padding: 10px 15px;
        margin-top: 8px;
    }

    .product-title-section {
        margin-bottom: 10px;
    }

    .search-results-live {
        max-height: 300px;
    }

    .search-result-item {
        padding: 10px 12px;
    }

    .search-result-img {
        width: 40px;
        height: 40px;
    }

    .search-result-name {
        font-size: 13px;
    }

    .search-result-price {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .product-header-section {
        padding: 20px 15px;
    }

    .key-features-block {
        grid-template-columns: 1fr;
    }

    .price-card {
        padding: 15px;
    }

    .price-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .shop-button {
        width: 100%;
        text-align: center;
    }

    .breadcrumbs {
        padding: 6px 10px;
        margin: 6px 0;
    }

    .breadcrumbs li {
        font-size: 11px;
    }

    .tab-button {
        padding: 10px 8px;
        font-size: 0.85rem;
    }

    .search-section {
        padding: 12px;
    }

    .search-section .form-control {
        padding: 12px 15px;
        font-size: 13px;
    }

    .search-section .input-group-btn .btn {
        padding: 12px 18px;
        font-size: 15px;
    }
}
/* Auto-generated informational text */
.auto-generated-info {
    background: #f8f9fa;
    margin: 20px 0;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.auto-generated-info p {
    font-size: 1.05rem;
    line-height: 1.8;
    color: #333;
    margin: 0;
}

.auto-generated-info strong {
    color: #003366;
    font-weight: 600;
}