/* Products Page Specific Styles */

/* Testing Categories Info Section */
.testing-categories-info {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.testing-intro {
    text-align: center;
    margin-bottom: 60px;
}

.testing-intro h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 16px;
}

.testing-intro p {
    font-size: 1.2rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
}

.categories-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.category-info-card {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.category-info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.category-header {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.category-icon {
    position: relative;
    width: 80px;
    height: 80px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
    font-size: 2rem;
    color: white;
}

.category-icon.category-1 {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

.category-icon.category-2 {
    background: linear-gradient(135deg, #10b981, #059669);
}

.category-number {
    position: absolute;
    top: -10px;
    right: -10px;
    background: #ef4444;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
}

.category-header h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

.category-header p {
    color: #64748b;
    font-size: 1.1rem;
}

.lab-partner {
    display: flex;
    align-items: center;
    background: #f8fafc;
    border-radius: 15px;
    padding: 25px;
    border-left: 4px solid #3b82f6;
}

.partner-logo {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
    color: white;
    font-size: 1.5rem;
}

.partner-info h4 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 5px;
}

.partner-info p {
    color: #64748b;
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.lab-partners-multiple {
    background: #f8fafc;
    border-radius: 15px;
    padding: 25px;
    border-left: 4px solid #10b981;
}

.partners-header h4 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 20px;
    text-align: center;
}

.partners-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.partner-item {
    display: flex;
    align-items: center;
    background: white;
    padding: 15px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
}

.partner-item i {
    color: #10b981;
    margin-right: 10px;
    font-size: 1.1rem;
}

.partner-item span {
    font-weight: 600;
    color: #1e293b;
}

.partner-features, .partner-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.feature-tag {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.category-info-card:nth-child(2) .feature-tag {
    background: linear-gradient(135deg, #10b981, #059669);
}

.testing-types {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.testing-type {
    text-align: center;
    padding: 30px 20px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    transition: transform 0.3s ease;
}

.testing-type:hover {
    transform: translateY(-3px);
}

.testing-type i {
    font-size: 2.5rem;
    color: #3b82f6;
    margin-bottom: 20px;
}

.testing-type h4 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 10px;
}

.testing-type p {
    color: #64748b;
    font-size: 0.95rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .categories-grid {
        grid-template-columns: 1fr;
    }
    
    .testing-types {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .partners-grid {
        grid-template-columns: 1fr;
    }
    
    .lab-partner {
        flex-direction: column;
        text-align: center;
    }
    
    .partner-logo {
        margin-right: 0;
        margin-bottom: 15px;
    }
}

@media (max-width: 480px) {
    .testing-types {
        grid-template-columns: 1fr;
    }
    
    .category-header {
        flex-direction: column;
        text-align: center;
    }
    
    .category-icon {
        margin-right: 0;
        margin-bottom: 15px;
    }
}

/* Hero Section */
.products-hero {
    background: linear-gradient(135deg, #1e293b 0%, #3b82f6 100%);
    padding: 120px 0 80px;
    color: white;
    position: relative;
    overflow: hidden;
}

/* Banner Image Styles */
.hero-banner-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.banner-placeholder {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.3;
    filter: brightness(0.4) blur(1px);
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.7) 0%, rgba(59, 130, 246, 0.6) 100%);
    z-index: 2;
}

/* CE Certification page: lighter blue tint */
.page-banner--ce .banner-overlay {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.35) 0%, rgba(59, 130, 246, 0.25) 100%);
}

.products-hero .container {
    position: relative;
    z-index: 3;
}

/* Responsive adjustments for banner image */
@media (max-width: 768px) {
    .banner-placeholder {
        opacity: 0.2;
        filter: brightness(0.3) blur(2px);
    }
    
    .banner-overlay {
        background: linear-gradient(135deg, rgba(30, 41, 59, 0.8) 0%, rgba(59, 130, 246, 0.7) 100%);
    }
    
    .page-banner--ce .banner-overlay {
        background: linear-gradient(135deg, rgba(30, 41, 59, 0.4) 0%, rgba(59, 130, 246, 0.3) 100%);
    }
}

@media (max-width: 480px) {
    .products-hero {
        min-height: 400px;
    }
    
    .banner-placeholder {
        opacity: 0.15;
    }
    
    .banner-overlay {
        background: linear-gradient(135deg, rgba(30, 41, 59, 0.85) 0%, rgba(59, 130, 246, 0.8) 100%);
    }
    
    .page-banner--ce .banner-overlay {
        background: linear-gradient(135deg, rgba(30, 41, 59, 0.45) 0%, rgba(59, 130, 246, 0.35) 100%);
    }
}

.products-hero .hero-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.products-hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text-white);
}

.products-hero p {
    font-size: 1.25rem;
    margin-bottom: 3rem;
    color: rgba(255, 255, 255, 0.9);
}

.search-container {
    position: relative;
    max-width: 500px;
    margin: 0 auto;
}

.search-container input {
    width: 100%;
    padding: 16px 20px 16px 50px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: var(--text-white);
    font-size: 1.125rem;
    transition: all 0.3s ease;
}

.search-container input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.search-container input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.15);
}

