/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    background-color: #f8f9fa;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 50px 0;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

/* Navigation Styles */
.nav {
    margin-bottom: 30px;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.nav-link.active {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

.logo {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    letter-spacing: -1px;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 300;
}

/* Main Content */
.main {
    padding: 50px 0;
}

/* Search Section */
.search-section {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    margin-bottom: 40px;
}

.search-box {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
}

.search-input {
    flex: 1;
    padding: 18px 25px;
    border: 2px solid #e1e5e9;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.3s ease;
    font-family: inherit;
}

.search-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.search-btn {
    padding: 18px 35px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.search-tips {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.tip {
    color: #6c757d;
    font-weight: 500;
    font-size: 14px;
}

.tag {
    padding: 10px 18px;
    background: #f8f9fa;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid #e9ecef;
}

.tag:hover {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* Statistics Section */
.stats-section {
    margin-bottom: 50px;
}

.stats {
    display: flex;
    justify-content: center;
    gap: 80px;
    flex-wrap: wrap;
}

.stat-item {
    text-align: center;
    background: white;
    padding: 30px 40px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    min-width: 150px;
}

.stat-number {
    display: block;
    font-size: 3rem;
    font-weight: 700;
    color: #667eea;
    margin-bottom: 8px;
}

.stat-label {
    color: #6c757d;
    font-size: 1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Filter Section */
.filter-section {
    background: white;
    padding: 35px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    margin-bottom: 50px;
}

.filter-group {
    margin-bottom: 30px;
}

.filter-group:last-child {
    margin-bottom: 0;
}

.filter-title {
    margin-bottom: 20px;
    color: #2c3e50;
    font-size: 1.4rem;
    font-weight: 600;
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.filter-tag {
    padding: 12px 22px;
    background: #f8f9fa;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 500;
    border: 2px solid transparent;
}

.filter-tag:hover,
.filter-tag.active {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* Brands Section */
.brands-section {
    margin-bottom: 50px;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 40px;
    color: #2c3e50;
    font-weight: 700;
}

.brands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.brand-card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.brand-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.brand-card:hover::before {
    transform: scaleX(1);
}

.brand-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    border-color: #667eea;
}

.brand-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.brand-logo {
    width: 70px;
    height: 70px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.brand-logo:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.brand-logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 15px;
    background: white;
    padding: 8px;
    box-sizing: border-box;
    transition: all 0.3s ease;
    opacity: 0;
}

.brand-logo-img:hover {
    transform: scale(1.1);
}

.brand-logo-img.loaded {
    opacity: 1;
}

.brand-logo-fallback {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: white;
    font-weight: bold;
    transition: all 0.3s ease;
}

.brand-logo-fallback:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
}

/* Logo Loading State */
.brand-logo.loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.brand-info h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
}

.brand-country {
    color: #6c757d;
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.brand-desc {
    color: #6c757d;
    line-height: 1.6;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.brand-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.category-tag {
    padding: 6px 12px;
    background: #f8f9fa;
    border-radius: 12px;
    font-size: 12px;
    color: #6c757d;
    font-weight: 500;
}

.contact-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.contact-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
    backdrop-filter: blur(8px);
}

.modal-content {
    background-color: white;
    margin: 3% auto;
    padding: 40px;
    border-radius: 20px;
    width: 90%;
    max-width: 800px;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    animation: modalSlideIn 0.4s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-60px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.close {
    position: absolute;
    right: 25px;
    top: 25px;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    color: #adb5bd;
    transition: color 0.3s ease;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f8f9fa;
}

.close:hover {
    color: #2c3e50;
    background: #e9ecef;
}

.modal-brand-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 2px solid #f8f9fa;
}

.modal-brand-logo {
    width: 120px;
    height: 120px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.modal-brand-logo:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 35px rgba(0,0,0,0.2);
}

.modal-brand-logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 20px;
    background: white;
    padding: 15px;
    box-sizing: border-box;
    transition: all 0.3s ease;
}

.modal-brand-logo-img:hover {
    transform: scale(1.1);
}

.modal-brand-logo-fallback {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    font-weight: bold;
    transition: all 0.3s ease;
}

.modal-brand-logo-fallback:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
}

.modal-brand-name {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 10px;
}

.modal-brand-country {
    color: #6c757d;
    font-size: 1.1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
}

.modal-brand-desc {
    color: #6c757d;
    font-size: 1.1rem;
    line-height: 1.7;
    max-width: 600px;
    margin: 0 auto;
}

.modal-section {
    margin-bottom: 35px;
}

.modal-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #f8f9fa;
}

.modal-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 25px;
}

.modal-category-tag {
    padding: 10px 18px;
    background: #f8f9fa;
    border-radius: 15px;
    font-size: 14px;
    color: #6c757d;
    font-weight: 500;
}

.modal-contact-info {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 25px;
}

.contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 18px;
}

.contact-item:last-child {
    margin-bottom: 0;
}

.contact-icon {
    width: 24px;
    margin-right: 15px;
    color: #667eea;
    font-size: 18px;
}

.contact-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.contact-link:hover {
    color: #764ba2;
    text-decoration: underline;
}

.modal-products {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.product-item {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 15px;
    text-align: center;
    transition: all 0.3s ease;
}

.product-item:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}

.product-name {
    font-weight: 700;
    margin-bottom: 8px;
    color: #2c3e50;
    font-size: 1.1rem;
}

.product-desc {
    font-size: 14px;
    color: #6c757d;
    line-height: 1.5;
}

/* Footer */
.footer {
    background: #2c3e50;
    color: white;
    text-align: center;
    padding: 40px 0;
    margin-top: 80px;
}

/* Page Summary */
.page-summary {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 25px;
    border-left: 4px solid #3498db;
    text-align: left;
}

.page-summary h4 {
    color: #3498db;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.page-summary p {
    margin: 0;
    line-height: 1.6;
    opacity: 0.9;
}

/* Bookmark Button */
.bookmark-container {
    position: absolute;
    top: 20px;
    right: 20px;
}

.bookmark-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 25px;
    padding: 10px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 500;
}

.bookmark-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

.bookmark-btn.bookmarked {
    background: #f39c12;
    border-color: #f39c12;
    color: white;
}

.bookmark-btn.bookmarked svg {
    fill: white;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .logo {
        font-size: 2.2rem;
    }
    
    .search-box {
        flex-direction: column;
    }
    
    .stats {
        gap: 20px;
    }
    
    .stat-item {
        padding: 20px 25px;
        min-width: 120px;
    }
    
    .brands-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        width: 95%;
        margin: 5% auto;
        padding: 25px;
    }
    
    .modal-products {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 40px 0;
    }
    
    .logo {
        font-size: 1.8rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .search-section {
        padding: 25px;
    }
    
    .brand-card {
        padding: 25px;
    }
    
    .modal-content {
        padding: 20px;
    }
    
    .modal-brand-name {
        font-size: 2rem;
    }
}

/* Loading Animation */
.loading {
    text-align: center;
    padding: 60px;
    color: #6c757d;
    font-size: 1.1rem;
}

.loading::after {
    content: '';
    display: inline-block;
    width: 24px;
    height: 24px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 15px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* No Results */
.no-results {
    text-align: center;
    padding: 60px;
    color: #6c757d;
    font-size: 1.2rem;
}

.no-results::before {
    content: '🔍';
    display: block;
    font-size: 4rem;
    margin-bottom: 25px;
}

/* Scrollbar Styling */
.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
} 