/* Frontend Styles for AI Tools Showcase */

.ai-tools-showcase {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 0;
}

/* Filters */
.ai-tools-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    align-items: center;
}

.filter-group {
    flex: 1;
    min-width: 200px;
}

.ai-tools-search,
.ai-tools-filter {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.ai-tools-search:focus,
.ai-tools-filter:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

.filter-results {
    padding: 10px 15px;
    background: white;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

#ai-tools-count {
    color: #4CAF50;
    font-size: 16px;
}

/* Grid Layout */
.ai-tools-grid {
    display: grid;
    gap: 25px;
    margin-bottom: 30px;
}

.ai-tools-grid-1 {
    grid-template-columns: 1fr;
}

.ai-tools-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.ai-tools-grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.ai-tools-grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

/* Plugin Card */
.ai-tool-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.ai-tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    border-color: #4CAF50;
}

.ai-tool-card.hidden {
    display: none;
}

/* Feature Image */
.ai-tool-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

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

.ai-tool-card:hover .ai-tool-image img {
    transform: scale(1.05);
}

.ai-tool-header {
    padding: 20px 20px 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.ai-tool-title {
    margin: 0 0 5px;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.3;
}

.ai-tool-version {
    font-size: 12px;
    opacity: 0.9;
    background: rgba(255,255,255,0.2);
    padding: 2px 8px;
    border-radius: 4px;
    display: inline-block;
}

.ai-tool-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ai-tool-description {
    color: #555;
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
    flex: 1;
}

/* Industries */
.ai-tool-industries {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.industry-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    background: #f0f0f0;
    border-radius: 12px;
    font-size: 11px;
    color: #666;
    font-weight: 500;
    border: 1px solid #e0e0e0;
}

/* Meta Info */
.ai-tool-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid #f0f0f0;
}

.ai-tool-category {
    font-size: 12px;
    color: #666;
    text-transform: capitalize;
}

.ai-tool-status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
}

.ai-tool-status.active {
    background: #e7f5ec;
    color: #2e7d32;
}

.ai-tool-status.coming-soon {
    background: #fff3e0;
    color: #f57c00;
}

.status-dot {
    width: 6px;
    height: 6px;
    background: currentColor;
    border-radius: 50%;
}

/* Pricing */
.ai-tool-pricing {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
}

.price-tag {
    display: flex;
    align-items: baseline;
    gap: 5px;
}

.price-amount {
    font-size: 20px;
    font-weight: 700;
    color: #2e7d32;
}

.price-unit {
    font-size: 12px;
    color: #666;
}

.ai-badge {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.ai-icon {
    font-size: 14px;
}

/* Footer Buttons */
.ai-tool-footer {
    padding: 0 20px 20px;
    display: flex;
    gap: 10px;
}

.ai-tool-btn {
    flex: 1;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    text-decoration: none;
    display: inline-block;
}

.ai-tool-details-btn {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
}

.ai-tool-details-btn:hover {
    background: #667eea;
    color: white;
}

.ai-tool-try-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.ai-tool-try-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* Modal */
.ai-tool-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ai-tool-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(5px);
}

.ai-tool-modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.ai-tool-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    border: none;
    background: rgba(0,0,0,0.1);
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1;
}

.ai-tool-modal-close:hover {
    background: rgba(0,0,0,0.2);
    transform: rotate(90deg);
}

.ai-tool-modal-body {
    padding: 30px;
}

.loading {
    text-align: center;
    padding: 40px;
    color: #999;
}

/* Modal Content Styles */
.plugin-detail-header {
    margin-bottom: 25px;
}

.plugin-detail-title {
    font-size: 28px;
    margin: 0 0 10px;
    color: #333;
}

.plugin-detail-meta {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.plugin-detail-section {
    margin-bottom: 25px;
}

.plugin-detail-section h3 {
    font-size: 18px;
    margin: 0 0 15px;
    color: #444;
    border-bottom: 2px solid #667eea;
    padding-bottom: 5px;
}

.plugin-detail-section ul {
    list-style: none;
    padding: 0;
}

.plugin-detail-section li {
    padding: 8px 0 8px 25px;
    position: relative;
}

.plugin-detail-section li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #4CAF50;
    font-weight: bold;
}

/* Error State */
.ai-tools-error {
    padding: 20px;
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 6px;
    color: #856404;
    text-align: center;
}

/* Responsive */
@media (max-width: 992px) {
    .ai-tools-grid-3,
    .ai-tools-grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .ai-tools-filters {
        flex-direction: column;
    }
    
    .filter-group {
        width: 100%;
    }
    
    .ai-tools-grid-2,
    .ai-tools-grid-3,
    .ai-tools-grid-4 {
        grid-template-columns: 1fr;
    }
    
    .ai-tool-modal-content {
        width: 95%;
    }
}
