/**
 * Mobile Phone Specifications - Comparison Styles
 * RTL-friendly styles for the comparison feature
 */

/* Comparison Button */
.mps-comparison-container {
    margin: 20px 0;
    text-align: center;
}

/* زر المقارنة داخل قسم المواصفات البسيطة */
.mps-comparison-container-inline {
    margin: 20px 0;
    text-align: center;
    padding: 12px;
    background: linear-gradient(to left, #f8f9fa, #e9ecef);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.mps-add-to-compare {
    background: linear-gradient(135deg, #4CAF50, #2E7D32);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 10px 20px;
    font-size: 15px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(76, 175, 80, 0.2);
}

.mps-add-to-compare:hover {
    background: linear-gradient(135deg, #43A047, #1B5E20);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(76, 175, 80, 0.3);
}

.mps-add-to-compare.added {
    background: linear-gradient(135deg, #F44336, #C62828);
    box-shadow: 0 4px 10px rgba(244, 67, 54, 0.2);
}

.mps-add-to-compare.added:hover {
    background: linear-gradient(135deg, #E53935, #B71C1C);
    box-shadow: 0 6px 12px rgba(244, 67, 54, 0.3);
}

.mps-add-to-compare i {
    margin-left: 8px;
    font-size: 18px;
}

/* Comparison List Panel */
.mps-comparison-list {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    background-color: rgba(255, 255, 255, 0.98);
    box-shadow: 0 -2px 15px rgba(0, 0, 0, 0.15);
    z-index: 999999 !important; /* زيادة قيمة z-index أكثر لضمان ظهوره فوق جميع العناصر */
    display: none;
    padding: 15px;
    border-top: 3px solid #d32f2f;
    max-height: 70vh;
    overflow-y: auto;
    transition: all 0.3s ease;
    transform: translateZ(0);
    margin: 0 !important; /* إزالة أي هوامش قد تؤثر على الموضع */
    padding-bottom: env(safe-area-inset-bottom) !important; /* دعم الأجهزة الحديثة مثل iPhone X وما بعده */
}

.mps-comparison-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.mps-comparison-header h3 {
    font-size: 18px;
    margin: 0;
    color: #d32f2f;
    font-weight: 700;
}

.mps-close-comparison {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    font-size: 24px;
    padding: 0;
}

.mps-close-comparison:hover {
    color: #d32f2f;
}

.mps-compare-items {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 10px;
    margin-bottom: 15px;
    gap: 15px;
}

.mps-compare-item {
    flex: 0 0 120px;
    background-color: #fff;
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.2s ease;
    border: 1px solid #eee;
}

.mps-compare-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateY(-3px);
}

.mps-compare-item img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin-bottom: 10px;
    background-color: #f9f9f9;
    border-radius: 4px;
    padding: 5px;
    display: block;
}

/* Flying element animation */
.flying-phone-element {
    position: fixed;
    z-index: 10000;
    width: 60px;
    height: 60px;
    background-color: #d32f2f;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: 0 0 15px rgba(211, 47, 47, 0.6);
    pointer-events: none;
    transition: transform 0.2s;
}

.flying-phone-element i {
    font-size: 24px;
}

/* Improved animation for newly added items */
@keyframes highlightNew {
    0% { transform: scale(1); box-shadow: 0 0 0 rgba(211, 47, 47, 0); }
    25% { transform: scale(1.08); box-shadow: 0 0 20px rgba(211, 47, 47, 0.7); }
    50% { transform: scale(1.05); box-shadow: 0 0 15px rgba(211, 47, 47, 0.5); }
    75% { transform: scale(1.03); box-shadow: 0 0 10px rgba(211, 47, 47, 0.3); }
    100% { transform: scale(1); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08); }
}

.mps-compare-item.new-item {
    animation: highlightNew 1.2s ease;
}

/* Improve compare actions buttons */
.mps-compare-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 10px;
    position: sticky;
    bottom: 0;
    background: rgba(255, 255, 255, 0.98);
    padding: 10px 0;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    z-index: 2;
}

.mps-compare-phones, 
.mps-clear-compare {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mps-compare-phones {
    background: linear-gradient(135deg, #2196F3, #1565C0);
    color: white;
    flex: 2;
    box-shadow: 0 4px 10px rgba(33, 150, 243, 0.3);
}

.mps-compare-phones:hover {
    background: linear-gradient(135deg, #1E88E5, #0D47A1);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(33, 150, 243, 0.4);
}

.mps-compare-phones i, 
.mps-clear-compare i {
    margin-left: 8px;
    font-size: 20px;
}

.mps-compare-phones:disabled {
    opacity: 0.7;
    transform: none;
    cursor: not-allowed;
}

.mps-clear-compare {
    background-color: #f5f5f5;
    color: #555;
    flex: 1;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.mps-clear-compare:hover {
    background-color: #e0e0e0;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* Toggle for the comparison list */
.mps-comparison-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(135deg, #2196F3, #1565C0);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(33, 150, 243, 0.4);
    z-index: 9998;
    border: none;
    transition: all 0.3s ease;
}

.mps-comparison-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(33, 150, 243, 0.5);
}

.mps-comparison-toggle:active {
    transform: scale(0.95);
}

.mps-comparison-toggle i {
    font-size: 28px;
}

.mps-comparison-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: #F44336;
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: bold;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* Comparison Page */
#mps-comparison-page {
    direction: rtl;
    margin: 30px 0;
}

/* Recent Phones Section */
.mps-recent-phones-container {
    margin-top: 40px;
    margin-bottom: 20px;
    padding-top: 20px;
    border-top: 2px solid #eee;
    clear: both;
    display: block;
    width: 100%;
}

#mps-comparison-page .mps-recent-phones-container {
    margin-top: 60px;
    padding: 30px;
    background-color: #f9f9f9;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    border: 1px solid #e0e0e0;
}

.mps-recent-phones-title {
    font-size: 22px;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #dee2e6;
    color: #333;
    font-weight: 600;
    position: relative;
    text-align: center;
}

#mps-comparison-page .mps-recent-phones-title {
    font-size: 28px;
    color: #d32f2f;
    text-align: center;
    margin-bottom: 30px;
}

.mps-recent-phones-title:after {
    content: "";
    position: absolute;
    bottom: -1px;
    right: 0;
    width: 60px;
    height: 3px;
    background-color: #d32f2f;
}

#mps-comparison-page .mps-recent-phones-title:after {
    width: 150px;
    height: 4px;
    right: 50%;
    transform: translateX(50%);
    background-color: #d32f2f;
}

.mps-recent-phones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
}

#mps-comparison-page .mps-recent-phones-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.mps-recent-phone-item {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 3px 8px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

#mps-comparison-page .mps-recent-phone-item {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #eee;
}

.mps-recent-phone-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.12);
}

#mps-comparison-page .mps-recent-phone-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.mps-recent-phone-image {
    height: 140px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8f9fa;
    padding: 10px;
    position: relative;
}

#mps-comparison-page .mps-recent-phone-image {
    height: 160px;
}

.mps-recent-phone-image img {
    max-height: 120px;
    max-width: 100%;
    object-fit: contain;
}

#mps-comparison-page .mps-recent-phone-image img {
    max-height: 140px;
}

.mps-review-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, #FF9800, #F57C00);
    color: white;
    font-size: 12px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    z-index: 2;
}

.mps-recent-phone-placeholder {
    width: 80px;
    height: 120px;
    background-color: #f0f0f0;
    border-radius: 8px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="%23aaaaaa"><path d="M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/><path d="M14.14 11.86l-3 3.87L9 13.14 6 17h12l-3.86-5.14z"/></svg>');
    background-repeat: no-repeat;
    background-position: center;
}

.mps-recent-phone-info {
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #f0f0f0;
}

#mps-comparison-page .mps-recent-phone-info {
    padding: 15px;
}

.mps-recent-phone-title {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    text-decoration: none;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-left: 10px;
}

#mps-comparison-page .mps-recent-phone-title {
    font-size: 16px;
    font-weight: 700;
}

.mps-recent-phone-title:hover {
    color: #2196F3;
    text-decoration: underline;
}

.mps-recent-phone-add {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #4CAF50, #2E7D32);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(76, 175, 80, 0.3);
    flex-shrink: 0;
}

.mps-recent-phone-add:hover {
    transform: scale(1.1);
    box-shadow: 0 3px 8px rgba(76, 175, 80, 0.4);
}

