/**
 * Catalog Component Styles - Clean Version
 * Мінімальні стилі без конфліктів
 */

.catalog-wrapper {
    max-width: 1140px;
    margin: 0 auto 20px;
    padding: 0 20px;
}

.catalog-card {
    background: white;
    border-radius: 20px;
    padding: 20px 30px;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
    margin-bottom: 30px;
}

.catalog-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: white;
    color: #00955c;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid #ddd;
}

.catalog-badge.new {
    color: #00955c;
    border-color: #ddd;
}

.catalog-content {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.catalog-logo-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    flex-shrink: 0;
    min-width: 150px;
    justify-content: flex-start;
}

.catalog-logo-section img {
    height: 80px;
    width: 177px;
    object-fit: contain;
}

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

.catalog-stars {
    display: flex;
    gap: 4px;
}

.catalog-star-icon {
    width: 20px;
    height: 20px;
    display: inline-block;
    vertical-align: middle;
}

.catalog-star-icon.large {
    width: 24px;
    height: 24px;
}

/* Стилі для зірок від wp_star_rating() */
.catalog-stars .star-icon {
    width: 20px;
    height: 20px;
    display: inline-block;
    vertical-align: middle;
}

.catalog-rating-value {
    font-size: 15px;
    font-weight: 700;
    color: #1a1a1a;
}

.catalog-rating-info-icon {
    width: 16px;
    height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: #00955c;
    margin-left: 4px;
    cursor: pointer;
    border: 1px solid #00955c;
    border-radius: 50%;
}

.catalog-details-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px 30px;
    flex: 1;
    margin-top: auto;
}

.catalog-detail-item {
    text-align: left;
}

.catalog-detail-label {
    color: #888;
    font-size: 11px;
    margin-bottom: 2px;
    font-weight: 500;
}

.catalog-detail-value {
    color: #1a1a1a;
    font-size: 18px;
    font-weight: 700;
}

.catalog-button-section {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    min-width: 280px;
    margin-top: auto;
}

.catalog-cta-button {
    background: #00955c;
    color: white;
    border: none;
    padding: 16px 40px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
    width: 100%;
}

.catalog-cta-button:hover {
    background: #007a4a;
}

.catalog-button-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 12px;
}

.catalog-verified-section {
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
}

.catalog-verified-icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.catalog-verified-icon img {
    width: 100%;
    height: 100%;
}

.catalog-verified-text {
    font-size: 12px;
    font-weight: 600;
    color: #00955c;
    position: relative;
    cursor: pointer;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.5;
    display: flex;
    align-items: center;
    gap: 8px;
}

.catalog-details-link {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #00955c;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s;
    background: none;
    border: none;
    padding: 0;
}

.catalog-details-link:hover {
    color: #007a4a;
}

.catalog-details-link span {
    font-size: 12px;
    font-weight: 600;
    line-height: 1.5;
}

.catalog-details-link svg {
    width: 18px !important;
    height: 18px !important;
    transition: transform 0.3s !important;
    transform-origin: center !important;
    display: inline-block !important;
    margin-left: 6px !important;
    flex-shrink: 0 !important;
}

.catalog-details-link.active svg {
    transform: rotate(180deg) !important;
}

/* Expanded Content */
.catalog-expanded-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    background: white;
    border: 1px solid #e8eae6;
    border-top: none;
    border-radius: 0 0 20px 20px;
    margin: 0;
    padding: 0;
}

.catalog-expanded-content.active {
    max-height: 3000px;
}

.catalog-card:has(+ .catalog-expanded-content.active) {
    border-radius: 20px 20px 0 0;
}

.catalog-expanded-grid {
    padding: 20px 30px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    background: white;
}

.catalog-expanded-section {
    background: #f9faf8;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #e8eae6;
    box-sizing: border-box;
}


.catalog-pros-cons {
    display: contents;
}

.catalog-expanded-section:has(.catalog-pros-cons) {
    grid-column: 1 / -1;
}

.catalog-contacts-section {
    grid-column: 1 / -1;
}

.catalog-section-title {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.catalog-pros-cons {
    display: grid;
    gap: 20px;
    width: 100%;
}

.catalog-pros-list, .catalog-cons-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.catalog-pros-list li, .catalog-cons-list li {
    list-style: none;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13px;
    line-height: 1.5;
    color: #555;
}

.catalog-pros-list li::before {
    content: "✓";
    color: #00955c;
    font-weight: 700;
    flex-shrink: 0;
    font-size: 14px;
}

.catalog-cons-list li::before {
    content: "✗";
    color: #ff9500;
    font-weight: 700;
    flex-shrink: 0;
    font-size: 14px;
}

.catalog-conditions-table {
    width: 100% !important;
    border-collapse: collapse !important;
    font-size: 13px !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    box-sizing: border-box !important;
    table-layout: fixed !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    background: transparent !important;
    line-height: 1.5 !important;
}

.catalog-conditions-table tr {
    border-bottom: 1px solid #e8eae6 !important;
    background: transparent !important;
}

.catalog-conditions-table tr:last-child {
    border-bottom: none !important;
}

.catalog-table-label {
    padding: 12px 0 !important;
    color: #666 !important;
    font-weight: 500 !important;
    font-size: 13px !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    text-align: left !important;
    width: 50% !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    border: none !important;
    background: transparent !important;
    margin: 0 !important;
    line-height: 1.5 !important;
}

.catalog-table-value {
    padding: 12px 0 !important;
    padding-left: 16px !important;
    color: #1a1a1a !important;
    font-weight: 600 !important;
    font-size: 13px !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    text-align: left !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    border: none !important;
    background: transparent !important;
    margin: 0 !important;
    line-height: 1.5 !important;
}

.catalog-contacts-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    width: 100%;
    box-sizing: border-box;
}

