/* Affiliate Comparison Table - Frontend Styles */

.act-wrapper {
    max-width: 100%;
    margin: 2rem 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.act-table {
    background: transparent;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Row Container */
.act-row {
    background: #ffffff;
    border: 2px solid #f3f4f6;
    border-radius: 12px;
    padding: 0;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.act-row:hover {
    border-color: #d1d5db;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

/* ===== DESKTOP LAYOUT (3 columns) ===== */
.act-row-inner {
    display: grid;
    grid-template-columns: 200px 1fr 220px;
    gap: 0;
    align-items: stretch;
    min-height: 160px;
}

/* Column 1: Number + Logo (LEFT) */
.act-col-number-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 1.5rem 1rem;
    background: white;
}

.act-number-badge-mobile {
    display: flex;
    align-items: center;
    gap: 1rem;
    width: 100%;
    justify-content: center;
}

.act-number {
    display: none;
}

.act-logo {
    width: 140px;
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.act-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.act-logo-placeholder svg {
    width: 120px;
    height: 120px;
}

/* Badge - Mobile only */
.act-badge-mobile {
    display: none;
}

/* Column 2: Content (MIDDLE) */
.act-col-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0;
    gap: 0.5rem;
}

/* Badge - Desktop */
.act-badge-desktop {
    display: inline-block;
    margin-bottom: 0;
}

.act-badge-desktop span {
    display: inline-block;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.act-product-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
    line-height: 1.3;
    padding-left: 0;
}

.act-description {
    font-size: 0.875rem;
    color: #4b5563;
    line-height: 1.5;
    margin: 0;
    padding-left: 0;
}

.act-features-list {
    list-style: none;
    padding: 0 0 1rem 0;
    margin: 0.25rem 0 0 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.act-features-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: #374151;
    line-height: 1.4;
    padding-left: 0;
    margin-left: 0;
}

.act-check-icon {
    width: 16px;
    height: 16px;
    color: #10b981;
    flex-shrink: 0;
    margin-top: 2px;
    margin-left: 0;
}

.act-features-list li span {
    flex: 1;
}

/* Column 3: Rating + Button (RIGHT) */
.act-col-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 1.5rem 1rem;
    background: white;
}

.act-rating-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.act-rating-box {
    background: #3b82f6;
    color: white;
    width: 65px;
    height: 65px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.act-rating-score {
    font-size: 1.75rem;
    font-weight: 900;
    line-height: 1;
}

.act-rating-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.125rem;
}

.act-stars {
    color: #fbbf24;
    font-size: 0.875rem;
    letter-spacing: 1px;
    margin-bottom: 0.125rem;
}

.act-rating-text {
    font-size: 0.6875rem;
    font-weight: 700;
    color: #3b82f6;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.act-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: #10b981;
    color: white;
    padding: 0.875rem 1.5rem;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
    width: 100%;
    text-align: center;
    position: relative;
    z-index: 5;
}

.act-button:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.4);
    color: white;
    text-decoration: none;
}

.act-arrow-icon {
    width: 18px;
    height: 18px;
    transition: transform 0.3s ease;
}

.act-button:hover .act-arrow-icon {
    transform: translateX(4px);
}

/* Alternative colors */
.act-row:nth-child(2) .act-rating-box {
    background: #8b5cf6;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.act-row:nth-child(2) .act-rating-text {
    color: #8b5cf6;
}

.act-row:nth-child(3) .act-rating-box {
    background: #06b6d4;
    box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}

.act-row:nth-child(3) .act-rating-text {
    color: #06b6d4;
}

/* ===== TABLET ===== */
@media (max-width: 1024px) {
    .act-row-inner {
        grid-template-columns: 180px 1fr 200px;
    }
    
    .act-logo {
        width: 120px;
        height: 120px;
    }
    
    .act-logo-placeholder svg {
        width: 100px;
        height: 100px;
    }
    
    .act-features-list {
        grid-template-columns: 1fr;
    }
}