.mps-recent-phone-add.added {
    background: linear-gradient(135deg, #F44336, #C62828);
    box-shadow: 0 2px 5px rgba(244, 67, 54, 0.3);
}

.mps-recent-phone-add.added:hover {
    background: linear-gradient(135deg, #E53935, #B71C1C);
    box-shadow: 0 3px 8px rgba(244, 67, 54, 0.4);
}

.mps-recent-phone-add i {
    font-size: 18px;
}

/* Loading indicator for recent phones */
.mps-recent-phones-loading {
    text-align: center;
    padding: 30px;
    font-size: 18px;
    color: #666;
    font-style: italic;
}

/* Responsive adjustments for recent phones */
@media (max-width: 768px) {
    .mps-recent-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 10px;
    }
    
    .mps-recent-phone-image {
        height: 120px;
    }
    
    .mps-recent-phone-image img {
        max-height: 100px;
    }
    
    .mps-recent-phone-info {
        padding: 8px;
    }
    
    .mps-recent-phone-title {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .mps-recent-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 8px;
    }
    
    .mps-recent-phone-image {
        height: 100px;
    }
    
    .mps-recent-phone-image img {
        max-height: 80px;
    }
    
    .mps-recent-phone-add {
        width: 26px;
        height: 26px;
    }
    
    .mps-recent-phone-add i {
        font-size: 16px;
    }
}

.mps-comparison-notice {
    text-align: center;
    padding: 40px;
    background-color: #f8f9fa;
    border-radius: 12px;
    margin-bottom: 30px;
    color: #666;
    border: 1px dashed #dee2e6;
}

.mps-empty-comparison {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.mps-empty-comparison i {
    font-size: 60px;
    color: #adb5bd;
    margin-bottom: 15px;
}

.mps-empty-comparison h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: #495057;
}

.mps-empty-comparison p {
    font-size: 16px;
    color: #6c757d;
    max-width: 600px;
    margin: 0 auto;
}

.mps-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 30px;
    font-size: 18px;
    color: #555;
    animation: pulse 1.5s infinite;
}

.mps-loading:before {
    content: '';
    width: 30px;
    height: 30px;
    border: 3px solid #e0e0e0;
    border-top: 3px solid #2196F3;
    border-radius: 50%;
    margin-left: 15px;
    animation: spin 1s linear infinite;
}

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

@keyframes pulse {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 20px, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

/* Retry button */
.mps-retry-button {
    display: inline-block;
    background: linear-gradient(135deg, #2196F3, #1565C0);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    margin-top: 15px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(33, 150, 243, 0.2);
    animation: fadeInUp 0.5s ease-out;
}

.mps-retry-button:hover {
    background: linear-gradient(135deg, #1E88E5, #0D47A1);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(33, 150, 243, 0.3);
}

.mps-retry-button:active {
    transform: translateY(1px);
}

/* Error message */
.mps-error {
    padding: 15px;
    background-color: #ffebee;
    border: 1px solid #ffcdd2;
    border-radius: 8px;
    color: #c62828;
    text-align: center;
    margin: 20px 0;
}

/* Swipe hint for mobile */
.mps-swipe-hint {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    background-color: rgba(33, 150, 243, 0.1);
    border-radius: 8px;
    color: #1976d2;
    margin-bottom: 15px;
    animation: pulse 2s infinite;
}

.mps-swipe-hint i {
    margin-left: 8px;
    font-size: 18px;
}

@keyframes pulse {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}

/* Comparison Table Container */
.mps-comparison-table-container {
    margin: 30px 0;
    position: relative;
    overflow-x: auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 5px 30px rgba(0,0,0,0.08);
    border: 1px solid rgba(0,0,0,0.08);
}

/* Comparison Table */
.mps-comparison-table {
    border-collapse: separate;
    border-spacing: 0;
    width: 100%;
    min-width: 100%;
    font-size: 15px;
    overflow: hidden;
}

/* Category Row */
.mps-category-row th {
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
    color: white;
    font-size: 16px;
    font-weight: 700;
    padding: 15px 20px;
    text-align: right;
    position: relative;
    border-top: 1px solid rgba(0,0,0,0.05);
}

/* Feature Row */
.mps-feature-row th {
    background-color: #f9f9f9;
    font-weight: 600;
    text-align: right;
    padding: 12px 20px;
    border-top: 1px solid #eee;
    width: 200px;
    min-width: 200px;
    position: sticky;
    left: 0;
    box-shadow: 5px 0 8px -3px rgba(0,0,0,0.05);
    z-index: 2;
}

.mps-feature-row td {
    padding: 12px 15px;
    text-align: center;
    border-top: 1px solid #eee;
    min-width: 140px;
    transition: all 0.3s ease;
}

/* Phone Header */
.mps-phone-header {
    padding: 20px 15px;
    text-align: center;
    vertical-align: top;
    background-color: #fff;
    min-width: 140px;
    position: relative;
    border-bottom: 2px solid #f44336;
}

.mps-phone-header:hover {
    background-color: #fafafa;
}

.mps-phone-header img {
    max-width: 120px;
    max-height: 150px;
    margin: 0 auto 10px;
    display: block;
    object-fit: contain;
    transition: transform 0.3s ease;
    padding: 5px;
}

.mps-phone-header:hover img {
    transform: translateY(-5px);
}

.mps-phone-header-link {
    font-weight: 700;
    color: #333;
    text-decoration: none;
    display: block;
    margin-top: 10px;
    transition: color 0.3s ease;
}

.mps-phone-header-link:hover {
    color: #f44336;
}

/* Highlighting */
.mps-highlight-better {
    background-color: rgba(76, 175, 80, 0.1);
    position: relative;
    font-weight: 600;
    color: #2e7d32;
}

.mps-highlight-better::after {
    content: '⭐';
    font-size: 10px;
    position: absolute;
    top: 4px;
    right: 4px;
    color: #2e7d32;
}

.mps-highlight-worse {
    background-color: rgba(244, 67, 54, 0.05);
    color: #777;
}

/* Row Hover Effect */
.mps-feature-row:hover td {
    background-color: rgba(0,0,0,0.02);
}

/* Swipe Hint */
.mps-swipe-hint {
    background: rgba(0,0,0,0.6);
    color: white;
    text-align: center;
    padding: 10px;
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 50px;
    z-index: 10;
    display: flex;
    align-items: center;
    font-size: 14px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    animation: fadeInOut 3s forwards;
    pointer-events: none;
}

.mps-swipe-hint i {
    margin-right: 8px;
    font-size: 20px;
}

@keyframes fadeInOut {
    0% { opacity: 0; }
    20% { opacity: 1; }
    80% { opacity: 1; }
    100% { opacity: 0; }
}

/* New comparison features */
.mps-specs-difference {
    margin-top: 8px;
    font-size: 12px;
    color: #4CAF50;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mps-specs-difference.negative {
    color: #F44336;
}

.mps-specs-difference i {
    font-size: 14px;
    margin-left: 4px;
}

/* Zebra striping for easier reading */
.mps-feature-row:nth-child(even) {
    background-color: rgba(0,0,0,0.01);
}

/* Feature importance indicator */
.mps-feature-important th::before {
    content: "•";
    color: #f44336;
    margin-left: 5px;
    font-size: 20px;
    vertical-align: middle;
    display: inline-block;
}

/* Tooltip for extra information */
.mps-feature-info {
    position: relative;
    cursor: help;
}

.mps-feature-info::after {
    content: "i";
    display: inline-block;
    width: 16px;
    height: 16px;
    background: #2196F3;
    color: white;
    border-radius: 50%;
    font-size: 12px;
    line-height: 16px;
    text-align: center;
    margin-right: 6px;
    font-style: italic;
    font-weight: 700;
}

.mps-feature-info:hover::before {
    content: attr(data-tooltip);
    position: absolute;
    background: rgba(33, 150, 243, 0.9);
    color: white;
    padding: 8px 12px;
    border-radius: 5px;
    font-size: 13px;
    width: 200px;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-bottom: 10px;
    z-index: 100;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    text-align: center;
    line-height: 1.5;
}

/* Custom scroll bar for comparison table */
.mps-comparison-table-container::-webkit-scrollbar {
    height: 8px;
    background-color: #f5f5f5;
    border-radius: 4px;
}

.mps-comparison-table-container::-webkit-scrollbar-thumb {
    background: linear-gradient(to left, #f44336, #d32f2f);
    border-radius: 4px;
}

.mps-comparison-table-container::-webkit-scrollbar-track {
    background-color: #f5f5f5;
    border-radius: 4px;
}

/* Selected Phones Box - تم إزالته بناءً على طلب المستخدم */
.mps-selected-phones-box {
    display: none !important; /* إخفاء المربع بشكل كامل */
}

.mps-selected-phones-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #333;
    text-align: center;
    position: relative;
    padding-bottom: 15px;
}

.mps-selected-phones-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(to right, #f44336, #d32f2f);
    border-radius: 3px;
}

.mps-selected-phones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

/* Improved item design */
.mps-selected-phone-item {
    background-color: #ffffff;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    position: relative;
    border: 1px solid #f0f0f0;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.03);
}

.mps-selected-phone-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 25px rgba(0,0,0,0.1);
    border-color: rgba(244, 67, 54, 0.2);
}

.mps-selected-phone-item.highlight-new {
    animation: pulseHighlight 2s infinite;
}

@keyframes pulseHighlight {
    0% {
        box-shadow: 0 5px 15px rgba(244, 67, 54, 0.1);
    }
    50% {
        box-shadow: 0 5px 25px rgba(244, 67, 54, 0.3);
    }
    100% {
        box-shadow: 0 5px 15px rgba(244, 67, 54, 0.1);
    }
}

/* More modern view comparison button */
.mps-view-comparison-button {
    display: block;
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    box-shadow: 0 8px 15px rgba(211, 47, 47, 0.2);
    position: relative;
    overflow: hidden;
}

.mps-view-comparison-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.2) 50%, transparent 100%);
    transition: all 0.6s;
}

