/* Broker List Styles - Clean & Simple */
.agencies-item {
    display: flex;
    gap: 30px;
    padding: 30px;
    border: 1px solid var(--Line);
    border-radius: 16px;
    background: white;
    transition: all 0.3s ease;
}

.agencies-item .logo-wrap {
    width: 90px;
    height: 90px;
    overflow: hidden;
    border-radius: 10px;
    border: 1px solid var(--Line);
    flex-shrink: 0;
}

.broker-avatar {
    width: 90px;
    height: 90px;
    border-radius: 10px;
    background: var(--Primary, #9ca040);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
    margin: 0 auto;
    border: 1px solid var(--Line);
}

.info .name {
    margin-bottom: 8px;
}

.type-price {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.broker-type {
    background: rgba(156, 160, 64, 0.1);
    color: var(--Primary);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 1rem;
    font-weight: 600;
    border: 1px solid var(--Primary);
}

.price-range {
    color: var(--Text-3);
    font-size: 1.4rem;
    font-weight: 700;
}

.location-container {
    margin-top: 0;
    margin-bottom: 16px;
}

.location {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 0;
}

.location i {
    color: var(--Primary);
    margin-top: 2px;
    flex-shrink: 0;
}

.location-list {
    color: var(--Note);
    line-height: 1.4;
    font-size: 1.1rem;
}

.broker-details {
    margin: 0;
}

.specialties {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 0;
}

.specialty-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--Background-1);
    color: var(--Text-2);
    padding: 12px 20px;
    border-radius: 25px;
    font-size: 1.2rem;
    font-weight: 600;
    border: 1px solid var(--Line);
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.specialty-item:hover {
    background: var(--Primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(156, 160, 64, 0.3);
}

.specialty-item i {
    color: var(--Primary);
    font-size: 1.3rem;
    transition: color 0.3s ease;
}

.specialty-item:hover i {
    color: white;
}

.specialty-icon {
    width: 16px;
    height: 16px;
    filter: brightness(0) saturate(100%) invert(0%) sepia(0%) saturate(0%) hue-rotate(0deg) brightness(0%) contrast(100%);
    transition: filter 0.3s ease;
}

.specialty-item:hover .specialty-icon {
    filter: brightness(0) saturate(100%) invert(100%) sepia(0%) saturate(0%) hue-rotate(0deg) brightness(100%) contrast(100%);
}

.discovery-card {
    background: linear-gradient(135deg, var(--Primary, #9ca040) 0%, #7a8332 100%);
    color: white;
    padding: 24px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(156, 160, 64, 0.3);
}

.discovery-card .star-icon {
    font-size: 2rem;
    margin-bottom: 12px;
    display: block;
}

.discovery-card h5 {
    margin-bottom: 12px;
    color: white;
    font-weight: 600;
}

.discovery-card p {
    margin-bottom: 20px;
    opacity: 0.9;
    line-height: 1.5;
}

.discovery-card .tf-btn {
    background: white;
    color: var(--Primary, #9ca040);
    border: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.discovery-card .tf-btn:hover {
    background: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.loading-spinner {
    text-align: center;
    padding: 60px 20px;
}

.spinner-border {
    width: 3rem;
    height: 3rem;
    border: 0.3em solid rgba(156, 160, 64, 0.2);
    border-radius: 50%;
    border-top: 0.3em solid var(--Primary, #9ca040);
    animation: spin 1s linear infinite;
}

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

    100% {
        transform: rotate(360deg);
    }
}

.wg-pagination button {
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.wg-pagination button:hover {
    background: #f8f9fa;
}

.wg-pagination .disabled button {
    opacity: 0.5;
    cursor: not-allowed;
}

.wg-pagination .disabled button:hover {
    background: none;
}

/* Contact section and button alignment */
.agencies-item .contact {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
    width: 100%;
}

.agencies-item .btn-group {
    display: flex;
    gap: 10px;
    align-items: center;
}

.agencies-item .btn-group .tf-btn {
    min-width: 80px;
    text-align: center;
}

/* Full width divider line above contact buttons */
.agencies-item .contact::before {
    content: "";
    position: absolute;
    left: -30px;
    right: -30px;
    top: -10px;
    height: 1px;
    background: var(--Line);
}

.agencies-item {
    position: relative;
}

.agencies-item .content {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.agencies-item .info {
    flex: 1;
}

/* Responsive styles */
@media (max-width: 768px) {
    .type-price {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .broker-type {
        font-size: 0.9rem;
        padding: 4px 12px;
    }

    .specialties {
        gap: 8px;
    }

    .specialty-item {
        font-size: 0.9rem;
        padding: 8px 14px;
    }

    .location-list {
        font-size: 1.1rem;
    }

    /* Maintain right alignment on mobile */
    .agencies-item .contact {
        margin-top: 16px;
    }

    .agencies-item .btn-group {
        gap: 8px;
    }

    .agencies-item .btn-group .tf-btn {
        min-width: 70px;
        font-size: 0.9rem;
        padding: 8px 12px;
    }

    /* Adjust divider for mobile padding */
    .agencies-item .contact::before {
        left: -20px;
        right: -20px;
    }
}