/* AffiliatedDreams Styles */

/* Admin Styles */
.affiliatedreams-admin-wrap {
    margin: 20px;
}

.affiliatedreams-admin-wrap h1 {
    color: #23282d;
}

/* Custom Products Table Styles */
.affiliatedreams-products-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.affiliatedreams-products-table th,
.affiliatedreams-products-table td {
    padding: 10px;
}

.affiliatedreams-products-filter {
    margin: 15px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.affiliatedreams-products-filter select,
.affiliatedreams-products-filter input[type="text"] {
    min-width: 200px;
    padding: 5px;
}

.affiliatedreams-result-count {
    margin: 10px 0;
    font-style: italic;
    color: #666;
}

.product-actions {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.product-actions .button-small {
    margin-right: 5px;
    margin-bottom: 5px;
}

/* Article Indicator Styles */
.has-article-yes {
    color: #46b450;
    font-size: 20px;
}

.has-article-no {
    color: #dc3232;
    font-size: 20px;
}

.linked-articles a {
    display: block;
    margin-bottom: 3px;
    text-decoration: none;
}

.linked-articles a:hover {
    text-decoration: underline;
}

.linked-articles .more-indicator {
    font-style: italic;
    color: #666;
    font-size: 12px;
}

/* Pagination Styles */
.tablenav-pages {
    margin: 15px 0;
    float: right;
}

.tablenav-pages .pagination-links {
    display: flex;
    align-items: center;
    gap: 5px;
}

.tablenav-pages .button {
    padding: 5px 10px;
    margin: 0 2px;
}

.tablenav-pages .paging-input {
    margin: 0 10px;
}

.tablenav-pages .disabled {
    color: #aaa;
    cursor: default;
}

/* Bulk Actions Styles - Scoped to AffiliatedDreams */
.affiliatedreams-admin-wrap .tablenav {
    margin: 15px 0;
    clear: both;
}

.affiliatedreams-admin-wrap .tablenav.top {
    margin-bottom: 10px;
}

.affiliatedreams-admin-wrap .tablenav.bottom {
    margin-top: 10px;
}

.affiliatedreams-admin-wrap .bulkactions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.affiliatedreams-admin-wrap .bulkactions select {
    min-width: 160px;
}

.affiliatedreams-admin-wrap .bulkactions .button.action:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Checkbox column - Scoped to AffiliatedDreams */
.affiliatedreams-products-table .check-column {
    width: 2.2em;
    text-align: center;
    vertical-align: top;
}

.affiliatedreams-products-table .check-column input[type="checkbox"] {
    margin: 0;
}

/* ASIN Lookup Styles */
.lookup-asin-btn {
    margin-left: 10px !important;
}

.asin-confidence {
    color: #46b450;
    font-weight: bold;
    margin-left: 10px;
    cursor: help;
}

.asin-found {
    color: #46b450;
    font-weight: bold;
    margin-left: 10px;
}

/* Discovery Results ASIN Column */
.affiliatedreams-discovery-results .asin-column {
    min-width: 100px;
}

/* Responsive adjustments for bulk actions */
@media screen and (max-width: 782px) {
    .affiliatedreams-admin-wrap .bulkactions {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .affiliatedreams-admin-wrap .bulkactions select,
    .affiliatedreams-admin-wrap .bulkactions .button {
        width: 100%;
        max-width: 200px;
    }
}

/* Product Box Styles */
.affiliatedreams-product-box {
    border: 1px solid #ddd;
    padding: 20px;
    margin-bottom: 20px;
    background-color: #fff;
}

.affiliatedreams-product-box img {
    max-width: 100%;
    height: auto;
}

.affiliatedreams-product-box h3 {
    margin-top: 0;
}

.affiliatedreams-product-box .price {
    font-weight: bold;
    color: #4CAF50;
}

.affiliatedreams-product-box .cta-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 5px;
}

/* Product Features Table Styles */
.affiliatedreams-features-table {
    width: 100%;
    border-collapse: collapse;
}

.affiliatedreams-features-table th,
.affiliatedreams-features-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: left;
}

.affiliatedreams-features-table th {
    background-color: #f2f2f2;
}

/* Comparison Table Styles */
.affiliatedreams-comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.affiliatedreams-comparison-table th,
.affiliatedreams-comparison-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: left;
}

.affiliatedreams-comparison-table th {
    background-color: #f2f2f2;
    position: sticky;
    top: 0;
    z-index: 10;
}

.affiliatedreams-comparison-table .highlight {
    background-color: #e6f7ff;
}

.affiliatedreams-loading {
    margin-top: 10px;
    padding: 10px;
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    border-radius: 4px;
}

#sortable-products {
    list-style-type: none;
    padding: 0;
}

#sortable-products li {
    padding: 10px;
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    margin-bottom: 5px;
    cursor: move;
}

#sortable-products .dashicons-menu {
    color: #999;
    margin-right: 10px;
}

/* Responsive Design */
@media screen and (max-width: 600px) {
    .affiliatedreams-comparison-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

/* Dashboard Styles */
.affiliatedreams-dashboard {
    margin-bottom: 30px;
}

.affiliatedreams-dashboard h2 {
    margin-bottom: 20px;
}

.dashboard-card {
    background-color: #fff;
    border: 1px solid #ddd;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.dashboard-card:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.dashboard-number {
    font-size: 32px;
    font-weight: bold;
    margin: 10px 0;
    color: #0073aa;
}

/* Settings Tabs Styles */
.nav-tab-wrapper {
    margin-bottom: 20px;
}

.tab-content {
    padding: 20px 0;
}

.shortcode-section, 
.import-section, 
.export-section {
    margin-bottom: 20px;
    padding: 15px;
    background-color: #f8f8f8;
    border-radius: 5px;
}

.shortcode-section h3, 
.import-section h3, 
.export-section h3 {
    margin-top: 0;
    margin-bottom: 10px;
}

div[id^="product_box_shortcode"], 
div[id^="product_features_shortcode"], 
div[id^="comparison_shortcode"] {
    padding: 10px;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-family: monospace;
    min-height: 30px;
}

/* Responsive Design for Dashboard */
@media screen and (max-width: 782px) {
    .affiliatedreams-dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-card {
        margin-bottom: 15px;
    }
}