.mps-view-comparison-button:hover::before {
    left: 100%;
}

.mps-view-comparison-button:hover {
    background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(211, 47, 47, 0.3);
}

/* Responsive styles */
@media (max-width: 768px) {
    .mps-comparison-table-container {
        margin: 20px -15px;
        border-radius: 0;
        width: calc(100% + 30px);
    }
    
    .mps-category-row th {
        padding: 12px 15px;
        font-size: 15px;
    }
    
    .mps-feature-row th {
        padding: 10px 15px;
        width: 160px;
        min-width: 160px;
        font-size: 14px;
    }
    
    .mps-feature-row td {
        padding: 10px;
        font-size: 13px;
    }
    
    .mps-phone-header {
        padding: 15px 10px;
        min-width: 120px;
    }
    
    .mps-phone-header img {
        max-width: 100px;
        max-height: 130px;
    }
    
    .mps-selected-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 15px;
    }
    
    .mps-selected-phone-item {
        padding: 15px 10px;
    }
    
    .mps-selected-phones-title {
        font-size: 20px;
    }
    
    .mps-view-comparison-button {
        padding: 15px;
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .mps-feature-row th {
        width: 140px;
        min-width: 140px;
        font-size: 13px;
        padding: 8px 12px;
    }
    
    .mps-feature-row td {
        padding: 8px;
        font-size: 12px;
        min-width: 110px;
    }
    
    .mps-phone-header {
        padding: 12px 8px;
        min-width: 110px;
    }
    
    .mps-phone-header img {
        max-width: 80px;
        max-height: 110px;
    }
    
    .mps-selected-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 10px;
    }
    
    .mps-selected-phone-item {
        padding: 10px;
    }
    
    .mps-selected-phones-title {
        font-size: 18px;
    }
}

/* Print styling for comparison tables */
@media print {
    .mps-comparison-table-container {
        overflow: visible;
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .mps-feature-row th {
        position: relative;
        box-shadow: none;
    }
    
    .mps-category-row th {
        background: #f9f9f9 !important;
        color: #000 !important;
        border-top: 2px solid #ddd;
    }
    
    .mps-highlight-better::after {
        display: none;
    }
    
    .mps-highlight-better {
        background-color: rgba(0,0,0,0.05) !important;
        color: #000 !important;
    }
    
    .mps-swipe-hint {
        display: none !important;
    }
}

/* Improved "Add to Compare" button */
.mps-add-to-compare {
    background: linear-gradient(135deg, #4CAF50, #2E7D32);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 12px 22px;
    font-size: 15px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.2);
    position: relative;
    overflow: hidden;
}

.mps-add-to-compare::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.2) 50%, transparent 100%);
    transition: all 0.6s;
}

.mps-add-to-compare:hover::before {
    left: 100%;
}

.mps-add-to-compare:hover {
    background: linear-gradient(135deg, #43A047, #1B5E20);
    transform: translateY(-3px);
    box-shadow: 0 6px 18px rgba(76, 175, 80, 0.3);
}

.mps-add-to-compare.added {
    background: linear-gradient(135deg, #F44336, #C62828);
    box-shadow: 0 4px 15px rgba(244, 67, 54, 0.2);
}

.mps-add-to-compare.added:hover {
    background: linear-gradient(135deg, #E53935, #B71C1C);
    box-shadow: 0 6px 18px rgba(244, 67, 54, 0.3);
}

.mps-add-to-compare i {
    margin-left: 8px;
    font-size: 18px;
    transition: transform 0.3s;
}

.mps-add-to-compare:hover i {
    transform: translateY(-2px);
}

/* Improved Comparison List panel */
.mps-comparison-list {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    background-color: rgba(255, 255, 255, 0.98);
    box-shadow: 0 -5px 25px rgba(0, 0, 0, 0.15);
    z-index: 999999 !important;
    display: none;
    padding: 20px;
    border-top: 3px solid #f44336;
    max-height: 70vh;
    overflow-y: auto;
    transition: all 0.3s ease;
    transform: translateZ(0);
    margin: 0 !important;
    padding-bottom: calc(20px + env(safe-area-inset-bottom)) !important;
    border-radius: 20px 20px 0 0;
}

.mps-comparison-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.mps-comparison-header h3 {
    font-size: 20px;
    margin: 0;
    color: #f44336;
    font-weight: 700;
}

.mps-close-comparison {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    font-size: 24px;
    padding: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.mps-close-comparison:hover {
    background-color: #f5f5f5;
    color: #f44336;
}

.mps-compare-items {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 15px;
    margin-bottom: 20px;
    gap: 15px;
}

.mps-compare-item {
    flex: 0 0 130px;
    background-color: #fff;
    border-radius: 12px;
    padding: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.3s ease;
    border: 1px solid #eee;
}

.mps-compare-item:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    transform: translateY(-5px);
}

.mps-compare-item img {
    width: 90px;
    height: 90px;
    object-fit: contain;
    margin-bottom: 12px;
    background-color: #f9f9f9;
    border-radius: 8px;
    padding: 5px;
    display: block;
    transition: transform 0.3s;
}

.mps-compare-item:hover img {
    transform: scale(1.05);
}

/* Toggle for the comparison list */
.mps-comparison-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: linear-gradient(135deg, #2196F3, #1565C0);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(33, 150, 243, 0.4);
    z-index: 9998;
    border: none;
    transition: all 0.3s ease;
}

.mps-comparison-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(33, 150, 243, 0.5);
}

.mps-comparison-toggle:active {
    transform: scale(0.95);
}

.mps-comparison-toggle i {
    font-size: 28px;
}

.mps-comparison-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: #F44336;
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: bold;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* Comparison Page */
#mps-comparison-page {
    direction: rtl;
    margin: 30px 0;
}

/* Recent Phones Section */
.mps-recent-phones-container {
    margin-top: 40px;
    margin-bottom: 20px;
    padding-top: 20px;
    border-top: 2px solid #eee;
    clear: both;
    display: block;
    width: 100%;
}

#mps-comparison-page .mps-recent-phones-container {
    margin-top: 60px;
    padding: 30px;
    background-color: #f9f9f9;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    border: 1px solid #e0e0e0;
}

.mps-recent-phones-title {
    font-size: 22px;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #dee2e6;
    color: #333;
    font-weight: 600;
    position: relative;
    text-align: center;
}

#mps-comparison-page .mps-recent-phones-title {
    font-size: 28px;
    color: #d32f2f;
    text-align: center;
    margin-bottom: 30px;
}

.mps-recent-phones-title:after {
    content: "";
    position: absolute;
    bottom: -1px;
    right: 0;
    width: 60px;
    height: 3px;
    background-color: #d32f2f;
}

#mps-comparison-page .mps-recent-phones-title:after {
    width: 150px;
    height: 4px;
    right: 50%;
    transform: translateX(50%);
    background-color: #d32f2f;
}

.mps-recent-phones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
}

#mps-comparison-page .mps-recent-phones-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.mps-recent-phone-item {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 3px 8px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

#mps-comparison-page .mps-recent-phone-item {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #eee;
}

.mps-recent-phone-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.12);
}

#mps-comparison-page .mps-recent-phone-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.mps-recent-phone-image {
    height: 140px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8f9fa;
    padding: 10px;
    position: relative;
}

#mps-comparison-page .mps-recent-phone-image {
    height: 160px;
}

.mps-recent-phone-image img {
    max-height: 120px;
    max-width: 100%;
    object-fit: contain;
}

#mps-comparison-page .mps-recent-phone-image img {
    max-height: 140px;
}

.mps-review-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, #FF9800, #F57C00);
    color: white;
    font-size: 12px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    z-index: 2;
}

.mps-recent-phone-placeholder {
    width: 80px;
    height: 120px;
    background-color: #f0f0f0;
    border-radius: 8px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="%23aaaaaa"><path d="M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/><path d="M14.14 11.86l-3 3.87L9 13.14 6 17h12l-3.86-5.14z"/></svg>');
    background-repeat: no-repeat;
    background-position: center;
}

.mps-recent-phone-info {
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #f0f0f0;
}

#mps-comparison-page .mps-recent-phone-info {
    padding: 15px;
}

.mps-recent-phone-title {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    text-decoration: none;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-left: 10px;
}

#mps-comparison-page .mps-recent-phone-title {
    font-size: 16px;
    font-weight: 700;
}

.mps-recent-phone-title:hover {
    color: #2196F3;
    text-decoration: underline;
}

.mps-recent-phone-add {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #4CAF50, #2E7D32);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(76, 175, 80, 0.3);
    flex-shrink: 0;
}

.mps-recent-phone-add:hover {
    transform: scale(1.1);
    box-shadow: 0 3px 8px rgba(76, 175, 80, 0.4);
}