.search-container i {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.125rem;
}

/* Product Categories Section */
.product-categories {
    padding: 80px 0;
    background: var(--bg-light);
}

/* Category Tabs */
.category-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
    justify-content: center;
    flex-wrap: wrap;
}

.category-tab {
    padding: 12px 24px;
    border: 2px solid var(--border-light);
    border-radius: 50px;
    background: var(--bg-white);
    color: var(--text-light);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-tab:hover,
.category-tab.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--text-white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Products Layout */
.products-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 3rem;
    align-items: start;
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1rem;
}

.product-card {
    background: var(--bg-white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-color);
}

.product-card.selected {
    border-color: var(--primary-color);
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.product-card.selected::after {
    content: '';
    position: absolute;
    top: 12px;
    right: 12px;
    width: 24px;
    height: 24px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-card.selected::before {
    content: '✓';
    position: absolute;
    top: 18px;
    right: 18px;
    color: var(--text-white);
    font-weight: bold;
    z-index: 10;
    font-size: 0.875rem;
}

.product-image {
    position: relative;
    height: 120px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-overlay {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 40px;
    height: 40px;
    background: var(--bg-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-md);
}

.product-overlay i {
    font-size: 1.125rem;
    color: var(--primary-color);
}

.product-info {
    padding: 0.75rem;
}

.product-info h3 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: var(--text-dark);
}

.product-info p {
    color: var(--text-light);
    margin-bottom: 0.5rem;
    font-size: 0.75rem;
    line-height: 1.3;
}

.category-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.category-badge.ppe {
    background: #fef3c7;
    color: #92400e;
}

.category-badge.medical {
    background: #dbeafe;
    color: #1e40af;
}

.category-badge.electrical {
    background: #fce7f3;
    color: #be185d;
}

.category-badge.machinery {
    background: #ecfdf5;
    color: #047857;
}

.category-badge.construction {
    background: #f3e8ff;
    color: #7c2d12;
}

.category-badge.toys {
    background: #fef2f2;
    color: #dc2626;
}

/* Standards Panel */
.standards-panel {
    background: var(--bg-white);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    position: sticky;
    top: 100px;
    max-height: 80vh;
    overflow-y: auto;
}

.panel-header {
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid var(--border-light);
}

.panel-header h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.panel-header p {
    color: var(--text-light);
    font-size: 0.875rem;
}

.standards-content {
    padding: 2rem;
}

.welcome-message {
    text-align: center;
    color: var(--text-light);
}

.welcome-message i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.welcome-message h3 {
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.welcome-message ul {
    text-align: left;
    margin-top: 1rem;
}

.welcome-message ul li {
    margin-bottom: 0.5rem;
    position: relative;
    padding-left: 1.5rem;
}

.welcome-message ul li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

/* Standards List */
.standards-list {
    margin-top: 2rem;
}

.standard-item {
    background: var(--bg-light);
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
    border-left: 4px solid var(--primary-color);
    cursor: pointer;
    transition: all 0.3s ease;
}

.standard-item:hover {
    background: #e0f2fe;
    transform: translateX(4px);
}

.standard-title {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.standard-title i {
    color: var(--primary-color);
}

.standard-description {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

.standard-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.standard-tag {
    background: var(--primary-color);
    color: var(--text-white);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

/* Requirements Section */
.requirements-section {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-light);
}

.requirements-section h4 {
    color: var(--text-dark);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.requirements-section h4 i {
    color: var(--primary-color);
}

.requirement-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    padding: 0.75rem;
    background: var(--bg-light);
    border-radius: 8px;
}

.requirement-item i {
    color: var(--success-color);
    font-size: 1.125rem;
}

.requirement-text {
    flex: 1;
}

.requirement-title {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
    font-size: 0.875rem;
}

.requirement-detail {
    font-size: 0.75rem;
    color: var(--text-light);
}

/* Timeline Section */
.timeline-section {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-light);
}

.timeline-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    padding: 1rem;
    background: var(--bg-light);
    border-radius: 8px;
}

.timeline-step {
    width: 32px;
    height: 32px;
    background: var(--primary-color);
    color: var(--text-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.timeline-content {
    flex: 1;
}

.timeline-title {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
    font-size: 0.875rem;
}

.timeline-duration {
    font-size: 0.75rem;
    color: var(--text-light);
}

/* Quick Actions */
.quick-actions {
    padding: 2rem;
    border-top: 1px solid var(--border-light);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.action-btn {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.action-btn.primary {
    background: var(--gradient-primary);
    color: var(--text-white);
}

.action-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.action-btn.secondary {
    background: var(--bg-light);
    color: var(--text-dark);
    border: 1px solid var(--border-light);
}

.action-btn.secondary:hover {
    background: var(--bg-white);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
}

.modal-content {
    background: var(--bg-white);
    margin: 5% auto;
    padding: 0;
    border-radius: 16px;
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    overflow: hidden;
    animation: modalSlideIn 0.3s ease;
}

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

.modal-header {
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid var(--border-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    color: var(--text-dark);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-light);
    cursor: pointer;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: var(--text-dark);
}

.modal-body {
    padding: 2rem;
    max-height: 60vh;
    overflow-y: auto;
}

/* Filter and Search States */
.product-card.hidden {
    display: none;
}

.no-results {
    text-align: center;
    padding: 3rem;
    color: var(--text-light);
}

.no-results i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--text-light);
}

/* Loading States */
.standards-content.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 200px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--bg-light);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 1200px) {
    .products-layout {
        grid-template-columns: 1fr 350px;
        gap: 2rem;
    }
}

@media (max-width: 968px) {
    .products-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .standards-panel {
        position: static;
        max-height: none;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .products-hero h1 {
        font-size: 2.5rem;
    }
    
    .category-tabs {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 1rem;
    }
    
    .category-tab {
        flex-shrink: 0;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 0.875rem;
    }
    
    .product-image {
        height: 100px;
    }
    
    .product-info {
        padding: 0.625rem;
    }
    
    .product-info h3 {
        font-size: 0.875rem;
    }
    
    .product-info p {
        font-size: 0.7rem;
    }
    
    .standards-panel,
    .panel-header,
    .standards-content,
    .quick-actions {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .products-hero {
        padding: 100px 0 60px;
    }
    
    .products-hero h1 {
        font-size: 2rem;
    }
    
    .search-container input {
        padding: 14px 16px 14px 44px;
        font-size: 1rem;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .quick-actions {
        padding: 1rem;
    }
}
