/* Component-specific styles */

/* Loading spinner */
.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Alert components */
.alert {
    padding: 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    border: 1px solid transparent;
}

.alert-success {
    background-color: #d1fae5;
    border-color: #a7f3d0;
    color: #065f46;
}

.alert-error {
    background-color: #fee2e2;
    border-color: #fecaca;
    color: #991b1b;
}

.alert-warning {
    background-color: #fef3c7;
    border-color: #fde68a;
    color: #92400e;
}

.alert-info {
    background-color: #dbeafe;
    border-color: #bfdbfe;
    color: #1e40af;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: white;
    border-radius: 12px;
    padding: 32px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal {
    transform: scale(1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.modal-title {
    font-size: 24px;
    font-weight: 700;
    color: #1f2937;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #6b7280;
    padding: 4px;
    border-radius: 4px;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: #374151;
}

.modal-body {
    margin-bottom: 24px;
}

.modal-footer {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* Tabs */
.tabs {
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 32px;
}

.tab-list {
    display: flex;
    gap: 0;
    list-style: none;
}

.tab-button {
    background: none;
    border: none;
    padding: 16px 24px;
    cursor: pointer;
    font-weight: 500;
    color: #6b7280;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.tab-button:hover {
    color: #374151;
}

.tab-button.active {
    color: #3b82f6;
    border-bottom-color: #3b82f6;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Accordion */
.accordion {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
}

.accordion-item {
    border-bottom: 1px solid #e5e7eb;
}

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

.accordion-header {
    background: none;
    border: none;
    width: 100%;
    padding: 20px;
    text-align: left;
    cursor: pointer;
    font-weight: 600;
    color: #1f2937;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s ease;
}

.accordion-header:hover {
    background: #f9fafb;
}

.accordion-icon {
    transition: transform 0.3s ease;
}

.accordion-item.active .accordion-icon {
    transform: rotate(180deg);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.accordion-item.active .accordion-content {
    max-height: 500px;
}

.accordion-body {
    padding: 0 20px 20px;
    color: #6b7280;
    line-height: 1.6;
}

/* Progress bar */
.progress {
    width: 100%;
    height: 8px;
    background: #e5e7eb;
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    transition: width 0.3s ease;
}

/* Badge */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.badge-success {
    background: #d1fae5;
    color: #065f46;
}

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

.badge-error {
    background: #fee2e2;
    color: #991b1b;
}

/* Tooltip */
.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip-content {
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    background: #1f2937;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.tooltip-content::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #1f2937;
}

.tooltip:hover .tooltip-content {
    opacity: 1;
    visibility: visible;
}

/* Card */
.card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
}

.card-header {
    padding: 24px 24px 0;
}

.card-body {
    padding: 24px;
}

.card-footer {
    padding: 0 24px 24px;
    border-top: 1px solid #f3f4f6;
    margin-top: 24px;
    padding-top: 24px;
}

/* Breadcrumb */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    font-size: 14px;
}

.breadcrumb-item {
    color: #6b7280;
}

.breadcrumb-item a {
    color: #3b82f6;
    text-decoration: none;
}

.breadcrumb-item a:hover {
    text-decoration: underline;
}

.breadcrumb-item.active {
    color: #1f2937;
    font-weight: 500;
}

.breadcrumb-separator {
    color: #d1d5db;
}

/* Pagination */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 32px 0;
}

.pagination-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    color: #374151;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.pagination-item:hover {
    border-color: #3b82f6;
    color: #3b82f6;
}

.pagination-item.active {
    background: #3b82f6;
    border-color: #3b82f6;
    color: white;
}

.pagination-item.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-item.disabled:hover {
    border-color: #d1d5db;
    color: #374151;
}

/* Search */
.search-container {
    position: relative;
    max-width: 400px;
}

.search-input {
    width: 100%;
    padding: 12px 16px 12px 48px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
}

/* Avatar */
.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e5e7eb;
}

.avatar-sm {
    width: 32px;
    height: 32px;
}

.avatar-lg {
    width: 56px;
    height: 56px;
}

.avatar-xl {
    width: 80px;
    height: 80px;
}

/* Status indicator */
.status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-online .status-dot {
    background: #10b981;
}

.status-offline .status-dot {
    background: #6b7280;
}

.status-busy .status-dot {
    background: #ef4444;
}

.status-away .status-dot {
    background: #f59e0b;
}

/* Comparison Table Styles */
.comparison-table-container {
    overflow-x: auto;
    margin: 40px 0;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    min-width: 800px;
}

.comparison-table th,
.comparison-table td {
    padding: 16px 12px;
    text-align: center;
    border-bottom: 1px solid #e5e7eb;
    vertical-align: middle;
}

.comparison-table th {
    background: #f8fafc;
    font-weight: 600;
    color: #1f2937;
    border-bottom: 2px solid #e5e7eb;
}

.comparison-table th:first-child {
    text-align: left;
    font-weight: 700;
}

.comparison-table td:first-child {
    text-align: left;
    font-weight: 500;
    color: #374151;
}

.highlight-column {
    background: linear-gradient(135deg, #dbeafe, #e0f2fe) !important;
    border-left: 3px solid #3b82f6;
    border-right: 3px solid #3b82f6;
    position: relative;
}

.company-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.check-icon {
    margin: 0 auto;
}

.cross-icon {
    margin: 0 auto;
}

.partial-icon {
    color: #f59e0b;
    font-weight: 500;
    font-size: 12px;
}

/* Competitor Cards */
.competitors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 32px;
    margin-top: 48px;
}

.competitor-card {
    background: white;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.competitor-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.prediworks-card {
    border: 2px solid #3b82f6;
    background: linear-gradient(135deg, #f0f9ff, #ffffff);
}

.competitor-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
    position: relative;
}

.competitor-logo {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    color: white;
    background: linear-gradient(135deg, #6b7280, #4b5563);
}

.fyxer-logo {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}

.fireflies-logo {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.notta-logo {
    background: linear-gradient(135deg, #10b981, #059669);
}

.otter-logo {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
}

.notion-logo {
    background: linear-gradient(135deg, #1f2937, #374151);
}

.competitor-info {
    flex: 1;
}

.competitor-name {
    font-size: 20px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 4px;
}

.competitor-rating {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stars {
    color: #fbbf24;
    font-size: 16px;
}

.rating-text {
    font-size: 14px;
    color: #6b7280;
}

.competitor-description {
    margin-bottom: 24px;
    color: #6b7280;
    line-height: 1.6;
}

.competitor-features h4 {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 12px;
}

.competitor-features ul {
    list-style: none;
    margin-bottom: 20px;
}

.competitor-features li {
    padding: 4px 0;
    color: #374151;
    font-size: 14px;
}

.competitor-features .weaknesses li {
    color: #6b7280;
}

.competitor-pricing {
    border-top: 1px solid #e5e7eb;
    padding-top: 20px;
    text-align: center;
}

.price {
    font-size: 28px;
    font-weight: 800;
    color: #1f2937;
    margin-bottom: 4px;
}

.price span {
    font-size: 16px;
    font-weight: 500;
    color: #6b7280;
}

.price-note {
    font-size: 12px;
    color: #6b7280;
    font-style: italic;
}

/* Responsive adjustments for comparison */
@media (max-width: 768px) {
    .comparison-table-container {
        margin: 20px -20px;
        border-radius: 0;
    }
    
    .comparison-table th,
    .comparison-table td {
        padding: 12px 8px;
        font-size: 14px;
    }
    
    .competitors-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .competitor-card {
        padding: 24px;
    }
    
    .competitor-header {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }
    
    .competitor-logo {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
}