.mps-recent-phone-add.added {
    background: linear-gradient(135deg, #F44336, #C62828);
    box-shadow: 0 2px 5px rgba(244, 67, 54, 0.3);
}

.mps-recent-phone-add.added:hover {
    background: linear-gradient(135deg, #E53935, #B71C1C);
    box-shadow: 0 3px 8px rgba(244, 67, 54, 0.4);
}

.mps-recent-phone-add i {
    font-size: 18px;
}

/* Loading indicator for recent phones */
.mps-recent-phones-loading {
    text-align: center;
    padding: 30px;
    font-size: 18px;
    color: #666;
    font-style: italic;
}

/* Responsive adjustments for recent phones */
@media (max-width: 768px) {
    .mps-recent-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 10px;
    }
    
    .mps-recent-phone-image {
        height: 120px;
    }
    
    .mps-recent-phone-image img {
        max-height: 100px;
    }
    
    .mps-recent-phone-info {
        padding: 8px;
    }
    
    .mps-recent-phone-title {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .mps-recent-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 8px;
    }
    
    .mps-recent-phone-image {
        height: 100px;
    }
    
    .mps-recent-phone-image img {
        max-height: 80px;
    }
    
    .mps-recent-phone-add {
        width: 26px;
        height: 26px;
    }
    
    .mps-recent-phone-add i {
        font-size: 16px;
    }
}

.mps-comparison-notice {
    text-align: center;
    padding: 40px;
    background-color: #f8f9fa;
    border-radius: 12px;
    margin-bottom: 30px;
    color: #666;
    border: 1px dashed #dee2e6;
}

.mps-empty-comparison {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.mps-empty-comparison i {
    font-size: 60px;
    color: #adb5bd;
    margin-bottom: 15px;
}

.mps-empty-comparison h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: #495057;
}

.mps-empty-comparison p {
    font-size: 16px;
    color: #6c757d;
    max-width: 600px;
    margin: 0 auto;
}

.mps-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 30px;
    font-size: 18px;
    color: #555;
    animation: pulse 1.5s infinite;
}

.mps-loading:before {
    content: '';
    width: 30px;
    height: 30px;
    border: 3px solid #e0e0e0;
    border-top: 3px solid #2196F3;
    border-radius: 50%;
    margin-left: 15px;
    animation: spin 1s linear infinite;
}

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

@keyframes pulse {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 20px, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

/* Retry button */
.mps-retry-button {
    display: inline-block;
    background: linear-gradient(135deg, #2196F3, #1565C0);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    margin-top: 15px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(33, 150, 243, 0.2);
    animation: fadeInUp 0.5s ease-out;
}

.mps-retry-button:hover {
    background: linear-gradient(135deg, #1E88E5, #0D47A1);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(33, 150, 243, 0.3);
}

.mps-retry-button:active {
    transform: translateY(1px);
}

/* Error message */
.mps-error {
    padding: 15px;
    background-color: #ffebee;
    border: 1px solid #ffcdd2;
    border-radius: 8px;
    color: #c62828;
    text-align: center;
    margin: 20px 0;
}

/* Swipe hint for mobile */
.mps-swipe-hint {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    background-color: rgba(33, 150, 243, 0.1);
    border-radius: 8px;
    color: #1976d2;
    margin-bottom: 15px;
    animation: pulse 2s infinite;
}

.mps-swipe-hint i {
    margin-left: 8px;
    font-size: 18px;
}

@keyframes pulse {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}

.mps-comparison-table-container {
    overflow-x: auto;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
}

.mps-comparison-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.mps-comparison-table th,
.mps-comparison-table td {
    padding: 12px 18px;
    text-align: right;
    border: 1px solid #e0e0e0;
    vertical-align: middle;
}

.mps-comparison-table th {
    background-color: #f5f5f5;
    font-weight: 600;
}

.mps-phone-header {
    text-align: center;
    min-width: 180px;
    background-color: #f8f9fa;
    padding: 15px 10px;
}

.mps-phone-header-link {
    display: block;
    color: #2196F3;
    font-weight: 600;
    text-decoration: none;
    margin-top: 10px;
    transition: color 0.3s;
}

.mps-phone-header-link:hover {
    color: #0D47A1;
    text-decoration: underline;
}

.mps-phone-header img {
    max-width: 140px;
    height: auto;
    margin-bottom: 15px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s;
    object-fit: contain;
}

/* Placeholder for missing header images */
.mps-phone-header:not(:has(img:not([style*="display: none"]))) {
    position: relative;
}

.mps-phone-header:not(:has(img:not([style*="display: none"]))):before {
    content: '';
    display: block;
    width: 100px;
    height: 120px;
    margin: 0 auto 15px;
    background-color: #f0f0f0;
    border-radius: 10px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="36" height="36" viewBox="0 0 24 24" fill="%23aaaaaa"><path d="M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/><path d="M14.14 11.86l-3 3.87L9 13.14 6 17h12l-3.86-5.14z"/></svg>');
    background-repeat: no-repeat;
    background-position: center;
}

.mps-phone-header img:hover {
    transform: scale(1.05);
}

.mps-category-row {
    background: linear-gradient(to left, #e0f7fa, #bbdefb);
}

.mps-category-row th {
    font-size: 17px;
    color: #0288d1;
    text-align: right;
    padding: 15px 18px;
    font-weight: 700;
    text-shadow: 0 1px 0 rgba(255,255,255,0.8);
}

.mps-feature-row:nth-child(even) {
    background-color: #f9f9f9;
}

.mps-feature-row:hover {
    background-color: #f0f7ff;
}

/* Highlight differences */
.mps-highlight-better {
    background-color: rgba(76, 175, 80, 0.15);
    font-weight: bold;
    position: relative;
}

.mps-highlight-better:after {
    content: '✓';
    position: absolute;
    top: 5px;
    left: 5px;
    color: #4CAF50;
    font-weight: bold;
    font-size: 12px;
}

.mps-highlight-worse {
    background-color: rgba(244, 67, 54, 0.1);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .mps-comparison-list {
        padding: 15px;
        max-height: 85vh;
        border-radius: 15px 15px 0 0;
        box-shadow: 0 -5px 25px rgba(0, 0, 0, 0.2);
    }
    
    /* تحسين التفاعل على الأجهزة المحمولة */
    .mps-comparison-list:before {
        content: '';
        width: 40px;
        height: 4px;
        background: rgba(0, 0, 0, 0.2);
        border-radius: 2px;
        position: absolute;
        top: 8px;
        left: 50%;
        transform: translateX(-50%);
    }
    
    .mps-comparison-header h3 {
        font-size: 18px;
    }
    
    .mps-compare-items {
        flex-direction: column;
        margin-bottom: 15px;
    }
    
    .mps-compare-item {
        max-width: 100%;
    }

    .mps-compare-actions {
        flex-direction: column;
    }

    .mps-compare-phones, 
    .mps-clear-compare {
        width: 100%;
        padding: 12px 10px;
    }
    
    .mps-phone-header {
        min-width: 140px;
        padding: 10px 5px;
    }
    
    .mps-phone-header img {
        max-width: 100px;
    }
    
    .mps-comparison-toggle {
        width: 50px;
        height: 50px;
        bottom: 15px;
        right: 15px;
    }
    
    .mps-comparison-toggle i {
        font-size: 24px;
    }
    
    .mps-comparison-table th,
    .mps-comparison-table td {
        padding: 8px 10px;
        font-size: 14px;
    }
    
    .mps-category-row th {
        font-size: 15px;
        padding: 10px;
    }
    
    .mps-empty-comparison h3 {
        font-size: 18px;
    }
    
    .mps-empty-comparison p {
        font-size: 14px;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .mps-comparison-list {
        max-height: 90vh;
        padding: 12px;
    }
    
    .mps-comparison-toggle {
        bottom: 10px;
        right: 10px;
        width: 45px;
        height: 45px;
    }
    
    .mps-comparison-count {
        width: 20px;
        height: 20px;
        font-size: 11px;
    }
    
    .mps-compare-item {
        padding: 8px 10px;
    }
    
    .mps-compare-item img {
        width: 40px;
        height: 40px;
        margin-left: 8px;
    }
    
    .mps-phone-header {
        min-width: 100px;
    }
    
    .mps-phone-header img {
        max-width: 80px;
    }

    .mps-add-to-compare {
        padding: 8px 15px;
        font-size: 14px;
    }
    
    .mps-add-to-compare i {
        font-size: 16px;
    }
    
    .mps-swipe-hint {
        padding: 8px;
        font-size: 13px;
    }
    
    .mps-swipe-hint i {
        font-size: 16px;
    }
} 

.mps-compare-item-title {
    font-size: 15px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #444;
    text-align: center;
    margin-bottom: 8px;
    width: 100%;
}

.mps-remove-from-compare {
    background: none;
    border: none;
    color: #F44336;
    cursor: pointer;
    font-size: 20px;
    padding: 0;
    transition: transform 0.2s;
    position: absolute;
    top: 5px;
    right: 5px;
}

.mps-remove-from-compare:hover {
    transform: scale(1.2);
}

/* Fix for image not displaying */
.mps-compare-item img[src=""] {
    display: none;
}

.mps-compare-item img:not([src]) {
    display: none;
}

/* Placeholder for missing images */
.mps-compare-item:not(:has(img:not([style*="display: none"]))) {
    padding-top: 15px;
}

.mps-compare-item:not(:has(img:not([style*="display: none"]))):before {
    content: '';
    display: block;
    width: 80px;
    height: 80px;
    background-color: #f0f0f0;
    border-radius: 4px;
    margin-bottom: 10px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="%23aaaaaa"><path d="M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/><path d="M14.14 11.86l-3 3.87L9 13.14 6 17h12l-3.86-5.14z"/></svg>');
    background-repeat: no-repeat;
    background-position: center;
} 

/* Phone search system styles */
.mps-phone-search-container {
    margin: 20px 0;
    position: relative;
}

.mps-phone-search-input {
    width: 100%;
    padding: 12px 15px;
    padding-left: 45px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    direction: rtl;
}

.mps-phone-search-input:focus {
    border-color: #d32f2f;
    box-shadow: 0 0 10px rgba(211, 47, 47, 0.2);
    outline: none;
}

.mps-phone-search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    pointer-events: none;
}

.mps-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
    max-height: 400px;
    overflow-y: auto;
    z-index: 1000;
    margin-top: 5px;
    display: none;
    border: 1px solid #ddd;
}

.mps-search-results.active {
    display: block;
}

.mps-search-result-item {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background-color 0.2s;
}

.mps-search-result-item:last-child {
    border-bottom: none;
}

.mps-search-result-item:hover {
    background-color: #f9f9f9;
}

.mps-search-result-image {
    width: 50px;
    height: 50px;
    margin-left: 15px;
    object-fit: contain;
    background-color: #f5f5f5;
    border-radius: 4px;
    padding: 5px;
}

.mps-search-result-title {
    flex: 1;
    font-weight: 600;
    color: #333;
}

.mps-search-result-add {
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.mps-search-result-add:hover {
    background-color: #388E3C;
    transform: scale(1.1);
}

.mps-search-result-add.added {
    background-color: #F44336;
}

.mps-no-results {
    padding: 15px;
    text-align: center;
    color: #666;
    font-style: italic;
}

/* Improved comparison list appearance */
.mps-comparison-list {
    animation: slideUp 0.3s ease-out;
    border-radius: 10px 10px 0 0;
    position: fixed !important; /* ضمان التثبيت */
    bottom: 0 !important; /* ضمان الظهور في أسفل الشاشة */
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
} 

/* Selected phones box - enhanced design */
.mps-selected-phones-box {
    background: linear-gradient(135deg, #ffffff 0%, #f7f7f7 100%);
    border: none;
    border-radius: 12px;
    padding: 25px;
    margin: 30px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08), 0 1px 3px rgba(0,0,0,0.1);
    position: relative;
    overflow: hidden;
}

.mps-selected-phones-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, #d32f2f 0%, #f44336 100%);
}

.mps-selected-phones-title {
    font-size: 22px;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
    text-align: center;
    border-bottom: 1px solid #eaeaea;
    padding-bottom: 15px;
    position: relative;
}

.mps-selected-phones-title::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background-color: #d32f2f;
    border-radius: 3px;
}

.mps-selected-phones-counter {
    position: absolute;
    top: -12px;
    right: -12px;
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 18px;
    box-shadow: 0 4px 8px rgba(211, 47, 47, 0.3);
    z-index: 2;
    transition: all 0.3s ease;
}

.mps-selected-phones-counter:hover {
    transform: scale(1.1);
}

.mps-selected-phones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.mps-selected-phone-item {
    background-color: #ffffff;
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    position: relative;
    border: 1px solid #f0f0f0;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.03);
}

.mps-selected-phone-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
    border-color: #e0e0e0;
}

.mps-selected-phone-item:hover .mps-selected-phone-image {
    transform: scale(1.05);
}

.mps-selected-phone-image {
    width: 90px;
    height: 90px;
    object-fit: contain;
    margin: 0 auto 12px;
    display: block;
    transition: all 0.3s ease;
}

.mps-selected-phone-title {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.mps-selected-phone-item:hover .mps-selected-phone-title {
    color: #d32f2f;
}

.mps-selected-phone-remove {
    position: absolute;
    top: 8px;
    right: 8px;
    background-color: rgba(244, 67, 54, 0.9);
    color: white;
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
    transition: all 0.3s;
    padding: 0;
    line-height: 1;
    opacity: 0;
    transform: scale(0.8);
}

.mps-selected-phone-item:hover .mps-selected-phone-remove {
    opacity: 1;
    transform: scale(1);
}

.mps-selected-phone-remove:hover {
    background-color: #d32f2f;
    transform: scale(1.2);
    box-shadow: 0 2px 8px rgba(211, 47, 47, 0.5);
}

.mps-selected-phone-remove i {
    font-size: 16px;
}

.mps-view-comparison-button {
    display: block;
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    box-shadow: 0 8px 15px rgba(211, 47, 47, 0.2);
    position: relative;
    overflow: hidden;
}

.mps-view-comparison-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.2) 50%, transparent 100%);
    transition: all 0.6s;
}

