/**
 * AI Review Summary Frontend Styles
 */

/* Summary link after rating */
.airs-summary-link-wrapper {
    margin: 5px 0;
    display: block;
    clear: both;
    padding-bottom: 20px;
}

.airs-summary-link {
    text-decoration: none;
    font-size: 15px;
    transition: all 0.2s ease;
}

.airs-summary-link:hover {
    color: #005a87;
    text-decoration: underline;
}


.airs-summary-link:hover span{
    text-decoration: none;
}

.airs-icon-svg svg{
    width: 25px;
    height: 25px;
}

/* Popup overlay */
.airs-popup-overlay {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

/* Popup container */
.airs-popup-container {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
    position: relative;
    animation: airs-popup-fade-in 0.3s ease-out;
}

@keyframes airs-popup-fade-in {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Popup header */
.airs-popup-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 25px;
    border-bottom: 1px solid #e1e5e9;
    background: #f8f9fa;
}

.airs-popup-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.airs-popup-close {
    background: none;
    border: none;
    padding: 5px;
    cursor: pointer;
    color: #666;
    transition: color 0.2s ease;
    border-radius: 4px;
}

.airs-popup-close:hover {
    color: #333;
    background-color: #e9ecef;
}

.airs-popup-close .dashicons {
    font-size: 20px;
    line-height: 1;
}

/* Popup content */
.airs-popup-content {
    padding: 25px;
    max-height: calc(80vh - 80px);
    overflow-y: auto;
}

/* Loading state */
.airs-popup-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
}

.airs-loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #0073aa;
    border-radius: 50%;
    animation: airs-spin 1s linear infinite;
    margin-bottom: 15px;
}

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

.airs-loading-text {
    color: #666;
    font-size: 14px;
}

/* Reviews link */
.airs-reviews-link {
    margin-bottom: 20px;
    padding: 12px 15px;
    background: #f8f9fa;
    border-radius: 6px;
    border-right: 4px solid #0073aa;
}

.airs-reviews-link a {
    display: inline-flex;
    align-items: center;
    color: #0073aa;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
}

.airs-reviews-link a:hover {
    text-decoration: underline;
}

.airs-reviews-link .dashicons {
    margin-left: 5px;
    font-size: 16px;
}

/* Summary content */
.airs-summary {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", inherit;
}

.airs-summary-text {
    margin-bottom: 25px;
    line-height: 1.6;
    color: #333;
    font-size: 15px;
}

/* Pros and cons */
.airs-pros-cons {
    display: flex;
    gap: 20px;
    margin-top: 20px;
}

.airs-pros, .airs-cons {
    flex: 1;
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    border-right: 4px solid;
}

.airs-pros {
    border-right-color: #28a745;
}

.airs-cons {
    border-right-color: #dc3545;
}

.airs-pros-title, .airs-cons-title {
    display: flex;
    align-items: center;
    margin: 0 0 15px 0;
    font-size: 16px;
    font-weight: 600;
}

.airs-pros-title {
    color: #28a745;
}

.airs-cons-title {
    color: #dc3545;
}

.airs-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    margin-left: 8px;
    font-size: 14px;
    font-weight: bold;
}

.airs-icon-plus {
    background-color: #d4edda;
    color: #28a745;
}

.airs-icon-minus {
    background-color: #f8d7da;
    color: #dc3545;
}

.airs-pros-list, .airs-cons-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.airs-pros-list li, .airs-cons-list li {
    margin-bottom: 10px;
    padding-right: 20px;
    position: relative;
    line-height: 1.5;
    color: #555;
}

.airs-pros-list li:before {
    content: "✓";
    position: absolute;
    right: 0;
    color: #28a745;
    font-weight: bold;
}

.airs-cons-list li:before {
    content: "✗";
    position: absolute;
    right: 0;
    color: #dc3545;
    font-weight: bold;
}

/* Summary stats */
.airs-summary-stats {
    margin-top: 25px;
    padding: 15px;
    background: #e9ecef;
    border-radius: 6px;
    text-align: center;
}

.airs-summary-stats p {
    margin: 0;
    font-size: 13px;
    color: #666;
    font-style: italic;
}

/* Responsive design */
@media (max-width: 768px) {
    .airs-popup-overlay {
        padding: 10px;
    }
    
    .airs-popup-container {
        max-height: 90vh;
    }
    
    .airs-popup-header {
        padding: 15px 20px;
    }
    
    .airs-popup-content {
        padding: 20px;
        max-height: calc(90vh - 70px);
    }
    
    .airs-pros-cons {
        flex-direction: column;
        gap: 15px;
    }
    
    .airs-pros, .airs-cons {
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .airs-popup-header {
        padding: 12px 15px;
    }
    
    .airs-popup-title {
        font-size: 16px;
    }
    
    .airs-popup-content {
        padding: 15px;
    }
    
    .airs-summary-text {
        font-size: 14px;
    }
}
