/* =========================================
   Authority Showcase - English Version Layout Optimization
   Changes from original:
   - Keep same height as Chinese version (160px)
   - Horizontal layout: left logo, right text
   - Smaller font size to fit all content
   - Optimized spacing
   - Preserve original animations
   ========================================= */

/* Keep same height as Chinese version */
.authority-showcase.visible {
    height: 160px !important;
}

/* Remove container width restriction - make full-width */
.authority-showcase .container {
    max-width: 100% !important;
    padding: 0 !important;
}

/* Grid wrapper - same height as Chinese version */
.authority-showcase-wrapper {
    height: 160px !important;
    padding: 0 60px !important;
}

@media (max-width: 1024px) {
    .authority-showcase.visible {
        height: 140px !important;
    }

    .authority-showcase .container {
        max-width: 100% !important;
        padding: 0 !important;
    }

    .authority-showcase-wrapper {
        height: 140px !important;
        padding: 0 40px !important;
    }
}

@media (max-width: 768px) {
    .authority-showcase.visible {
        height: 300px !important;
    }

    .authority-showcase .container {
        max-width: 100% !important;
        padding: 0 !important;
    }

    .authority-showcase-wrapper {
        height: 300px !important;
        padding: 0 30px !important;
    }
}

/* Horizontal layout for cards */
.authority-item {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    text-align: left !important;
    padding: 28px 28px !important;
    gap: 20px;
}

/* Logo positioning */
.authority-logo {
    flex-shrink: 0 !important;
    margin-bottom: 0 !important;
    margin-right: 0 !important;
    width: 100px !important;
    height: 40px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.authority-logo img {
    max-width: 100% !important;
    max-height: 40px !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    /* Preserve original filter and opacity */
    filter: brightness(0) invert(1) !important;
    opacity: 0.95 !important;
}

/* Text description area - compact font to fit all content */
.authority-desc {
    flex: 1 !important;
    text-align: left !important;
    font-size: 13px !important;
    line-height: 1.6 !important;
    color: rgba(255, 255, 255, 0.9) !important;
    margin: 0 !important;
    min-width: 0; /* Allows text to wrap properly */
    font-weight: 400 !important;
    letter-spacing: 0.3px !important;
}

/* Preserve hover effects from original CSS */
.authority-item:hover .authority-logo img {
    opacity: 1 !important;
    transform: scale(1.05) !important;
    transition: all 0.3s ease !important;
}

.authority-item:hover .authority-desc {
    color: rgba(255, 255, 255, 1) !important;
}

/* Responsive adjustments for tablets */
@media (max-width: 1024px) {
    .authority-item {
        padding: 28px 20px !important;
        gap: 16px;
    }

    .authority-logo {
        width: 90px !important;
        height: 36px !important;
    }

    .authority-logo img {
        max-height: 36px !important;
    }

    .authority-desc {
        font-size: 12px !important;
        line-height: 1.6 !important;
    }
}

/* Responsive adjustments for mobile - stack vertically on mobile */
@media (max-width: 768px) {
    .authority-item {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        padding: 24px 20px !important;
        gap: 12px;
    }

    .authority-logo {
        width: auto !important;
        height: 32px !important;
    }

    .authority-logo img {
        max-height: 32px !important;
        max-width: 120px !important;
    }

    .authority-desc {
        text-align: center !important;
        font-size: 13px !important;
        line-height: 1.7 !important;
    }
}