.mps-view-comparison-button:hover::before {
    left: 100%;
}

.mps-view-comparison-button:hover {
    background: linear-gradient(135deg, #c62828 0%, #e53935 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(211, 47, 47, 0.3);
}

.mps-view-comparison-button:active {
    transform: translateY(0);
    box-shadow: 0 5px 10px rgba(211, 47, 47, 0.3);
}

.mps-view-comparison-button i {
    margin-left: 10px;
    transition: all 0.3s;
}

.mps-view-comparison-button:hover i {
    transform: translateX(5px);
}

.mps-empty-selection {
    text-align: center;
    padding: 30px 20px;
    color: #777;
    font-style: italic;
    background-color: #f9f9f9;
    border-radius: 8px;
    border: 1px dashed #ddd;
}

/* Enhanced flying element */
.flying-phone-element {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
    box-shadow: 0 0 30px rgba(211, 47, 47, 0.6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: fixed;
    z-index: 9999;
    pointer-events: none;
}

.flying-phone-element i {
    font-size: 32px;
    color: white;
    animation: pulse 1s infinite alternate;
}

@keyframes pulse {
    0% { transform: scale(0.9); opacity: 0.8; }
    100% { transform: scale(1.1); opacity: 1; }
}

/* Newly added phone highlight animation */
.mps-selected-phone-item.highlight-new {
    animation: highlightNew 1.5s ease;
}

@keyframes highlightNew {
    0% { box-shadow: 0 0 0 0 rgba(211, 47, 47, 0.4); }
    70% { box-shadow: 0 0 0 15px rgba(211, 47, 47, 0); }
    100% { box-shadow: 0 0 0 0 rgba(211, 47, 47, 0); }
}

/* Phone search container - enhanced */
.mps-phone-search-container {
    position: relative;
    margin-bottom: 30px;
    transition: all 0.3s ease;
}

.mps-phone-search-input {
    width: 100%;
    padding: 16px 20px 16px 50px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.03);
}

.mps-phone-search-input:focus {
    border-color: #d32f2f;
    box-shadow: 0 5px 15px rgba(211, 47, 47, 0.1);
    outline: none;
}

.mps-phone-search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #777;
    font-size: 24px;
    transition: all 0.3s ease;
}

.mps-phone-search-input:focus + .mps-phone-search-icon {
    color: #d32f2f;
}

.mps-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-radius: 0 0 10px 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    z-index: 100;
    max-height: 400px;
    overflow-y: auto;
    border: 1px solid #e0e0e0;
    border-top: none;
    display: none;
}

/* Responsive styles */
@media (max-width: 768px) {
    .mps-selected-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 15px;
    }
    
    .mps-selected-phone-image {
        width: 70px;
        height: 70px;
    }
    
    .mps-selected-phones-title {
        font-size: 20px;
    }
    
    .mps-view-comparison-button {
        padding: 14px;
        font-size: 16px;
    }
    
    .mps-selected-phone-remove {
        opacity: 1;
        transform: scale(1);
    }
} 

/* Notification styles */
.mps-notification {
    position: fixed;
    bottom: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(51, 51, 51, 0.95);
    color: white;
    padding: 15px 25px;
    border-radius: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    font-size: 16px;
    font-weight: 500;
    z-index: 9999;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    opacity: 0;
    text-align: center;
    min-width: 250px;
    max-width: 80%;
}

.mps-notification-show {
    bottom: 30px;
    opacity: 1;
}

/* Counter animation */
@keyframes pulse-animation {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.3);
    }
    100% {
        transform: scale(1);
    }
}

.pulse-animation {
    animation: pulse-animation 0.5s ease;
}

/* Improved comparison list */
.mps-comparison-list {
    background: linear-gradient(135deg, #ffffff 0%, #f8f8f8 100%);
    border-bottom: none;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    border-radius: 0 0 15px 15px;
    padding: 20px;
    position: relative;
}

.mps-comparison-list::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    right: 0;
    height: 10px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.05), transparent);
    border-radius: 50%;
}

.mps-comparison-list-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
    position: relative;
}

.mps-comparison-list-title::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #d32f2f 0%, #f44336 100%);
    border-radius: 3px;
}

