/* Catalog Components Specific Styles */

/* Simple Catalog Header */
.catalog-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2rem 0;
    border-bottom: 2px solid #e5e7eb;
}

.catalog-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #111827;
    margin: 0 0 1rem 0;
}

.page-description {
    color: #6b7280;
    font-size: 1.1rem;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

/* Single Page Styles */
.component-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e9ecef;
}

.component-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin: 0;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.component-type {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.catalog-description {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    border-left: 4px solid #007bff;
}

.catalog-data-section {
    display: grid;
    gap: 2rem;
    margin-bottom: 2rem;
}

.card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.card h3 {
    margin: 0 0 1.5rem 0;
    color: #2c3e50;
    font-size: 1.3rem;
    font-weight: 600;
}

.score-display {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}

.score-circle.large {
    text-align: center;
}

.circle.overall-score {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: bold;
    margin: 0 auto 1rem;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.components-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.component-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
}

.component-item:hover {
    background: #e9ecef;
    transform: translateY(-1px);
}

.component-icon {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #6c757d, #495057);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.component-name {
    font-weight: 500;
    color: #2c3e50;
    word-break: break-word;
    flex: 1;
}

/* Component status indicators - plain and simple */
.component-status {
    margin-left: auto;
    opacity: 0.6;
    transition: opacity 0.2s ease;
    font-size: 0.7rem;
}

.component-status.linked {
    color: #28a745;
}

.component-status.unlinked {
    color: #dc3545;
}

.component-item:hover .component-status {
    opacity: 0.8;
}

/* Component link styles */
.component-link {
    color: inherit;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.component-link:hover {
    color: #2c3e50;
    text-decoration: none;
}

/* Enhanced hover states for component items */
.component-item:has(.component-link) {
    cursor: pointer;
}

.component-item:has(.component-link):hover {
    background: rgba(248, 249, 250, 0.8);
    border-color: rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

/* Style for non-linked components */
.component-item:not(:has(.component-link)) .component-name {
    color: #6c757d;
    font-style: italic;
}

.component-item:not(:has(.component-link)) .component-icon {
    background: linear-gradient(135deg, #adb5bd, #868e96);
    opacity: 0.8;
}

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

.search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    z-index: 2;
}

.search-input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: #fff;
}

.search-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.software-section {
    margin-top: 2rem;
}

.software-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    padding: 1rem 0;
}

.software-card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 1.5rem;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.software-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #007bff, #28a745);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.software-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    border-color: #007bff;
}

.software-card:hover::before {
    transform: scaleX(1);
}

.software-card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.software-card-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #007bff, #0056b3);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.software-card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
    line-height: 1.4;
    word-break: break-word;
}

/* Responsive Design */
@media (max-width: 768px) {
    .catalog-header h1 {
        font-size: 2rem;
    }

    .component-title {
        font-size: 1.8rem;
    }

    .component-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .software-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 1rem;
    }

    .components-grid {
        grid-template-columns: 1fr;
    }

    .software-card {
        padding: 1.25rem;
    }

    .software-card-header {
        gap: 0.75rem;
    }

    .software-card-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .software-card-title {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .software-grid {
        grid-template-columns: 1fr;
    }

    .search-wrapper {
        margin-bottom: 2rem;
    }

    .card {
        padding: 1.5rem;
    }
}