.catalog-contact-item {
    font-size: 13px;
}

.catalog-contact-label {
    color: #888;
    margin-bottom: 6px;
    font-weight: 500;
}

.catalog-contact-value {
    color: #1a1a1a;
    font-weight: 600;
    font-size: 13px !important;
}

.catalog-contact-value a {
    font-size: 13px !important;
}

.catalog-contact-link {
    color: #00955c;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.catalog-contact-link:hover {
    color: #007a4a;
}

.catalog-contacts-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    border: none;
    background: transparent;
    margin-top: 0;
    width: 100%;
    box-sizing: border-box;
}

.catalog-hide-button {
    background: none;
    border: none;
    cursor: pointer;
    color: #00955c;
    font-size: 14px;
    font-weight: 600;
    padding: 0;
    transition: color 0.2s;
    text-decoration: none;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.5;
    flex-shrink: 0;
}

.catalog-hide-button:hover {
    color: #007a4a;
}

.catalog-contacts-footer .catalog-contact-link {
    font-size: 14px;
    font-weight: 600;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.5;
    text-align: right;
    flex-grow: 1;
}

/* Desktop (769px+) */
@media (min-width: 769px) {
    .catalog-expanded-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .catalog-pros-cons {
        grid-template-columns: 1fr 1fr;
        grid-column: 1 / -1;
    }
    
    .catalog-contacts-section {
        grid-column: 1 / -1;
    }
}

/* Tablet (768px) */
@media (max-width: 768px) {
    .catalog-expanded-grid {
        display: block;
        padding: 16px 25px;
    }

    .catalog-expanded-section {
        padding: 16px;
        margin-bottom: 16px;
    }

    .catalog-section-title {
        font-size: 13px;
        margin-bottom: 12px;
    }

    .catalog-pros-cons {
        display: block;
    }

    .catalog-contacts-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }

    .catalog-contact-item {
        font-size: 12px;
    }

    .catalog-contact-label {
        margin-bottom: 4px;
        font-size: 11px;
    }

    .catalog-contacts-footer {
        padding: 20px 25px;
    }

    .catalog-hide-button,
    .catalog-contact-link {
        font-size: 12px;
    }
}

/* Mobile (480px) */
@media (max-width: 480px) {
    .catalog-content {
        flex-direction: column;
        gap: 20px;
    }

    .catalog-details-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .catalog-detail-value {
        font-size: 15px;
    }

    .catalog-button-section {
        width: 100%;
        min-width: auto;
    }

    .catalog-expanded-grid {
        display: block;
        padding: 12px 20px;
    }

    .catalog-expanded-section {
        padding: 12px;
        margin-bottom: 12px;
    }

    .catalog-section-title {
        font-size: 12px;
        margin-bottom: 10px;
    }

    .catalog-pros-cons {
        display: block;
    }

    .catalog-contacts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .catalog-contact-item {
        font-size: 11px;
    }

    .catalog-contact-label {
        margin-bottom: 3px;
        font-size: 10px;
    }

    .catalog-table-label,
    .catalog-table-value {
        font-size: 12px;
        padding: 8px 0;
    }

    .catalog-contacts-footer {
        padding: 16px 20px;
        flex-direction: row;
        gap: 12px;
    }

    .hide-button,
    .catalog-contact-link {
        font-size: 11px;
    }
}

/* Small (360px) */
@media (max-width: 360px) {
    .catalog-card {
        padding: 16px 20px;
    }

    .catalog-content {
        gap: 20px;
    }

    .catalog-logo-section img {
        height: 60px;
    }

    .catalog-details-grid {
        gap: 12px;
    }

    .catalog-detail-label {
        font-size: 10px;
    }

    .catalog-detail-value {
        font-size: 14px;
    }

    .catalog-expanded-grid {
        padding: 10px 16px;
        gap: 10px;
    }

    .catalog-expanded-section {
        padding: 10px;
        margin-bottom: 10px;
    }

    .catalog-section-title {
        font-size: 11px;
        margin-bottom: 8px;
    }

    .catalog-details-grid {
        gap: 12px;
    }

    .catalog-contact-item {
        font-size: 10px;
    }

    .catalog-contact-label {
        font-size: 9px;
        margin-bottom: 2px;
    }

    .catalog-table-label,
    .catalog-table-value {
        font-size: 11px;
        padding: 6px 0;
    }

    .catalog-details-link {
        font-size: 12px;
    }

    .catalog-details-link svg {
        width: 16px;
        height: 16px;
    }

    .catalog-contacts-footer {
        padding: 12px 16px;
        flex-direction: column;
        gap: 10px;
    }
}