/* Improved comparison table */
.mps-comparison-table-container {
    margin: 30px 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.mps-comparison-table {
    border-collapse: separate;
    border-spacing: 0;
    width: 100%;
    background: white;
}

.mps-comparison-table thead th {
    background: linear-gradient(135deg, #f5f5f5 0%, #ffffff 100%);
    padding: 15px;
    text-align: center;
    border-bottom: 2px solid #eaeaea;
    position: sticky;
    top: 0;
    z-index: 10;
}

.mps-comparison-table th.mps-phone-header {
    min-width: 180px;
    padding: 20px 15px;
}

.mps-comparison-table th.mps-phone-header img {
    max-height: 120px;
    width: auto;
    margin: 0 auto 10px;
    display: block;
    transition: all 0.3s ease;
}

.mps-comparison-table th.mps-phone-header:hover img {
    transform: scale(1.05);
}

.mps-comparison-table .mps-phone-header-link {
    color: #333;
    font-weight: 600;
    text-decoration: none;
    display: block;
    margin-top: 10px;
    transition: all 0.3s ease;
}

.mps-comparison-table .mps-phone-header-link:hover {
    color: #d32f2f;
}

.mps-comparison-table .mps-category-row th {
    background: linear-gradient(90deg, #f5f5f5 0%, #ffffff 100%);
    color: #333;
    font-size: 18px;
    padding: 15px;
    text-align: right;
    border-bottom: 1px solid #eaeaea;
}

.mps-comparison-table .mps-feature-row th {
    background-color: #f9f9f9;
    padding: 12px 15px;
    text-align: right;
    border-bottom: 1px solid #eaeaea;
    font-weight: 600;
}

.mps-comparison-table .mps-feature-row td {
    padding: 12px 15px;
    text-align: center;
    border-bottom: 1px solid #eaeaea;
    transition: all 0.2s ease;
}

.mps-comparison-table .mps-feature-row:hover td {
    background-color: #f9f9f9;
}

.mps-comparison-table .highlight {
    background-color: rgba(211, 47, 47, 0.05);
    font-weight: 700;
    color: #d32f2f;
}

/* Swipe hint */
.mps-swipe-hint {
    background: rgba(51, 51, 51, 0.8);
    color: white;
    padding: 10px 15px;
    border-radius: 30px;
    display: inline-flex;
    align-items: center;
    position: absolute;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    animation: fadeInOut 3s forwards;
}

.mps-swipe-hint i {
    margin-right: 8px;
    animation: swipeAnimation 1.5s infinite;
}

@keyframes swipeAnimation {
    0% { transform: translateX(-5px); }
    50% { transform: translateX(5px); }
    100% { transform: translateX(-5px); }
}

@keyframes fadeInOut {
    0% { opacity: 0; }
    10% { opacity: 1; }
    80% { opacity: 1; }
    100% { opacity: 0; }
}

/* Improved search results */
.mps-search-results {
    padding: 10px;
}

.mps-search-result-item {
    display: flex;
    align-items: center;
    padding: 12px;
    border-bottom: 1px solid #eaeaea;
    transition: all 0.2s ease;
    cursor: pointer;
}

.mps-search-result-item:last-child {
    border-bottom: none;
}

.mps-search-result-item:hover {
    background-color: #f9f9f9;
}

.mps-search-result-image {
    width: 50px;
    height: 50px;
    object-fit: contain;
    margin-right: 15px;
}

.mps-search-result-title {
    flex: 1;
    font-weight: 600;
    color: #333;
}

.mps-search-result-add {
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
    color: white;
    border: none;
    border-radius: 30px;
    padding: 8px 15px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
}

.mps-search-result-add:hover {
    background: linear-gradient(135deg, #c62828 0%, #e53935 100%);
    box-shadow: 0 5px 10px rgba(211, 47, 47, 0.2);
    transform: translateY(-2px);
}

.mps-search-result-add i {
    margin-right: 5px;
    font-size: 16px;
}

.mps-search-result-add.added {
    background: #4CAF50;
}

.mps-search-result-add.added:hover {
    background: #388E3C;
}

/* Loading animation */
.mps-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
    font-size: 18px;
    color: #666;
    position: relative;
}

.mps-loading::before {
    content: '';
    display: inline-block;
    width: 24px;
    height: 24px;
    margin-right: 15px;
    border: 3px solid #ddd;
    border-top-color: #d32f2f;
    border-radius: 50%;
    animation: spin 1s infinite linear;
}

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

/* Search loading indicator */
.mps-search-loading {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%) scale(0);
    width: 20px;
    height: 20px;
    border: 2px solid #eee;
    border-top: 2px solid #d32f2f;
    border-radius: 50%;
    opacity: 0;
    transition: all 0.2s ease;
}

.mps-search-loading.active {
    animation: spin 0.8s linear infinite;
    opacity: 1;
    transform: translateY(-50%) scale(1);
}

.mps-phone-search-container.focused .mps-phone-search-input {
    border-color: #d32f2f;
    box-shadow: 0 5px 15px rgba(211, 47, 47, 0.1);
}

.mps-search-hint {
    padding: 15px;
    color: #777;
    text-align: center;
    font-style: italic;
}

.mps-search-error {
    padding: 15px;
    color: #d32f2f;
    text-align: center;
    font-style: italic;
}

.mps-search-no-results {
    padding: 20px;
    color: #777;
    text-align: center;
    font-style: italic;
    background-color: #f9f9f9;
    border-radius: 8px;
}

.mps-search-result-item.focused {
    background-color: #f5f5f5;
    outline: none;
    box-shadow: inset 0 0 0 2px #d32f2f;
}

/* Improve RTL support */
body.rtl .mps-phone-search-icon {
    left: auto;
    right: 15px;
}

body.rtl .mps-phone-search-input {
    padding: 16px 50px 16px 20px;
}

body.rtl .mps-search-loading {
    right: auto;
    left: 15px;
}

body.rtl .mps-search-result-image {
    margin-right: 0;
    margin-left: 15px;
}

body.rtl .mps-search-result-add i {
    margin-right: 0;
    margin-left: 5px;
}

body.rtl .mps-view-comparison-button i {
    margin-left: 0;
    margin-right: 10px;
}

body.rtl .mps-selected-phones-counter {
    right: auto;
    left: -12px;
}

body.rtl .mps-selected-phone-remove {
    right: auto;
    left: 8px;
}

body.rtl .mps-swipe-hint i {
    margin-right: 0;
    margin-left: 8px;
}

/* Floating comparison button */
.mps-comparison-floating-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(211, 47, 47, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    z-index: 999;
    transition: all 0.3s ease;
    transform: scale(0);
    opacity: 0;
}

.mps-comparison-floating-button.active {
    transform: scale(1);
    opacity: 1;
}

.mps-comparison-floating-button:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 20px rgba(211, 47, 47, 0.4);
}

.mps-comparison-floating-button i {
    font-size: 28px;
}

.mps-comparison-floating-button .mps-floating-counter {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: #333;
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

body.rtl .mps-comparison-floating-button {
    right: auto;
    left: 20px;
}

body.rtl .mps-comparison-floating-button .mps-floating-counter {
    right: auto;
    left: -5px;
}

/* Improved empty comparison message */
.mps-empty-comparison {
    background-color: #f9f9f9;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    margin: 20px 0;
    border: 1px dashed #ddd;
}

.mps-empty-comparison-icon {
    font-size: 60px;
    color: #ccc;
    margin-bottom: 20px;
    display: block;
}

.mps-empty-comparison-text {
    font-size: 18px;
    color: #777;
    margin-bottom: 20px;
}

.mps-empty-comparison-subtext {
    font-size: 14px;
    color: #999;
    margin-bottom: 20px;
}

/* Load more button */
.mps-load-more-button {
    display: block;
    width: 100%;
    padding: 14px;
    margin: 20px 0;
    background: linear-gradient(135deg, #f5f5f5 0%, #ffffff 100%);
    color: #333;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.mps-load-more-button:hover {
    background: linear-gradient(135deg, #eeeeee 0%, #f5f5f5 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.08);
    border-color: #d0d0d0;
}

.mps-load-more-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
}

.mps-load-more-button i {
    margin-left: 8px;
    transition: all 0.3s;
}

.mps-load-more-button:hover i {
    transform: translateY(2px);
}

.mps-load-more-button.loading {
    position: relative;
    color: transparent;
}

.mps-load-more-button.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin-top: -10px;
    margin-left: -10px;
    border: 3px solid #ddd;
    border-top-color: #d32f2f;
    border-radius: 50%;
    animation: spin 1s infinite linear;
}

body.rtl .mps-load-more-button i {
    margin-left: 0;
    margin-right: 8px;
}

/* Settings panel */
.mps-settings-panel {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.mps-settings-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eaeaea;
    position: relative;
}

.mps-settings-title::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #d32f2f 0%, #f44336 100%);
    border-radius: 3px;
}

.mps-settings-row {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.mps-settings-label {
    flex: 1;
    font-size: 15px;
    color: #333;
}

.mps-settings-control {
    flex: 1;
    text-align: right;
}

.mps-settings-select {
    padding: 8px 12px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    background-color: #fff;
    color: #333;
    min-width: 100px;
    cursor: pointer;
    transition: all 0.2s;
}

.mps-settings-select:focus {
    border-color: #d32f2f;
    outline: none;
    box-shadow: 0 0 0 2px rgba(211, 47, 47, 0.1);
}

.mps-settings-button {
    padding: 8px 15px;
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.mps-settings-button:hover {
    background: linear-gradient(135deg, #c62828 0%, #e53935 100%);
    box-shadow: 0 4px 8px rgba(211, 47, 47, 0.2);
}

body.rtl .mps-settings-title::after {
    left: auto;
    right: 0;
}

body.rtl .mps-settings-control {
    text-align: left;
} 

/* Category Header with Toggle */
.mps-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.mps-category-name {
    flex: 1;
}

.mps-toggle-category {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    transition: all 0.3s;
}

.mps-toggle-category:hover {
    background-color: rgba(255,255,255,0.2);
}

.mps-toggle-category i {
    font-size: 20px;
    transition: transform 0.3s;
}

.mps-category-row.collapsed .mps-toggle-category i {
    transform: rotate(-90deg);
}

.mps-category-content.collapsed {
    display: none;
}

/* Comparison Controls */
.mps-comparison-controls {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
    justify-content: center;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 10px;
    border: 1px solid #e9ecef;
}

.mps-expand-all-btn,
.mps-collapse-all-btn,
.mps-show-differences-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 15px;
    border: none;
    border-radius: 8px;
    background-color: #fff;
    color: #333;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: all 0.3s;
}

.mps-expand-all-btn:hover,
.mps-collapse-all-btn:hover,
.mps-show-differences-btn:hover {
    background-color: #f5f5f5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.mps-expand-all-btn i,
.mps-collapse-all-btn i,
.mps-show-differences-btn i {
    margin-right: 5px;
    font-size: 18px;
}

/* Differences Only Mode */
.mps-comparison-table.differences-only .mps-feature-row {
    animation: fadeIn 0.5s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Responsive styles for controls */
@media (max-width: 768px) {
    .mps-comparison-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        padding: 10px;
    }
    
    .mps-expand-all-btn,
    .mps-collapse-all-btn,
    .mps-show-differences-btn {
        padding: 8px;
        font-size: 13px;
    }
    
    .mps-toggle-category {
        width: 24px;
        height: 24px;
    }
    
    .mps-toggle-category i {
        font-size: 18px;
    }
}

/* RTL support for controls */
body.rtl .mps-expand-all-btn i,
body.rtl .mps-collapse-all-btn i,
body.rtl .mps-show-differences-btn i {
    margin-right: 0;
    margin-left: 5px;
}

/* Accessibility Improvements */
.mps-feature-info:focus {
    outline: 2px solid #2196F3;
    outline-offset: 2px;
}

.mps-toggle-category:focus,
.mps-expand-all-btn:focus,
.mps-collapse-all-btn:focus,
.mps-show-differences-btn:focus {
    outline: 2px solid #2196F3;
    outline-offset: 2px;
    box-shadow: 0 0 0 4px rgba(33, 150, 243, 0.2);
}

/* Keyboard navigation indicators */
.mps-feature-row:focus-within {
    background-color: rgba(33, 150, 243, 0.05);
}

/* Improved Print Support */
@media print {
    .mps-comparison-table-container {
        overflow: visible;
        box-shadow: none;
        border: 1px solid #ddd;
        margin: 0;
        padding: 0;
    }
    
    .mps-comparison-controls,
    .mps-swipe-hint,
    .mps-toggle-category,
    .mps-specs-difference {
        display: none !important;
    }
    
    .mps-category-header {
        justify-content: center;
    }
    
    .mps-category-row th {
        background: #f5f5f5 !important;
        color: #000 !important;
        text-align: center;
        padding: 15px 0;
        border-top: 2px solid #ddd;
        border-bottom: 1px solid #ddd;
    }
    
    .mps-feature-row th {
        position: relative !important;
        box-shadow: none !important;
        background-color: #fff !important;
        border-right: 1px solid #ddd;
        font-weight: 700;
    }
    
    .mps-feature-row td {
        border-right: 1px solid #eee;
    }
    
    .mps-feature-row:last-child td,
    .mps-feature-row:last-child th {
        border-bottom: 1px solid #ddd;
    }
    
    .mps-highlight-better {
        background-color: rgba(0,0,0,0.05) !important;
        color: #000 !important;
    }
    
    .mps-highlight-worse {
        background-color: transparent !important;
        color: #000 !important;
    }
    
    .mps-highlight-better::after {
        display: none !important;
    }
    
    .mps-phone-header {
        padding: 10px 5px;
        border-bottom: 1px solid #ddd;
    }
    
    .mps-phone-header img {
        max-height: 100px;
    }
    
    /* Add print header and footer */
    .mps-comparison-table-container::before {
        content: 'مقارنة الهواتف';
        display: block;
        text-align: center;
        font-size: 20px;
        font-weight: bold;
        margin-bottom: 10px;
    }
    
    .mps-comparison-table-container::after {
        content: 'تم إنشاء هذه المقارنة بواسطة موقعنا - ' attr(data-print-url);
        display: block;
        text-align: center;
        margin-top: 10px;
        font-size: 12px;
        color: #666;
    }
    
    /* Force page breaks between categories */
    .mps-category-content {
        page-break-inside: avoid;
    }
    
    /* Ensure at least 2 rows per page */
    .mps-feature-row:nth-child(1),
    .mps-feature-row:nth-child(2) {
        page-break-inside: avoid;
    }
    
    /* Make sure the header is repeated on each page */
    thead {
        display: table-header-group;
    }
    
    /* Hide comparison list and all buttons */
    .mps-comparison-list,
    .mps-comparison-toggle,
    .mps-selected-phones-box button,
    .mps-comparison-floating-button {
        display: none !important;
    }
}

/* Reduced motion preference support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .mps-comparison-table-container {
        scroll-behavior: auto !important;
    }
    
    .mps-phone-header:hover img,
    .mps-compare-item:hover,
    .mps-selected-phone-item:hover {
        transform: none !important;
    }
    
    .mps-swipe-hint {
        display: none !important;
    }
}

.mps-print-comparison-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 15px;
    border: none;
    border-radius: 8px;
    background-color: #f5f5f5;
    color: #333;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: all 0.3s;
}

.mps-print-comparison-btn:hover {
    background-color: #e0e0e0;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.mps-print-comparison-btn i {
    margin-right: 5px;
    font-size: 18px;
    color: #555;
}

body.mps-printing * {
    transition: none !important;
    animation: none !important;
}

/* Make footer use current date */
body.mps-printing .mps-comparison-table-container::after {
    content: 'تم إنشاء هذه المقارنة بواسطة موقعنا - ' attr(data-print-url) ' - ' attr(data-print-date);
}

/* RTL support for print button */
body.rtl .mps-print-comparison-btn i {
    margin-right: 0;
    margin-left: 5px;
}

/* Responsive Table Layout */
@media (max-width: 768px) {
    /* Improve container for mobile */
    .mps-comparison-table-container {
        margin: 20px -15px;
        max-width: calc(100% + 30px);
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x proximity;
        padding-bottom: 15px;
    }
    
    /* Make the comparison table better on mobile */
    .mps-comparison-table {
        min-width: 650px; /* Ensure minimum width for small screens */
        border-spacing: 0;
    }
    
    /* Improve sticky headers */
    .mps-comparison-table th.mps-phone-header {
        min-width: 120px;
        padding: 10px 8px;
        position: sticky;
        top: 0;
        z-index: 10;
        background-color: #fff;
    }
    
    /* Make feature headers sticky */
    .mps-feature-row th {
        position: sticky;
        left: 0;
        background-color: #f5f5f5;
        z-index: 5;
        box-shadow: 2px 0 5px rgba(0,0,0,0.05);
        min-width: 120px;
        max-width: 140px;
        font-size: 13px;
        padding: 10px;
    }
    
    /* Adjust cell content */
    .mps-feature-row td {
        font-size: 13px;
        padding: 10px 8px;
        min-width: 110px;
    }
    
    /* Better swipe hint */
    .mps-swipe-hint {
        background: rgba(0,0,0,0.7);
        color: white;
        padding: 8px 15px;
        border-radius: 20px;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        z-index: 100;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 2px 10px rgba(0,0,0,0.3);
        opacity: 0.9;
        pointer-events: none;
        font-weight: 500;
    }
    
    .mps-swipe-hint i {
        margin-left: 8px;
        font-size: 18px;
        animation: swipeMotion 1.5s infinite;
    }
    
    @keyframes swipeMotion {
        0% { transform: translateX(-5px); }
        50% { transform: translateX(5px); }
        100% { transform: translateX(-5px); }
    }
    
    /* Better scroll indicators */
    .mps-comparison-table-container:after {
        content: "";
        position: absolute;
        top: 0;
        right: 0;
        height: 100%;
        width: 30px;
        background: linear-gradient(to right, rgba(255,255,255,0), rgba(255,255,255,0.8));
        pointer-events: none;
        z-index: 3;
    }
    
    .mps-comparison-table-container:before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        height: 100%;
        width: 5px;
        background: linear-gradient(to left, rgba(255,255,255,0), rgba(255,255,255,0.8));
        pointer-events: none;
        z-index: 3;
    }
}

/* Extra Small Devices */
@media (max-width: 480px) {
    /* Further optimize for very small screens */
    .mps-comparison-table {
        min-width: 600px;
    }
    
    .mps-phone-header {
        min-width: 100px;
        padding: 8px 5px;
    }
    
    .mps-phone-header img {
        max-width: 70px;
        max-height: 90px;
    }
    
    .mps-phone-header-link {
        font-size: 13px;
    }
    
    .mps-feature-row th {
        min-width: 100px;
        max-width: 120px;
        font-size: 12px;
        padding: 8px 6px;
    }
    
    .mps-feature-row td {
        font-size: 12px;
        padding: 8px 5px;
        min-width: 100px;
    }
    
    /* Better touch targets for small screens */
    .mps-toggle-category,
    .mps-expand-all-btn,
    .mps-collapse-all-btn,
    .mps-show-differences-btn {
        min-height: 40px;
        min-width: 40px;
    }
    
    /* Adjust comparison controls */
    .mps-comparison-controls {
        padding: 10px;
        gap: 6px;
    }
    
    /* Better layout for selected phones */
    .mps-selected-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
    
    .mps-selected-phone-item {
        padding: 10px;
    }
    
    .mps-selected-phone-image {
        width: 60px;
        height: 60px;
        margin-bottom: 8px;
    }
    
    .mps-selected-phone-title {
        font-size: 12px;
    }
}

/* Touch Optimized Scrolling */
.mps-comparison-table-container {
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scroll-behavior: smooth;
}

/* Better handling for comparison items in small screens */
@media (max-width: 768px) {
    .mps-comparison-list {
        max-height: 80vh;
        padding: 15px;
    }
    
    .mps-compare-items {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 10px;
        overflow-x: visible;
    }
    
    .mps-compare-item {
        flex: unset;
        width: auto;
        height: auto;
    }
}

/* More compact layout for small phones */
@media (max-width: 360px) {
    .mps-selected-phones-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 8px;
    }
    
    .mps-comparison-controls {
        flex-direction: column;
    }
    
    .mps-expand-all-btn,
    .mps-collapse-all-btn,
    .mps-show-differences-btn,
    .mps-print-comparison-btn {
        width: 100%;
        margin-bottom: 5px;
    }
}

/* Better scrollbars for webkit browsers */
.mps-comparison-table-container::-webkit-scrollbar {
    height: 6px;
}

.mps-comparison-table-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.mps-comparison-table-container::-webkit-scrollbar-thumb {
    background: #d32f2f;
    border-radius: 3px;
}

.mps-comparison-table-container::-webkit-scrollbar-thumb:hover {
    background: #b71c1c;
}

/* Optimization for both portrait and landscape on phones */
@media (max-width: 900px) and (orientation: landscape) {
    .mps-comparison-table-container {
        max-height: 70vh;
        overflow-y: auto;
    }
    
    .mps-feature-row th {
        position: sticky;
        left: 0;
        z-index: 5;
    }
    
    .mps-phone-header {
        position: sticky;
        top: 0;
        z-index: 6;
    }
    
    /* Create a special corner cell for dual-sticky effect */
    .mps-comparison-table thead th:first-child {
        position: sticky;
        top: 0;
        left: 0;
        z-index: 7;
        background-color: #fff;
    }
}

/* Highlighted cell on mobile tap */
.mps-comparison-table td.cell-highlighted {
    background-color: rgba(211, 47, 47, 0.1);
    box-shadow: inset 0 0 0 2px #d32f2f;
    position: relative;
    z-index: 4;
    transform: scale(1.02);
    transition: all 0.2s ease;
}

/* Fade out highlight after a few seconds */
.mps-comparison-table td.cell-highlighted {
    animation: fadeHighlight 2s forwards;
}

@keyframes fadeHighlight {
    0% { background-color: rgba(211, 47, 47, 0.2); }
    70% { background-color: rgba(211, 47, 47, 0.2); }
    100% { background-color: rgba(211, 47, 47, 0.05); }
}

/* Drag handle for mobile comparison list */
.mps-comparison-drag-handle {
    width: 60px;
    height: 5px;
    background-color: #ddd;
    border-radius: 3px;
    margin: 0 auto 15px;
    cursor: grab;
    position: relative;
    top: 5px;
    opacity: 0.8;
    transition: all 0.3s ease;
}

.mps-comparison-drag-handle:hover,
.mps-comparison-drag-handle:active {
    background-color: #bbb;
    opacity: 1;
}

/* Smoother animation for being dragged state */
.mps-comparison-list.being-dragged {
    transition: transform 0.1s ease-out !important;
}

/* Backdrop for comparison list on mobile */
.mps-comparison-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0,0,0,0);
    z-index: 99998;
    transition: background-color 0.3s ease;
    pointer-events: none;
}