/* ===== MOBILE LAYOUT (Vertical Stack) ===== */
@media (max-width: 768px) {
    .act-table {
        gap: 1rem;
    }
    
    .act-row {
        border-radius: 8px;
    }
    
    /* Mobile: Vertical stacking */
    .act-row-inner {
        display: flex;
        flex-direction: column;
        min-height: auto;
    }
    
    /* 1. Number + Badge (Horizontal) */
    .act-col-number-logo {
        border-right: none;
        border-bottom: none;
        padding: 1rem;
        background: white;
    }
    
    .act-number-badge-mobile {
        flex-direction: row;
        justify-content: center;
        width: 100%;
    }
    
    .act-number {
        display: none;
    }
    
    .act-badge-mobile {
        display: block;
    }
    
    .act-badge-mobile span {
        background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
        color: white;
        padding: 0.5rem 0.875rem;
        border-radius: 6px;
        font-size: 0.6875rem;
        font-weight: 700;
        letter-spacing: 0.5px;
        text-transform: uppercase;
        white-space: nowrap;
        box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
    }
    
    /* 2. Logo (Centered, Full Width) */
    .act-logo {
        width: 160px;
        height: 160px;
        margin: 1rem auto;
    }
    
    .act-logo-placeholder svg {
        width: 140px;
        height: 140px;
    }
    
    /* 3. Product Info Section */
    .act-col-info {
        padding: 1rem;
        padding-left: 0;
        border-right: none;
        border-bottom: none;
        background: white;
    }
    
    .act-badge-desktop {
        display: none;
    }
    
    .act-product-name {
        font-size: 1.25rem;
        text-align: center;
        margin-bottom: 1rem;
    }
    
    .act-description {
        font-size: 0.875rem;
        text-align: center;
        margin-bottom: 1rem;
    }
    
    .act-features-list {
        grid-template-columns: 1fr;
        gap: 0.625rem;
        margin-top: 1rem;
    }
    
    .act-features-list li {
        font-size: 0.8125rem;
    }
    
    /* 4. Rating + Button Section */
    .act-col-cta {
        padding: 1.5rem 1rem;
        background: white;
        gap: 1rem;
    }
    
    .act-rating-wrapper {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .act-rating-box {
        width: 65px;
        height: 65px;
    }
    
    .act-rating-score {
        font-size: 1.75rem;
    }
    
    .act-button {
        padding: 0.875rem 1.5rem;
        font-size: 0.9375rem;
    }
}

/* Very Small Mobile */
@media (max-width: 480px) {
    .act-wrapper {
        margin: 1rem 0;
    }
    
    .act-logo {
        width: 120px;
        height: 120px;
    }
    
    .act-logo-placeholder svg {
        width: 100px;
        height: 100px;
    }
    
    .act-product-name {
        font-size: 1.125rem;
    }
    
    .act-description {
        font-size: 0.8125rem;
    }
    
    .act-rating-box {
        width: 60px;
        height: 60px;
    }
    
    .act-rating-score {
        font-size: 1.5rem;
    }
}

/* Editor Styles */
.editor-styles-wrapper .act-row-inner,
.block-editor-block-list__layout .act-row-inner {
    display: flex !important;
    flex-direction: column !important;
    gap: 1rem !important;
}

.editor-styles-wrapper .act-col-number-logo,
.block-editor-block-list__layout .act-col-number-logo {
    flex-direction: row !important;
    justify-content: flex-start !important;
    border-right: none !important;
    border-bottom: 1px solid #e5e7eb !important;
    background: white !important;
}

.editor-styles-wrapper .act-col-info,
.block-editor-block-list__layout .act-col-info {
    border-right: none !important;
    border-bottom: 1px solid #e5e7eb !important;
    background: white !important;
}

.editor-styles-wrapper .act-col-cta,
.block-editor-block-list__layout .act-col-cta {
    border-right: none !important;
    background: white !important;
}

.editor-styles-wrapper .act-badge-mobile,
.block-editor-block-list__layout .act-badge-mobile {
    display: block !important;
}

.editor-styles-wrapper .act-badge-desktop,
.block-editor-block-list__layout .act-badge-desktop {
    display: none !important;
}

/* Loading state */
.act-wrapper.loading {
    opacity: 0.6;
    pointer-events: none;
}