.mps-comparison-backdrop.active {
    background-color: rgba(0,0,0,0.5);
    pointer-events: auto;
}

/* Flex layout for selected phones on mobile */
.mps-selected-phones-grid.mps-flex-layout {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    padding-bottom: 10px;
}

.mps-flex-layout .mps-selected-phone-item {
    flex: 0 0 auto;
    width: 140px;
    scroll-snap-align: start;
    margin-right: 10px;
}

/* Hint that there's more to scroll */
.mps-flex-layout:after {
    content: "";
    flex: 0 0 10px;
}

/* Custom scrollbar for flex layout */
.mps-flex-layout::-webkit-scrollbar {
    height: 4px;
}

.mps-flex-layout::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 2px;
}

.mps-flex-layout::-webkit-scrollbar-thumb {
    background: #d32f2f;
    border-radius: 2px;
}

/* Disabled view comparison button */
.mps-view-comparison-button.disabled {
    background: linear-gradient(135deg, #9e9e9e 0%, #757575 100%);
    cursor: not-allowed;
    opacity: 0.7;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.mps-view-comparison-button.disabled:hover {
    transform: none;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    background: linear-gradient(135deg, #9e9e9e 0%, #757575 100%);
}

.mps-view-comparison-button.disabled::before {
    content: none;
}

/* Enhanced swipe hint for better visibility */
.mps-swipe-hint {
    background: rgba(0,0,0,0.75);
    color: white;
    padding: 12px 20px;
    border-radius: 50px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    opacity: 0.95;
    pointer-events: none;
    font-weight: 600;
    font-size: 16px;
    max-width: 80%;
    text-align: center;
    border: 2px solid rgba(255,255,255,0.3);
}

.mps-swipe-hint i {
    margin-left: 10px;
    font-size: 24px;
    color: #ffeb3b;
}

/* Animated swipe indicator */
.mps-swipe-animation {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: radial-gradient(circle, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 70%);
    opacity: 0;
    animation: pulse-swipe 2s infinite;
}

@keyframes pulse-swipe {
    0% { opacity: 0; transform: scale(0.8); }
    50% { opacity: 0.5; transform: scale(1.1); }
    100% { opacity: 0; transform: scale(0.8); }
}

/* Show animation on swipe hint icon */
.mps-swipe-hint i {
    animation: swipe-motion 1.5s infinite;
}

@keyframes swipe-motion {
    0% { transform: translateX(-8px); }
    50% { transform: translateX(8px); }
    100% { transform: translateX(-8px); }
}

/* Recent Phones Header with Search */
.mps-recent-phones-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.mps-recent-phones-search {
    display: flex;
    align-items: center;
    max-width: 300px;
    width: 100%;
    position: relative;
    margin-right: auto;
}

.mps-recent-phone-search-input {
    width: 100%;
    padding: 10px 15px;
    padding-left: 40px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.mps-recent-phone-search-input:focus {
    border-color: #d32f2f;
    box-shadow: 0 0 10px rgba(211, 47, 47, 0.2);
    outline: none;
}

.mps-recent-phone-search-btn {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #777;
    cursor: pointer;
    font-size: 20px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mps-recent-phone-search-btn:hover {
    color: #d32f2f;
}

/* Go to Comparison Button */
.mps-go-to-comparison-btn {
    display: block;
    width: 100%;
    padding: 14px;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #2196F3, #1565C0);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    box-shadow: 0 4px 10px rgba(33, 150, 243, 0.2);
    position: relative;
    overflow: hidden;
    opacity: 0.7;
}

.mps-go-to-comparison-btn:hover {
    background: linear-gradient(135deg, #1E88E5, #0D47A1);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(33, 150, 243, 0.3);
    opacity: 1;
}

.mps-go-to-comparison-btn.active {
    opacity: 1;
    animation: pulse-btn 2s infinite;
}

@keyframes pulse-btn {
    0% { box-shadow: 0 0 0 0 rgba(33, 150, 243, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(33, 150, 243, 0); }
    100% { box-shadow: 0 0 0 0 rgba(33, 150, 243, 0); }
}

.mps-go-to-comparison-btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: 0.6s;
}

.mps-go-to-comparison-btn.active:hover::after {
    left: 100%;
}

.mps-go-to-comparison-btn i {
    margin-left: 8px;
    vertical-align: middle;
}

/* Show Latest Phones Button */
.mps-show-recent-phones-btn {
    display: block;
    width: 100%;
    max-width: 300px;
    margin: 20px auto;
    padding: 14px;
    background: linear-gradient(135deg, #4CAF50, #2E7D32);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    box-shadow: 0 4px 10px rgba(76, 175, 80, 0.2);
}

.mps-show-recent-phones-btn:hover {
    background: linear-gradient(135deg, #43A047, #1B5E20);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(76, 175, 80, 0.3);
}

.mps-show-recent-phones-btn i {
    margin-left: 8px;
    vertical-align: middle;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .mps-recent-phones-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .mps-recent-phones-search {
        max-width: 100%;
        margin-top: 15px;
    }
}